Skip to contentSkip to conversation

ARM: shmobile: mackerel: Remove legacy board support

PATCH In review Magnus Damm 3 participants 5 messages Oct 29, 2014

Subsystems (4)
lore
Share & tools
lore

Magnus Damm

author maintainer
#0 lore raw

PATCH 3/3 ARM: shmobile: mackerel: Remove legacy board support

From: Magnus Damm <[email protected]>

Remove old sh7372 Mackerel board support. The sh7372 SoC never went to mass production anyway and the few Mackerel boards that still exist do not support DT due to lack of DT bindings for the interrupt controller.

Anyone wanting to play with old hardware can focus on EMEV2, sh73a0 or r8a7740 instead.

---

 arch/arm/mach-shmobile/Kconfig                        |    9 
 arch/arm/mach-shmobile/Makefile                       |    1 
 arch/arm/mach-shmobile/Makefile.boot                  |    1 
 arch/arm/mach-shmobile/board-mackerel.c               | 1522 -----------------
 arch/arm/mach-shmobile/include/mach/head-mackerel.txt |   93 -
 arch/arm/mach-shmobile/include/mach/mmc-mackerel.h    |   38 
 arch/arm/mach-shmobile/include/mach/mmc.h             |    5 
 arch/arm/mach-shmobile/include/mach/zboot.h           |    5 
 8 files changed, 1 insertion(+), 1673 deletions(-)
arch/arm/mach-shmobile/Kconfig +0 -9
@@ -155,15 +155,6 @@ config MACH_APE6EVM_REFERENCE
 
 	   This is intended to aid developers
 
-config MACH_MACKEREL
-	bool "mackerel board"
-	depends on ARCH_SH7372
-	select ARCH_REQUIRE_GPIOLIB
-	select REGULATOR_FIXED_VOLTAGE if REGULATOR
-	select SMSC_PHY if SMSC911X
-	select SND_SOC_AK4642 if SND_SIMPLE_CARD
-	select USE_OF
-
 config MACH_ARMADILLO800EVA
 	bool "Armadillo-800 EVA board"
 	depends on ARCH_R8A7740
arch/arm/mach-shmobile/Makefile +0 -1
@@ -60,7 +60,6 @@ obj-$(CONFIG_MACH_MARZEN)	+= board-marze
 else
 obj-$(CONFIG_MACH_APE6EVM)	+= board-ape6evm.o
 obj-$(CONFIG_MACH_APE6EVM_REFERENCE)	+= board-ape6evm-reference.o
-obj-$(CONFIG_MACH_MACKEREL)	+= board-mackerel.o
 obj-$(CONFIG_MACH_BOCKW)	+= board-bockw.o
 obj-$(CONFIG_MACH_BOCKW_REFERENCE)	+= board-bockw-reference.o
 obj-$(CONFIG_MACH_MARZEN)	+= board-marzen.o
arch/arm/mach-shmobile/Makefile.boot +0 -1
@@ -7,7 +7,6 @@ loadaddr-$(CONFIG_MACH_BOCKW) += 0x60008
 loadaddr-$(CONFIG_MACH_BOCKW_REFERENCE) += 0x60008000
 loadaddr-$(CONFIG_MACH_KZM9G) += 0x41008000
 loadaddr-$(CONFIG_MACH_KZM9G_REFERENCE) += 0x41008000
-loadaddr-$(CONFIG_MACH_MACKEREL) += 0x40008000
 loadaddr-$(CONFIG_MACH_MARZEN) += 0x60008000
 
 __ZRELADDR	:= $(sort $(loadaddr-y))
arch/arm/mach-shmobile/board-mackerel.c deleted +0 -1521

1,521 lines not on this page · raw message

+++ /dev/null 2013-06-03 21:41:10.638032047 +0900
@@ -1,93 +0,0 @@
-LIST "partner-jet-setup.txt"
-LIST "(C) Copyright 2010 Renesas Solutions Corp" -LIST "Kuninori Morimoto <[email protected]>" -
-LIST "RWT Setting"
-EW 0xE6020004, 0xA500
-EW 0xE6030004, 0xA500
-
-LIST "GPIO Setting"
-EB 0xE6051013, 0xA2
-
-LIST "CPG"
-ED 0xE61500C0, 0x00000002
-
-WAIT 1, 0xFE40009C
-
-LIST "FRQCR"
-ED 0xE6150000, 0x2D1305C3
-ED 0xE61500E0, 0x9E40358E
-ED 0xE6150004, 0x80331050
-
-WAIT 1, 0xFE40009C
-
-ED 0xE61500E4, 0x00002000
-
-WAIT 1, 0xFE40009C
-
-LIST "PLL"
-ED 0xE6150028, 0x00004000
-
-WAIT 1, 0xFE40009C
-
-ED 0xE615002C, 0x93000040
-
-WAIT 1, 0xFE40009C
-
-LIST "SUB/USBClk"
-ED 0xE6150080, 0x00000180
-
-LIST "BSC"
-ED 0xFEC10000, 0x00E0001B
-
-LIST "SBSC1"
-ED 0xFE400354, 0x01AD8000
-ED 0xFE400354, 0x01AD8001
-
-WAIT 5, 0xFE40009C
-
-ED 0xFE400008, 0xBCC90151
-ED 0xFE400040, 0x41774113
-ED 0xFE400044, 0x2712E229
-ED 0xFE400048, 0x20C18505
-ED 0xFE40004C, 0x00110209
-ED 0xFE400010, 0x00000087
-
-WAIT 30, 0xFE40009C
-
-ED 0xFE400084, 0x0000003F
-EB 0xFE500000, 0x00
-
-WAIT 5, 0xFE40009C
-
-ED 0xFE400084, 0x0000FF0A
-EB 0xFE500000, 0x00
-
-WAIT 1, 0xFE40009C
-
-ED 0xFE400084, 0x00002201
-EB 0xFE500000, 0x00
-ED 0xFE400084, 0x00000302
-EB 0xFE500000, 0x00
-EB 0xFE5C0000, 0x00
-ED 0xFE400008, 0xBCC90159
-ED 0xFE40008C, 0x88800004
-ED 0xFE400094, 0x00000004
-ED 0xFE400028, 0xA55A0032
-ED 0xFE40002C, 0xA55A000C
-ED 0xFE400020, 0xA55A2048
-ED 0xFE400008, 0xBCC90959
-
-LIST "Change CPGA setting"
-ED 0xE61500E0, 0x9E40352E
-ED 0xE6150004, 0x80331050
-
-WAIT 1, 0xFE40009C
-
-ED 0xFE400354, 0x01AD8002
-
-LIST "SCIF0 - Serial port for earlyprintk"
-EB 0xE6053098, 0xe1
-EW 0xE6C40000, 0x0000
-EB 0xE6C40004, 0x19
-EW 0xE6C40008, 0x0030

arch/arm/mach-shmobile/include/mach/mmc-mackerel.h deleted +0 -38
@@ -1,38 +0,0 @@
-#ifndef MMC_MACKEREL_H
-#define MMC_MACKEREL_H
-
-#define PORT0CR      (void __iomem *)0xe6051000
-#define PORT1CR      (void __iomem *)0xe6051001
-#define PORT2CR      (void __iomem *)0xe6051002
-#define PORT159CR    (void __iomem *)0xe605009f
-
-#define PORTR031_000DR (void __iomem *)0xe6055000
-#define PORTL159_128DR (void __iomem *)0xe6054010
-
-static inline void mmc_init_progress(void)
-{
-       /* Initialise LEDS0-3
-        * registers: PORT0CR-PORT2CR,PORT159CR (LED0-LED3 Control)
-        * value:     0x10 - enable output
-        */
-       __raw_writeb(0x10, PORT0CR);
-       __raw_writeb(0x10, PORT1CR);
-       __raw_writeb(0x10, PORT2CR);
-       __raw_writeb(0x10, PORT159CR);
-}
-
-static inline void mmc_update_progress(int n)
-{
-	unsigned a = 0, b = 0;
-
-	if (n < 3)
-		a = 1 << n;
-	else
-		b = 1 << 31;
-
-	__raw_writel((__raw_readl(PORTR031_000DR) & ~0x7) | a,
-		     PORTR031_000DR);
-	__raw_writel((__raw_readl(PORTL159_128DR) & ~(1 << 31)) | b,
-		     PORTL159_128DR);
-}
-#endif /* MMC_MACKEREL_H */
arch/arm/mach-shmobile/include/mach/mmc.h +0 -5
@@ -7,10 +7,5 @@
  *
  **************************************************/
 
-#ifdef CONFIG_MACH_MACKEREL
-#include "mach/mmc-mackerel.h"
-#else
 #error "unsupported board."
-#endif
-
 #endif /* MMC_H */
arch/arm/mach-shmobile/include/mach/zboot.h +1 -4
@@ -9,10 +9,7 @@
  *
  **************************************************/
 
-#ifdef CONFIG_MACH_MACKEREL
-#define MEMORY_START	0x40000000
-#include "mach/head-mackerel.txt"
-#elif defined(CONFIG_MACH_KZM9G) || defined(CONFIG_MACH_KZM9G_REFERENCE)
+#if defined(CONFIG_MACH_KZM9G) || defined(CONFIG_MACH_KZM9G_REFERENCE)
 #define MEMORY_START	0x43000000
 #include "mach/head-kzm9g.txt"
 #else
#1 lore raw

Hi Magnus,

Quoted 4 lines · Magnus Damm

Remove old sh7372 Mackerel board support. The sh7372 SoC never went to mass production anyway and the few Mackerel boards that still exist do not support DT due to lack of DT bindings for the interrupt controller.

This leaves a bit of fall-out:

$ git grep -i mackerel
Documentation/arm/SH-Mobile/zboot-rom-sdhi.txt:This code has been
tested on an mackerel board using the developer 1A eSD
Documentation/arm/SH-Mobile/zboot-rom-sdhi.txt:the notes in
arch/arm/mach-shmobile/board-mackerel.c.
Documentation/devicetree/bindings/arm/shmobile.txt:  - Mackerel
(R0P7372LC0016RL, AP4 EVM 2nd)
Documentation/devicetree/bindings/arm/shmobile.txt:    compatible "renesas,mackerel"
MAINTAINERS:F:  arch/arm/configs/mackerel_defconfig
arch/arm/boot/dts/Makefile:     sh7372-mackerel.dtb \
arch/arm/boot/dts/sh7372-mackerel.dts: * Device Tree Source for the
mackerel board
arch/arm/boot/dts/sh7372-mackerel.dts:  model = "Mackerel (AP4 EVM 2nd)";
arch/arm/boot/dts/sh7372-mackerel.dts:  compatible = "renesas,mackerel";
arch/arm/configs/mackerel_defconfig:CONFIG_LOCALVERSION="-mackerel"
arch/arm/configs/mackerel_defconfig:CONFIG_MACH_MACKEREL=y
arch/arm/tools/mach-types:mackerel              MACH_MACKEREL
 MACKEREL                3211
$

You may want to keep zboot-rom-sdhi.txt (does this apply to any other boards?) and mach-types for historical reasons.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds

author maintainer
#2 lore raw
In reply to Magnus Damm

Hi Geert,

Quoted 30 lines · Geert Uytterhoeven

Hi Magnus,

Quoted 4 lines · Magnus Damm

Remove old sh7372 Mackerel board support. The sh7372 SoC never went to mass production anyway and the few Mackerel boards that still exist do not support DT due to lack of DT bindings for the interrupt controller.

This leaves a bit of fall-out:

$ git grep -i mackerel
Documentation/arm/SH-Mobile/zboot-rom-sdhi.txt:This code has been
tested on an mackerel board using the developer 1A eSD
Documentation/arm/SH-Mobile/zboot-rom-sdhi.txt:the notes in
arch/arm/mach-shmobile/board-mackerel.c.
Documentation/devicetree/bindings/arm/shmobile.txt:  - Mackerel
(R0P7372LC0016RL, AP4 EVM 2nd)
Documentation/devicetree/bindings/arm/shmobile.txt:    compatible > "renesas,mackerel"
MAINTAINERS:F:  arch/arm/configs/mackerel_defconfig
arch/arm/boot/dts/Makefile:     sh7372-mackerel.dtb \
arch/arm/boot/dts/sh7372-mackerel.dts: * Device Tree Source for the
mackerel board
arch/arm/boot/dts/sh7372-mackerel.dts:  model = "Mackerel (AP4 EVM 2nd)";
arch/arm/boot/dts/sh7372-mackerel.dts:  compatible = "renesas,mackerel";
arch/arm/configs/mackerel_defconfig:CONFIG_LOCALVERSION="-mackerel"
arch/arm/configs/mackerel_defconfig:CONFIG_MACH_MACKEREL=y
arch/arm/tools/mach-types:mackerel              MACH_MACKEREL
 MACKEREL                3211
$
Quoted 2 lines

You may want to keep zboot-rom-sdhi.txt (does this apply to any other boards?) and mach-types for historical reasons.

Thanks, yes, more stuff indeed needs to be removed. Regarding the zboot bit, I think keeping that around for some time makes sense. Perhaps trimming away the mackerel references would help. I do think we can ditch the bindings since we phase out the board support, but perhaps that's wrong. =)

Do you think it is good timing to get rid of Mackerel now, or do you prefer to wait?

Cheers,

/ magnus

#3 lore raw
In reply to Magnus Damm

Hi Magnus,

Quoted 3 lines · Magnus Damm

I do think
we can ditch the bindings since we phase out the board support, but perhaps that's wrong. =)

The DTS only contains the memory node, which we can easily resurrect, if needed.

Quoted 2 lines

Do you think it is good timing to get rid of Mackerel now, or do you prefer to wait?

I think the Mackerel-specific code can go.

The sh7372 SoC code is still there. That contains some still interesting parts (cpuidle and wake-up source code). If they can stay for a little while, I'm happy.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds

#4 lore raw
In reply to Magnus Damm
Quoted 10 lines · Geert Uytterhoeven

Hi Magnus,

Quoted 3 lines · Magnus Damm

I do think
we can ditch the bindings since we phase out the board support, but perhaps that's wrong. =)

The DTS only contains the memory node, which we can easily resurrect, if needed.

Quoted 8 lines
Quoted 2 lines

Do you think it is good timing to get rid of Mackerel now, or do you prefer to wait?

I think the Mackerel-specific code can go.

The sh7372 SoC code is still there. That contains some still interesting parts (cpuidle and wake-up source code). If they can stay for a little while, I'm happy.

From my point of view I don't see a lot of value in keeping unused SoC code lying around. For one thing it will be hard to avoid bitrot if we can't even boot the code. So I'd prefer to remove sh7372 SoC code and Mackerel board code in one hit. But I am prepared to be convinced otherwise.