Skip to content

Commit 1d767ca

Browse files
committed
Merge tag 'sh-for-linus' of git://github.com/pmundt/linux-sh
Pull SuperH updates from Paul Mundt: - New CPUs: SH7734 (SH-4A), SH7264 and SH7269 (SH-2A) - New boards: RSK2+SH7264, RSK2+SH7269 - Unbreaking kgdb for SMP - Consolidation of _32/_64 page fault handling. - watchdog and legacy DMA chainsawing, part 1 - Conversion to evt2irq() hwirq lookup, to support relocation of vectored IRQs for irqdomains. * tag 'sh-for-linus' of git://github.com/pmundt/linux-sh: (98 commits) sh: intc: Kill off special reservation interface. sh: Enable PIO API for hp6xx and se770x. sh: Kill off machvec IRQ hinting. sh: dma: More legacy cpu dma chainsawing. sh: Kill off MAX_DMA_ADDRESS leftovers. sh: Tidy up some of the cpu legacy dma header mess. sh: Move sh4a dma header from cpu-sh4 to cpu-sh4a. sh64: Fix up vmalloc fault range check. Revert "sh: Ensure fixmap and store queue space can co-exist." serial: sh-sci: Fix for port types without BRI interrupts. sh: legacy PCI evt2irq migration. sh: cpu dma evt2irq migration. sh: sh7763rdp evt2irq migration. sh: sdk7780 evt2irq migration. sh: migor evt2irq migration. sh: landisk evt2irq migration. sh: kfr2r09 evt2irq migration. sh: ecovec24 evt2irq migration. sh: ap325rxa evt2irq migration. sh: urquell evt2irq migration. ...
2 parents 6101167 + 5f19f14 commit 1d767ca

File tree

152 files changed

+13243
-2205
lines changed

Some content is hidden

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

152 files changed

+13243
-2205
lines changed

MAINTAINERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6573,7 +6573,7 @@ M: Paul Mundt <lethal@linux-sh.org>
65736573
L: linux-sh@vger.kernel.org
65746574
W: http://www.linux-sh.org
65756575
Q: http://patchwork.kernel.org/project/linux-sh/list/
6576-
T: git git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6.git sh-latest
6576+
T: git git://github.com/pmundt/linux-sh.git sh-latest
65776577
S: Supported
65786578
F: Documentation/sh/
65796579
F: arch/sh/

arch/sh/Kconfig

Lines changed: 43 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,8 @@ config ARCH_HAS_DEFAULT_IDLE
155155

156156
config NO_IOPORT
157157
def_bool !PCI
158-
depends on !SH_CAYMAN && !SH_SH4202_MICRODEV && !SH_SHMIN
158+
depends on !SH_CAYMAN && !SH_SH4202_MICRODEV && !SH_SHMIN && \
159+
!SH_HP6XX && !SH_SOLUTION_ENGINE
159160

160161
config IO_TRAPPED
161162
bool
@@ -286,6 +287,20 @@ config CPU_SUBTYPE_SH7263
286287
select SYS_SUPPORTS_CMT
287288
select SYS_SUPPORTS_MTU2
288289

290+
config CPU_SUBTYPE_SH7264
291+
bool "Support SH7264 processor"
292+
select CPU_SH2A
293+
select CPU_HAS_FPU
294+
select SYS_SUPPORTS_CMT
295+
select SYS_SUPPORTS_MTU2
296+
297+
config CPU_SUBTYPE_SH7269
298+
bool "Support SH7269 processor"
299+
select CPU_SH2A
300+
select CPU_HAS_FPU
301+
select SYS_SUPPORTS_CMT
302+
select SYS_SUPPORTS_MTU2
303+
289304
config CPU_SUBTYPE_MXG
290305
bool "Support MX-G processor"
291306
select CPU_SH2A
@@ -425,6 +440,16 @@ config CPU_SUBTYPE_SH7724
425440
help
426441
Select SH7724 if you have an SH-MobileR2R CPU.
427442

443+
config CPU_SUBTYPE_SH7734
444+
bool "Support SH7734 processor"
445+
select CPU_SH4A
446+
select CPU_SHX2
447+
select ARCH_WANT_OPTIONAL_GPIOLIB
448+
select USB_ARCH_HAS_OHCI
449+
select USB_ARCH_HAS_EHCI
450+
help
451+
Select SH7734 if you have a SH4A SH7734 CPU.
452+
428453
config CPU_SUBTYPE_SH7757
429454
bool "Support SH7757 processor"
430455
select CPU_SH4A
@@ -582,7 +607,9 @@ config SH_CLK_CPG
582607
config SH_CLK_CPG_LEGACY
583608
depends on SH_CLK_CPG
584609
def_bool y if !CPU_SUBTYPE_SH7785 && !ARCH_SHMOBILE && \
585-
!CPU_SHX3 && !CPU_SUBTYPE_SH7757
610+
!CPU_SHX3 && !CPU_SUBTYPE_SH7757 && \
611+
!CPU_SUBTYPE_SH7734 && !CPU_SUBTYPE_SH7264 && \
612+
!CPU_SUBTYPE_SH7269
586613

587614
source "kernel/time/Kconfig"
588615

@@ -683,6 +710,20 @@ config SECCOMP
683710

684711
If unsure, say N.
685712

713+
config CC_STACKPROTECTOR
714+
bool "Enable -fstack-protector buffer overflow detection (EXPERIMENTAL)"
715+
depends on SUPERH32 && EXPERIMENTAL
716+
help
717+
This option turns on the -fstack-protector GCC feature. This
718+
feature puts, at the beginning of functions, a canary value on
719+
the stack just before the return address, and validates
720+
the value just before actually returning. Stack based buffer
721+
overflows (that need to overwrite this return address) now also
722+
overwrite the canary, which gets detected and the attack is then
723+
neutralized via a kernel panic.
724+
725+
This feature requires gcc version 4.2 or above.
726+
686727
config SMP
687728
bool "Symmetric multi-processing support"
688729
depends on SYS_SUPPORTS_SMP

arch/sh/Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,10 @@ ifeq ($(CONFIG_DWARF_UNWINDER),y)
199199
KBUILD_CFLAGS += -fasynchronous-unwind-tables
200200
endif
201201

202+
ifeq ($(CONFIG_CC_STACKPROTECTOR),y)
203+
KBUILD_CFLAGS += -fstack-protector
204+
endif
205+
202206
libs-$(CONFIG_SUPERH32) := arch/sh/lib/ $(libs-y)
203207
libs-$(CONFIG_SUPERH64) := arch/sh/lib64/ $(libs-y)
204208

arch/sh/boards/Kconfig

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,8 @@ config SH_RTS7751R2D
133133

134134
config SH_RSK
135135
bool "Renesas Starter Kit"
136-
depends on CPU_SUBTYPE_SH7201 || CPU_SUBTYPE_SH7203
136+
depends on CPU_SUBTYPE_SH7201 || CPU_SUBTYPE_SH7203 || \
137+
CPU_SUBTYPE_SH7264 || CPU_SUBTYPE_SH7269
137138
help
138139
Select this option if configuring for any of the RSK+ MCU
139140
evaluation platforms.
@@ -338,8 +339,6 @@ config SH_APSH4AD0A
338339
help
339340
Select AP-SH4AD-0A if configuring for an ALPHAPROJECT AP-SH4AD-0A.
340341

341-
endmenu
342-
343342
source "arch/sh/boards/mach-r2d/Kconfig"
344343
source "arch/sh/boards/mach-highlander/Kconfig"
345344
source "arch/sh/boards/mach-sdk7780/Kconfig"
@@ -359,3 +358,5 @@ config SH_MAGIC_PANEL_R2_VERSION
359358
endmenu
360359

361360
endif
361+
362+
endmenu

arch/sh/boards/board-edosk7705.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,15 @@
1313
#include <linux/platform_device.h>
1414
#include <linux/interrupt.h>
1515
#include <linux/smc91x.h>
16+
#include <linux/sh_intc.h>
1617
#include <asm/machvec.h>
1718
#include <asm/sizes.h>
1819

1920
#define SMC_IOBASE 0xA2000000
2021
#define SMC_IO_OFFSET 0x300
2122
#define SMC_IOADDR (SMC_IOBASE + SMC_IO_OFFSET)
2223

23-
#define ETHERNET_IRQ 0x09
24+
#define ETHERNET_IRQ evt2irq(0x320)
2425

2526
static void __init sh_edosk7705_init_irq(void)
2627
{
@@ -73,6 +74,5 @@ device_initcall(init_edosk7705_devices);
7374
*/
7475
static struct sh_machine_vector mv_edosk7705 __initmv = {
7576
.mv_name = "EDOSK7705",
76-
.mv_nr_irqs = 80,
7777
.mv_init_irq = sh_edosk7705_init_irq,
7878
};

arch/sh/boards/board-edosk7760.c

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
#include <linux/platform_device.h>
2424
#include <linux/smc91x.h>
2525
#include <linux/interrupt.h>
26+
#include <linux/sh_intc.h>
2627
#include <linux/i2c.h>
2728
#include <linux/mtd/physmap.h>
2829
#include <asm/machvec.h>
@@ -40,8 +41,6 @@
4041
#define SMC_IO_OFFSET 0x300
4142
#define SMC_IOADDR (SMC_IOBASE + SMC_IO_OFFSET)
4243

43-
#define ETHERNET_IRQ 5
44-
4544
/* NOR flash */
4645
static struct mtd_partition edosk7760_nor_flash_partitions[] = {
4746
{
@@ -99,8 +98,8 @@ static struct resource sh7760_i2c1_res[] = {
9998
.end = SH7760_I2C1_MMIOEND,
10099
.flags = IORESOURCE_MEM,
101100
},{
102-
.start = SH7760_I2C1_IRQ,
103-
.end = SH7760_I2C1_IRQ,
101+
.start = evt2irq(0x9e0),
102+
.end = evt2irq(0x9e0),
104103
.flags = IORESOURCE_IRQ,
105104
},
106105
};
@@ -122,8 +121,8 @@ static struct resource sh7760_i2c0_res[] = {
122121
.end = SH7760_I2C0_MMIOEND,
123122
.flags = IORESOURCE_MEM,
124123
}, {
125-
.start = SH7760_I2C0_IRQ,
126-
.end = SH7760_I2C0_IRQ,
124+
.start = evt2irq(0x9c0),
125+
.end = evt2irq(0x9c0),
127126
.flags = IORESOURCE_IRQ,
128127
},
129128
};
@@ -150,8 +149,8 @@ static struct resource smc91x_res[] = {
150149
.flags = IORESOURCE_MEM,
151150
},
152151
[1] = {
153-
.start = ETHERNET_IRQ,
154-
.end = ETHERNET_IRQ,
152+
.start = evt2irq(0x2a0),
153+
.end = evt2irq(0x2a0),
155154
.flags = IORESOURCE_IRQ ,
156155
}
157156
};
@@ -189,5 +188,4 @@ device_initcall(init_edosk7760_devices);
189188
*/
190189
struct sh_machine_vector mv_edosk7760 __initmv = {
191190
.mv_name = "EDOSK7760",
192-
.mv_nr_irqs = 128,
193191
};

arch/sh/boards/board-espt.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include <linux/mtd/physmap.h>
1515
#include <linux/io.h>
1616
#include <linux/sh_eth.h>
17+
#include <linux/sh_intc.h>
1718
#include <asm/machvec.h>
1819
#include <asm/sizes.h>
1920

@@ -71,7 +72,7 @@ static struct resource sh_eth_resources[] = {
7172
.flags = IORESOURCE_MEM,
7273
}, {
7374

74-
.start = 57, /* irq number */
75+
.start = evt2irq(0x920), /* irq number */
7576
.flags = IORESOURCE_IRQ,
7677
},
7778
};

arch/sh/boards/board-magicpanelr2.c

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
#include <linux/mtd/partitions.h>
2020
#include <linux/mtd/physmap.h>
2121
#include <linux/mtd/map.h>
22+
#include <linux/sh_intc.h>
2223
#include <mach/magicpanelr2.h>
2324
#include <asm/heartbeat.h>
2425
#include <cpu/sh7720.h>
@@ -245,8 +246,8 @@ static struct resource smsc911x_resources[] = {
245246
.flags = IORESOURCE_MEM,
246247
},
247248
[1] = {
248-
.start = 35,
249-
.end = 35,
249+
.start = evt2irq(0x660),
250+
.end = evt2irq(0x660),
250251
.flags = IORESOURCE_IRQ,
251252
},
252253
};
@@ -358,17 +359,17 @@ static void __init init_mpr2_IRQ(void)
358359
{
359360
plat_irq_setup_pins(IRQ_MODE_IRQ); /* install handlers for IRQ0-5 */
360361

361-
irq_set_irq_type(32, IRQ_TYPE_LEVEL_LOW); /* IRQ0 CAN1 */
362-
irq_set_irq_type(33, IRQ_TYPE_LEVEL_LOW); /* IRQ1 CAN2 */
363-
irq_set_irq_type(34, IRQ_TYPE_LEVEL_LOW); /* IRQ2 CAN3 */
364-
irq_set_irq_type(35, IRQ_TYPE_LEVEL_LOW); /* IRQ3 SMSC9115 */
365-
irq_set_irq_type(36, IRQ_TYPE_EDGE_RISING); /* IRQ4 touchscreen */
366-
irq_set_irq_type(37, IRQ_TYPE_EDGE_FALLING); /* IRQ5 touchscreen */
367-
368-
intc_set_priority(32, 13); /* IRQ0 CAN1 */
369-
intc_set_priority(33, 13); /* IRQ0 CAN2 */
370-
intc_set_priority(34, 13); /* IRQ0 CAN3 */
371-
intc_set_priority(35, 6); /* IRQ3 SMSC9115 */
362+
irq_set_irq_type(evt2irq(0x600), IRQ_TYPE_LEVEL_LOW); /* IRQ0 CAN1 */
363+
irq_set_irq_type(evt2irq(0x620), IRQ_TYPE_LEVEL_LOW); /* IRQ1 CAN2 */
364+
irq_set_irq_type(evt2irq(0x640), IRQ_TYPE_LEVEL_LOW); /* IRQ2 CAN3 */
365+
irq_set_irq_type(evt2irq(0x660), IRQ_TYPE_LEVEL_LOW); /* IRQ3 SMSC9115 */
366+
irq_set_irq_type(evt2irq(0x680), IRQ_TYPE_EDGE_RISING); /* IRQ4 touchscreen */
367+
irq_set_irq_type(evt2irq(0x6a0), IRQ_TYPE_EDGE_FALLING); /* IRQ5 touchscreen */
368+
369+
intc_set_priority(evt2irq(0x600), 13); /* IRQ0 CAN1 */
370+
intc_set_priority(evt2irq(0x620), 13); /* IRQ0 CAN2 */
371+
intc_set_priority(evt2irq(0x640), 13); /* IRQ0 CAN3 */
372+
intc_set_priority(evt2irq(0x660), 6); /* IRQ3 SMSC9115 */
372373
}
373374

374375
/*

arch/sh/boards/board-polaris.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,5 @@ static void __init init_polaris_irq(void)
141141

142142
static struct sh_machine_vector mv_polaris __initmv = {
143143
.mv_name = "Polaris",
144-
.mv_nr_irqs = 61,
145144
.mv_init_irq = init_polaris_irq,
146145
};

arch/sh/boards/board-secureedge5410.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,5 @@ static void __init init_snapgear_IRQ(void)
7171
*/
7272
static struct sh_machine_vector mv_snapgear __initmv = {
7373
.mv_name = "SnapGear SecureEdge5410",
74-
.mv_nr_irqs = 72,
7574
.mv_init_irq = init_snapgear_IRQ,
7675
};

0 commit comments

Comments
 (0)