Skip to content

Commit

Permalink
Merge tag 'cris-for-4.3' of git://git.kernel.org/pub/scm/linux/kernel…
Browse files Browse the repository at this point in the history
…/git/jesper/cris

Pull CRIS updates from Jesper Nilsson:
 "Mostly removal of old cruft of which we can use a generic version, or
  fixes for code not commonly run in the cris port, but also additions
  to enable some good debug"

* tag 'cris-for-4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/jesper/cris: (25 commits)
  CRISv10: delete unused lib/dmacopy.c
  CRISv10: delete unused lib/old_checksum.c
  CRIS: fix switch_mm() lockdep splat
  CRISv32: enable LOCKDEP_SUPPORT
  CRIS: add STACKTRACE_SUPPORT
  CRISv32: annotate irq enable in idle loop
  CRISv32: add support for irqflags tracing
  CRIS: UAPI: use generic types.h
  CRIS: UAPI: use generic shmbuf.h
  CRIS: UAPI: use generic msgbuf.h
  CRIS: UAPI: use generic socket.h
  CRIS: UAPI: use generic sembuf.h
  CRIS: UAPI: use generic sockios.h
  CRIS: UAPI: use generic auxvec.h
  CRIS: UAPI: use generic headers via Kbuild
  CRIS: UAPI: fix elf.h export
  CRIS: don't make asm/elf.h depend on asm/user.h
  CRIS: UAPI: fix ptrace.h
  CRISv32: Squash compile warnings for axisflashmap
  CRISv32: Add GPIO driver to the default configs
  ...
  • Loading branch information
torvalds committed Sep 12, 2015
2 parents 10fbd36 + 254a0f4 commit 6917b51
Show file tree
Hide file tree
Showing 50 changed files with 220 additions and 421 deletions.
12 changes: 12 additions & 0 deletions arch/cris/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,17 @@ config FORCE_MAX_ZONEORDER
int
default 6

config TRACE_IRQFLAGS_SUPPORT
depends on ETRAX_ARCH_V32
def_bool y

config STACKTRACE_SUPPORT
def_bool y

config LOCKDEP_SUPPORT
depends on ETRAX_ARCH_V32
def_bool y

config CRIS
bool
default y
Expand All @@ -58,6 +69,7 @@ config CRIS
select CLKSRC_MMIO if ETRAX_ARCH_V32
select GENERIC_CLOCKEVENTS if ETRAX_ARCH_V32
select GENERIC_SCHED_CLOCK if ETRAX_ARCH_V32
select HAVE_DEBUG_BUGVERBOSE if ETRAX_ARCH_V32

config HZ
int
Expand Down
8 changes: 8 additions & 0 deletions arch/cris/arch-v10/kernel/entry.S
Original file line number Diff line number Diff line change
Expand Up @@ -955,6 +955,14 @@ sys_call_table:
.long sys_process_vm_writev
.long sys_kcmp /* 350 */
.long sys_finit_module
.long sys_sched_setattr
.long sys_sched_getattr
.long sys_renameat2
.long sys_seccomp /* 355 */
.long sys_getrandom
.long sys_memfd_create
.long sys_bpf
.long sys_execveat

/*
* NOTE!! This doesn't have to be exact - we just have
Expand Down
42 changes: 0 additions & 42 deletions arch/cris/arch-v10/lib/dmacopy.c

This file was deleted.

86 changes: 0 additions & 86 deletions arch/cris/arch-v10/lib/old_checksum.c

This file was deleted.

16 changes: 8 additions & 8 deletions arch/cris/arch-v32/drivers/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ config ETRAX_PA_CHANGEABLE_DIR
default "0x00" if ETRAXFS
default "0x00000000" if !ETRAXFS
help
This is a bitmask (8 bits) with information of what bits in PA that a
This is a bitmask with information of what bits in PA that a
user can change direction on using ioctl's.
Bit set = changeable.
You probably want 0 here, but it depends on your hardware.
Expand All @@ -213,7 +213,7 @@ config ETRAX_PA_CHANGEABLE_BITS
default "0x00" if ETRAXFS
default "0x00000000" if !ETRAXFS
help
This is a bitmask (8 bits) with information of what bits in PA
This is a bitmask with information of what bits in PA
that a user can change the value on using ioctl's.
Bit set = changeable.

Expand All @@ -223,7 +223,7 @@ config ETRAX_PB_CHANGEABLE_DIR
default "0x00000" if ETRAXFS
default "0x00000000" if !ETRAXFS
help
This is a bitmask (18 bits) with information of what bits in PB
This is a bitmask with information of what bits in PB
that a user can change direction on using ioctl's.
Bit set = changeable.
You probably want 0 here, but it depends on your hardware.
Expand All @@ -234,7 +234,7 @@ config ETRAX_PB_CHANGEABLE_BITS
default "0x00000" if ETRAXFS
default "0x00000000" if !ETRAXFS
help
This is a bitmask (18 bits) with information of what bits in PB
This is a bitmask with information of what bits in PB
that a user can change the value on using ioctl's.
Bit set = changeable.

Expand All @@ -244,7 +244,7 @@ config ETRAX_PC_CHANGEABLE_DIR
default "0x00000" if ETRAXFS
default "0x00000000" if !ETRAXFS
help
This is a bitmask (18 bits) with information of what bits in PC
This is a bitmask with information of what bits in PC
that a user can change direction on using ioctl's.
Bit set = changeable.
You probably want 0 here, but it depends on your hardware.
Expand All @@ -253,9 +253,9 @@ config ETRAX_PC_CHANGEABLE_BITS
hex "PC user changeable bits mask"
depends on ETRAX_GPIO
default "0x00000" if ETRAXFS
default "0x00000000" if ETRAXFS
default "0x00000000" if !ETRAXFS
help
This is a bitmask (18 bits) with information of what bits in PC
This is a bitmask with information of what bits in PC
that a user can change the value on using ioctl's.
Bit set = changeable.

Expand All @@ -264,7 +264,7 @@ config ETRAX_PD_CHANGEABLE_DIR
depends on ETRAX_GPIO && ETRAXFS
default "0x00000"
help
This is a bitmask (18 bits) with information of what bits in PD
This is a bitmask with information of what bits in PD
that a user can change direction on using ioctl's.
Bit set = changeable.
You probably want 0x00000 here, but it depends on your hardware.
Expand Down
9 changes: 5 additions & 4 deletions arch/cris/arch-v32/drivers/axisflashmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,7 @@ static int __init init_axis_flash(void)
size_t len;
int ram_rootfs_partition = -1; /* -1 => no RAM rootfs partition */
int part;
struct mtd_partition *partition;

/* We need a root fs. If it resides in RAM, we need to use an
* MTDRAM device, so it must be enabled in the kernel config,
Expand All @@ -329,7 +330,7 @@ static int __init init_axis_flash(void)

main_mtd = flash_probe();
if (main_mtd)
printk(KERN_INFO "%s: 0x%08x bytes of NOR flash memory.\n",
printk(KERN_INFO "%s: 0x%08llx bytes of NOR flash memory.\n",
main_mtd->name, main_mtd->size);

#ifdef CONFIG_ETRAX_NANDFLASH
Expand Down Expand Up @@ -388,10 +389,10 @@ static int __init init_axis_flash(void)
#endif

if (main_mtd) {
loff_t ptable_sector = CONFIG_ETRAX_PTABLE_SECTOR;
main_mtd->owner = THIS_MODULE;
axisflash_mtd = main_mtd;

loff_t ptable_sector = CONFIG_ETRAX_PTABLE_SECTOR;

/* First partition (rescue) is always set to the default. */
pidx++;
Expand Down Expand Up @@ -517,7 +518,7 @@ static int __init init_axis_flash(void)
/* Decide whether to use default partition table. */
/* Only use default table if we actually have a device (main_mtd) */

struct mtd_partition *partition = &axis_partitions[0];
partition = &axis_partitions[0];
if (main_mtd && !ptable_ok) {
memcpy(axis_partitions, axis_default_partitions,
sizeof(axis_default_partitions));
Expand Down Expand Up @@ -580,7 +581,7 @@ static int __init init_axis_flash(void)
printk(KERN_INFO "axisflashmap: Adding RAM partition "
"for rootfs image.\n");
err = mtdram_init_device(mtd_ram,
(void *)partition[part].offset,
(void *)(u_int32_t)partition[part].offset,
partition[part].size,
partition[part].name);
if (err)
Expand Down
4 changes: 2 additions & 2 deletions arch/cris/arch-v32/drivers/mach-a3/gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -957,7 +957,7 @@ static void __init virtual_gpio_init(void)

static int __init gpio_init(void)
{
int res;
int res, res2;

printk(KERN_INFO "ETRAX FS GPIO driver v2.7, (c) 2003-2008 "
"Axis Communications AB\n");
Expand All @@ -977,7 +977,7 @@ static int __init gpio_init(void)
CRIS_LED_DISK_READ(0);
CRIS_LED_DISK_WRITE(0);

int res2 = request_irq(GIO_INTR_VECT, gpio_interrupt,
res2 = request_irq(GIO_INTR_VECT, gpio_interrupt,
IRQF_SHARED, "gpio", &alarmlist);
if (res2) {
printk(KERN_ERR "err: irq for gpio\n");
Expand Down
3 changes: 1 addition & 2 deletions arch/cris/arch-v32/drivers/mach-fs/gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -425,12 +425,11 @@ gpio_open(struct inode *inode, struct file *filp)
if (p > GPIO_MINOR_LAST)
return -EINVAL;

priv = kmalloc(sizeof(struct gpio_private), GFP_KERNEL);
priv = kzalloc(sizeof(struct gpio_private), GFP_KERNEL);
if (!priv)
return -ENOMEM;

mutex_lock(&gpio_mutex);
memset(priv, 0, sizeof(*priv));

priv->minor = p;

Expand Down
19 changes: 19 additions & 0 deletions arch/cris/arch-v32/kernel/entry.S
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,17 @@ ret_from_sys_call:

.type _Rexit,@function
_Rexit:
#if defined(CONFIG_TRACE_IRQFLAGS)
addoq +PT_ccs, $sp, $acr
move.d [$acr], $r0
btstq 15, $r0 ; I1
bpl 1f
nop
jsr trace_hardirqs_on
nop
1:
#endif

;; This epilogue MUST match the prologues in multiple_interrupt, irq.h
;; and ptregs.h.
addq 4, $sp ; Skip orig_r10.
Expand Down Expand Up @@ -875,6 +886,14 @@ sys_call_table:
.long sys_process_vm_writev
.long sys_kcmp /* 350 */
.long sys_finit_module
.long sys_sched_setattr
.long sys_sched_getattr
.long sys_renameat2
.long sys_seccomp /* 355 */
.long sys_getrandom
.long sys_memfd_create
.long sys_bpf
.long sys_execveat

/*
* NOTE!! This doesn't have to be exact - we just have
Expand Down
4 changes: 2 additions & 2 deletions arch/cris/arch-v32/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ extern void stop_watchdog(void);
/* We use this if we don't have any better idle routine. */
void default_idle(void)
{
local_irq_enable();
/* Halt until exception. */
__asm__ volatile("ei \n\t"
"halt ");
__asm__ volatile("halt");
}

/*
Expand Down
1 change: 0 additions & 1 deletion arch/cris/arch-v32/kernel/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include <asm/processor.h>
#include <asm/ucontext.h>
#include <asm/uaccess.h>
#include <arch/ptrace.h>
#include <arch/hwregs/cpu_vect.h>

extern unsigned long cris_signal_return_page;
Expand Down
Loading

0 comments on commit 6917b51

Please sign in to comment.