Skip to content

Commit 669bb4c

Browse files
committed
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32
Pull AVR32 updates from Hans-Christian Noren Egtvedt. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32: avr32: wire up pkey syscalls AVR32-pio: Replace two seq_printf() calls by seq_puts() in pio_bank_show() AVR32-pio: Use seq_putc() in pio_bank_show() AVR32-clock: Combine nine seq_printf() calls into one call in clk_show() AVR32-clock: Use seq_putc() in two functions
2 parents 0261b5d + 8712a5b commit 669bb4c

File tree

4 files changed

+30
-15
lines changed

4 files changed

+30
-15
lines changed

arch/avr32/include/uapi/asm/unistd.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -340,5 +340,8 @@
340340
#define __NR_copy_file_range 325
341341
#define __NR_preadv2 326
342342
#define __NR_pwritev2 327
343+
#define __NR_pkey_mprotect 328
344+
#define __NR_pkey_alloc 329
345+
#define __NR_pkey_free 330
343346

344347
#endif /* _UAPI__ASM_AVR32_UNISTD_H */

arch/avr32/kernel/syscall_table.S

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,4 +341,7 @@ sys_call_table:
341341
.long __sys_copy_file_range
342342
.long __sys_preadv2
343343
.long __sys_pwritev2
344+
.long sys_pkey_mprotect
345+
.long sys_pkey_alloc
346+
.long sys_pkey_free /* 330 */
344347
.long sys_ni_syscall /* r8 is saturated at nr_syscalls */

arch/avr32/mach-at32ap/clock.c

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ dump_clock(struct clk *parent, struct clkinf *r)
242242
clk_get_rate(parent));
243243
if (parent->dev)
244244
seq_printf(r->s, ", for %s", dev_name(parent->dev));
245-
seq_printf(r->s, "\n");
245+
seq_putc(r->s, '\n');
246246

247247
/* cost of this scan is small, but not linear... */
248248
r->nest = nest + NEST_DELTA;
@@ -261,23 +261,32 @@ static int clk_show(struct seq_file *s, void *unused)
261261
struct clk *clk;
262262

263263
/* show all the power manager registers */
264-
seq_printf(s, "MCCTRL = %8x\n", pm_readl(MCCTRL));
265-
seq_printf(s, "CKSEL = %8x\n", pm_readl(CKSEL));
266-
seq_printf(s, "CPUMASK = %8x\n", pm_readl(CPU_MASK));
267-
seq_printf(s, "HSBMASK = %8x\n", pm_readl(HSB_MASK));
268-
seq_printf(s, "PBAMASK = %8x\n", pm_readl(PBA_MASK));
269-
seq_printf(s, "PBBMASK = %8x\n", pm_readl(PBB_MASK));
270-
seq_printf(s, "PLL0 = %8x\n", pm_readl(PLL0));
271-
seq_printf(s, "PLL1 = %8x\n", pm_readl(PLL1));
272-
seq_printf(s, "IMR = %8x\n", pm_readl(IMR));
264+
seq_printf(s,
265+
"MCCTRL = %8x\n"
266+
"CKSEL = %8x\n"
267+
"CPUMASK = %8x\n"
268+
"HSBMASK = %8x\n"
269+
"PBAMASK = %8x\n"
270+
"PBBMASK = %8x\n"
271+
"PLL0 = %8x\n"
272+
"PLL1 = %8x\n"
273+
"IMR = %8x\n",
274+
pm_readl(MCCTRL),
275+
pm_readl(CKSEL),
276+
pm_readl(CPU_MASK),
277+
pm_readl(HSB_MASK),
278+
pm_readl(PBA_MASK),
279+
pm_readl(PBB_MASK),
280+
pm_readl(PLL0),
281+
pm_readl(PLL1),
282+
pm_readl(IMR));
273283
for (i = 0; i < 8; i++) {
274284
if (i == 5)
275285
continue;
276286
seq_printf(s, "GCCTRL%d = %8x\n", i, pm_readl(GCCTRL(i)));
277287
}
278288

279-
seq_printf(s, "\n");
280-
289+
seq_putc(s, '\n');
281290
r.s = s;
282291
r.nest = 0;
283292
/* protected from changes on the list while dumping */

arch/avr32/mach-at32ap/pio.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -367,13 +367,13 @@ static void pio_bank_show(struct seq_file *s, struct gpio_chip *chip)
367367
(mask & pdsr) ? "hi" : "lo",
368368
(mask & pusr) ? " " : "up");
369369
if (ifsr & mask)
370-
seq_printf(s, " deglitch");
370+
seq_puts(s, " deglitch");
371371
if ((osr & mdsr) & mask)
372-
seq_printf(s, " open-drain");
372+
seq_puts(s, " open-drain");
373373
if (imr & mask)
374374
seq_printf(s, " irq-%d edge-both",
375375
gpio_to_irq(chip->base + i));
376-
seq_printf(s, "\n");
376+
seq_putc(s, '\n');
377377
}
378378
}
379379

0 commit comments

Comments
 (0)