diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-11-15 17:26:38 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-11-15 17:26:38 -0500 |
| commit | 98d38dd2ee30322fc9934d7490be3c5bee80950e (patch) | |
| tree | a65a3ccb525156f1dd5ffdc7286eddcfd33d3c5e | |
| parent | e4528d696f0fbb8eda231e2696b9ce0660f1e814 (diff) | |
| parent | 621c2cd853fca98258b720d9fe7e8c031ec7f96f (diff) | |
Merge tag 'for-3.13' of git://git.openrisc.net/~jonas/linux
Pull OpenRISC updates from Jonas Bonn:
- small cleanups to make allmodconfig pass
- defconfig refresh
- a handful of code sanitization patches
* tag 'for-3.13' of git://git.openrisc.net/~jonas/linux:
openrisc: Refactor or32_early_setup()
openrisc: Remove unused declaration of __initramfs_start
openrisc: Use the declarations provided by <asm/sections.h>
openrisc: Refresh or1ksim_defconfig for v3.12
openrisc: Refactor 16-bit constant relocation
openrisc: include: asm: Kbuild: add default "vga.h"
openrisc: Makefile: append "-D__linux__" to KBUILD_CFLAGS
| -rw-r--r-- | arch/openrisc/Makefile | 2 | ||||
| -rw-r--r-- | arch/openrisc/configs/or1ksim_defconfig | 10 | ||||
| -rw-r--r-- | arch/openrisc/include/asm/Kbuild | 1 | ||||
| -rw-r--r-- | arch/openrisc/kernel/module.c | 6 | ||||
| -rw-r--r-- | arch/openrisc/kernel/setup.c | 25 | ||||
| -rw-r--r-- | arch/openrisc/kernel/vmlinux.h | 2 |
6 files changed, 19 insertions, 27 deletions
diff --git a/arch/openrisc/Makefile b/arch/openrisc/Makefile index 4739b8302a58..89076a66eee2 100644 --- a/arch/openrisc/Makefile +++ b/arch/openrisc/Makefile | |||
| @@ -24,7 +24,7 @@ OBJCOPYFLAGS := -O binary -R .note -R .comment -S | |||
| 24 | LDFLAGS_vmlinux := | 24 | LDFLAGS_vmlinux := |
| 25 | LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name) | 25 | LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name) |
| 26 | 26 | ||
| 27 | KBUILD_CFLAGS += -pipe -ffixed-r10 | 27 | KBUILD_CFLAGS += -pipe -ffixed-r10 -D__linux__ |
| 28 | 28 | ||
| 29 | ifeq ($(CONFIG_OPENRISC_HAVE_INST_MUL),y) | 29 | ifeq ($(CONFIG_OPENRISC_HAVE_INST_MUL),y) |
| 30 | KBUILD_CFLAGS += $(call cc-option,-mhard-mul) | 30 | KBUILD_CFLAGS += $(call cc-option,-mhard-mul) |
diff --git a/arch/openrisc/configs/or1ksim_defconfig b/arch/openrisc/configs/or1ksim_defconfig index ea172bdfa36a..42fe5303a370 100644 --- a/arch/openrisc/configs/or1ksim_defconfig +++ b/arch/openrisc/configs/or1ksim_defconfig | |||
| @@ -1,9 +1,9 @@ | |||
| 1 | CONFIG_CROSS_COMPILE="or32-linux-" | 1 | CONFIG_CROSS_COMPILE="or32-linux-" |
| 2 | CONFIG_NO_HZ=y | ||
| 2 | CONFIG_LOG_BUF_SHIFT=14 | 3 | CONFIG_LOG_BUF_SHIFT=14 |
| 3 | CONFIG_BLK_DEV_INITRD=y | 4 | CONFIG_BLK_DEV_INITRD=y |
| 4 | # CONFIG_RD_GZIP is not set | 5 | # CONFIG_RD_GZIP is not set |
| 5 | CONFIG_EXPERT=y | 6 | CONFIG_EXPERT=y |
| 6 | # CONFIG_SYSCTL_SYSCALL is not set | ||
| 7 | # CONFIG_KALLSYMS is not set | 7 | # CONFIG_KALLSYMS is not set |
| 8 | # CONFIG_EPOLL is not set | 8 | # CONFIG_EPOLL is not set |
| 9 | # CONFIG_TIMERFD is not set | 9 | # CONFIG_TIMERFD is not set |
| @@ -15,7 +15,6 @@ CONFIG_SLOB=y | |||
| 15 | CONFIG_MODULES=y | 15 | CONFIG_MODULES=y |
| 16 | # CONFIG_BLOCK is not set | 16 | # CONFIG_BLOCK is not set |
| 17 | CONFIG_OPENRISC_BUILTIN_DTB="or1ksim" | 17 | CONFIG_OPENRISC_BUILTIN_DTB="or1ksim" |
| 18 | CONFIG_NO_HZ=y | ||
| 19 | CONFIG_HZ_100=y | 18 | CONFIG_HZ_100=y |
| 20 | CONFIG_NET=y | 19 | CONFIG_NET=y |
| 21 | CONFIG_PACKET=y | 20 | CONFIG_PACKET=y |
| @@ -39,11 +38,8 @@ CONFIG_DEVTMPFS_MOUNT=y | |||
| 39 | # CONFIG_FW_LOADER is not set | 38 | # CONFIG_FW_LOADER is not set |
| 40 | CONFIG_PROC_DEVICETREE=y | 39 | CONFIG_PROC_DEVICETREE=y |
| 41 | CONFIG_NETDEVICES=y | 40 | CONFIG_NETDEVICES=y |
| 42 | CONFIG_MICREL_PHY=y | ||
| 43 | CONFIG_NET_ETHERNET=y | ||
| 44 | CONFIG_ETHOC=y | 41 | CONFIG_ETHOC=y |
| 45 | # CONFIG_NETDEV_1000 is not set | 42 | CONFIG_MICREL_PHY=y |
| 46 | # CONFIG_NETDEV_10000 is not set | ||
| 47 | # CONFIG_WLAN is not set | 43 | # CONFIG_WLAN is not set |
| 48 | # CONFIG_INPUT is not set | 44 | # CONFIG_INPUT is not set |
| 49 | # CONFIG_SERIO is not set | 45 | # CONFIG_SERIO is not set |
| @@ -55,11 +51,9 @@ CONFIG_SERIAL_8250_CONSOLE=y | |||
| 55 | CONFIG_SERIAL_OF_PLATFORM=y | 51 | CONFIG_SERIAL_OF_PLATFORM=y |
| 56 | # CONFIG_HW_RANDOM is not set | 52 | # CONFIG_HW_RANDOM is not set |
| 57 | # CONFIG_HWMON is not set | 53 | # CONFIG_HWMON is not set |
| 58 | # CONFIG_MFD_SUPPORT is not set | ||
| 59 | # CONFIG_USB_SUPPORT is not set | 54 | # CONFIG_USB_SUPPORT is not set |
| 60 | # CONFIG_DNOTIFY is not set | 55 | # CONFIG_DNOTIFY is not set |
| 61 | CONFIG_TMPFS=y | 56 | CONFIG_TMPFS=y |
| 62 | CONFIG_NFS_FS=y | 57 | CONFIG_NFS_FS=y |
| 63 | CONFIG_NFS_V3=y | ||
| 64 | # CONFIG_ENABLE_WARN_DEPRECATED is not set | 58 | # CONFIG_ENABLE_WARN_DEPRECATED is not set |
| 65 | # CONFIG_ENABLE_MUST_CHECK is not set | 59 | # CONFIG_ENABLE_MUST_CHECK is not set |
diff --git a/arch/openrisc/include/asm/Kbuild b/arch/openrisc/include/asm/Kbuild index 78405625e799..da1951a22907 100644 --- a/arch/openrisc/include/asm/Kbuild +++ b/arch/openrisc/include/asm/Kbuild | |||
| @@ -65,6 +65,7 @@ generic-y += trace_clock.h | |||
| 65 | generic-y += types.h | 65 | generic-y += types.h |
| 66 | generic-y += ucontext.h | 66 | generic-y += ucontext.h |
| 67 | generic-y += user.h | 67 | generic-y += user.h |
| 68 | generic-y += vga.h | ||
| 68 | generic-y += word-at-a-time.h | 69 | generic-y += word-at-a-time.h |
| 69 | generic-y += xor.h | 70 | generic-y += xor.h |
| 70 | generic-y += preempt.h | 71 | generic-y += preempt.h |
diff --git a/arch/openrisc/kernel/module.c b/arch/openrisc/kernel/module.c index 10ff50f0202a..ef872ae4c878 100644 --- a/arch/openrisc/kernel/module.c +++ b/arch/openrisc/kernel/module.c | |||
| @@ -47,12 +47,10 @@ int apply_relocate_add(Elf32_Shdr *sechdrs, | |||
| 47 | *location = value; | 47 | *location = value; |
| 48 | break; | 48 | break; |
| 49 | case R_OR32_CONST: | 49 | case R_OR32_CONST: |
| 50 | location = (uint16_t *)location + 1; | 50 | *((uint16_t *)location + 1) = value; |
| 51 | *((uint16_t *)location) = (uint16_t) (value); | ||
| 52 | break; | 51 | break; |
| 53 | case R_OR32_CONSTH: | 52 | case R_OR32_CONSTH: |
| 54 | location = (uint16_t *)location + 1; | 53 | *((uint16_t *)location + 1) = value >> 16; |
| 55 | *((uint16_t *)location) = (uint16_t) (value >> 16); | ||
| 56 | break; | 54 | break; |
| 57 | case R_OR32_JUMPTARG: | 55 | case R_OR32_JUMPTARG: |
| 58 | value -= (uint32_t)location; | 56 | value -= (uint32_t)location; |
diff --git a/arch/openrisc/kernel/setup.c b/arch/openrisc/kernel/setup.c index 09a769b69572..4fc7ccc0a2cf 100644 --- a/arch/openrisc/kernel/setup.c +++ b/arch/openrisc/kernel/setup.c | |||
| @@ -40,6 +40,7 @@ | |||
| 40 | #include <linux/device.h> | 40 | #include <linux/device.h> |
| 41 | #include <linux/of_platform.h> | 41 | #include <linux/of_platform.h> |
| 42 | 42 | ||
| 43 | #include <asm/sections.h> | ||
| 43 | #include <asm/segment.h> | 44 | #include <asm/segment.h> |
| 44 | #include <asm/pgtable.h> | 45 | #include <asm/pgtable.h> |
| 45 | #include <asm/types.h> | 46 | #include <asm/types.h> |
| @@ -75,7 +76,7 @@ static unsigned long __init setup_memory(void) | |||
| 75 | 76 | ||
| 76 | ram_start_pfn = PFN_UP(memory_start); | 77 | ram_start_pfn = PFN_UP(memory_start); |
| 77 | /* free_ram_start_pfn is first page after kernel */ | 78 | /* free_ram_start_pfn is first page after kernel */ |
| 78 | free_ram_start_pfn = PFN_UP(__pa(&_end)); | 79 | free_ram_start_pfn = PFN_UP(__pa(_end)); |
| 79 | ram_end_pfn = PFN_DOWN(memblock_end_of_DRAM()); | 80 | ram_end_pfn = PFN_DOWN(memblock_end_of_DRAM()); |
| 80 | 81 | ||
| 81 | max_pfn = ram_end_pfn; | 82 | max_pfn = ram_end_pfn; |
| @@ -207,15 +208,15 @@ void __init setup_cpuinfo(void) | |||
| 207 | * Falls back on built-in device tree in case null pointer is passed. | 208 | * Falls back on built-in device tree in case null pointer is passed. |
| 208 | */ | 209 | */ |
| 209 | 210 | ||
| 210 | void __init or32_early_setup(unsigned int fdt) | 211 | void __init or32_early_setup(void *fdt) |
| 211 | { | 212 | { |
| 212 | if (fdt) { | 213 | if (fdt) |
| 213 | early_init_devtree((void*) fdt); | 214 | pr_info("FDT at %p\n", fdt); |
| 214 | printk(KERN_INFO "FDT at 0x%08x\n", fdt); | 215 | else { |
| 215 | } else { | 216 | fdt = __dtb_start; |
| 216 | early_init_devtree(__dtb_start); | 217 | pr_info("Compiled-in FDT at %p\n", fdt); |
| 217 | printk(KERN_INFO "Compiled-in FDT at %p\n", __dtb_start); | ||
| 218 | } | 218 | } |
| 219 | early_init_devtree(fdt); | ||
| 219 | } | 220 | } |
| 220 | 221 | ||
| 221 | static int __init openrisc_device_probe(void) | 222 | static int __init openrisc_device_probe(void) |
| @@ -288,10 +289,10 @@ void __init setup_arch(char **cmdline_p) | |||
| 288 | setup_cpuinfo(); | 289 | setup_cpuinfo(); |
| 289 | 290 | ||
| 290 | /* process 1's initial memory region is the kernel code/data */ | 291 | /* process 1's initial memory region is the kernel code/data */ |
| 291 | init_mm.start_code = (unsigned long)&_stext; | 292 | init_mm.start_code = (unsigned long)_stext; |
| 292 | init_mm.end_code = (unsigned long)&_etext; | 293 | init_mm.end_code = (unsigned long)_etext; |
| 293 | init_mm.end_data = (unsigned long)&_edata; | 294 | init_mm.end_data = (unsigned long)_edata; |
| 294 | init_mm.brk = (unsigned long)&_end; | 295 | init_mm.brk = (unsigned long)_end; |
| 295 | 296 | ||
| 296 | #ifdef CONFIG_BLK_DEV_INITRD | 297 | #ifdef CONFIG_BLK_DEV_INITRD |
| 297 | initrd_start = (unsigned long)&__initrd_start; | 298 | initrd_start = (unsigned long)&__initrd_start; |
diff --git a/arch/openrisc/kernel/vmlinux.h b/arch/openrisc/kernel/vmlinux.h index ee842a2d3f36..70b9ce41835c 100644 --- a/arch/openrisc/kernel/vmlinux.h +++ b/arch/openrisc/kernel/vmlinux.h | |||
| @@ -1,10 +1,8 @@ | |||
| 1 | #ifndef __OPENRISC_VMLINUX_H_ | 1 | #ifndef __OPENRISC_VMLINUX_H_ |
| 2 | #define __OPENRISC_VMLINUX_H_ | 2 | #define __OPENRISC_VMLINUX_H_ |
| 3 | 3 | ||
| 4 | extern char _stext, _etext, _edata, _end; | ||
| 5 | #ifdef CONFIG_BLK_DEV_INITRD | 4 | #ifdef CONFIG_BLK_DEV_INITRD |
| 6 | extern char __initrd_start, __initrd_end; | 5 | extern char __initrd_start, __initrd_end; |
| 7 | extern char __initramfs_start; | ||
| 8 | #endif | 6 | #endif |
| 9 | 7 | ||
| 10 | extern u32 __dtb_start[]; | 8 | extern u32 __dtb_start[]; |
