Skip to content

Commit e216015

Browse files
committed
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
All merge conflicts were simple overlapping changes. Signed-off-by: David S. Miller <davem@davemloft.net>
2 parents 62e1309 + 6d04dfc commit e216015

105 files changed

Lines changed: 1186 additions & 643 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎Documentation/devicetree/bindings/interrupt-controller/snps,archs-idu-intc.txt‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ Properties:
1515
Second cell specifies the irq distribution mode to cores
1616
0=Round Robin; 1=cpu0, 2=cpu1, 4=cpu2, 8=cpu3
1717

18+
The second cell in interrupts property is deprecated and may be ignored by
19+
the kernel.
20+
1821
intc accessed via the special ARC AUX register interface, hence "reg" property
1922
is not specified.
2023

‎MAINTAINERS‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10208,7 +10208,6 @@ F: drivers/media/tuners/qt1010*
1020810208
QUALCOMM ATHEROS ATH9K WIRELESS DRIVER
1020910209
M: QCA ath9k Development <ath9k-devel@qca.qualcomm.com>
1021010210
L: linux-wireless@vger.kernel.org
10211-
L: ath9k-devel@lists.ath9k.org
1021210211
W: http://wireless.kernel.org/en/users/Drivers/ath9k
1021310212
S: Supported
1021410213
F: drivers/net/wireless/ath/ath9k/

‎Makefile‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
VERSION = 4
22
PATCHLEVEL = 10
33
SUBLEVEL = 0
4-
EXTRAVERSION = -rc5
5-
NAME = Anniversary Edition
4+
EXTRAVERSION = -rc6
5+
NAME = Fearless Coyote
66

77
# *DOCUMENTATION*
88
# To see a list of typical targets execute "make help"

‎arch/arc/include/asm/delay.h‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,9 @@ static inline void __delay(unsigned long loops)
2626
" lp 1f \n"
2727
" nop \n"
2828
"1: \n"
29-
: : "r"(loops));
29+
:
30+
: "r"(loops)
31+
: "lp_count");
3032
}
3133

3234
extern void __bad_udelay(void);

‎arch/arc/kernel/head.S‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -71,14 +71,14 @@ ENTRY(stext)
7171
GET_CPU_ID r5
7272
cmp r5, 0
7373
mov.nz r0, r5
74-
#ifdef CONFIG_ARC_SMP_HALT_ON_RESET
75-
; Non-Master can proceed as system would be booted sufficiently
76-
jnz first_lines_of_secondary
77-
#else
74+
bz .Lmaster_proceed
75+
7876
; Non-Masters wait for Master to boot enough and bring them up
79-
jnz arc_platform_smp_wait_to_boot
80-
#endif
81-
; Master falls thru
77+
; when they resume, tail-call to entry point
78+
mov blink, @first_lines_of_secondary
79+
j arc_platform_smp_wait_to_boot
80+
81+
.Lmaster_proceed:
8282
#endif
8383

8484
; Clear BSS before updating any globals

‎arch/arc/kernel/mcip.c‎

Lines changed: 23 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -93,11 +93,10 @@ static void mcip_probe_n_setup(void)
9393
READ_BCR(ARC_REG_MCIP_BCR, mp);
9494

9595
sprintf(smp_cpuinfo_buf,
96-
"Extn [SMP]\t: ARConnect (v%d): %d cores with %s%s%s%s%s\n",
96+
"Extn [SMP]\t: ARConnect (v%d): %d cores with %s%s%s%s\n",
9797
mp.ver, mp.num_cores,
9898
IS_AVAIL1(mp.ipi, "IPI "),
9999
IS_AVAIL1(mp.idu, "IDU "),
100-
IS_AVAIL1(mp.llm, "LLM "),
101100
IS_AVAIL1(mp.dbg, "DEBUG "),
102101
IS_AVAIL1(mp.gfrc, "GFRC"));
103102

@@ -175,7 +174,6 @@ static void idu_irq_unmask(struct irq_data *data)
175174
raw_spin_unlock_irqrestore(&mcip_lock, flags);
176175
}
177176

178-
#ifdef CONFIG_SMP
179177
static int
180178
idu_irq_set_affinity(struct irq_data *data, const struct cpumask *cpumask,
181179
bool force)
@@ -205,12 +203,27 @@ idu_irq_set_affinity(struct irq_data *data, const struct cpumask *cpumask,
205203

206204
return IRQ_SET_MASK_OK;
207205
}
208-
#endif
206+
207+
static void idu_irq_enable(struct irq_data *data)
208+
{
209+
/*
210+
* By default send all common interrupts to all available online CPUs.
211+
* The affinity of common interrupts in IDU must be set manually since
212+
* in some cases the kernel will not call irq_set_affinity() by itself:
213+
* 1. When the kernel is not configured with support of SMP.
214+
* 2. When the kernel is configured with support of SMP but upper
215+
* interrupt controllers does not support setting of the affinity
216+
* and cannot propagate it to IDU.
217+
*/
218+
idu_irq_set_affinity(data, cpu_online_mask, false);
219+
idu_irq_unmask(data);
220+
}
209221

210222
static struct irq_chip idu_irq_chip = {
211223
.name = "MCIP IDU Intc",
212224
.irq_mask = idu_irq_mask,
213225
.irq_unmask = idu_irq_unmask,
226+
.irq_enable = idu_irq_enable,
214227
#ifdef CONFIG_SMP
215228
.irq_set_affinity = idu_irq_set_affinity,
216229
#endif
@@ -243,36 +256,14 @@ static int idu_irq_xlate(struct irq_domain *d, struct device_node *n,
243256
const u32 *intspec, unsigned int intsize,
244257
irq_hw_number_t *out_hwirq, unsigned int *out_type)
245258
{
246-
irq_hw_number_t hwirq = *out_hwirq = intspec[0];
247-
int distri = intspec[1];
248-
unsigned long flags;
249-
259+
/*
260+
* Ignore value of interrupt distribution mode for common interrupts in
261+
* IDU which resides in intspec[1] since setting an affinity using value
262+
* from Device Tree is deprecated in ARC.
263+
*/
264+
*out_hwirq = intspec[0];
250265
*out_type = IRQ_TYPE_NONE;
251266

252-
/* XXX: validate distribution scheme again online cpu mask */
253-
if (distri == 0) {
254-
/* 0 - Round Robin to all cpus, otherwise 1 bit per core */
255-
raw_spin_lock_irqsave(&mcip_lock, flags);
256-
idu_set_dest(hwirq, BIT(num_online_cpus()) - 1);
257-
idu_set_mode(hwirq, IDU_M_TRIG_LEVEL, IDU_M_DISTRI_RR);
258-
raw_spin_unlock_irqrestore(&mcip_lock, flags);
259-
} else {
260-
/*
261-
* DEST based distribution for Level Triggered intr can only
262-
* have 1 CPU, so generalize it to always contain 1 cpu
263-
*/
264-
int cpu = ffs(distri);
265-
266-
if (cpu != fls(distri))
267-
pr_warn("IDU irq %lx distri mode set to cpu %x\n",
268-
hwirq, cpu);
269-
270-
raw_spin_lock_irqsave(&mcip_lock, flags);
271-
idu_set_dest(hwirq, cpu);
272-
idu_set_mode(hwirq, IDU_M_TRIG_LEVEL, IDU_M_DISTRI_DEST);
273-
raw_spin_unlock_irqrestore(&mcip_lock, flags);
274-
}
275-
276267
return 0;
277268
}
278269

‎arch/arc/kernel/smp.c‎

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -90,22 +90,37 @@ void __init smp_cpus_done(unsigned int max_cpus)
9090
*/
9191
static volatile int wake_flag;
9292

93+
#ifdef CONFIG_ISA_ARCOMPACT
94+
95+
#define __boot_read(f) f
96+
#define __boot_write(f, v) f = v
97+
98+
#else
99+
100+
#define __boot_read(f) arc_read_uncached_32(&f)
101+
#define __boot_write(f, v) arc_write_uncached_32(&f, v)
102+
103+
#endif
104+
93105
static void arc_default_smp_cpu_kick(int cpu, unsigned long pc)
94106
{
95107
BUG_ON(cpu == 0);
96-
wake_flag = cpu;
108+
109+
__boot_write(wake_flag, cpu);
97110
}
98111

99112
void arc_platform_smp_wait_to_boot(int cpu)
100113
{
101-
while (wake_flag != cpu)
114+
/* for halt-on-reset, we've waited already */
115+
if (IS_ENABLED(CONFIG_ARC_SMP_HALT_ON_RESET))
116+
return;
117+
118+
while (__boot_read(wake_flag) != cpu)
102119
;
103120

104-
wake_flag = 0;
105-
__asm__ __volatile__("j @first_lines_of_secondary \n");
121+
__boot_write(wake_flag, 0);
106122
}
107123

108-
109124
const char *arc_platform_smp_cpuinfo(void)
110125
{
111126
return plat_smp_ops.info ? : "";

‎arch/arc/kernel/unaligned.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,8 +241,9 @@ int misaligned_fixup(unsigned long address, struct pt_regs *regs,
241241
if (state.fault)
242242
goto fault;
243243

244+
/* clear any remanants of delay slot */
244245
if (delay_mode(regs)) {
245-
regs->ret = regs->bta;
246+
regs->ret = regs->bta ~1U;
246247
regs->status32 &= ~STATUS_DE_MASK;
247248
} else {
248249
regs->ret += state.instr_len;

‎arch/arm64/crypto/aes-modes.S‎

Lines changed: 42 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -193,15 +193,16 @@ AES_ENTRY(aes_cbc_encrypt)
193193
cbz w6, .Lcbcencloop
194194

195195
ld1 {v0.16b}, [x5] /* get iv */
196-
enc_prepare w3, x2, x5
196+
enc_prepare w3, x2, x6
197197

198198
.Lcbcencloop:
199199
ld1 {v1.16b}, [x1], #16 /* get next pt block */
200200
eor v0.16b, v0.16b, v1.16b /* ..and xor with iv */
201-
encrypt_block v0, w3, x2, x5, w6
201+
encrypt_block v0, w3, x2, x6, w7
202202
st1 {v0.16b}, [x0], #16
203203
subs w4, w4, #1
204204
bne .Lcbcencloop
205+
st1 {v0.16b}, [x5] /* return iv */
205206
ret
206207
AES_ENDPROC(aes_cbc_encrypt)
207208

@@ -211,7 +212,7 @@ AES_ENTRY(aes_cbc_decrypt)
211212
cbz w6, .LcbcdecloopNx
212213

213214
ld1 {v7.16b}, [x5] /* get iv */
214-
dec_prepare w3, x2, x5
215+
dec_prepare w3, x2, x6
215216

216217
.LcbcdecloopNx:
217218
#if INTERLEAVE >= 2
@@ -248,14 +249,15 @@ AES_ENTRY(aes_cbc_decrypt)
248249
.Lcbcdecloop:
249250
ld1 {v1.16b}, [x1], #16 /* get next ct block */
250251
mov v0.16b, v1.16b /* ...and copy to v0 */
251-
decrypt_block v0, w3, x2, x5, w6
252+
decrypt_block v0, w3, x2, x6, w7
252253
eor v0.16b, v0.16b, v7.16b /* xor with iv => pt */
253254
mov v7.16b, v1.16b /* ct is next iv */
254255
st1 {v0.16b}, [x0], #16
255256
subs w4, w4, #1
256257
bne .Lcbcdecloop
257258
.Lcbcdecout:
258259
FRAME_POP
260+
st1 {v7.16b}, [x5] /* return iv */
259261
ret
260262
AES_ENDPROC(aes_cbc_decrypt)
261263

@@ -267,36 +269,27 @@ AES_ENDPROC(aes_cbc_decrypt)
267269

268270
AES_ENTRY(aes_ctr_encrypt)
269271
FRAME_PUSH
270-
cbnz w6, .Lctrfirst /* 1st time around? */
271-
umov x5, v4.d[1] /* keep swabbed ctr in reg */
272-
rev x5, x5
273-
#if INTERLEAVE >= 2
274-
cmn w5, w4 /* 32 bit overflow? */
275-
bcs .Lctrinc
276-
add x5, x5, #1 /* increment BE ctr */
277-
b .LctrincNx
278-
#else
279-
b .Lctrinc
280-
#endif
281-
.Lctrfirst:
272+
cbz w6, .Lctrnotfirst /* 1st time around? */
282273
enc_prepare w3, x2, x6
283274
ld1 {v4.16b}, [x5]
284-
umov x5, v4.d[1] /* keep swabbed ctr in reg */
285-
rev x5, x5
275+
276+
.Lctrnotfirst:
277+
umov x8, v4.d[1] /* keep swabbed ctr in reg */
278+
rev x8, x8
286279
#if INTERLEAVE >= 2
287-
cmn w5, w4 /* 32 bit overflow? */
280+
cmn w8, w4 /* 32 bit overflow? */
288281
bcs .Lctrloop
289282
.LctrloopNx:
290283
subs w4, w4, #INTERLEAVE
291284
bmi .Lctr1x
292285
#if INTERLEAVE == 2
293286
mov v0.8b, v4.8b
294287
mov v1.8b, v4.8b
295-
rev x7, x5
296-
add x5, x5, #1
288+
rev x7, x8
289+
add x8, x8, #1
297290
ins v0.d[1], x7
298-
rev x7, x5
299-
add x5, x5, #1
291+
rev x7, x8
292+
add x8, x8, #1
300293
ins v1.d[1], x7
301294
ld1 {v2.16b-v3.16b}, [x1], #32 /* get 2 input blocks */
302295
do_encrypt_block2x
@@ -305,7 +298,7 @@ AES_ENTRY(aes_ctr_encrypt)
305298
st1 {v0.16b-v1.16b}, [x0], #32
306299
#else
307300
ldr q8, =0x30000000200000001 /* addends 1,2,3[,0] */
308-
dup v7.4s, w5
301+
dup v7.4s, w8
309302
mov v0.16b, v4.16b
310303
add v7.4s, v7.4s, v8.4s
311304
mov v1.16b, v4.16b
@@ -323,49 +316,52 @@ AES_ENTRY(aes_ctr_encrypt)
323316
eor v2.16b, v7.16b, v2.16b
324317
eor v3.16b, v5.16b, v3.16b
325318
st1 {v0.16b-v3.16b}, [x0], #64
326-
add x5, x5, #INTERLEAVE
319+
add x8, x8, #INTERLEAVE
327320
#endif
328-
cbz w4, .LctroutNx
329-
.LctrincNx:
330-
rev x7, x5
321+
rev x7, x8
331322
ins v4.d[1], x7
323+
cbz w4, .Lctrout
332324
b .LctrloopNx
333-
.LctroutNx:
334-
sub x5, x5, #1
335-
rev x7, x5
336-
ins v4.d[1], x7
337-
b .Lctrout
338325
.Lctr1x:
339326
adds w4, w4, #INTERLEAVE
340327
beq .Lctrout
341328
#endif
342329
.Lctrloop:
343330
mov v0.16b, v4.16b
344331
encrypt_block v0, w3, x2, x6, w7
332+
333+
adds x8, x8, #1 /* increment BE ctr */
334+
rev x7, x8
335+
ins v4.d[1], x7
336+
bcs .Lctrcarry /* overflow? */
337+
338+
.Lctrcarrydone:
345339
subs w4, w4, #1
346340
bmi .Lctrhalfblock /* blocks < 0 means 1/2 block */
347341
ld1 {v3.16b}, [x1], #16
348342
eor v3.16b, v0.16b, v3.16b
349343
st1 {v3.16b}, [x0], #16
350-
beq .Lctrout
351-
.Lctrinc:
352-
adds x5, x5, #1 /* increment BE ctr */
353-
rev x7, x5
354-
ins v4.d[1], x7
355-
bcc .Lctrloop /* no overflow? */
356-
umov x7, v4.d[0] /* load upper word of ctr */
357-
rev x7, x7 /* ... to handle the carry */
358-
add x7, x7, #1
359-
rev x7, x7
360-
ins v4.d[0], x7
361-
b .Lctrloop
344+
bne .Lctrloop
345+
346+
.Lctrout:
347+
st1 {v4.16b}, [x5] /* return next CTR value */
348+
FRAME_POP
349+
ret
350+
362351
.Lctrhalfblock:
363352
ld1 {v3.8b}, [x1]
364353
eor v3.8b, v0.8b, v3.8b
365354
st1 {v3.8b}, [x0]
366-
.Lctrout:
367355
FRAME_POP
368356
ret
357+
358+
.Lctrcarry:
359+
umov x7, v4.d[0] /* load upper word of ctr */
360+
rev x7, x7 /* ... to handle the carry */
361+
add x7, x7, #1
362+
rev x7, x7
363+
ins v4.d[0], x7
364+
b .Lctrcarrydone
369365
AES_ENDPROC(aes_ctr_encrypt)
370366
.ltorg
371367

0 commit comments

Comments
 (0)