linux-mmc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/36] ARM: samsung platform cleanup
@ 2019-10-10 20:28 Arnd Bergmann
       [not found] ` <20191010203043.1241612-1-arnd@arndb.de>
  2019-10-23 13:10 ` [PATCH 00/36] ARM: samsung platform cleanup Krzysztof Kozlowski
  0 siblings, 2 replies; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-10 20:28 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski
  Cc: linux-hwmon, linux-pwm, linux-fbdev, linux-samsung-soc,
	Arnd Bergmann, linux-pm, patches, linux-usb, linux-mmc,
	linux-kernel, dri-devel, linux-clk, alsa-devel, linux-leds,
	linux-serial, linux-input, linux-spi, linux-stm32,
	linux-arm-kernel

I've spent some time looking at the remaining ARMv4/ARMv5 platforms
that are not part of ARCH_MULTIPLATFORM, and tried to get them closer
to that. Here is what came out of that for the samsung platforms:

* Exynos and s5pv210 are made independent of plat-samsung
* device drivers stop using mach/*.h headers for s3c24xx
  (and other platforms not in this series)
* s3c24xx and s3c64xx get merged into mach-s3c, removing
  the need for plat-samsung (I have other patches for the
  remaining plat-* directories)
* mach/io.h gets cleaned up to only be needed for BAST
  PC104 mode (looking for ideas to proceed)
* mach/irqs.h remains for now, this still needs to be converted
  to sparse IRQs.

Some bits are a little ugly, but overall I think this a big
improvement.

The contents are available for testing in

git://kernel.org:/pub/scm/linux/kernel/git/arnd/playground.git s3c-multiplatform

Given the overall size of the series I expect that there will
be bugs, so at this points I'm looking for reviews, acks and
testing from anyone who still has the hardware, in particular
s3c24xx, but also the other samsung platforms I'm touching.

      Arnd

Arnd Bergmann (36):
  ARM: samsung: make S3C24XX_MISCCR access indirect
  ARM: s3c: simplify mach/io.h
  usb: gadget: s3c: use platform resources
  usb: gadget: s3c-hsudc: remove platform header dependency
  ARM: samsung: make pm-debug platform independent
  ARM: samsung: move CONFIG_DEBUG_S3C_UART to Kconfig.debug
  ARM: exynos: use private samsung_cpu_id copy
  ARM: exynos: stop selecting PLAT_SAMSUNG
  ARM: samsung: move pm check code to drivers/soc
  ARM: s5pv210: use private pm save/restore
  ARM: s5pv210: split from plat-samsung
  ARM: s3c64xx: remove mach/hardware.h
  ARM: s3c: move regs-spi.h into spi driver
  ARM: s3c: move irqchip driver back into platform
  ARM: s3c: adc: move header to linux/soc/samsung
  ARM: s3c: move spi fiq handler into platform
  ARM: s3c: h1940-audio: turn into platform driver
  ARM: s3c: gta02-audio: turn into platform driver
  ARM: s3c: rx1950: turn into platform driver
  ASoC: samsung: s3c2412-i2s: avoid hardcoded S3C2410_PA_IIS
  ARM: s3c: move iis pinctrl config into boards
  ARM: s3c: leds: move setpull() calls into board files
  ARM: s3c: move s3cmci pinctrl handling into board files
  ARM: s3c: include mach/irqs.h where needed
  ARM: s3c: spi: avoid hardcoding fiq number in driver
  ARM: s3c: bast: avoid irq_desc array usage
  ARM: s3c: fix mmc gpio lookup tables
  fbdev: s3c2410fb: remove mach header dependency
  ARM: s3c: cpufreq: split out registers
  ARM: s3c: remove cpufreq header dependencies
  ARM: s3c: cpufreq: use global s3c2412_cpufreq_setrefresh
  ARM: s3c: iotiming: make functions static
  ARM: s3c: move low-level clk reg access into platform code
  ARM: s3c: stop including mach/hardware.h from mach/io.h
  ARM: s3c: move into a common directory
  ARM: s3c: make headers local if possible

 MAINTAINERS                                   |  16 +-
 arch/arm/Kconfig                              |   5 +-
 arch/arm/Kconfig.debug                        |  18 +-
 arch/arm/Makefile                             |   7 +-
 arch/arm/mach-exynos/Makefile                 |   4 -
 arch/arm/mach-exynos/common.h                 |   6 +-
 arch/arm/mach-exynos/exynos.c                 |  19 +-
 arch/arm/mach-exynos/include/mach/map.h       |  18 --
 arch/arm/mach-exynos/platsmp.c                |   4 +-
 arch/arm/mach-exynos/pm.c                     |   8 +-
 arch/arm/{plat-samsung => mach-s3c}/Kconfig   |  62 +----
 .../Kconfig => mach-s3c/Kconfig.s3c24xx}      |   0
 .../Kconfig => mach-s3c/Kconfig.s3c64xx}      |   0
 arch/arm/{plat-samsung => mach-s3c}/Makefile  |  15 +-
 .../{mach-s3c24xx => mach-s3c}/Makefile.boot  |   0
 .../Makefile => mach-s3c/Makefile.s3c24xx}    |  15 +-
 .../Makefile => mach-s3c/Makefile.s3c64xx}    |  14 +-
 .../include/plat => mach-s3c}/adc-core.h      |   0
 arch/arm/{plat-samsung => mach-s3c}/adc.c     |   4 +-
 arch/arm/{mach-s3c24xx => mach-s3c}/anubis.h  |   0
 .../arm/{mach-s3c64xx => mach-s3c}/ata-core.h |   0
 .../{mach-s3c64xx => mach-s3c}/backlight.h    |   0
 .../arm/{mach-s3c24xx => mach-s3c}/bast-ide.c |   3 +-
 .../arm/{mach-s3c24xx => mach-s3c}/bast-irq.c |   8 +-
 arch/arm/{mach-s3c24xx => mach-s3c}/bast.h    |   0
 .../{mach-s3c24xx => mach-s3c}/common-smdk.c  |  17 +-
 .../{mach-s3c24xx => mach-s3c}/common-smdk.h  |   0
 arch/arm/{plat-samsung => mach-s3c}/cpu.c     |  21 +-
 .../include/plat => mach-s3c}/cpu.h           |  11 -
 .../cpufreq-utils.c                           |  38 +++-
 arch/arm/{mach-s3c64xx => mach-s3c}/cpuidle.c |   4 +-
 .../arm/{mach-s3c64xx => mach-s3c}/crag6410.h |   2 +-
 .../{mach-s3c64xx => mach-s3c}/dev-audio.c    |   9 +-
 .../dev-backlight.c                           |   4 +-
 .../dev-uart-s3c64xx.c}                       |   5 +-
 .../arm/{plat-samsung => mach-s3c}/dev-uart.c |   2 +-
 arch/arm/{plat-samsung => mach-s3c}/devs.c    |  56 +++--
 .../include/plat => mach-s3c}/devs.h          |   0
 .../mach/dma.h => mach-s3c/dma-s3c24xx.h}     |   0
 .../mach/dma.h => mach-s3c/dma-s3c64xx.h}     |   0
 arch/arm/mach-s3c/dma.h                       |   7 +
 arch/arm/{mach-s3c24xx => mach-s3c}/fb-core.h |   0
 .../include/plat => mach-s3c}/fb.h            |   0
 .../plat => mach-s3c}/gpio-cfg-helpers.h      |   0
 .../include/plat => mach-s3c}/gpio-cfg.h      |   0
 .../include/plat => mach-s3c}/gpio-core.h     |   2 +-
 .../gpio-samsung-s3c24xx.h}                   |   2 +
 .../gpio-samsung-s3c64xx.h}                   |   0
 .../{plat-samsung => mach-s3c}/gpio-samsung.c |  18 +-
 arch/arm/mach-s3c/gpio-samsung.h              |   7 +
 arch/arm/{mach-s3c24xx => mach-s3c}/gta02.h   |   2 +-
 .../h1940-bluetooth.c                         |   7 +-
 arch/arm/{mach-s3c24xx => mach-s3c}/h1940.h   |   0
 .../include/mach => mach-s3c}/hardware.h      |   7 -
 .../include/plat => mach-s3c}/iic-core.h      |   0
 arch/arm/mach-s3c/include/mach/io.h           |  50 +++++
 .../include/mach/irqs-s3c24xx.h}              |   0
 .../include/mach/irqs-s3c64xx.h}              |   0
 arch/arm/mach-s3c/include/mach/irqs.h         |   7 +
 .../plat => mach-s3c/include/mach}/map-base.h |   0
 arch/arm/{plat-samsung => mach-s3c}/init.c    |   4 +-
 .../iotiming-s3c2410.c                        |  12 +-
 .../iotiming-s3c2412.c                        |   6 +-
 .../irq-pm.c => mach-s3c/irq-pm-s3c24xx.c}    |  16 +-
 .../irq-pm.c => mach-s3c/irq-pm-s3c64xx.c}    |   8 +-
 arch/arm/mach-s3c/irq-s3c24xx-fiq-exports.c   |   9 +
 .../arm/mach-s3c/irq-s3c24xx-fiq.S            |  10 +-
 .../arm/mach-s3c}/irq-s3c24xx.c               |  23 +-
 .../arm/{mach-s3c64xx => mach-s3c}/irq-uart.h |   0
 .../include/plat => mach-s3c}/keypad.h        |   0
 .../mach-amlm5900.c                           |  37 ++-
 .../{mach-s3c24xx => mach-s3c}/mach-anubis.c  |  14 +-
 .../{mach-s3c64xx => mach-s3c}/mach-anw6410.c |  17 +-
 .../mach-at2440evb.c                          |  28 ++-
 .../{mach-s3c24xx => mach-s3c}/mach-bast.c    |  22 +-
 .../mach-crag6410-module.c                    |   2 +-
 .../mach-crag6410.c                           |  27 ++-
 .../{mach-s3c24xx => mach-s3c}/mach-gta02.c   |  57 ++++-
 .../{mach-s3c24xx => mach-s3c}/mach-h1940.c   |  65 ++++--
 .../arm/{mach-s3c64xx => mach-s3c}/mach-hmt.c |  15 +-
 .../{mach-s3c24xx => mach-s3c}/mach-jive.c    |  27 ++-
 .../mach-mini2440.c                           |  48 ++--
 .../mach-mini6410.c                           |  22 +-
 .../arm/{mach-s3c24xx => mach-s3c}/mach-n30.c |  40 +++-
 .../arm/{mach-s3c64xx => mach-s3c}/mach-ncp.c |  13 +-
 .../mach-nexcoder.c                           |  20 +-
 .../mach-osiris-dvs.c                         |   4 +-
 .../{mach-s3c24xx => mach-s3c}/mach-osiris.c  |  22 +-
 .../{mach-s3c24xx => mach-s3c}/mach-otom.c    |  17 +-
 .../{mach-s3c24xx => mach-s3c}/mach-qt2410.c  |  37 ++-
 .../mach-real6410.c                           |  18 +-
 .../{mach-s3c24xx => mach-s3c}/mach-rx1950.c  |  57 +++--
 .../{mach-s3c24xx => mach-s3c}/mach-rx3715.c  |  26 ++-
 .../mach-s3c2416-dt.c                         |   8 +-
 .../mach-s3c64xx-dt.c                         |   6 +-
 .../{mach-s3c64xx => mach-s3c}/mach-smartq.c  |  18 +-
 .../{mach-s3c64xx => mach-s3c}/mach-smartq.h  |   0
 .../{mach-s3c64xx => mach-s3c}/mach-smartq5.c |  18 +-
 .../{mach-s3c64xx => mach-s3c}/mach-smartq7.c |  18 +-
 .../mach-smdk2410.c                           |  14 +-
 .../mach-smdk2413.c                           |  21 +-
 .../mach-smdk2416.c                           |  23 +-
 .../mach-smdk2440.c                           |  25 ++-
 .../mach-smdk2443.c                           |  14 +-
 .../mach-smdk6400.c                           |  13 +-
 .../mach-smdk6410.c                           |  23 +-
 .../mach-tct_hammer.c                         |  24 +-
 .../{mach-s3c24xx => mach-s3c}/mach-vr1000.c  |  20 +-
 .../{mach-s3c24xx => mach-s3c}/mach-vstms.c   |  20 +-
 .../include/plat => mach-s3c}/map-s3c.h       |  12 +-
 .../mach/map.h => mach-s3c/map-s3c24xx.h}     |   6 +-
 .../mach/map.h => mach-s3c/map-s3c64xx.h}     |   4 +-
 .../include/plat => mach-s3c}/map-s5p.h       |   4 +-
 arch/arm/mach-s3c/map.h                       |   7 +
 .../{mach-s3c24xx => mach-s3c}/nand-core.h    |   0
 .../{mach-s3c64xx => mach-s3c}/onenand-core.h |   0
 arch/arm/{mach-s3c24xx => mach-s3c}/osiris.h  |   0
 arch/arm/{mach-s3c24xx => mach-s3c}/otom.h    |   0
 arch/arm/{mach-s3c64xx => mach-s3c}/pl080.c   |   4 +-
 .../{plat-samsung => mach-s3c}/platformdata.c |   4 +-
 .../{mach-s3c24xx => mach-s3c}/pll-s3c2410.c  |   4 +-
 .../pll-s3c2440-12000000.c                    |   4 +-
 .../pll-s3c2440-16934400.c                    |   4 +-
 .../{plat-samsung => mach-s3c}/pm-common.c    |   2 +-
 arch/arm/mach-s3c/pm-common.h                 |  40 ++++
 .../pm-core.h => mach-s3c/pm-core-s3c24xx.h}  |   8 +-
 .../pm-core.h => mach-s3c/pm-core-s3c64xx.h}  |  50 +----
 arch/arm/mach-s3c/pm-core.h                   |   7 +
 arch/arm/{plat-samsung => mach-s3c}/pm-gpio.c |   6 +-
 .../arm/{mach-s3c24xx => mach-s3c}/pm-h1940.S |   5 +-
 .../{mach-s3c24xx => mach-s3c}/pm-s3c2410.c   |  11 +-
 .../{mach-s3c24xx => mach-s3c}/pm-s3c2412.c   |  11 +-
 .../{mach-s3c24xx => mach-s3c}/pm-s3c2416.c   |   6 +-
 .../pm.c => mach-s3c/pm-s3c24xx.c}            |  12 +-
 .../pm.c => mach-s3c/pm-s3c64xx.c}            |  66 +++++-
 arch/arm/{plat-samsung => mach-s3c}/pm.c      |  20 +-
 .../include/plat => mach-s3c}/pm.h            |   2 +-
 .../include/plat => mach-s3c}/pwm-core.h      |   0
 .../include/plat => mach-s3c}/regs-adc.h      |   0
 .../regs-clock-s3c24xx.h}                     |   2 +
 .../regs-clock-s3c64xx.h}                     |   0
 arch/arm/mach-s3c/regs-clock.h                |   7 +
 .../arm/{mach-s3c24xx => mach-s3c}/regs-dsc.h |   0
 .../regs-gpio-memport.h                       |   0
 .../regs-gpio-s3c24xx.h}                      |   2 +
 .../regs-gpio-s3c64xx.h}                      |   0
 arch/arm/mach-s3c/regs-gpio.h                 |   7 +
 .../regs-irq-s3c24xx.h}                       |   2 +
 .../regs-irq-s3c64xx.h}                       |   0
 arch/arm/mach-s3c/regs-irq.h                  |   7 +
 .../include/plat => mach-s3c}/regs-irqtype.h  |   0
 .../arm/{mach-s3c24xx => mach-s3c}/regs-mem.h |   2 +
 .../{mach-s3c64xx => mach-s3c}/regs-modem.h   |   0
 .../mach => mach-s3c}/regs-s3c2443-clock.h    |  50 +++++
 .../{mach-s3c64xx => mach-s3c}/regs-srom.h    |   0
 .../arm/{mach-s3c64xx => mach-s3c}/regs-sys.h |   0
 .../regs-syscon-power.h                       |   0
 .../regs-usb-hsotg-phy.h                      |   0
 .../include/mach => mach-s3c}/rtc-core.h      |   0
 arch/arm/{mach-s3c24xx => mach-s3c}/s3c2410.c |  21 +-
 .../s3c2412-power.h                           |   0
 arch/arm/{mach-s3c24xx => mach-s3c}/s3c2412.c |  16 +-
 .../include/mach => mach-s3c}/s3c2412.h       |   2 +
 arch/arm/{mach-s3c24xx => mach-s3c}/s3c2416.c |  28 +--
 arch/arm/{mach-s3c24xx => mach-s3c}/s3c2440.c |  17 +-
 arch/arm/{mach-s3c24xx => mach-s3c}/s3c2442.c |  17 +-
 arch/arm/{mach-s3c24xx => mach-s3c}/s3c2443.c |  21 +-
 arch/arm/{mach-s3c24xx => mach-s3c}/s3c244x.c |  16 +-
 .../common.c => mach-s3c/s3c24xx.c}           |  21 +-
 .../common.h => mach-s3c/s3c24xx.h}           |   1 +
 arch/arm/{mach-s3c64xx => mach-s3c}/s3c6400.c |  14 +-
 arch/arm/{mach-s3c64xx => mach-s3c}/s3c6410.c |  17 +-
 .../common.c => mach-s3c/s3c64xx.c}           |  24 +-
 .../common.h => mach-s3c/s3c64xx.h}           |   0
 .../include/plat => mach-s3c}/samsung-time.h  |   0
 .../include/plat => mach-s3c}/sdhci.h         |   2 +-
 .../{mach-s3c24xx => mach-s3c}/setup-camif.c  |   4 +-
 .../setup-fb-24bpp.c                          |   6 +-
 .../{mach-s3c24xx => mach-s3c}/setup-i2c.c    |   7 +-
 .../{mach-s3c64xx => mach-s3c}/setup-i2c0.c   |   4 +-
 .../{mach-s3c64xx => mach-s3c}/setup-i2c1.c   |   4 +-
 .../{mach-s3c64xx => mach-s3c}/setup-ide.c    |   8 +-
 .../{mach-s3c64xx => mach-s3c}/setup-keypad.c |   6 +-
 .../setup-sdhci-gpio-s3c24xx.c}               |   6 +-
 .../setup-sdhci-gpio-s3c64xx.c}               |   6 +-
 .../setup-spi-s3c24xx.c}                      |   6 +-
 .../setup-spi-s3c64xx.c}                      |   4 +-
 .../arm/{mach-s3c24xx => mach-s3c}/setup-ts.c |   5 +-
 .../setup-usb-phy.c                           |   6 +-
 .../{mach-s3c24xx => mach-s3c}/simtec-audio.c |  11 +-
 .../{mach-s3c24xx => mach-s3c}/simtec-nor.c   |   2 +-
 .../{mach-s3c24xx => mach-s3c}/simtec-pm.c    |   8 +-
 .../{mach-s3c24xx => mach-s3c}/simtec-usb.c   |   6 +-
 arch/arm/{mach-s3c24xx => mach-s3c}/simtec.h  |   0
 .../sleep-s3c2410.S                           |   7 +-
 .../sleep-s3c2412.S                           |   5 +-
 .../sleep.S => mach-s3c/sleep-s3c24xx.S}      |   7 +-
 .../sleep.S => mach-s3c/sleep-s3c64xx.S}      |   4 +-
 .../arm/{mach-s3c24xx => mach-s3c}/spi-core.h |   0
 .../include/plat => mach-s3c}/usb-phy.h       |   0
 arch/arm/{mach-s3c24xx => mach-s3c}/vr1000.h  |   0
 .../{plat-samsung => mach-s3c}/wakeup-mask.c  |   4 +-
 .../include/plat => mach-s3c}/wakeup-mask.h   |   0
 .../watchdog-reset.c                          |   0
 .../watchdog-reset.h                          |   0
 arch/arm/mach-s3c24xx/include/mach/fb.h       |   2 -
 arch/arm/mach-s3c24xx/include/mach/io.h       | 212 ------------------
 arch/arm/mach-s3c64xx/include/mach/hardware.h |  17 --
 arch/arm/mach-s5pv210/Kconfig                 |   1 +
 arch/arm/mach-s5pv210/Makefile                |   7 -
 arch/arm/mach-s5pv210/pm.c                    |  51 ++++-
 arch/arm/mach-s5pv210/regs-clock.h            |   2 +-
 arch/arm/mach-s5pv210/s5pv210.c               |   2 -
 drivers/clk/samsung/clk-s3c2410-dclk.c        |  10 +-
 drivers/cpufreq/s3c2410-cpufreq.c             |  10 +-
 drivers/cpufreq/s3c2412-cpufreq.c             |  44 ++--
 drivers/cpufreq/s3c2440-cpufreq.c             |  29 ++-
 drivers/cpufreq/s3c24xx-cpufreq-debugfs.c     |   2 +-
 drivers/cpufreq/s3c24xx-cpufreq.c             |  14 +-
 drivers/hwmon/s3c-hwmon.c                     |   2 +-
 drivers/input/touchscreen/s3c2410_ts.c        |  37 ++-
 drivers/irqchip/Makefile                      |   1 -
 drivers/leds/leds-s3c24xx.c                   |   7 -
 drivers/mmc/host/Kconfig                      |   2 +-
 drivers/mmc/host/s3cmci.c                     |  72 ++----
 drivers/power/supply/s3c_adc_battery.c        |   2 +-
 drivers/pwm/Kconfig                           |   2 +-
 drivers/soc/samsung/Kconfig                   |  48 +++-
 drivers/soc/samsung/Makefile                  |   3 +
 .../soc/samsung/s3c-pm-check.c                |   2 +-
 .../soc/samsung/s3c-pm-debug.c                |  26 +--
 drivers/spi/Kconfig                           |   2 +-
 drivers/spi/Makefile                          |   1 -
 .../spi/spi-s3c24xx-regs.h                    |   3 +-
 drivers/spi/spi-s3c24xx.c                     |  28 +--
 drivers/tty/serial/Kconfig                    |   2 +-
 drivers/usb/gadget/udc/s3c-hsudc.c            |  55 +----
 drivers/usb/gadget/udc/s3c2410_udc.c          |  31 +--
 drivers/usb/gadget/udc/s3c2410_udc.h          |   1 +
 .../usb/gadget/udc/s3c2410_udc_regs.h         |   2 +
 .../video/fbdev/s3c2410fb-regs-lcd.h          |  28 +--
 drivers/video/fbdev/s3c2410fb.c               |  16 +-
 .../linux/platform_data}/fb-s3c2410.h         |  33 ++-
 include/linux/platform_data/mmc-s3cmci.h      |   2 +
 include/linux/platform_data/s3c-hsudc.h       |   2 +
 .../linux/soc/samsung/s3c-adc.h               |   0
 .../linux/soc/samsung/s3c-cpu-freq.h          |   0
 .../linux/soc/samsung/s3c-cpufreq-core.h      |  10 +-
 .../linux/soc/samsung/s3c-pm.h                |  69 +++---
 .../linux/spi/s3c24xx-fiq.h                   |   5 +
 include/linux/spi/s3c24xx.h                   |   2 +-
 sound/soc/samsung/Kconfig                     |   2 +-
 sound/soc/samsung/h1940_uda1380.c             |  71 ++----
 sound/soc/samsung/neo1973_wm8753.c            |  85 +++----
 sound/soc/samsung/rx1950_uda1380.c            |  72 ++----
 sound/soc/samsung/s3c-i2s-v2.c                |   3 +-
 sound/soc/samsung/s3c-i2s-v2.h                |   3 +-
 sound/soc/samsung/s3c2412-i2s.c               |   9 +-
 sound/soc/samsung/s3c24xx-i2s.c               |   7 -
 259 files changed, 1716 insertions(+), 1648 deletions(-)
 delete mode 100644 arch/arm/mach-exynos/include/mach/map.h
 rename arch/arm/{plat-samsung => mach-s3c}/Kconfig (73%)
 rename arch/arm/{mach-s3c24xx/Kconfig => mach-s3c/Kconfig.s3c24xx} (100%)
 rename arch/arm/{mach-s3c64xx/Kconfig => mach-s3c/Kconfig.s3c64xx} (100%)
 rename arch/arm/{plat-samsung => mach-s3c}/Makefile (67%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/Makefile.boot (100%)
 rename arch/arm/{mach-s3c24xx/Makefile => mach-s3c/Makefile.s3c24xx} (86%)
 rename arch/arm/{mach-s3c64xx/Makefile => mach-s3c/Makefile.s3c64xx} (83%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/adc-core.h (100%)
 rename arch/arm/{plat-samsung => mach-s3c}/adc.c (99%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/anubis.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/ata-core.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/backlight.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/bast-ide.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/bast-irq.c (95%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/bast.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/common-smdk.c (93%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/common-smdk.h (100%)
 rename arch/arm/{plat-samsung => mach-s3c}/cpu.c (62%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/cpu.h (91%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/cpufreq-utils.c (70%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/cpuidle.c (96%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/crag6410.h (95%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/dev-audio.c (97%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/dev-backlight.c (98%)
 rename arch/arm/{mach-s3c64xx/dev-uart.c => mach-s3c/dev-uart-s3c64xx.c} (95%)
 rename arch/arm/{plat-samsung => mach-s3c}/dev-uart.c (97%)
 rename arch/arm/{plat-samsung => mach-s3c}/devs.c (96%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/devs.h (100%)
 rename arch/arm/{mach-s3c24xx/include/mach/dma.h => mach-s3c/dma-s3c24xx.h} (100%)
 rename arch/arm/{mach-s3c64xx/include/mach/dma.h => mach-s3c/dma-s3c64xx.h} (100%)
 create mode 100644 arch/arm/mach-s3c/dma.h
 rename arch/arm/{mach-s3c24xx => mach-s3c}/fb-core.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/fb.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/gpio-cfg-helpers.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/gpio-cfg.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/gpio-core.h (99%)
 rename arch/arm/{mach-s3c24xx/include/mach/gpio-samsung.h => mach-s3c/gpio-samsung-s3c24xx.h} (99%)
 rename arch/arm/{mach-s3c64xx/include/mach/gpio-samsung.h => mach-s3c/gpio-samsung-s3c64xx.h} (100%)
 rename arch/arm/{plat-samsung => mach-s3c}/gpio-samsung.c (99%)
 create mode 100644 arch/arm/mach-s3c/gpio-samsung.h
 rename arch/arm/{mach-s3c24xx => mach-s3c}/gta02.h (94%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/h1940-bluetooth.c (96%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/h1940.h (100%)
 rename arch/arm/{mach-s3c24xx/include/mach => mach-s3c}/hardware.h (76%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/iic-core.h (100%)
 create mode 100644 arch/arm/mach-s3c/include/mach/io.h
 rename arch/arm/{mach-s3c24xx/include/mach/irqs.h => mach-s3c/include/mach/irqs-s3c24xx.h} (100%)
 rename arch/arm/{mach-s3c64xx/include/mach/irqs.h => mach-s3c/include/mach/irqs-s3c64xx.h} (100%)
 create mode 100644 arch/arm/mach-s3c/include/mach/irqs.h
 rename arch/arm/{plat-samsung/include/plat => mach-s3c/include/mach}/map-base.h (100%)
 rename arch/arm/{plat-samsung => mach-s3c}/init.c (98%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/iotiming-s3c2410.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/iotiming-s3c2412.c (98%)
 rename arch/arm/{mach-s3c24xx/irq-pm.c => mach-s3c/irq-pm-s3c24xx.c} (93%)
 rename arch/arm/{mach-s3c64xx/irq-pm.c => mach-s3c/irq-pm-s3c64xx.c} (97%)
 create mode 100644 arch/arm/mach-s3c/irq-s3c24xx-fiq-exports.c
 rename drivers/spi/spi-s3c24xx-fiq.S => arch/arm/mach-s3c/irq-s3c24xx-fiq.S (94%)
 rename {drivers/irqchip => arch/arm/mach-s3c}/irq-s3c24xx.c (99%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/irq-uart.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/keypad.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-amlm5900.c (84%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-anubis.c (97%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-anw6410.c (96%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-at2440evb.c (88%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-bast.c (98%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-crag6410-module.c (99%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-crag6410.c (98%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-gta02.c (90%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-h1940.c (92%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-hmt.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-jive.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-mini2440.c (93%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-mini6410.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-n30.c (93%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-ncp.c (92%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-nexcoder.c (92%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-osiris-dvs.c (98%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-osiris.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-otom.c (89%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-qt2410.c (88%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-real6410.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-rx1950.c (93%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-rx3715.c (90%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-s3c2416-dt.c (92%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-s3c64xx-dt.c (95%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-smartq.c (97%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-smartq.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-smartq5.c (93%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-smartq7.c (94%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-smdk2410.c (89%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-smdk2413.c (90%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-smdk2416.c (95%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-smdk2440.c (89%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-smdk2443.c (93%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-smdk6400.c (92%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/mach-smdk6410.c (98%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-tct_hammer.c (82%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-vr1000.c (95%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/mach-vstms.c (90%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/map-s3c.h (87%)
 rename arch/arm/{mach-s3c24xx/include/mach/map.h => mach-s3c/map-s3c24xx.h} (97%)
 rename arch/arm/{mach-s3c64xx/include/mach/map.h => mach-s3c/map-s3c64xx.h} (98%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/map-s5p.h (85%)
 create mode 100644 arch/arm/mach-s3c/map.h
 rename arch/arm/{mach-s3c24xx => mach-s3c}/nand-core.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/onenand-core.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/osiris.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/otom.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/pl080.c (99%)
 rename arch/arm/{plat-samsung => mach-s3c}/platformdata.c (96%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/pll-s3c2410.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/pll-s3c2440-12000000.c (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/pll-s3c2440-16934400.c (98%)
 rename arch/arm/{plat-samsung => mach-s3c}/pm-common.c (98%)
 create mode 100644 arch/arm/mach-s3c/pm-common.h
 rename arch/arm/{mach-s3c24xx/include/mach/pm-core.h => mach-s3c/pm-core-s3c24xx.h} (95%)
 rename arch/arm/{mach-s3c64xx/include/mach/pm-core.h => mach-s3c/pm-core-s3c64xx.h} (58%)
 create mode 100644 arch/arm/mach-s3c/pm-core.h
 rename arch/arm/{plat-samsung => mach-s3c}/pm-gpio.c (99%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/pm-h1940.S (80%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/pm-s3c2410.c (96%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/pm-s3c2412.c (95%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/pm-s3c2416.c (95%)
 rename arch/arm/{mach-s3c24xx/pm.c => mach-s3c/pm-s3c24xx.c} (94%)
 rename arch/arm/{mach-s3c64xx/pm.c => mach-s3c/pm-s3c64xx.c} (83%)
 rename arch/arm/{plat-samsung => mach-s3c}/pm.c (94%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/pm.h (98%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/pwm-core.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/regs-adc.h (100%)
 rename arch/arm/{mach-s3c24xx/include/mach/regs-clock.h => mach-s3c/regs-clock-s3c24xx.h} (99%)
 rename arch/arm/{mach-s3c64xx/include/mach/regs-clock.h => mach-s3c/regs-clock-s3c64xx.h} (100%)
 create mode 100644 arch/arm/mach-s3c/regs-clock.h
 rename arch/arm/{mach-s3c24xx => mach-s3c}/regs-dsc.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/regs-gpio-memport.h (100%)
 rename arch/arm/{mach-s3c24xx/include/mach/regs-gpio.h => mach-s3c/regs-gpio-s3c24xx.h} (99%)
 rename arch/arm/{mach-s3c64xx/include/mach/regs-gpio.h => mach-s3c/regs-gpio-s3c64xx.h} (100%)
 create mode 100644 arch/arm/mach-s3c/regs-gpio.h
 rename arch/arm/{mach-s3c24xx/include/mach/regs-irq.h => mach-s3c/regs-irq-s3c24xx.h} (98%)
 rename arch/arm/{mach-s3c64xx/include/mach/regs-irq.h => mach-s3c/regs-irq-s3c64xx.h} (100%)
 create mode 100644 arch/arm/mach-s3c/regs-irq.h
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/regs-irqtype.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/regs-mem.h (98%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/regs-modem.h (100%)
 rename arch/arm/{mach-s3c24xx/include/mach => mach-s3c}/regs-s3c2443-clock.h (81%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/regs-srom.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/regs-sys.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/regs-syscon-power.h (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/regs-usb-hsotg-phy.h (100%)
 rename arch/arm/{mach-s3c24xx/include/mach => mach-s3c}/rtc-core.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c2410.c (90%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c2412-power.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c2412.c (94%)
 rename arch/arm/{mach-s3c24xx/include/mach => mach-s3c}/s3c2412.h (96%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c2416.c (88%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c2440.c (85%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c2442.c (82%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c2443.c (89%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/s3c244x.c (93%)
 rename arch/arm/{mach-s3c24xx/common.c => mach-s3c/s3c24xx.c} (98%)
 rename arch/arm/{mach-s3c24xx/common.h => mach-s3c/s3c24xx.h} (99%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/s3c6400.c (89%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/s3c6410.c (89%)
 rename arch/arm/{mach-s3c64xx/common.c => mach-s3c/s3c64xx.c} (97%)
 rename arch/arm/{mach-s3c64xx/common.h => mach-s3c/s3c64xx.h} (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/samsung-time.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/sdhci.h (99%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/setup-camif.c (95%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/setup-fb-24bpp.c (86%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/setup-i2c.c (79%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/setup-i2c0.c (90%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/setup-i2c1.c (90%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/setup-ide.c (89%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/setup-keypad.c (86%)
 rename arch/arm/{mach-s3c24xx/setup-sdhci-gpio.c => mach-s3c/setup-sdhci-gpio-s3c24xx.c} (90%)
 rename arch/arm/{mach-s3c64xx/setup-sdhci-gpio.c => mach-s3c/setup-sdhci-gpio-s3c64xx.c} (95%)
 rename arch/arm/{mach-s3c24xx/setup-spi.c => mach-s3c/setup-spi-s3c24xx.c} (85%)
 rename arch/arm/{mach-s3c64xx/setup-spi.c => mach-s3c/setup-spi-s3c64xx.c} (89%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/setup-ts.c (88%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/setup-usb-phy.c (96%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/simtec-audio.c (86%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/simtec-nor.c (98%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/simtec-pm.c (92%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/simtec-usb.c (96%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/simtec.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/sleep-s3c2410.S (92%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/sleep-s3c2412.S (93%)
 rename arch/arm/{mach-s3c24xx/sleep.S => mach-s3c/sleep-s3c24xx.S} (92%)
 rename arch/arm/{mach-s3c64xx/sleep.S => mach-s3c/sleep-s3c64xx.S} (97%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/spi-core.h (100%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/usb-phy.h (100%)
 rename arch/arm/{mach-s3c24xx => mach-s3c}/vr1000.h (100%)
 rename arch/arm/{plat-samsung => mach-s3c}/wakeup-mask.c (94%)
 rename arch/arm/{plat-samsung/include/plat => mach-s3c}/wakeup-mask.h (100%)
 rename arch/arm/{plat-samsung => mach-s3c}/watchdog-reset.c (100%)
 rename arch/arm/{mach-s3c64xx => mach-s3c}/watchdog-reset.h (100%)
 delete mode 100644 arch/arm/mach-s3c24xx/include/mach/fb.h
 delete mode 100644 arch/arm/mach-s3c24xx/include/mach/io.h
 delete mode 100644 arch/arm/mach-s3c64xx/include/mach/hardware.h
 rename arch/arm/plat-samsung/pm-check.c => drivers/soc/samsung/s3c-pm-check.c (99%)
 rename arch/arm/plat-samsung/pm-debug.c => drivers/soc/samsung/s3c-pm-debug.c (78%)
 rename arch/arm/plat-samsung/include/plat/regs-spi.h => drivers/spi/spi-s3c24xx-regs.h (95%)
 rename arch/arm/plat-samsung/include/plat/regs-udc.h => drivers/usb/gadget/udc/s3c2410_udc_regs.h (99%)
 rename arch/arm/mach-s3c24xx/include/mach/regs-lcd.h => drivers/video/fbdev/s3c2410fb-regs-lcd.h (84%)
 rename {arch/arm/plat-samsung/include/plat => include/linux/platform_data}/fb-s3c2410.h (57%)
 rename arch/arm/plat-samsung/include/plat/adc.h => include/linux/soc/samsung/s3c-adc.h (100%)
 rename arch/arm/plat-samsung/include/plat/cpu-freq.h => include/linux/soc/samsung/s3c-cpu-freq.h (100%)
 rename arch/arm/plat-samsung/include/plat/cpu-freq-core.h => include/linux/soc/samsung/s3c-cpufreq-core.h (96%)
 rename arch/arm/plat-samsung/include/plat/pm-common.h => include/linux/soc/samsung/s3c-pm.h (55%)
 rename drivers/spi/spi-s3c24xx-fiq.h => include/linux/spi/s3c24xx-fiq.h (78%)

Cc: linux-kernel@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-samsung-soc@vger.kernel.org
Cc: linux-pm@vger.kernel.org
Cc: patches@opensource.cirrus.com
Cc: linux-stm32@st-md-mailman.stormreply.com
Cc: linux-clk@vger.kernel.org
Cc: linux-hwmon@vger.kernel.org
Cc: linux-input@vger.kernel.org
Cc: linux-leds@vger.kernel.org
Cc: linux-mmc@vger.kernel.org
Cc: linux-pwm@vger.kernel.org
Cc: linux-spi@vger.kernel.org
Cc: linux-serial@vger.kernel.org
Cc: linux-usb@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-fbdev@vger.kernel.org
Cc: alsa-devel@alsa-project.org
-- 
2.20.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG
       [not found] ` <20191010203043.1241612-1-arnd@arndb.de>
@ 2019-10-10 20:29   ` Arnd Bergmann
  2019-10-15 14:12     ` Ulf Hansson
  2019-10-23 10:57     ` Krzysztof Kozlowski
  2019-10-10 20:29   ` [PATCH 11/36] ARM: s5pv210: split from plat-samsung Arnd Bergmann
  2019-10-10 20:30   ` [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files Arnd Bergmann
  2 siblings, 2 replies; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-10 20:29 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Ulf Hansson
  Cc: linux-samsung-soc, Arnd Bergmann, Bartlomiej Zolnierkiewicz,
	linus.walleij, linux-mmc, linux-kernel, Olof Johansson,
	Enrico Weigelt, metux IT consult, Sascha Hauer, linux-arm-kernel

Now that no code in arch/arm is shared between mach-exynos and the
others, make the split formal.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/arm/Kconfig.debug        | 8 ++++----
 arch/arm/Makefile             | 1 -
 arch/arm/mach-exynos/Makefile | 4 ----
 arch/arm/plat-samsung/Kconfig | 4 ++--
 drivers/mmc/host/Kconfig      | 2 +-
 5 files changed, 7 insertions(+), 12 deletions(-)

diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index d05b836dfeb2..9c4f2d6deb06 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -998,7 +998,7 @@ choice
 		  via SCIFA4 on Renesas SH-Mobile AG5 (SH73A0).
 
 	config DEBUG_S3C_UART0
-		depends on PLAT_SAMSUNG
+		depends on PLAT_SAMSUNG || ARCH_EXYNOS
 		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
 		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
 		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
@@ -1010,7 +1010,7 @@ choice
 		  by the boot-loader before use.
 
 	config DEBUG_S3C_UART1
-		depends on PLAT_SAMSUNG
+		depends on PLAT_SAMSUNG || ARCH_EXYNOS
 		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
 		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
 		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
@@ -1022,7 +1022,7 @@ choice
 		  by the boot-loader before use.
 
 	config DEBUG_S3C_UART2
-		depends on PLAT_SAMSUNG
+		depends on PLAT_SAMSUNG || ARCH_EXYNOS
 		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
 		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
 		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
@@ -1034,7 +1034,7 @@ choice
 		  by the boot-loader before use.
 
 	config DEBUG_S3C_UART3
-		depends on PLAT_SAMSUNG && (ARCH_EXYNOS || ARCH_S5PV210)
+		depends on ARCH_EXYNOS || ARCH_S5PV210
 		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
 		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
 		select DEBUG_S5PV210_UART if ARCH_S5PV210
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index db857d07114f..f492d7c338fe 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -233,7 +233,6 @@ machine-$(CONFIG_PLAT_SPEAR)		+= spear
 
 # Platform directory name.  This list is sorted alphanumerically
 # by CONFIG_* macro name.
-plat-$(CONFIG_ARCH_EXYNOS)	+= samsung
 plat-$(CONFIG_ARCH_OMAP)	+= omap
 plat-$(CONFIG_ARCH_S3C64XX)	+= samsung
 plat-$(CONFIG_ARCH_S5PV210)	+= samsung
diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile
index 0fd3fcf8bfb0..53fa363c8e44 100644
--- a/arch/arm/mach-exynos/Makefile
+++ b/arch/arm/mach-exynos/Makefile
@@ -3,10 +3,6 @@
 # Copyright (c) 2010-2011 Samsung Electronics Co., Ltd.
 #		http://www.samsung.com/
 
-ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree)/arch/arm/plat-samsung/include
-
-# Core
-
 obj-$(CONFIG_ARCH_EXYNOS)	+= exynos.o exynos-smc.o firmware.o
 
 obj-$(CONFIG_EXYNOS_CPU_SUSPEND) += pm.o sleep.o
diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
index 832ab0e6cd72..e31a156a27df 100644
--- a/arch/arm/plat-samsung/Kconfig
+++ b/arch/arm/plat-samsung/Kconfig
@@ -4,7 +4,7 @@
 
 config PLAT_SAMSUNG
 	bool
-	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_EXYNOS || ARCH_S5PV210
+	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
 	default y
 	select GENERIC_IRQ_CHIP
 	select NO_IOPORT_MAP
@@ -240,7 +240,7 @@ config SAMSUNG_PM_DEBUG
 	bool "Samsung PM Suspend debug"
 	depends on PM && DEBUG_KERNEL
 	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
-	depends on DEBUG_EXYNOS_UART || DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART
+	depends on DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART
 	help
 	  Say Y here if you want verbose debugging from the PM Suspend and
 	  Resume code. See <file:Documentation/arm/samsung-s3c24xx/suspend.rst>
diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
index 49ea02c467bf..400a581c918c 100644
--- a/drivers/mmc/host/Kconfig
+++ b/drivers/mmc/host/Kconfig
@@ -275,7 +275,7 @@ config MMC_SDHCI_TEGRA
 
 config MMC_SDHCI_S3C
 	tristate "SDHCI support on Samsung S3C SoC"
-	depends on MMC_SDHCI && PLAT_SAMSUNG
+	depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_EXYNOS)
 	help
 	  This selects the Secure Digital Host Controller Interface (SDHCI)
 	  often referrered to as the HSMMC block in some of the Samsung S3C
-- 
2.20.0

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 11/36] ARM: s5pv210: split from plat-samsung
       [not found] ` <20191010203043.1241612-1-arnd@arndb.de>
  2019-10-10 20:29   ` [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG Arnd Bergmann
@ 2019-10-10 20:29   ` Arnd Bergmann
  2019-10-11  5:51     ` Uwe Kleine-König
                       ` (3 more replies)
  2019-10-10 20:30   ` [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files Arnd Bergmann
  2 siblings, 4 replies; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-10 20:29 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Ulf Hansson, Thierry Reding,
	Mark Brown, Greg Kroah-Hartman, Jiri Slaby, Sangbeom Kim,
	Sylwester Nawrocki, Liam Girdwood
  Cc: linux-pwm, alsa-devel, linux-samsung-soc, Arnd Bergmann,
	Bartlomiej Zolnierkiewicz, linux-kernel, linus.walleij,
	linux-mmc, Takashi Iwai, Jaroslav Kysela, Mauro Carvalho Chehab,
	Faiz Abbas, Clément Péron, linux-serial,
	Uwe Kleine-König, Olof Johansson, linux-spi, Sascha Hauer,
	linux-arm-kernel

These can be build completely independently, so split
the two Kconfig symbols.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/arm/Kconfig.debug        | 6 +++---
 arch/arm/Makefile             | 1 -
 arch/arm/plat-samsung/Kconfig | 2 +-
 drivers/mmc/host/Kconfig      | 2 +-
 drivers/pwm/Kconfig           | 2 +-
 drivers/spi/Kconfig           | 2 +-
 drivers/tty/serial/Kconfig    | 2 +-
 sound/soc/samsung/Kconfig     | 2 +-
 8 files changed, 9 insertions(+), 10 deletions(-)

diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index 9c4f2d6deb06..4c4e97ae4fcb 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -998,7 +998,7 @@ choice
 		  via SCIFA4 on Renesas SH-Mobile AG5 (SH73A0).
 
 	config DEBUG_S3C_UART0
-		depends on PLAT_SAMSUNG || ARCH_EXYNOS
+		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
 		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
 		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
 		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
@@ -1010,7 +1010,7 @@ choice
 		  by the boot-loader before use.
 
 	config DEBUG_S3C_UART1
-		depends on PLAT_SAMSUNG || ARCH_EXYNOS
+		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
 		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
 		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
 		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
@@ -1022,7 +1022,7 @@ choice
 		  by the boot-loader before use.
 
 	config DEBUG_S3C_UART2
-		depends on PLAT_SAMSUNG || ARCH_EXYNOS
+		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
 		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
 		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
 		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index f492d7c338fe..a1bc15cda751 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -235,7 +235,6 @@ machine-$(CONFIG_PLAT_SPEAR)		+= spear
 # by CONFIG_* macro name.
 plat-$(CONFIG_ARCH_OMAP)	+= omap
 plat-$(CONFIG_ARCH_S3C64XX)	+= samsung
-plat-$(CONFIG_ARCH_S5PV210)	+= samsung
 plat-$(CONFIG_PLAT_ORION)	+= orion
 plat-$(CONFIG_PLAT_PXA)		+= pxa
 plat-$(CONFIG_PLAT_S3C24XX)	+= samsung
diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
index 740bdb23f38a..1530946cc672 100644
--- a/arch/arm/plat-samsung/Kconfig
+++ b/arch/arm/plat-samsung/Kconfig
@@ -4,7 +4,7 @@
 
 config PLAT_SAMSUNG
 	bool
-	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
+	depends on PLAT_S3C24XX || ARCH_S3C64XX
 	default y
 	select GENERIC_IRQ_CHIP
 	select NO_IOPORT_MAP
diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
index 400a581c918c..16a0e5430b44 100644
--- a/drivers/mmc/host/Kconfig
+++ b/drivers/mmc/host/Kconfig
@@ -275,7 +275,7 @@ config MMC_SDHCI_TEGRA
 
 config MMC_SDHCI_S3C
 	tristate "SDHCI support on Samsung S3C SoC"
-	depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_EXYNOS)
+	depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS)
 	help
 	  This selects the Secure Digital Host Controller Interface (SDHCI)
 	  often referrered to as the HSMMC block in some of the Samsung S3C
diff --git a/drivers/pwm/Kconfig b/drivers/pwm/Kconfig
index e3a2518503ed..8eb738cac0c7 100644
--- a/drivers/pwm/Kconfig
+++ b/drivers/pwm/Kconfig
@@ -394,7 +394,7 @@ config PWM_ROCKCHIP
 
 config PWM_SAMSUNG
 	tristate "Samsung PWM support"
-	depends on PLAT_SAMSUNG || ARCH_EXYNOS
+	depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
 	help
 	  Generic PWM framework driver for Samsung.
 
diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
index 6f7fdcbb9151..355391ee643d 100644
--- a/drivers/spi/Kconfig
+++ b/drivers/spi/Kconfig
@@ -625,7 +625,7 @@ config SPI_S3C24XX_FIQ
 
 config SPI_S3C64XX
 	tristate "Samsung S3C64XX series type SPI"
-	depends on (PLAT_SAMSUNG || ARCH_EXYNOS || COMPILE_TEST)
+	depends on (PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS || COMPILE_TEST)
 	help
 	  SPI driver for Samsung S3C64XX and newer SoCs.
 
diff --git a/drivers/tty/serial/Kconfig b/drivers/tty/serial/Kconfig
index 4789b5d62f63..17f01cf3009c 100644
--- a/drivers/tty/serial/Kconfig
+++ b/drivers/tty/serial/Kconfig
@@ -237,7 +237,7 @@ config SERIAL_CLPS711X_CONSOLE
 
 config SERIAL_SAMSUNG
 	tristate "Samsung SoC serial support"
-	depends on PLAT_SAMSUNG || ARCH_EXYNOS
+	depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
 	select SERIAL_CORE
 	help
 	  Support for the on-chip UARTs on the Samsung S3C24XX series CPUs,
diff --git a/sound/soc/samsung/Kconfig b/sound/soc/samsung/Kconfig
index 638983123d8f..7a0035dd9995 100644
--- a/sound/soc/samsung/Kconfig
+++ b/sound/soc/samsung/Kconfig
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: GPL-2.0-only
 menuconfig SND_SOC_SAMSUNG
 	tristate "ASoC support for Samsung"
-	depends on PLAT_SAMSUNG || ARCH_EXYNOS || COMPILE_TEST
+	depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS || COMPILE_TEST
 	depends on COMMON_CLK
 	select SND_SOC_GENERIC_DMAENGINE_PCM
 	---help---
-- 
2.20.0

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files
       [not found] ` <20191010203043.1241612-1-arnd@arndb.de>
  2019-10-10 20:29   ` [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG Arnd Bergmann
  2019-10-10 20:29   ` [PATCH 11/36] ARM: s5pv210: split from plat-samsung Arnd Bergmann
@ 2019-10-10 20:30   ` Arnd Bergmann
  2019-10-15 14:12     ` Ulf Hansson
  2019-10-16 13:12     ` Linus Walleij
  2 siblings, 2 replies; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-10 20:30 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Ben Dooks, Ulf Hansson
  Cc: linux-samsung-soc, Arnd Bergmann, linus.walleij, linux-mmc,
	linux-kernel, linux-arm-kernel

Rather than call the internal s3c_gpio_cfgall_range() function
through a platform header, move the code into the set_power
callback that is already exported by the board, and add
a default implementation.

In DT mode, the code already does not set the pin config,
so nothing changes there.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/arm/mach-s3c24xx/include/mach/pm-core.h |  1 +
 arch/arm/mach-s3c24xx/mach-amlm5900.c        | 15 +++++
 arch/arm/mach-s3c24xx/mach-at2440evb.c       | 10 ++-
 arch/arm/mach-s3c24xx/mach-gta02.c           | 15 +++++
 arch/arm/mach-s3c24xx/mach-h1940.c           |  8 +++
 arch/arm/mach-s3c24xx/mach-mini2440.c        |  9 ++-
 arch/arm/mach-s3c24xx/mach-n30.c             |  9 +++
 arch/arm/mach-s3c24xx/mach-qt2410.c          | 15 +++++
 arch/arm/mach-s3c24xx/mach-rx1950.c          |  9 +++
 arch/arm/mach-s3c24xx/mach-tct_hammer.c      | 15 +++++
 arch/arm/plat-samsung/devs.c                 | 29 ++++++++
 drivers/mmc/host/s3cmci.c                    | 69 +++++---------------
 include/linux/platform_data/mmc-s3cmci.h     |  2 +
 13 files changed, 152 insertions(+), 54 deletions(-)

diff --git a/arch/arm/mach-s3c24xx/include/mach/pm-core.h b/arch/arm/mach-s3c24xx/include/mach/pm-core.h
index 8f87606c4cdc..a22b4a37ee57 100644
--- a/arch/arm/mach-s3c24xx/include/mach/pm-core.h
+++ b/arch/arm/mach-s3c24xx/include/mach/pm-core.h
@@ -12,6 +12,7 @@
 
 #include "regs-clock.h"
 #include "regs-irq.h"
+#include <mach/irqs.h>
 
 static inline void s3c_pm_debug_init_uart(void)
 {
diff --git a/arch/arm/mach-s3c24xx/mach-amlm5900.c b/arch/arm/mach-s3c24xx/mach-amlm5900.c
index 9a9daf526d0c..40ad23b52bc0 100644
--- a/arch/arm/mach-s3c24xx/mach-amlm5900.c
+++ b/arch/arm/mach-s3c24xx/mach-amlm5900.c
@@ -13,6 +13,7 @@
 #include <linux/list.h>
 #include <linux/timer.h>
 #include <linux/init.h>
+#include <linux/gpio/machine.h>
 #include <linux/gpio.h>
 #include <linux/device.h>
 #include <linux/platform_device.h>
@@ -124,6 +125,19 @@ static struct s3c2410_uartcfg amlm5900_uartcfgs[] = {
 	}
 };
 
+static struct gpiod_lookup_table amlm5900_mmc_gpio_table = {
+	.dev_id = "s3c2410-sdi",
+	.table = {
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
+		{ },
+	},
+};
 
 static struct platform_device *amlm5900_devices[] __initdata = {
 #ifdef CONFIG_FB_S3C2410
@@ -219,6 +233,7 @@ static void __init amlm5900_init(void)
 	s3c24xx_fb_set_platdata(&amlm5900_fb_info);
 #endif
 	s3c_i2c0_set_platdata(NULL);
+	gpiod_add_lookup_table(&amlm5900_mmc_gpio_table);
 	platform_add_devices(amlm5900_devices, ARRAY_SIZE(amlm5900_devices));
 }
 
diff --git a/arch/arm/mach-s3c24xx/mach-at2440evb.c b/arch/arm/mach-s3c24xx/mach-at2440evb.c
index 58c5ef3cf1d7..3a793aaf2cba 100644
--- a/arch/arm/mach-s3c24xx/mach-at2440evb.c
+++ b/arch/arm/mach-s3c24xx/mach-at2440evb.c
@@ -136,7 +136,7 @@ static struct platform_device at2440evb_device_eth = {
 };
 
 static struct s3c24xx_mci_pdata at2440evb_mci_pdata __initdata = {
-	/* Intentionally left blank */
+	.set_power = s3c24xx_mci_def_set_power,
 };
 
 static struct gpiod_lookup_table at2440evb_mci_gpio_table = {
@@ -144,10 +144,18 @@ static struct gpiod_lookup_table at2440evb_mci_gpio_table = {
 	.table = {
 		/* Card detect S3C2410_GPG(10) */
 		GPIO_LOOKUP("GPG", 10, "cd", GPIO_ACTIVE_LOW),
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
 		{ },
 	},
 };
 
+
 /* 7" LCD panel */
 
 static struct s3c2410fb_display at2440evb_lcd_cfg __initdata = {
diff --git a/arch/arm/mach-s3c24xx/mach-gta02.c b/arch/arm/mach-s3c24xx/mach-gta02.c
index 1ca0460d82f4..61b8c6badeb8 100644
--- a/arch/arm/mach-s3c24xx/mach-gta02.c
+++ b/arch/arm/mach-s3c24xx/mach-gta02.c
@@ -489,6 +489,20 @@ static struct platform_device gta02_audio = {
 	.id = -1,
 };
 
+static struct gpiod_lookup_table gta02_mmc_gpio_table = {
+	.dev_id = "s3c2410-sdi",
+	.table = {
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
+		{ },
+	},
+};
+
 static void __init gta02_map_io(void)
 {
 	s3c24xx_init_io(gta02_iodesc, ARRAY_SIZE(gta02_iodesc));
@@ -545,6 +559,7 @@ static void __init gta02_machine_init(void)
 			      S3C_GPIO_PULL_NONE);
 
 	gpiod_add_lookup_table(&gta02_audio_gpio_table);
+	gpiod_add_lookup_table(&gta02_mmc_gpio_table);
 	platform_add_devices(gta02_devices, ARRAY_SIZE(gta02_devices));
 	pm_power_off = gta02_poweroff;
 
diff --git a/arch/arm/mach-s3c24xx/mach-h1940.c b/arch/arm/mach-s3c24xx/mach-h1940.c
index 11f705fb5e32..24f785da7659 100644
--- a/arch/arm/mach-s3c24xx/mach-h1940.c
+++ b/arch/arm/mach-s3c24xx/mach-h1940.c
@@ -462,6 +462,7 @@ static void h1940_set_mmc_power(unsigned char power_mode, unsigned short vdd)
 static struct s3c24xx_mci_pdata h1940_mmc_cfg __initdata = {
 	.set_power     = h1940_set_mmc_power,
 	.ocr_avail     = MMC_VDD_32_33,
+	.set_power = s3c24xx_mci_def_set_power,
 };
 
 static struct gpiod_lookup_table h1940_mmc_gpio_table = {
@@ -471,6 +472,13 @@ static struct gpiod_lookup_table h1940_mmc_gpio_table = {
 		GPIO_LOOKUP("GPF", 5, "cd", GPIO_ACTIVE_LOW),
 		/* Write protect S3C2410_GPH(8) */
 		GPIO_LOOKUP("GPH", 8, "wp", GPIO_ACTIVE_LOW),
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
 		{ },
 	},
 };
diff --git a/arch/arm/mach-s3c24xx/mach-mini2440.c b/arch/arm/mach-s3c24xx/mach-mini2440.c
index 894d43ff94f1..5c000efdf0e8 100644
--- a/arch/arm/mach-s3c24xx/mach-mini2440.c
+++ b/arch/arm/mach-s3c24xx/mach-mini2440.c
@@ -236,7 +236,7 @@ static struct s3c2410fb_mach_info mini2440_fb_info __initdata = {
 
 static struct s3c24xx_mci_pdata mini2440_mmc_cfg __initdata = {
 	.wprotect_invert	= 1,
-	.set_power		= NULL,
+	.set_power		= s3c24xx_mci_def_set_power,
 	.ocr_avail		= MMC_VDD_32_33|MMC_VDD_33_34,
 };
 
@@ -247,6 +247,13 @@ static struct gpiod_lookup_table mini2440_mmc_gpio_table = {
 		GPIO_LOOKUP("GPG", 8, "cd", GPIO_ACTIVE_LOW),
 		/* Write protect S3C2410_GPH(8) */
 		GPIO_LOOKUP("GPH", 8, "wp", GPIO_ACTIVE_HIGH),
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
 		{ },
 	},
 };
diff --git a/arch/arm/mach-s3c24xx/mach-n30.c b/arch/arm/mach-s3c24xx/mach-n30.c
index 5f5ca4b7015c..8d7ad61e9930 100644
--- a/arch/arm/mach-s3c24xx/mach-n30.c
+++ b/arch/arm/mach-s3c24xx/mach-n30.c
@@ -339,6 +339,8 @@ static struct s3c2410fb_mach_info n30_fb_info __initdata = {
 
 static void n30_sdi_set_power(unsigned char power_mode, unsigned short vdd)
 {
+	s3c24xx_mci_def_set_power(power_mode, vdd);
+
 	switch (power_mode) {
 	case MMC_POWER_ON:
 	case MMC_POWER_UP:
@@ -364,6 +366,13 @@ static struct gpiod_lookup_table n30_mci_gpio_table = {
 		/* Write protect S3C2410_GPG(10) */
 		GPIO_LOOKUP("GPG", 10, "wp", GPIO_ACTIVE_LOW),
 		{ },
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
 	},
 };
 
diff --git a/arch/arm/mach-s3c24xx/mach-qt2410.c b/arch/arm/mach-s3c24xx/mach-qt2410.c
index 6686f02a3f4f..9b47b8434f10 100644
--- a/arch/arm/mach-s3c24xx/mach-qt2410.c
+++ b/arch/arm/mach-s3c24xx/mach-qt2410.c
@@ -219,6 +219,20 @@ static struct gpiod_lookup_table qt2410_spi_gpiod_table = {
 	},
 };
 
+static struct gpiod_lookup_table qt2410_mmc_gpiod_table = {
+	.dev_id = "s3c2410-sdi",
+	.table = {
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
+		{ },
+	},
+};
+
 /* Board devices */
 
 static struct platform_device *qt2410_devices[] __initdata = {
@@ -342,6 +356,7 @@ static void __init qt2410_machine_init(void)
 	s3c_gpio_cfgall_range(S3C2410_GPE(0), 5, S3C_GPIO_SFN(2),
 			      S3C_GPIO_PULL_NONE);
 	gpiod_add_lookup_table(&qt2410_spi_gpiod_table);
+	gpiod_add_lookup_table(&qt2410_mmc_gpiod_table);
 	platform_add_devices(qt2410_devices, ARRAY_SIZE(qt2410_devices));
 	s3c_pm_init();
 }
diff --git a/arch/arm/mach-s3c24xx/mach-rx1950.c b/arch/arm/mach-s3c24xx/mach-rx1950.c
index 4eeede398775..820e626f5129 100644
--- a/arch/arm/mach-s3c24xx/mach-rx1950.c
+++ b/arch/arm/mach-s3c24xx/mach-rx1950.c
@@ -545,6 +545,8 @@ static struct platform_device rx1950_backlight = {
 
 static void rx1950_set_mmc_power(unsigned char power_mode, unsigned short vdd)
 {
+	s3c24xx_mci_def_set_power(power_mode, vdd);
+
 	switch (power_mode) {
 	case MMC_POWER_OFF:
 		gpio_direction_output(S3C2410_GPJ(1), 0);
@@ -570,6 +572,13 @@ static struct gpiod_lookup_table rx1950_mmc_gpio_table = {
 		GPIO_LOOKUP("GPF", 5, "cd", GPIO_ACTIVE_LOW),
 		/* Write protect S3C2410_GPH(8) */
 		GPIO_LOOKUP("GPH", 8, "wp", GPIO_ACTIVE_LOW),
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
 		{ },
 	},
 };
diff --git a/arch/arm/mach-s3c24xx/mach-tct_hammer.c b/arch/arm/mach-s3c24xx/mach-tct_hammer.c
index 8d8ddd6ea305..d6dbbe6759bc 100644
--- a/arch/arm/mach-s3c24xx/mach-tct_hammer.c
+++ b/arch/arm/mach-s3c24xx/mach-tct_hammer.c
@@ -7,6 +7,7 @@
 // derived from linux/arch/arm/mach-s3c2410/mach-bast.c, written by
 // Ben Dooks <ben@simtec.co.uk>
 
+#include <linux/gpio/machine.h>
 #include <linux/kernel.h>
 #include <linux/types.h>
 #include <linux/interrupt.h>
@@ -103,6 +104,19 @@ static struct s3c2410_uartcfg tct_hammer_uartcfgs[] = {
 	}
 };
 
+static struct gpiod_lookup_table tct_hammer_mmc_gpio_table = {
+	.dev_id = "s3c2410-sdi",
+	.table = {
+		/* bus pins */
+		GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
+		GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
+		{ },
+	},
+};
 
 static struct platform_device *tct_hammer_devices[] __initdata = {
 	&s3c_device_adc,
@@ -131,6 +145,7 @@ static void __init tct_hammer_init_time(void)
 static void __init tct_hammer_init(void)
 {
 	s3c_i2c0_set_platdata(NULL);
+	gpiod_add_lookup_table(&tct_hammer_mmc_gpio_table);
 	platform_add_devices(tct_hammer_devices, ARRAY_SIZE(tct_hammer_devices));
 }
 
diff --git a/arch/arm/plat-samsung/devs.c b/arch/arm/plat-samsung/devs.c
index ddd90f0bb380..c0739bda060b 100644
--- a/arch/arm/plat-samsung/devs.c
+++ b/arch/arm/plat-samsung/devs.c
@@ -5,6 +5,7 @@
 //
 // Base SAMSUNG platform device definitions
 
+#include <linux/gpio.h>
 #include <linux/kernel.h>
 #include <linux/types.h>
 #include <linux/interrupt.h>
@@ -40,6 +41,8 @@
 #include <mach/dma.h>
 #include <mach/irqs.h>
 #include <mach/map.h>
+#include <mach/gpio-samsung.h>
+#include <plat/gpio-cfg.h>
 #include <mach/regs-s3c2443-clock.h>
 
 #include <plat/cpu.h>
@@ -833,16 +836,42 @@ struct platform_device s3c_device_rtc = {
 /* SDI */
 
 #ifdef CONFIG_PLAT_S3C24XX
+void s3c24xx_mci_def_set_power(unsigned char power_mode, unsigned short vdd)
+{
+	switch (power_mode) {
+	case MMC_POWER_ON:
+	case MMC_POWER_UP:
+		/* Configure GPE5...GPE10 pins in SD mode */
+		s3c_gpio_cfgall_range(S3C2410_GPE(5), 6, S3C_GPIO_SFN(2),
+				      S3C_GPIO_PULL_NONE);
+		break;
+
+	case MMC_POWER_OFF:
+	default:
+		gpio_direction_output(S3C2410_GPE(5), 0);
+		break;
+	}
+}
+
 static struct resource s3c_sdi_resource[] = {
 	[0] = DEFINE_RES_MEM(S3C24XX_PA_SDI, S3C24XX_SZ_SDI),
 	[1] = DEFINE_RES_IRQ(IRQ_SDI),
 };
 
+static struct s3c24xx_mci_pdata s3cmci_def_pdata = {
+	/* This is currently here to avoid a number of if (host->pdata)
+	 * checks. Any zero fields to ensure reasonable defaults are picked. */
+	.no_wprotect = 1,
+	.no_detect = 1,
+	.set_power = s3c24xx_mci_def_set_power,
+};
+
 struct platform_device s3c_device_sdi = {
 	.name		= "s3c2410-sdi",
 	.id		= -1,
 	.num_resources	= ARRAY_SIZE(s3c_sdi_resource),
 	.resource	= s3c_sdi_resource,
+	.dev.platform_data = &s3cmci_def_pdata,
 };
 
 void __init s3c24xx_mci_set_platdata(struct s3c24xx_mci_pdata *pdata)
diff --git a/drivers/mmc/host/s3cmci.c b/drivers/mmc/host/s3cmci.c
index bce9c33bc4b5..c2b46640a78b 100644
--- a/drivers/mmc/host/s3cmci.c
+++ b/drivers/mmc/host/s3cmci.c
@@ -25,9 +25,7 @@
 #include <linux/of_device.h>
 #include <linux/mmc/slot-gpio.h>
 
-#include <plat/gpio-cfg.h>
 #include <mach/dma.h>
-#include <mach/gpio-samsung.h>
 
 #include <linux/platform_data/mmc-s3cmci.h>
 
@@ -307,7 +305,8 @@ static inline void clear_imask(struct s3cmci_host *host)
 static void s3cmci_check_sdio_irq(struct s3cmci_host *host)
 {
 	if (host->sdio_irqen) {
-		if (gpio_get_value(S3C2410_GPE(8)) == 0) {
+		if (host->pdata->bus[3] &&
+		    gpiod_get_value(host->pdata->bus[3]) == 0) {
 			pr_debug("%s: signalling irq\n", __func__);
 			mmc_signal_sdio_irq(host->mmc);
 		}
@@ -1213,33 +1212,20 @@ static void s3cmci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
 	switch (ios->power_mode) {
 	case MMC_POWER_ON:
 	case MMC_POWER_UP:
-		/* Configure GPE5...GPE10 pins in SD mode */
-		if (!host->pdev->dev.of_node)
-			s3c_gpio_cfgall_range(S3C2410_GPE(5), 6, S3C_GPIO_SFN(2),
-					      S3C_GPIO_PULL_NONE);
-
-		if (host->pdata->set_power)
-			host->pdata->set_power(ios->power_mode, ios->vdd);
-
 		if (!host->is2440)
 			mci_con |= S3C2410_SDICON_FIFORESET;
-
 		break;
 
 	case MMC_POWER_OFF:
 	default:
-		if (!host->pdev->dev.of_node)
-			gpio_direction_output(S3C2410_GPE(5), 0);
-
 		if (host->is2440)
 			mci_con |= S3C2440_SDICON_SDRESET;
-
-		if (host->pdata->set_power)
-			host->pdata->set_power(ios->power_mode, ios->vdd);
-
 		break;
 	}
 
+	if (host->pdata->set_power)
+		host->pdata->set_power(ios->power_mode, ios->vdd);
+
 	s3cmci_set_clk(host, ios);
 
 	/* Set CLOCK_ENABLE */
@@ -1317,13 +1303,6 @@ static const struct mmc_host_ops s3cmci_ops = {
 	.enable_sdio_irq = s3cmci_enable_sdio_irq,
 };
 
-static struct s3c24xx_mci_pdata s3cmci_def_pdata = {
-	/* This is currently here to avoid a number of if (host->pdata)
-	 * checks. Any zero fields to ensure reasonable defaults are picked. */
-	 .no_wprotect = 1,
-	 .no_detect = 1,
-};
-
 #ifdef CONFIG_ARM_S3C24XX_CPUFREQ
 
 static int s3cmci_cpufreq_transition(struct notifier_block *nb,
@@ -1477,24 +1456,21 @@ static int s3cmci_probe_pdata(struct s3cmci_host *host)
 	int i, ret;
 
 	host->is2440 = platform_get_device_id(pdev)->driver_data;
+	pdata = pdev->dev.platform_data;
+	if (!pdata) {
+		dev_err(&pdev->dev, "need platform data");
+		return -ENXIO;
+	}
 
-	for (i = S3C2410_GPE(5); i <= S3C2410_GPE(10); i++) {
-		ret = gpio_request(i, dev_name(&pdev->dev));
-		if (ret) {
+	for (i = 0; i < 6; i++) {
+		pdata->bus[i] = devm_gpiod_get_index(&pdev->dev, "bus", i,
+						     GPIOD_OUT_LOW);
+		if (IS_ERR(pdata->bus[i])) {
 			dev_err(&pdev->dev, "failed to get gpio %d\n", i);
-
-			for (i--; i >= S3C2410_GPE(5); i--)
-				gpio_free(i);
-
-			return ret;
+			return PTR_ERR(pdata->bus[i]);
 		}
 	}
 
-	if (!pdev->dev.platform_data)
-		pdev->dev.platform_data = &s3cmci_def_pdata;
-
-	pdata = pdev->dev.platform_data;
-
 	if (pdata->no_wprotect)
 		mmc->caps2 |= MMC_CAP2_NO_WRITE_PROTECT;
 
@@ -1549,7 +1525,6 @@ static int s3cmci_probe(struct platform_device *pdev)
 	struct s3cmci_host *host;
 	struct mmc_host	*mmc;
 	int ret;
-	int i;
 
 	mmc = mmc_alloc_host(sizeof(struct s3cmci_host), &pdev->dev);
 	if (!mmc) {
@@ -1593,7 +1568,7 @@ static int s3cmci_probe(struct platform_device *pdev)
 			"failed to get io memory region resource.\n");
 
 		ret = -ENOENT;
-		goto probe_free_gpio;
+		goto probe_free_host;
 	}
 
 	host->mem = request_mem_region(host->mem->start,
@@ -1602,7 +1577,7 @@ static int s3cmci_probe(struct platform_device *pdev)
 	if (!host->mem) {
 		dev_err(&pdev->dev, "failed to request io memory region.\n");
 		ret = -ENOENT;
-		goto probe_free_gpio;
+		goto probe_free_host;
 	}
 
 	host->base = ioremap(host->mem->start, resource_size(host->mem));
@@ -1726,11 +1701,6 @@ static int s3cmci_probe(struct platform_device *pdev)
  probe_free_mem_region:
 	release_mem_region(host->mem->start, resource_size(host->mem));
 
- probe_free_gpio:
-	if (!pdev->dev.of_node)
-		for (i = S3C2410_GPE(5); i <= S3C2410_GPE(10); i++)
-			gpio_free(i);
-
  probe_free_host:
 	mmc_free_host(mmc);
 
@@ -1756,7 +1726,6 @@ static int s3cmci_remove(struct platform_device *pdev)
 {
 	struct mmc_host		*mmc  = platform_get_drvdata(pdev);
 	struct s3cmci_host	*host = mmc_priv(mmc);
-	int i;
 
 	s3cmci_shutdown(pdev);
 
@@ -1769,10 +1738,6 @@ static int s3cmci_remove(struct platform_device *pdev)
 
 	free_irq(host->irq, host);
 
-	if (!pdev->dev.of_node)
-		for (i = S3C2410_GPE(5); i <= S3C2410_GPE(10); i++)
-			gpio_free(i);
-
 	iounmap(host->base);
 	release_mem_region(host->mem->start, resource_size(host->mem));
 
diff --git a/include/linux/platform_data/mmc-s3cmci.h b/include/linux/platform_data/mmc-s3cmci.h
index 33310b11cbdd..bacb86db3112 100644
--- a/include/linux/platform_data/mmc-s3cmci.h
+++ b/include/linux/platform_data/mmc-s3cmci.h
@@ -35,6 +35,7 @@ struct s3c24xx_mci_pdata {
 	unsigned long	ocr_avail;
 	void		(*set_power)(unsigned char power_mode,
 				     unsigned short vdd);
+	struct gpio_desc *bus[6];
 };
 
 /**
@@ -44,6 +45,7 @@ struct s3c24xx_mci_pdata {
  * Copy the platform data supplied by @pdata so that this can be marked
  * __initdata.
  */
+extern void s3c24xx_mci_def_set_power(unsigned char power_mode, unsigned short vdd);
 extern void s3c24xx_mci_set_platdata(struct s3c24xx_mci_pdata *pdata);
 
 #endif /* _ARCH_NCI_H */
-- 
2.20.0

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-10 20:29   ` [PATCH 11/36] ARM: s5pv210: split from plat-samsung Arnd Bergmann
@ 2019-10-11  5:51     ` Uwe Kleine-König
  2019-10-22 14:01       ` Arnd Bergmann
  2019-10-15 14:13     ` Ulf Hansson
                       ` (2 subsequent siblings)
  3 siblings, 1 reply; 21+ messages in thread
From: Uwe Kleine-König @ 2019-10-11  5:51 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Ulf Hansson, Liam Girdwood, linus.walleij, alsa-devel,
	linux-kernel, Thierry Reding, Sylwester Nawrocki,
	Mauro Carvalho Chehab, linux-samsung-soc, Krzysztof Kozlowski,
	Kukjin Kim, Clément Péron, linux-serial, Jiri Slaby,
	linux-pwm, Bartlomiej Zolnierkiewicz, Sascha Hauer, Mark Brown,
	Jaroslav Kysela, linux-arm-kernel, Sangbeom Kim,
	Greg Kroah-Hartman, linux-mmc

On Thu, Oct 10, 2019 at 10:29:55PM +0200, Arnd Bergmann wrote:
> These can be build completely independently, so split
> the two Kconfig symbols.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

I'd mention the two symbols' names you're working on in the commit log.
I guess it's about PLAT_SAMSUNG and ARCH_S5PV210. And I wouldn't call it
"split" which IMHO suggests there was only one symbol before.

Maybe:

	Don't imply PLAT_SAMSUNG if ARCH_S5PV210 is enabled

would be a better subject line?

> ---
>  arch/arm/Kconfig.debug        | 6 +++---
>  arch/arm/Makefile             | 1 -
>  arch/arm/plat-samsung/Kconfig | 2 +-
>  drivers/mmc/host/Kconfig      | 2 +-
>  drivers/pwm/Kconfig           | 2 +-
>  drivers/spi/Kconfig           | 2 +-
>  drivers/tty/serial/Kconfig    | 2 +-
>  sound/soc/samsung/Kconfig     | 2 +-
>  8 files changed, 9 insertions(+), 10 deletions(-)
> 
> diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
> index 9c4f2d6deb06..4c4e97ae4fcb 100644
> --- a/arch/arm/Kconfig.debug
> +++ b/arch/arm/Kconfig.debug
> @@ -998,7 +998,7 @@ choice
>  		  via SCIFA4 on Renesas SH-Mobile AG5 (SH73A0).
>  
>  	config DEBUG_S3C_UART0
> -		depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1010,7 +1010,7 @@ choice
>  		  by the boot-loader before use.
>  
>  	config DEBUG_S3C_UART1
> -		depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1022,7 +1022,7 @@ choice
>  		  by the boot-loader before use.
>  
>  	config DEBUG_S3C_UART2
> -		depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index f492d7c338fe..a1bc15cda751 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -235,7 +235,6 @@ machine-$(CONFIG_PLAT_SPEAR)		+= spear
>  # by CONFIG_* macro name.
>  plat-$(CONFIG_ARCH_OMAP)	+= omap
>  plat-$(CONFIG_ARCH_S3C64XX)	+= samsung
> -plat-$(CONFIG_ARCH_S5PV210)	+= samsung

Would it make more sense to make this

	plat-$(PLAT_SAMSUNG) += samsung

(in a separate patch)? Hmm, it seems there is no plat-y for
PLAT_S3C24XX=y builds. Is this intended? If yes, the directory name
containing "samsung" suggests something that seems untrue.

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG
  2019-10-10 20:29   ` [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG Arnd Bergmann
@ 2019-10-15 14:12     ` Ulf Hansson
  2019-10-23 10:57     ` Krzysztof Kozlowski
  1 sibling, 0 replies; 21+ messages in thread
From: Ulf Hansson @ 2019-10-15 14:12 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Kukjin Kim, Krzysztof Kozlowski, linux-samsung-soc, Linux ARM,
	Linus Walleij, Olof Johansson, Sascha Hauer,
	Bartlomiej Zolnierkiewicz, Enrico Weigelt, metux IT consult,
	Linux Kernel Mailing List, linux-mmc

On Thu, 10 Oct 2019 at 22:34, Arnd Bergmann <arnd@arndb.de> wrote:
>
> Now that no code in arch/arm is shared between mach-exynos and the
> others, make the split formal.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  arch/arm/Kconfig.debug        | 8 ++++----
>  arch/arm/Makefile             | 1 -
>  arch/arm/mach-exynos/Makefile | 4 ----
>  arch/arm/plat-samsung/Kconfig | 4 ++--
>  drivers/mmc/host/Kconfig      | 2 +-

For the mmc part:

Acked-by: Ulf Hansson <ulf.hansson@linaro.org>

Kind regards
Uffe


>  5 files changed, 7 insertions(+), 12 deletions(-)
>
> diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
> index d05b836dfeb2..9c4f2d6deb06 100644
> --- a/arch/arm/Kconfig.debug
> +++ b/arch/arm/Kconfig.debug
> @@ -998,7 +998,7 @@ choice
>                   via SCIFA4 on Renesas SH-Mobile AG5 (SH73A0).
>
>         config DEBUG_S3C_UART0
> -               depends on PLAT_SAMSUNG
> +               depends on PLAT_SAMSUNG || ARCH_EXYNOS
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1010,7 +1010,7 @@ choice
>                   by the boot-loader before use.
>
>         config DEBUG_S3C_UART1
> -               depends on PLAT_SAMSUNG
> +               depends on PLAT_SAMSUNG || ARCH_EXYNOS
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1022,7 +1022,7 @@ choice
>                   by the boot-loader before use.
>
>         config DEBUG_S3C_UART2
> -               depends on PLAT_SAMSUNG
> +               depends on PLAT_SAMSUNG || ARCH_EXYNOS
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1034,7 +1034,7 @@ choice
>                   by the boot-loader before use.
>
>         config DEBUG_S3C_UART3
> -               depends on PLAT_SAMSUNG && (ARCH_EXYNOS || ARCH_S5PV210)
> +               depends on ARCH_EXYNOS || ARCH_S5PV210
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
>                 select DEBUG_S5PV210_UART if ARCH_S5PV210
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index db857d07114f..f492d7c338fe 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -233,7 +233,6 @@ machine-$(CONFIG_PLAT_SPEAR)                += spear
>
>  # Platform directory name.  This list is sorted alphanumerically
>  # by CONFIG_* macro name.
> -plat-$(CONFIG_ARCH_EXYNOS)     += samsung
>  plat-$(CONFIG_ARCH_OMAP)       += omap
>  plat-$(CONFIG_ARCH_S3C64XX)    += samsung
>  plat-$(CONFIG_ARCH_S5PV210)    += samsung
> diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile
> index 0fd3fcf8bfb0..53fa363c8e44 100644
> --- a/arch/arm/mach-exynos/Makefile
> +++ b/arch/arm/mach-exynos/Makefile
> @@ -3,10 +3,6 @@
>  # Copyright (c) 2010-2011 Samsung Electronics Co., Ltd.
>  #              http://www.samsung.com/
>
> -ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree)/arch/arm/plat-samsung/include
> -
> -# Core
> -
>  obj-$(CONFIG_ARCH_EXYNOS)      += exynos.o exynos-smc.o firmware.o
>
>  obj-$(CONFIG_EXYNOS_CPU_SUSPEND) += pm.o sleep.o
> diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
> index 832ab0e6cd72..e31a156a27df 100644
> --- a/arch/arm/plat-samsung/Kconfig
> +++ b/arch/arm/plat-samsung/Kconfig
> @@ -4,7 +4,7 @@
>
>  config PLAT_SAMSUNG
>         bool
> -       depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_EXYNOS || ARCH_S5PV210
> +       depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
>         default y
>         select GENERIC_IRQ_CHIP
>         select NO_IOPORT_MAP
> @@ -240,7 +240,7 @@ config SAMSUNG_PM_DEBUG
>         bool "Samsung PM Suspend debug"
>         depends on PM && DEBUG_KERNEL
>         depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
> -       depends on DEBUG_EXYNOS_UART || DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART
> +       depends on DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART
>         help
>           Say Y here if you want verbose debugging from the PM Suspend and
>           Resume code. See <file:Documentation/arm/samsung-s3c24xx/suspend.rst>
> diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
> index 49ea02c467bf..400a581c918c 100644
> --- a/drivers/mmc/host/Kconfig
> +++ b/drivers/mmc/host/Kconfig
> @@ -275,7 +275,7 @@ config MMC_SDHCI_TEGRA
>
>  config MMC_SDHCI_S3C
>         tristate "SDHCI support on Samsung S3C SoC"
> -       depends on MMC_SDHCI && PLAT_SAMSUNG
> +       depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_EXYNOS)
>         help
>           This selects the Secure Digital Host Controller Interface (SDHCI)
>           often referrered to as the HSMMC block in some of the Samsung S3C
> --
> 2.20.0
>

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files
  2019-10-10 20:30   ` [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files Arnd Bergmann
@ 2019-10-15 14:12     ` Ulf Hansson
  2019-10-16 13:12     ` Linus Walleij
  1 sibling, 0 replies; 21+ messages in thread
From: Ulf Hansson @ 2019-10-15 14:12 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Kukjin Kim, Krzysztof Kozlowski, Ben Dooks, linux-samsung-soc,
	Linux ARM, Linus Walleij, Linux Kernel Mailing List, linux-mmc

On Thu, 10 Oct 2019 at 22:47, Arnd Bergmann <arnd@arndb.de> wrote:
>
> Rather than call the internal s3c_gpio_cfgall_range() function
> through a platform header, move the code into the set_power
> callback that is already exported by the board, and add
> a default implementation.
>
> In DT mode, the code already does not set the pin config,
> so nothing changes there.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

This looks good to me!

Acked-by: Ulf Hansson <ulf.hansson@linaro.org>

Kind regards
Uffe


> ---
>  arch/arm/mach-s3c24xx/include/mach/pm-core.h |  1 +
>  arch/arm/mach-s3c24xx/mach-amlm5900.c        | 15 +++++
>  arch/arm/mach-s3c24xx/mach-at2440evb.c       | 10 ++-
>  arch/arm/mach-s3c24xx/mach-gta02.c           | 15 +++++
>  arch/arm/mach-s3c24xx/mach-h1940.c           |  8 +++
>  arch/arm/mach-s3c24xx/mach-mini2440.c        |  9 ++-
>  arch/arm/mach-s3c24xx/mach-n30.c             |  9 +++
>  arch/arm/mach-s3c24xx/mach-qt2410.c          | 15 +++++
>  arch/arm/mach-s3c24xx/mach-rx1950.c          |  9 +++
>  arch/arm/mach-s3c24xx/mach-tct_hammer.c      | 15 +++++
>  arch/arm/plat-samsung/devs.c                 | 29 ++++++++
>  drivers/mmc/host/s3cmci.c                    | 69 +++++---------------
>  include/linux/platform_data/mmc-s3cmci.h     |  2 +
>  13 files changed, 152 insertions(+), 54 deletions(-)
>
> diff --git a/arch/arm/mach-s3c24xx/include/mach/pm-core.h b/arch/arm/mach-s3c24xx/include/mach/pm-core.h
> index 8f87606c4cdc..a22b4a37ee57 100644
> --- a/arch/arm/mach-s3c24xx/include/mach/pm-core.h
> +++ b/arch/arm/mach-s3c24xx/include/mach/pm-core.h
> @@ -12,6 +12,7 @@
>
>  #include "regs-clock.h"
>  #include "regs-irq.h"
> +#include <mach/irqs.h>
>
>  static inline void s3c_pm_debug_init_uart(void)
>  {
> diff --git a/arch/arm/mach-s3c24xx/mach-amlm5900.c b/arch/arm/mach-s3c24xx/mach-amlm5900.c
> index 9a9daf526d0c..40ad23b52bc0 100644
> --- a/arch/arm/mach-s3c24xx/mach-amlm5900.c
> +++ b/arch/arm/mach-s3c24xx/mach-amlm5900.c
> @@ -13,6 +13,7 @@
>  #include <linux/list.h>
>  #include <linux/timer.h>
>  #include <linux/init.h>
> +#include <linux/gpio/machine.h>
>  #include <linux/gpio.h>
>  #include <linux/device.h>
>  #include <linux/platform_device.h>
> @@ -124,6 +125,19 @@ static struct s3c2410_uartcfg amlm5900_uartcfgs[] = {
>         }
>  };
>
> +static struct gpiod_lookup_table amlm5900_mmc_gpio_table = {
> +       .dev_id = "s3c2410-sdi",
> +       .table = {
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
> +               { },
> +       },
> +};
>
>  static struct platform_device *amlm5900_devices[] __initdata = {
>  #ifdef CONFIG_FB_S3C2410
> @@ -219,6 +233,7 @@ static void __init amlm5900_init(void)
>         s3c24xx_fb_set_platdata(&amlm5900_fb_info);
>  #endif
>         s3c_i2c0_set_platdata(NULL);
> +       gpiod_add_lookup_table(&amlm5900_mmc_gpio_table);
>         platform_add_devices(amlm5900_devices, ARRAY_SIZE(amlm5900_devices));
>  }
>
> diff --git a/arch/arm/mach-s3c24xx/mach-at2440evb.c b/arch/arm/mach-s3c24xx/mach-at2440evb.c
> index 58c5ef3cf1d7..3a793aaf2cba 100644
> --- a/arch/arm/mach-s3c24xx/mach-at2440evb.c
> +++ b/arch/arm/mach-s3c24xx/mach-at2440evb.c
> @@ -136,7 +136,7 @@ static struct platform_device at2440evb_device_eth = {
>  };
>
>  static struct s3c24xx_mci_pdata at2440evb_mci_pdata __initdata = {
> -       /* Intentionally left blank */
> +       .set_power = s3c24xx_mci_def_set_power,
>  };
>
>  static struct gpiod_lookup_table at2440evb_mci_gpio_table = {
> @@ -144,10 +144,18 @@ static struct gpiod_lookup_table at2440evb_mci_gpio_table = {
>         .table = {
>                 /* Card detect S3C2410_GPG(10) */
>                 GPIO_LOOKUP("GPG", 10, "cd", GPIO_ACTIVE_LOW),
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
>                 { },
>         },
>  };
>
> +
>  /* 7" LCD panel */
>
>  static struct s3c2410fb_display at2440evb_lcd_cfg __initdata = {
> diff --git a/arch/arm/mach-s3c24xx/mach-gta02.c b/arch/arm/mach-s3c24xx/mach-gta02.c
> index 1ca0460d82f4..61b8c6badeb8 100644
> --- a/arch/arm/mach-s3c24xx/mach-gta02.c
> +++ b/arch/arm/mach-s3c24xx/mach-gta02.c
> @@ -489,6 +489,20 @@ static struct platform_device gta02_audio = {
>         .id = -1,
>  };
>
> +static struct gpiod_lookup_table gta02_mmc_gpio_table = {
> +       .dev_id = "s3c2410-sdi",
> +       .table = {
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
> +               { },
> +       },
> +};
> +
>  static void __init gta02_map_io(void)
>  {
>         s3c24xx_init_io(gta02_iodesc, ARRAY_SIZE(gta02_iodesc));
> @@ -545,6 +559,7 @@ static void __init gta02_machine_init(void)
>                               S3C_GPIO_PULL_NONE);
>
>         gpiod_add_lookup_table(&gta02_audio_gpio_table);
> +       gpiod_add_lookup_table(&gta02_mmc_gpio_table);
>         platform_add_devices(gta02_devices, ARRAY_SIZE(gta02_devices));
>         pm_power_off = gta02_poweroff;
>
> diff --git a/arch/arm/mach-s3c24xx/mach-h1940.c b/arch/arm/mach-s3c24xx/mach-h1940.c
> index 11f705fb5e32..24f785da7659 100644
> --- a/arch/arm/mach-s3c24xx/mach-h1940.c
> +++ b/arch/arm/mach-s3c24xx/mach-h1940.c
> @@ -462,6 +462,7 @@ static void h1940_set_mmc_power(unsigned char power_mode, unsigned short vdd)
>  static struct s3c24xx_mci_pdata h1940_mmc_cfg __initdata = {
>         .set_power     = h1940_set_mmc_power,
>         .ocr_avail     = MMC_VDD_32_33,
> +       .set_power = s3c24xx_mci_def_set_power,
>  };
>
>  static struct gpiod_lookup_table h1940_mmc_gpio_table = {
> @@ -471,6 +472,13 @@ static struct gpiod_lookup_table h1940_mmc_gpio_table = {
>                 GPIO_LOOKUP("GPF", 5, "cd", GPIO_ACTIVE_LOW),
>                 /* Write protect S3C2410_GPH(8) */
>                 GPIO_LOOKUP("GPH", 8, "wp", GPIO_ACTIVE_LOW),
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
>                 { },
>         },
>  };
> diff --git a/arch/arm/mach-s3c24xx/mach-mini2440.c b/arch/arm/mach-s3c24xx/mach-mini2440.c
> index 894d43ff94f1..5c000efdf0e8 100644
> --- a/arch/arm/mach-s3c24xx/mach-mini2440.c
> +++ b/arch/arm/mach-s3c24xx/mach-mini2440.c
> @@ -236,7 +236,7 @@ static struct s3c2410fb_mach_info mini2440_fb_info __initdata = {
>
>  static struct s3c24xx_mci_pdata mini2440_mmc_cfg __initdata = {
>         .wprotect_invert        = 1,
> -       .set_power              = NULL,
> +       .set_power              = s3c24xx_mci_def_set_power,
>         .ocr_avail              = MMC_VDD_32_33|MMC_VDD_33_34,
>  };
>
> @@ -247,6 +247,13 @@ static struct gpiod_lookup_table mini2440_mmc_gpio_table = {
>                 GPIO_LOOKUP("GPG", 8, "cd", GPIO_ACTIVE_LOW),
>                 /* Write protect S3C2410_GPH(8) */
>                 GPIO_LOOKUP("GPH", 8, "wp", GPIO_ACTIVE_HIGH),
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
>                 { },
>         },
>  };
> diff --git a/arch/arm/mach-s3c24xx/mach-n30.c b/arch/arm/mach-s3c24xx/mach-n30.c
> index 5f5ca4b7015c..8d7ad61e9930 100644
> --- a/arch/arm/mach-s3c24xx/mach-n30.c
> +++ b/arch/arm/mach-s3c24xx/mach-n30.c
> @@ -339,6 +339,8 @@ static struct s3c2410fb_mach_info n30_fb_info __initdata = {
>
>  static void n30_sdi_set_power(unsigned char power_mode, unsigned short vdd)
>  {
> +       s3c24xx_mci_def_set_power(power_mode, vdd);
> +
>         switch (power_mode) {
>         case MMC_POWER_ON:
>         case MMC_POWER_UP:
> @@ -364,6 +366,13 @@ static struct gpiod_lookup_table n30_mci_gpio_table = {
>                 /* Write protect S3C2410_GPG(10) */
>                 GPIO_LOOKUP("GPG", 10, "wp", GPIO_ACTIVE_LOW),
>                 { },
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
>         },
>  };
>
> diff --git a/arch/arm/mach-s3c24xx/mach-qt2410.c b/arch/arm/mach-s3c24xx/mach-qt2410.c
> index 6686f02a3f4f..9b47b8434f10 100644
> --- a/arch/arm/mach-s3c24xx/mach-qt2410.c
> +++ b/arch/arm/mach-s3c24xx/mach-qt2410.c
> @@ -219,6 +219,20 @@ static struct gpiod_lookup_table qt2410_spi_gpiod_table = {
>         },
>  };
>
> +static struct gpiod_lookup_table qt2410_mmc_gpiod_table = {
> +       .dev_id = "s3c2410-sdi",
> +       .table = {
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
> +               { },
> +       },
> +};
> +
>  /* Board devices */
>
>  static struct platform_device *qt2410_devices[] __initdata = {
> @@ -342,6 +356,7 @@ static void __init qt2410_machine_init(void)
>         s3c_gpio_cfgall_range(S3C2410_GPE(0), 5, S3C_GPIO_SFN(2),
>                               S3C_GPIO_PULL_NONE);
>         gpiod_add_lookup_table(&qt2410_spi_gpiod_table);
> +       gpiod_add_lookup_table(&qt2410_mmc_gpiod_table);
>         platform_add_devices(qt2410_devices, ARRAY_SIZE(qt2410_devices));
>         s3c_pm_init();
>  }
> diff --git a/arch/arm/mach-s3c24xx/mach-rx1950.c b/arch/arm/mach-s3c24xx/mach-rx1950.c
> index 4eeede398775..820e626f5129 100644
> --- a/arch/arm/mach-s3c24xx/mach-rx1950.c
> +++ b/arch/arm/mach-s3c24xx/mach-rx1950.c
> @@ -545,6 +545,8 @@ static struct platform_device rx1950_backlight = {
>
>  static void rx1950_set_mmc_power(unsigned char power_mode, unsigned short vdd)
>  {
> +       s3c24xx_mci_def_set_power(power_mode, vdd);
> +
>         switch (power_mode) {
>         case MMC_POWER_OFF:
>                 gpio_direction_output(S3C2410_GPJ(1), 0);
> @@ -570,6 +572,13 @@ static struct gpiod_lookup_table rx1950_mmc_gpio_table = {
>                 GPIO_LOOKUP("GPF", 5, "cd", GPIO_ACTIVE_LOW),
>                 /* Write protect S3C2410_GPH(8) */
>                 GPIO_LOOKUP("GPH", 8, "wp", GPIO_ACTIVE_LOW),
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
>                 { },
>         },
>  };
> diff --git a/arch/arm/mach-s3c24xx/mach-tct_hammer.c b/arch/arm/mach-s3c24xx/mach-tct_hammer.c
> index 8d8ddd6ea305..d6dbbe6759bc 100644
> --- a/arch/arm/mach-s3c24xx/mach-tct_hammer.c
> +++ b/arch/arm/mach-s3c24xx/mach-tct_hammer.c
> @@ -7,6 +7,7 @@
>  // derived from linux/arch/arm/mach-s3c2410/mach-bast.c, written by
>  // Ben Dooks <ben@simtec.co.uk>
>
> +#include <linux/gpio/machine.h>
>  #include <linux/kernel.h>
>  #include <linux/types.h>
>  #include <linux/interrupt.h>
> @@ -103,6 +104,19 @@ static struct s3c2410_uartcfg tct_hammer_uartcfgs[] = {
>         }
>  };
>
> +static struct gpiod_lookup_table tct_hammer_mmc_gpio_table = {
> +       .dev_id = "s3c2410-sdi",
> +       .table = {
> +               /* bus pins */
> +               GPIO_LOOKUP_IDX("GPIOE",  5, "bus", 0, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  6, "bus", 1, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  7, "bus", 2, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  8, "bus", 3, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE",  9, "bus", 4, GPIO_ACTIVE_HIGH),
> +               GPIO_LOOKUP_IDX("GPIOE", 10, "bus", 5, GPIO_ACTIVE_HIGH),
> +               { },
> +       },
> +};
>
>  static struct platform_device *tct_hammer_devices[] __initdata = {
>         &s3c_device_adc,
> @@ -131,6 +145,7 @@ static void __init tct_hammer_init_time(void)
>  static void __init tct_hammer_init(void)
>  {
>         s3c_i2c0_set_platdata(NULL);
> +       gpiod_add_lookup_table(&tct_hammer_mmc_gpio_table);
>         platform_add_devices(tct_hammer_devices, ARRAY_SIZE(tct_hammer_devices));
>  }
>
> diff --git a/arch/arm/plat-samsung/devs.c b/arch/arm/plat-samsung/devs.c
> index ddd90f0bb380..c0739bda060b 100644
> --- a/arch/arm/plat-samsung/devs.c
> +++ b/arch/arm/plat-samsung/devs.c
> @@ -5,6 +5,7 @@
>  //
>  // Base SAMSUNG platform device definitions
>
> +#include <linux/gpio.h>
>  #include <linux/kernel.h>
>  #include <linux/types.h>
>  #include <linux/interrupt.h>
> @@ -40,6 +41,8 @@
>  #include <mach/dma.h>
>  #include <mach/irqs.h>
>  #include <mach/map.h>
> +#include <mach/gpio-samsung.h>
> +#include <plat/gpio-cfg.h>
>  #include <mach/regs-s3c2443-clock.h>
>
>  #include <plat/cpu.h>
> @@ -833,16 +836,42 @@ struct platform_device s3c_device_rtc = {
>  /* SDI */
>
>  #ifdef CONFIG_PLAT_S3C24XX
> +void s3c24xx_mci_def_set_power(unsigned char power_mode, unsigned short vdd)
> +{
> +       switch (power_mode) {
> +       case MMC_POWER_ON:
> +       case MMC_POWER_UP:
> +               /* Configure GPE5...GPE10 pins in SD mode */
> +               s3c_gpio_cfgall_range(S3C2410_GPE(5), 6, S3C_GPIO_SFN(2),
> +                                     S3C_GPIO_PULL_NONE);
> +               break;
> +
> +       case MMC_POWER_OFF:
> +       default:
> +               gpio_direction_output(S3C2410_GPE(5), 0);
> +               break;
> +       }
> +}
> +
>  static struct resource s3c_sdi_resource[] = {
>         [0] = DEFINE_RES_MEM(S3C24XX_PA_SDI, S3C24XX_SZ_SDI),
>         [1] = DEFINE_RES_IRQ(IRQ_SDI),
>  };
>
> +static struct s3c24xx_mci_pdata s3cmci_def_pdata = {
> +       /* This is currently here to avoid a number of if (host->pdata)
> +        * checks. Any zero fields to ensure reasonable defaults are picked. */
> +       .no_wprotect = 1,
> +       .no_detect = 1,
> +       .set_power = s3c24xx_mci_def_set_power,
> +};
> +
>  struct platform_device s3c_device_sdi = {
>         .name           = "s3c2410-sdi",
>         .id             = -1,
>         .num_resources  = ARRAY_SIZE(s3c_sdi_resource),
>         .resource       = s3c_sdi_resource,
> +       .dev.platform_data = &s3cmci_def_pdata,
>  };
>
>  void __init s3c24xx_mci_set_platdata(struct s3c24xx_mci_pdata *pdata)
> diff --git a/drivers/mmc/host/s3cmci.c b/drivers/mmc/host/s3cmci.c
> index bce9c33bc4b5..c2b46640a78b 100644
> --- a/drivers/mmc/host/s3cmci.c
> +++ b/drivers/mmc/host/s3cmci.c
> @@ -25,9 +25,7 @@
>  #include <linux/of_device.h>
>  #include <linux/mmc/slot-gpio.h>
>
> -#include <plat/gpio-cfg.h>
>  #include <mach/dma.h>
> -#include <mach/gpio-samsung.h>
>
>  #include <linux/platform_data/mmc-s3cmci.h>
>
> @@ -307,7 +305,8 @@ static inline void clear_imask(struct s3cmci_host *host)
>  static void s3cmci_check_sdio_irq(struct s3cmci_host *host)
>  {
>         if (host->sdio_irqen) {
> -               if (gpio_get_value(S3C2410_GPE(8)) == 0) {
> +               if (host->pdata->bus[3] &&
> +                   gpiod_get_value(host->pdata->bus[3]) == 0) {
>                         pr_debug("%s: signalling irq\n", __func__);
>                         mmc_signal_sdio_irq(host->mmc);
>                 }
> @@ -1213,33 +1212,20 @@ static void s3cmci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
>         switch (ios->power_mode) {
>         case MMC_POWER_ON:
>         case MMC_POWER_UP:
> -               /* Configure GPE5...GPE10 pins in SD mode */
> -               if (!host->pdev->dev.of_node)
> -                       s3c_gpio_cfgall_range(S3C2410_GPE(5), 6, S3C_GPIO_SFN(2),
> -                                             S3C_GPIO_PULL_NONE);
> -
> -               if (host->pdata->set_power)
> -                       host->pdata->set_power(ios->power_mode, ios->vdd);
> -
>                 if (!host->is2440)
>                         mci_con |= S3C2410_SDICON_FIFORESET;
> -
>                 break;
>
>         case MMC_POWER_OFF:
>         default:
> -               if (!host->pdev->dev.of_node)
> -                       gpio_direction_output(S3C2410_GPE(5), 0);
> -
>                 if (host->is2440)
>                         mci_con |= S3C2440_SDICON_SDRESET;
> -
> -               if (host->pdata->set_power)
> -                       host->pdata->set_power(ios->power_mode, ios->vdd);
> -
>                 break;
>         }
>
> +       if (host->pdata->set_power)
> +               host->pdata->set_power(ios->power_mode, ios->vdd);
> +
>         s3cmci_set_clk(host, ios);
>
>         /* Set CLOCK_ENABLE */
> @@ -1317,13 +1303,6 @@ static const struct mmc_host_ops s3cmci_ops = {
>         .enable_sdio_irq = s3cmci_enable_sdio_irq,
>  };
>
> -static struct s3c24xx_mci_pdata s3cmci_def_pdata = {
> -       /* This is currently here to avoid a number of if (host->pdata)
> -        * checks. Any zero fields to ensure reasonable defaults are picked. */
> -        .no_wprotect = 1,
> -        .no_detect = 1,
> -};
> -
>  #ifdef CONFIG_ARM_S3C24XX_CPUFREQ
>
>  static int s3cmci_cpufreq_transition(struct notifier_block *nb,
> @@ -1477,24 +1456,21 @@ static int s3cmci_probe_pdata(struct s3cmci_host *host)
>         int i, ret;
>
>         host->is2440 = platform_get_device_id(pdev)->driver_data;
> +       pdata = pdev->dev.platform_data;
> +       if (!pdata) {
> +               dev_err(&pdev->dev, "need platform data");
> +               return -ENXIO;
> +       }
>
> -       for (i = S3C2410_GPE(5); i <= S3C2410_GPE(10); i++) {
> -               ret = gpio_request(i, dev_name(&pdev->dev));
> -               if (ret) {
> +       for (i = 0; i < 6; i++) {
> +               pdata->bus[i] = devm_gpiod_get_index(&pdev->dev, "bus", i,
> +                                                    GPIOD_OUT_LOW);
> +               if (IS_ERR(pdata->bus[i])) {
>                         dev_err(&pdev->dev, "failed to get gpio %d\n", i);
> -
> -                       for (i--; i >= S3C2410_GPE(5); i--)
> -                               gpio_free(i);
> -
> -                       return ret;
> +                       return PTR_ERR(pdata->bus[i]);
>                 }
>         }
>
> -       if (!pdev->dev.platform_data)
> -               pdev->dev.platform_data = &s3cmci_def_pdata;
> -
> -       pdata = pdev->dev.platform_data;
> -
>         if (pdata->no_wprotect)
>                 mmc->caps2 |= MMC_CAP2_NO_WRITE_PROTECT;
>
> @@ -1549,7 +1525,6 @@ static int s3cmci_probe(struct platform_device *pdev)
>         struct s3cmci_host *host;
>         struct mmc_host *mmc;
>         int ret;
> -       int i;
>
>         mmc = mmc_alloc_host(sizeof(struct s3cmci_host), &pdev->dev);
>         if (!mmc) {
> @@ -1593,7 +1568,7 @@ static int s3cmci_probe(struct platform_device *pdev)
>                         "failed to get io memory region resource.\n");
>
>                 ret = -ENOENT;
> -               goto probe_free_gpio;
> +               goto probe_free_host;
>         }
>
>         host->mem = request_mem_region(host->mem->start,
> @@ -1602,7 +1577,7 @@ static int s3cmci_probe(struct platform_device *pdev)
>         if (!host->mem) {
>                 dev_err(&pdev->dev, "failed to request io memory region.\n");
>                 ret = -ENOENT;
> -               goto probe_free_gpio;
> +               goto probe_free_host;
>         }
>
>         host->base = ioremap(host->mem->start, resource_size(host->mem));
> @@ -1726,11 +1701,6 @@ static int s3cmci_probe(struct platform_device *pdev)
>   probe_free_mem_region:
>         release_mem_region(host->mem->start, resource_size(host->mem));
>
> - probe_free_gpio:
> -       if (!pdev->dev.of_node)
> -               for (i = S3C2410_GPE(5); i <= S3C2410_GPE(10); i++)
> -                       gpio_free(i);
> -
>   probe_free_host:
>         mmc_free_host(mmc);
>
> @@ -1756,7 +1726,6 @@ static int s3cmci_remove(struct platform_device *pdev)
>  {
>         struct mmc_host         *mmc  = platform_get_drvdata(pdev);
>         struct s3cmci_host      *host = mmc_priv(mmc);
> -       int i;
>
>         s3cmci_shutdown(pdev);
>
> @@ -1769,10 +1738,6 @@ static int s3cmci_remove(struct platform_device *pdev)
>
>         free_irq(host->irq, host);
>
> -       if (!pdev->dev.of_node)
> -               for (i = S3C2410_GPE(5); i <= S3C2410_GPE(10); i++)
> -                       gpio_free(i);
> -
>         iounmap(host->base);
>         release_mem_region(host->mem->start, resource_size(host->mem));
>
> diff --git a/include/linux/platform_data/mmc-s3cmci.h b/include/linux/platform_data/mmc-s3cmci.h
> index 33310b11cbdd..bacb86db3112 100644
> --- a/include/linux/platform_data/mmc-s3cmci.h
> +++ b/include/linux/platform_data/mmc-s3cmci.h
> @@ -35,6 +35,7 @@ struct s3c24xx_mci_pdata {
>         unsigned long   ocr_avail;
>         void            (*set_power)(unsigned char power_mode,
>                                      unsigned short vdd);
> +       struct gpio_desc *bus[6];
>  };
>
>  /**
> @@ -44,6 +45,7 @@ struct s3c24xx_mci_pdata {
>   * Copy the platform data supplied by @pdata so that this can be marked
>   * __initdata.
>   */
> +extern void s3c24xx_mci_def_set_power(unsigned char power_mode, unsigned short vdd);
>  extern void s3c24xx_mci_set_platdata(struct s3c24xx_mci_pdata *pdata);
>
>  #endif /* _ARCH_NCI_H */
> --
> 2.20.0
>

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-10 20:29   ` [PATCH 11/36] ARM: s5pv210: split from plat-samsung Arnd Bergmann
  2019-10-11  5:51     ` Uwe Kleine-König
@ 2019-10-15 14:13     ` Ulf Hansson
  2019-10-15 14:23     ` Thierry Reding
  2019-10-23 12:14     ` Krzysztof Kozlowski
  3 siblings, 0 replies; 21+ messages in thread
From: Ulf Hansson @ 2019-10-15 14:13 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Kukjin Kim, Krzysztof Kozlowski, Thierry Reding, Mark Brown,
	Greg Kroah-Hartman, Jiri Slaby, Sangbeom Kim, Sylwester Nawrocki,
	Liam Girdwood, linux-pwm, alsa-devel, linux-samsung-soc,
	Bartlomiej Zolnierkiewicz, Linux Kernel Mailing List,
	Linus Walleij, linux-mmc, Takashi Iwai, Jaroslav Kysela,
	Mauro Carvalho Chehab

On Thu, 10 Oct 2019 at 22:38, Arnd Bergmann <arnd@arndb.de> wrote:
>
> These can be build completely independently, so split
> the two Kconfig symbols.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  arch/arm/Kconfig.debug        | 6 +++---
>  arch/arm/Makefile             | 1 -
>  arch/arm/plat-samsung/Kconfig | 2 +-
>  drivers/mmc/host/Kconfig      | 2 +-
>  drivers/pwm/Kconfig           | 2 +-
>  drivers/spi/Kconfig           | 2 +-
>  drivers/tty/serial/Kconfig    | 2 +-
>  sound/soc/samsung/Kconfig     | 2 +-
>  8 files changed, 9 insertions(+), 10 deletions(-)

For the mmc parts:

Acked-by: Ulf Hansson <ulf.hansson@linaro.org>

Kind regards
Uffe


>
> diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
> index 9c4f2d6deb06..4c4e97ae4fcb 100644
> --- a/arch/arm/Kconfig.debug
> +++ b/arch/arm/Kconfig.debug
> @@ -998,7 +998,7 @@ choice
>                   via SCIFA4 on Renesas SH-Mobile AG5 (SH73A0).
>
>         config DEBUG_S3C_UART0
> -               depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +               depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1010,7 +1010,7 @@ choice
>                   by the boot-loader before use.
>
>         config DEBUG_S3C_UART1
> -               depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +               depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1022,7 +1022,7 @@ choice
>                   by the boot-loader before use.
>
>         config DEBUG_S3C_UART2
> -               depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +               depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index f492d7c338fe..a1bc15cda751 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -235,7 +235,6 @@ machine-$(CONFIG_PLAT_SPEAR)                += spear
>  # by CONFIG_* macro name.
>  plat-$(CONFIG_ARCH_OMAP)       += omap
>  plat-$(CONFIG_ARCH_S3C64XX)    += samsung
> -plat-$(CONFIG_ARCH_S5PV210)    += samsung
>  plat-$(CONFIG_PLAT_ORION)      += orion
>  plat-$(CONFIG_PLAT_PXA)                += pxa
>  plat-$(CONFIG_PLAT_S3C24XX)    += samsung
> diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
> index 740bdb23f38a..1530946cc672 100644
> --- a/arch/arm/plat-samsung/Kconfig
> +++ b/arch/arm/plat-samsung/Kconfig
> @@ -4,7 +4,7 @@
>
>  config PLAT_SAMSUNG
>         bool
> -       depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
> +       depends on PLAT_S3C24XX || ARCH_S3C64XX
>         default y
>         select GENERIC_IRQ_CHIP
>         select NO_IOPORT_MAP
> diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
> index 400a581c918c..16a0e5430b44 100644
> --- a/drivers/mmc/host/Kconfig
> +++ b/drivers/mmc/host/Kconfig
> @@ -275,7 +275,7 @@ config MMC_SDHCI_TEGRA
>
>  config MMC_SDHCI_S3C
>         tristate "SDHCI support on Samsung S3C SoC"
> -       depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_EXYNOS)
> +       depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS)
>         help
>           This selects the Secure Digital Host Controller Interface (SDHCI)
>           often referrered to as the HSMMC block in some of the Samsung S3C
> diff --git a/drivers/pwm/Kconfig b/drivers/pwm/Kconfig
> index e3a2518503ed..8eb738cac0c7 100644
> --- a/drivers/pwm/Kconfig
> +++ b/drivers/pwm/Kconfig
> @@ -394,7 +394,7 @@ config PWM_ROCKCHIP
>
>  config PWM_SAMSUNG
>         tristate "Samsung PWM support"
> -       depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +       depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>         help
>           Generic PWM framework driver for Samsung.
>
> diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
> index 6f7fdcbb9151..355391ee643d 100644
> --- a/drivers/spi/Kconfig
> +++ b/drivers/spi/Kconfig
> @@ -625,7 +625,7 @@ config SPI_S3C24XX_FIQ
>
>  config SPI_S3C64XX
>         tristate "Samsung S3C64XX series type SPI"
> -       depends on (PLAT_SAMSUNG || ARCH_EXYNOS || COMPILE_TEST)
> +       depends on (PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS || COMPILE_TEST)
>         help
>           SPI driver for Samsung S3C64XX and newer SoCs.
>
> diff --git a/drivers/tty/serial/Kconfig b/drivers/tty/serial/Kconfig
> index 4789b5d62f63..17f01cf3009c 100644
> --- a/drivers/tty/serial/Kconfig
> +++ b/drivers/tty/serial/Kconfig
> @@ -237,7 +237,7 @@ config SERIAL_CLPS711X_CONSOLE
>
>  config SERIAL_SAMSUNG
>         tristate "Samsung SoC serial support"
> -       depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +       depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>         select SERIAL_CORE
>         help
>           Support for the on-chip UARTs on the Samsung S3C24XX series CPUs,
> diff --git a/sound/soc/samsung/Kconfig b/sound/soc/samsung/Kconfig
> index 638983123d8f..7a0035dd9995 100644
> --- a/sound/soc/samsung/Kconfig
> +++ b/sound/soc/samsung/Kconfig
> @@ -1,7 +1,7 @@
>  # SPDX-License-Identifier: GPL-2.0-only
>  menuconfig SND_SOC_SAMSUNG
>         tristate "ASoC support for Samsung"
> -       depends on PLAT_SAMSUNG || ARCH_EXYNOS || COMPILE_TEST
> +       depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS || COMPILE_TEST
>         depends on COMMON_CLK
>         select SND_SOC_GENERIC_DMAENGINE_PCM
>         ---help---
> --
> 2.20.0
>
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-10 20:29   ` [PATCH 11/36] ARM: s5pv210: split from plat-samsung Arnd Bergmann
  2019-10-11  5:51     ` Uwe Kleine-König
  2019-10-15 14:13     ` Ulf Hansson
@ 2019-10-15 14:23     ` Thierry Reding
  2019-10-23 12:14     ` Krzysztof Kozlowski
  3 siblings, 0 replies; 21+ messages in thread
From: Thierry Reding @ 2019-10-15 14:23 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Kukjin Kim, Krzysztof Kozlowski, Ulf Hansson, Mark Brown,
	Greg Kroah-Hartman, Jiri Slaby, Sangbeom Kim, Sylwester Nawrocki,
	Liam Girdwood, linux-samsung-soc, linux-arm-kernel,
	linus.walleij, Uwe Kleine-König, Jaroslav Kysela,
	Takashi Iwai, Olof Johansson, Sascha Hauer,
	Clément Péron, Mauro Carvalho Chehab

[-- Attachment #1: Type: text/plain, Size: 560 bytes --]

On Thu, Oct 10, 2019 at 10:29:55PM +0200, Arnd Bergmann wrote:
[...]
> diff --git a/drivers/pwm/Kconfig b/drivers/pwm/Kconfig
> index e3a2518503ed..8eb738cac0c7 100644
> --- a/drivers/pwm/Kconfig
> +++ b/drivers/pwm/Kconfig
> @@ -394,7 +394,7 @@ config PWM_ROCKCHIP
>  
>  config PWM_SAMSUNG
>  	tristate "Samsung PWM support"
> -	depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +	depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  	help
>  	  Generic PWM framework driver for Samsung.
>  

Acked-by: Thierry Reding <thierry.reding@gmail.com>

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files
  2019-10-10 20:30   ` [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files Arnd Bergmann
  2019-10-15 14:12     ` Ulf Hansson
@ 2019-10-16 13:12     ` Linus Walleij
  1 sibling, 0 replies; 21+ messages in thread
From: Linus Walleij @ 2019-10-16 13:12 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Ulf Hansson, linux-samsung-soc, linux-mmc, linux-kernel,
	Krzysztof Kozlowski, Kukjin Kim, Ben Dooks, Linux ARM

On Thu, Oct 10, 2019 at 10:47 PM Arnd Bergmann <arnd@arndb.de> wrote:

> Rather than call the internal s3c_gpio_cfgall_range() function
> through a platform header, move the code into the set_power
> callback that is already exported by the board, and add
> a default implementation.
>
> In DT mode, the code already does not set the pin config,
> so nothing changes there.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

It looks good:
Acked-by: Linus Walleij <linus.walleij@linaro.org>

It would feel better if someone was actually testing it on these
boards. I see Ben is listed as maintainer so I bet he will
pull the board out :)

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-11  5:51     ` Uwe Kleine-König
@ 2019-10-22 14:01       ` Arnd Bergmann
  2019-10-22 15:53         ` Uwe Kleine-König
  0 siblings, 1 reply; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-22 14:01 UTC (permalink / raw)
  To: Uwe Kleine-König
  Cc: Kukjin Kim, Krzysztof Kozlowski, Ulf Hansson, Thierry Reding,
	Mark Brown, Greg Kroah-Hartman, Jiri Slaby, Sangbeom Kim,
	Sylwester Nawrocki, Liam Girdwood,
	moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES, Linux ARM,
	Linus Walleij, Jaroslav Kysela, Takashi Iwai, Olof Johansson,
	Sascha Hauer, Clément Péron

On Fri, Oct 11, 2019 at 7:51 AM Uwe Kleine-König
<u.kleine-koenig@pengutronix.de> wrote:
>
> On Thu, Oct 10, 2019 at 10:29:55PM +0200, Arnd Bergmann wrote:
> > These can be build completely independently, so split
> > the two Kconfig symbols.
> >
> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>
> I'd mention the two symbols' names you're working on in the commit log.
> I guess it's about PLAT_SAMSUNG and ARCH_S5PV210. And I wouldn't call it
> "split" which IMHO suggests there was only one symbol before.
>
> Maybe:
>
>         Don't imply PLAT_SAMSUNG if ARCH_S5PV210 is enabled
>
> would be a better subject line?

Ok, changed to

ARM: s5pv210: don't imply CONFIG_PLAT_SAMSUNG

> > @@ -235,7 +235,6 @@ machine-$(CONFIG_PLAT_SPEAR)              += spear
> >  # by CONFIG_* macro name.
> >  plat-$(CONFIG_ARCH_OMAP)     += omap
> >  plat-$(CONFIG_ARCH_S3C64XX)  += samsung
> > -plat-$(CONFIG_ARCH_S5PV210)  += samsung
>
> Would it make more sense to make this
>
>         plat-$(PLAT_SAMSUNG) += samsung
>
> (in a separate patch)? Hmm, it seems there is no plat-y for
> PLAT_S3C24XX=y builds. Is this intended? If yes, the directory name
> containing "samsung" suggests something that seems untrue.

By the end of the series, the plat-samsung directory is completely
removed (folded into mach-s3c), so that would only add more
churn for the same result I think.

     Arnd

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-22 14:01       ` Arnd Bergmann
@ 2019-10-22 15:53         ` Uwe Kleine-König
  2019-10-22 16:20           ` Arnd Bergmann
  0 siblings, 1 reply; 21+ messages in thread
From: Uwe Kleine-König @ 2019-10-22 15:53 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Ulf Hansson, Liam Girdwood, Linus Walleij,
	ALSA Development Mailing List, linux-kernel, Thierry Reding,
	Sylwester Nawrocki, Mauro Carvalho Chehab,
	moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES,
	Krzysztof Kozlowski, Kukjin Kim, Clément Péron,
	linux-serial, Jiri Slaby, Linux PWM List,
	Bartlomiej Zolnierkiewicz, Sascha Hauer, Mark Brown,
	Jaroslav Kysela

Hello,

On Tue, Oct 22, 2019 at 04:01:12PM +0200, Arnd Bergmann wrote:
> > > @@ -235,7 +235,6 @@ machine-$(CONFIG_PLAT_SPEAR)              += spear
> > >  # by CONFIG_* macro name.
> > >  plat-$(CONFIG_ARCH_OMAP)     += omap
> > >  plat-$(CONFIG_ARCH_S3C64XX)  += samsung
> > > -plat-$(CONFIG_ARCH_S5PV210)  += samsung
> >
> > Would it make more sense to make this
> >
> >         plat-$(PLAT_SAMSUNG) += samsung
> >
> > (in a separate patch)? Hmm, it seems there is no plat-y for
> > PLAT_S3C24XX=y builds. Is this intended? If yes, the directory name
> > containing "samsung" suggests something that seems untrue.
> 
> By the end of the series, the plat-samsung directory is completely
> removed (folded into mach-s3c), so that would only add more
> churn for the same result I think.

fine for me. The background of my question was me wondering if builds
for PLAT_S3C24XX=y (before your patch series) don't need plat-samsung.

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-22 15:53         ` Uwe Kleine-König
@ 2019-10-22 16:20           ` Arnd Bergmann
  0 siblings, 0 replies; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-22 16:20 UTC (permalink / raw)
  To: Uwe Kleine-König
  Cc: Kukjin Kim, Krzysztof Kozlowski, Ulf Hansson, Thierry Reding,
	Mark Brown, Greg Kroah-Hartman, Jiri Slaby, Sangbeom Kim,
	Sylwester Nawrocki, Liam Girdwood,
	moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES, Linux ARM,
	Linus Walleij, Jaroslav Kysela, Takashi Iwai, Olof Johansson,
	Sascha Hauer, Clément Péron

On Tue, Oct 22, 2019 at 5:53 PM Uwe Kleine-König
<u.kleine-koenig@pengutronix.de> wrote:
> The background of my question was me wondering if builds
> for PLAT_S3C24XX=y (before your patch series) don't need plat-samsung.

What I found is that the DT-based platforms (exynos and s5p) need almost nothing
from plat-samsung, while the board files and the s3c24xx/s3c64xx power
management
needs almost all of it.

      Arnd

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG
  2019-10-10 20:29   ` [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG Arnd Bergmann
  2019-10-15 14:12     ` Ulf Hansson
@ 2019-10-23 10:57     ` Krzysztof Kozlowski
  2019-10-23 12:43       ` Arnd Bergmann
  1 sibling, 1 reply; 21+ messages in thread
From: Krzysztof Kozlowski @ 2019-10-23 10:57 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Kukjin Kim, Ulf Hansson, linux-samsung-soc, linux-arm-kernel,
	linus.walleij, Olof Johansson, Sascha Hauer,
	Bartlomiej Zolnierkiewicz, Enrico Weigelt, metux IT consult,
	linux-kernel, linux-mmc

On Thu, Oct 10, 2019 at 10:29:52PM +0200, Arnd Bergmann wrote:
> Now that no code in arch/arm is shared between mach-exynos and the
> others, make the split formal.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  arch/arm/Kconfig.debug        | 8 ++++----
>  arch/arm/Makefile             | 1 -
>  arch/arm/mach-exynos/Makefile | 4 ----
>  arch/arm/plat-samsung/Kconfig | 4 ++--
>  drivers/mmc/host/Kconfig      | 2 +-
>  5 files changed, 7 insertions(+), 12 deletions(-)
> 
> diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
> index d05b836dfeb2..9c4f2d6deb06 100644
> --- a/arch/arm/Kconfig.debug
> +++ b/arch/arm/Kconfig.debug
> @@ -998,7 +998,7 @@ choice
>  		  via SCIFA4 on Renesas SH-Mobile AG5 (SH73A0).
>  
>  	config DEBUG_S3C_UART0
> -		depends on PLAT_SAMSUNG
> +		depends on PLAT_SAMSUNG || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1010,7 +1010,7 @@ choice
>  		  by the boot-loader before use.
>  
>  	config DEBUG_S3C_UART1
> -		depends on PLAT_SAMSUNG
> +		depends on PLAT_SAMSUNG || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1022,7 +1022,7 @@ choice
>  		  by the boot-loader before use.
>  
>  	config DEBUG_S3C_UART2
> -		depends on PLAT_SAMSUNG
> +		depends on PLAT_SAMSUNG || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1034,7 +1034,7 @@ choice
>  		  by the boot-loader before use.
>  
>  	config DEBUG_S3C_UART3
> -		depends on PLAT_SAMSUNG && (ARCH_EXYNOS || ARCH_S5PV210)
> +		depends on ARCH_EXYNOS || ARCH_S5PV210

You need to keep PLAT_SAMSUNG because of additional architectures, so
follow pattern from DEBUG_S3C_UART2.

Best regards,
Krzysztof

>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
>  		select DEBUG_S5PV210_UART if ARCH_S5PV210
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index db857d07114f..f492d7c338fe 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -233,7 +233,6 @@ machine-$(CONFIG_PLAT_SPEAR)		+= spear
>  
>  # Platform directory name.  This list is sorted alphanumerically
>  # by CONFIG_* macro name.
> -plat-$(CONFIG_ARCH_EXYNOS)	+= samsung
>  plat-$(CONFIG_ARCH_OMAP)	+= omap
>  plat-$(CONFIG_ARCH_S3C64XX)	+= samsung
>  plat-$(CONFIG_ARCH_S5PV210)	+= samsung
> diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile
> index 0fd3fcf8bfb0..53fa363c8e44 100644
> --- a/arch/arm/mach-exynos/Makefile
> +++ b/arch/arm/mach-exynos/Makefile
> @@ -3,10 +3,6 @@
>  # Copyright (c) 2010-2011 Samsung Electronics Co., Ltd.
>  #		http://www.samsung.com/
>  
> -ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree)/arch/arm/plat-samsung/include
> -
> -# Core
> -
>  obj-$(CONFIG_ARCH_EXYNOS)	+= exynos.o exynos-smc.o firmware.o
>  
>  obj-$(CONFIG_EXYNOS_CPU_SUSPEND) += pm.o sleep.o
> diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
> index 832ab0e6cd72..e31a156a27df 100644
> --- a/arch/arm/plat-samsung/Kconfig
> +++ b/arch/arm/plat-samsung/Kconfig
> @@ -4,7 +4,7 @@
>  
>  config PLAT_SAMSUNG
>  	bool
> -	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_EXYNOS || ARCH_S5PV210
> +	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
>  	default y
>  	select GENERIC_IRQ_CHIP
>  	select NO_IOPORT_MAP
> @@ -240,7 +240,7 @@ config SAMSUNG_PM_DEBUG
>  	bool "Samsung PM Suspend debug"
>  	depends on PM && DEBUG_KERNEL
>  	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
> -	depends on DEBUG_EXYNOS_UART || DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART
> +	depends on DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART
>  	help
>  	  Say Y here if you want verbose debugging from the PM Suspend and
>  	  Resume code. See <file:Documentation/arm/samsung-s3c24xx/suspend.rst>
> diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
> index 49ea02c467bf..400a581c918c 100644
> --- a/drivers/mmc/host/Kconfig
> +++ b/drivers/mmc/host/Kconfig
> @@ -275,7 +275,7 @@ config MMC_SDHCI_TEGRA
>  
>  config MMC_SDHCI_S3C
>  	tristate "SDHCI support on Samsung S3C SoC"
> -	depends on MMC_SDHCI && PLAT_SAMSUNG
> +	depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_EXYNOS)
>  	help
>  	  This selects the Secure Digital Host Controller Interface (SDHCI)
>  	  often referrered to as the HSMMC block in some of the Samsung S3C
> -- 
> 2.20.0
> 

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-10 20:29   ` [PATCH 11/36] ARM: s5pv210: split from plat-samsung Arnd Bergmann
                       ` (2 preceding siblings ...)
  2019-10-15 14:23     ` Thierry Reding
@ 2019-10-23 12:14     ` Krzysztof Kozlowski
  2019-10-23 13:17       ` Arnd Bergmann
  3 siblings, 1 reply; 21+ messages in thread
From: Krzysztof Kozlowski @ 2019-10-23 12:14 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Kukjin Kim, Ulf Hansson, Thierry Reding, Mark Brown,
	Greg Kroah-Hartman, Jiri Slaby, Sangbeom Kim, Sylwester Nawrocki,
	Liam Girdwood, linux-samsung-soc, linux-arm-kernel,
	linus.walleij, Uwe Kleine-König, Jaroslav Kysela,
	Takashi Iwai, Olof Johansson, Sascha Hauer,
	Clément Péron, Mauro Carvalho Chehab

On Thu, Oct 10, 2019 at 10:29:55PM +0200, Arnd Bergmann wrote:
> These can be build completely independently, so split
> the two Kconfig symbols.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  arch/arm/Kconfig.debug        | 6 +++---
>  arch/arm/Makefile             | 1 -
>  arch/arm/plat-samsung/Kconfig | 2 +-
>  drivers/mmc/host/Kconfig      | 2 +-
>  drivers/pwm/Kconfig           | 2 +-
>  drivers/spi/Kconfig           | 2 +-
>  drivers/tty/serial/Kconfig    | 2 +-
>  sound/soc/samsung/Kconfig     | 2 +-
>  8 files changed, 9 insertions(+), 10 deletions(-)
> 
> diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
> index 9c4f2d6deb06..4c4e97ae4fcb 100644
> --- a/arch/arm/Kconfig.debug
> +++ b/arch/arm/Kconfig.debug
> @@ -998,7 +998,7 @@ choice
>  		  via SCIFA4 on Renesas SH-Mobile AG5 (SH73A0).
>  
>  	config DEBUG_S3C_UART0
> -		depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS

How are you going to select DEBUG_S5PV210_UART now?

Best regards,
Krzysztof


>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1010,7 +1010,7 @@ choice
>  		  by the boot-loader before use.
>  
>  	config DEBUG_S3C_UART1
> -		depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> @@ -1022,7 +1022,7 @@ choice
>  		  by the boot-loader before use.
>  
>  	config DEBUG_S3C_UART2
> -		depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +		depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  		select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>  		select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>  		select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index f492d7c338fe..a1bc15cda751 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -235,7 +235,6 @@ machine-$(CONFIG_PLAT_SPEAR)		+= spear
>  # by CONFIG_* macro name.
>  plat-$(CONFIG_ARCH_OMAP)	+= omap
>  plat-$(CONFIG_ARCH_S3C64XX)	+= samsung
> -plat-$(CONFIG_ARCH_S5PV210)	+= samsung
>  plat-$(CONFIG_PLAT_ORION)	+= orion
>  plat-$(CONFIG_PLAT_PXA)		+= pxa
>  plat-$(CONFIG_PLAT_S3C24XX)	+= samsung
> diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
> index 740bdb23f38a..1530946cc672 100644
> --- a/arch/arm/plat-samsung/Kconfig
> +++ b/arch/arm/plat-samsung/Kconfig
> @@ -4,7 +4,7 @@
>  
>  config PLAT_SAMSUNG
>  	bool
> -	depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
> +	depends on PLAT_S3C24XX || ARCH_S3C64XX
>  	default y
>  	select GENERIC_IRQ_CHIP
>  	select NO_IOPORT_MAP
> diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
> index 400a581c918c..16a0e5430b44 100644
> --- a/drivers/mmc/host/Kconfig
> +++ b/drivers/mmc/host/Kconfig
> @@ -275,7 +275,7 @@ config MMC_SDHCI_TEGRA
>  
>  config MMC_SDHCI_S3C
>  	tristate "SDHCI support on Samsung S3C SoC"
> -	depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_EXYNOS)
> +	depends on MMC_SDHCI && (PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS)
>  	help
>  	  This selects the Secure Digital Host Controller Interface (SDHCI)
>  	  often referrered to as the HSMMC block in some of the Samsung S3C
> diff --git a/drivers/pwm/Kconfig b/drivers/pwm/Kconfig
> index e3a2518503ed..8eb738cac0c7 100644
> --- a/drivers/pwm/Kconfig
> +++ b/drivers/pwm/Kconfig
> @@ -394,7 +394,7 @@ config PWM_ROCKCHIP
>  
>  config PWM_SAMSUNG
>  	tristate "Samsung PWM support"
> -	depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +	depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  	help
>  	  Generic PWM framework driver for Samsung.
>  
> diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
> index 6f7fdcbb9151..355391ee643d 100644
> --- a/drivers/spi/Kconfig
> +++ b/drivers/spi/Kconfig
> @@ -625,7 +625,7 @@ config SPI_S3C24XX_FIQ
>  
>  config SPI_S3C64XX
>  	tristate "Samsung S3C64XX series type SPI"
> -	depends on (PLAT_SAMSUNG || ARCH_EXYNOS || COMPILE_TEST)
> +	depends on (PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS || COMPILE_TEST)
>  	help
>  	  SPI driver for Samsung S3C64XX and newer SoCs.
>  
> diff --git a/drivers/tty/serial/Kconfig b/drivers/tty/serial/Kconfig
> index 4789b5d62f63..17f01cf3009c 100644
> --- a/drivers/tty/serial/Kconfig
> +++ b/drivers/tty/serial/Kconfig
> @@ -237,7 +237,7 @@ config SERIAL_CLPS711X_CONSOLE
>  
>  config SERIAL_SAMSUNG
>  	tristate "Samsung SoC serial support"
> -	depends on PLAT_SAMSUNG || ARCH_EXYNOS
> +	depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>  	select SERIAL_CORE
>  	help
>  	  Support for the on-chip UARTs on the Samsung S3C24XX series CPUs,
> diff --git a/sound/soc/samsung/Kconfig b/sound/soc/samsung/Kconfig
> index 638983123d8f..7a0035dd9995 100644
> --- a/sound/soc/samsung/Kconfig
> +++ b/sound/soc/samsung/Kconfig
> @@ -1,7 +1,7 @@
>  # SPDX-License-Identifier: GPL-2.0-only
>  menuconfig SND_SOC_SAMSUNG
>  	tristate "ASoC support for Samsung"
> -	depends on PLAT_SAMSUNG || ARCH_EXYNOS || COMPILE_TEST
> +	depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS || COMPILE_TEST
>  	depends on COMMON_CLK
>  	select SND_SOC_GENERIC_DMAENGINE_PCM
>  	---help---
> -- 
> 2.20.0
> 

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG
  2019-10-23 10:57     ` Krzysztof Kozlowski
@ 2019-10-23 12:43       ` Arnd Bergmann
  0 siblings, 0 replies; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-23 12:43 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Ulf Hansson, moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES,
	Bartlomiej Zolnierkiewicz, Linus Walleij, linux-mmc,
	linux-kernel, Kukjin Kim, Olof Johansson, Enrico Weigelt,
	metux IT consult, Sascha Hauer, Linux ARM

On Wed, Oct 23, 2019 at 12:57 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
> On Thu, Oct 10, 2019 at 10:29:52PM +0200, Arnd Bergmann wrote:
> > @@ -1022,7 +1022,7 @@ choice
> >                 by the boot-loader before use.
> >
> >       config DEBUG_S3C_UART2
> > -             depends on PLAT_SAMSUNG
> > +             depends on PLAT_SAMSUNG || ARCH_EXYNOS
> >               select DEBUG_EXYNOS_UART if ARCH_EXYNOS
> >               select DEBUG_S3C24XX_UART if ARCH_S3C24XX
> >               select DEBUG_S3C64XX_UART if ARCH_S3C64XX
> > @@ -1034,7 +1034,7 @@ choice
> >                 by the boot-loader before use.
> >
> >       config DEBUG_S3C_UART3
> > -             depends on PLAT_SAMSUNG && (ARCH_EXYNOS || ARCH_S5PV210)
> > +             depends on ARCH_EXYNOS || ARCH_S5PV210
>
> You need to keep PLAT_SAMSUNG because of additional architectures, so
> follow pattern from DEBUG_S3C_UART2.

Are you sure? I think my version is correct: for UART2, the
"PLAT_SAMSUNG || ARCH_EXYNOS" is equivalent to "s3c24xx || s3c64xx ||
s5pv210 || exynos", which keeps the existing behavior unchanged.

For UART3, the "PLAT_SAMSUNG && ..." is redundant, this is already
limited to "s5pv210 || exynos", which my patch keeps. Changing it to
"PLAT_SAMSUNG || ..." would allow selecting the symbol on s3c24xx
and s3c64xx, which presumably is not valid.

      Arnd

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 00/36] ARM: samsung platform cleanup
  2019-10-10 20:28 [PATCH 00/36] ARM: samsung platform cleanup Arnd Bergmann
       [not found] ` <20191010203043.1241612-1-arnd@arndb.de>
@ 2019-10-23 13:10 ` Krzysztof Kozlowski
  2019-10-23 13:39   ` Arnd Bergmann
  1 sibling, 1 reply; 21+ messages in thread
From: Krzysztof Kozlowski @ 2019-10-23 13:10 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: linux-fbdev, alsa-devel, dri-devel, Sylwester Nawrocki,
	linux-clk, linux-leds, linux-samsung-soc, linux-stm32, Lihua Yao,
	Kukjin Kim, linux-serial, linux-input, Paweł Chmiel,
	linux-pwm, Sergio Prado, linux-pm, Lihua Yao, linux-arm-kernel,
	linux-hwmon, patches, linux-usb, linux-mmc, linux-kernel,
	linux-spi

On Thu, Oct 10, 2019 at 10:28:02PM +0200, Arnd Bergmann wrote:
> I've spent some time looking at the remaining ARMv4/ARMv5 platforms
> that are not part of ARCH_MULTIPLATFORM, and tried to get them closer
> to that. Here is what came out of that for the samsung platforms:
> 
> * Exynos and s5pv210 are made independent of plat-samsung
> * device drivers stop using mach/*.h headers for s3c24xx
>   (and other platforms not in this series)
> * s3c24xx and s3c64xx get merged into mach-s3c, removing
>   the need for plat-samsung (I have other patches for the
>   remaining plat-* directories)
> * mach/io.h gets cleaned up to only be needed for BAST
>   PC104 mode (looking for ideas to proceed)
> * mach/irqs.h remains for now, this still needs to be converted
>   to sparse IRQs.
> 
> Some bits are a little ugly, but overall I think this a big
> improvement.
> 
> The contents are available for testing in
> 
> git://kernel.org:/pub/scm/linux/kernel/git/arnd/playground.git s3c-multiplatform

When sending v2, can you Cc:

Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
Lihua Yao <ylhuajnu@outlook.com>
(or Lihua Yao <ylhuajnu@163.com> if outlook.com bounces)
Sergio Prado <sergio.prado@e-labworks.com>
Sylwester Nawrocki <s.nawrocki@samsung.com>

These are folks which to my knowledge had working S3C and S5P boards
so maybe they could provide testing.

Best regards,
Krzysztof

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-23 12:14     ` Krzysztof Kozlowski
@ 2019-10-23 13:17       ` Arnd Bergmann
  2019-10-23 14:12         ` Krzysztof Kozlowski
  0 siblings, 1 reply; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-23 13:17 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Kukjin Kim, Ulf Hansson, Thierry Reding, Mark Brown,
	Greg Kroah-Hartman, Jiri Slaby, Sangbeom Kim, Sylwester Nawrocki,
	Liam Girdwood,
	moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES, Linux ARM,
	Linus Walleij, Uwe Kleine-König, Jaroslav Kysela,
	Takashi Iwai, Olof Johansson, Sascha Hauer

On Wed, Oct 23, 2019 at 2:15 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
> On Thu, Oct 10, 2019 at 10:29:55PM +0200, Arnd Bergmann wrote:
> > These can be build completely independently, so split
> > the two Kconfig symbols.
> >       config DEBUG_S3C_UART0
> > -             depends on PLAT_SAMSUNG || ARCH_EXYNOS
> > +             depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>
> How are you going to select DEBUG_S5PV210_UART now?

I don't see a problem here, the patch should not change the behavior at all.

The whole entry now looks like:

        config DEBUG_S3C_UART0
                depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
                select DEBUG_EXYNOS_UART if ARCH_EXYNOS
                select DEBUG_S3C24XX_UART if ARCH_S3C24XX
                select DEBUG_S3C64XX_UART if ARCH_S3C64XX
                select DEBUG_S5PV210_UART if ARCH_S5PV210
                bool "Use Samsung S3C UART 0 for low-level debug"

so this will work as before with any of ARCH_EXYNOS, ARCH_S3C24XX,
ARCH_S3C64XX and ARCH_S5PV210.

What am I missing?

     Arnd

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 00/36] ARM: samsung platform cleanup
  2019-10-23 13:10 ` [PATCH 00/36] ARM: samsung platform cleanup Krzysztof Kozlowski
@ 2019-10-23 13:39   ` Arnd Bergmann
  2019-10-23 15:17     ` Lihua Yao
  0 siblings, 1 reply; 21+ messages in thread
From: Arnd Bergmann @ 2019-10-23 13:39 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Linux Fbdev development list, ALSA Development Mailing List,
	dri-devel, Sylwester Nawrocki, linux-clk, linux-leds,
	moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES, linux-stm32,
	Lihua Yao, Kukjin Kim, linux-serial, open list:HID CORE LAYER,
	Paweł Chmiel, Linux PWM List, Sergio Prado, Linux PM list

On Wed, Oct 23, 2019 at 3:11 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
> On Thu, Oct 10, 2019 at 10:28:02PM +0200, Arnd Bergmann wrote:
> > The contents are available for testing in
> >
> > git://kernel.org:/pub/scm/linux/kernel/git/arnd/playground.git s3c-multiplatform
>
> When sending v2, can you Cc:
>
> Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
> Lihua Yao <ylhuajnu@outlook.com>
> (or Lihua Yao <ylhuajnu@163.com> if outlook.com bounces)
> Sergio Prado <sergio.prado@e-labworks.com>
> Sylwester Nawrocki <s.nawrocki@samsung.com>
>
> These are folks which to my knowledge had working S3C and S5P boards
> so maybe they could provide testing.

Ok, will do. I've uploaded the modified version based on your comments to
the above URL for now.

I'll probably give it a little more time before resending, but they
could already
start testing that version.

Thanks a lot for the review!

      Arnd

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 11/36] ARM: s5pv210: split from plat-samsung
  2019-10-23 13:17       ` Arnd Bergmann
@ 2019-10-23 14:12         ` Krzysztof Kozlowski
  0 siblings, 0 replies; 21+ messages in thread
From: Krzysztof Kozlowski @ 2019-10-23 14:12 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Ulf Hansson, Linus Walleij, ALSA Development Mailing List,
	Liam Girdwood, Thierry Reding, Sylwester Nawrocki,
	Mauro Carvalho Chehab,
	moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES,
	Takashi Iwai, Kukjin Kim, Clément Péron, linux-serial,
	Uwe Kleine-König, Linux PWM List, Bartlomiej Zolnierkiewicz,
	Sascha Hauer, Jiri Slaby, Mark Brown, Jaroslav Kysela

On Wed, Oct 23, 2019 at 03:17:35PM +0200, Arnd Bergmann wrote:
> On Wed, Oct 23, 2019 at 2:15 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
> > On Thu, Oct 10, 2019 at 10:29:55PM +0200, Arnd Bergmann wrote:
> > > These can be build completely independently, so split
> > > the two Kconfig symbols.
> > >       config DEBUG_S3C_UART0
> > > -             depends on PLAT_SAMSUNG || ARCH_EXYNOS
> > > +             depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
> >
> > How are you going to select DEBUG_S5PV210_UART now?
> 
> I don't see a problem here, the patch should not change the behavior at all.
> 
> The whole entry now looks like:
> 
>         config DEBUG_S3C_UART0
>                 depends on PLAT_SAMSUNG || ARCH_S5PV210 || ARCH_EXYNOS
>                 select DEBUG_EXYNOS_UART if ARCH_EXYNOS
>                 select DEBUG_S3C24XX_UART if ARCH_S3C24XX
>                 select DEBUG_S3C64XX_UART if ARCH_S3C64XX
>                 select DEBUG_S5PV210_UART if ARCH_S5PV210
>                 bool "Use Samsung S3C UART 0 for low-level debug"
> 
> so this will work as before with any of ARCH_EXYNOS, ARCH_S3C24XX,
> ARCH_S3C64XX and ARCH_S5PV210.
> 
> What am I missing?

Ah, everything is OK, I mixed up removed with added line so it looked
reversed (removal of ARCH_S5PV210).

Looks good.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 00/36] ARM: samsung platform cleanup
  2019-10-23 13:39   ` Arnd Bergmann
@ 2019-10-23 15:17     ` Lihua Yao
  0 siblings, 0 replies; 21+ messages in thread
From: Lihua Yao @ 2019-10-23 15:17 UTC (permalink / raw)
  To: Arnd Bergmann, Krzysztof Kozlowski
  Cc: Linux Fbdev development list, ALSA Development Mailing List,
	dri-devel, Sylwester Nawrocki, linux-stm32, linux-leds,
	moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES, linux-clk,
	Kukjin Kim, linux-serial, open list:HID CORE LAYER,
	Paweł Chmiel, Linux PWM List, Sergio Prado, Linux PM list,
	Lihua Yao

Hi Arnd, Krzysztof,

On 23/10/2019 9:39 PM, Arnd Bergmann wrote:
> On Wed, Oct 23, 2019 at 3:11 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>> On Thu, Oct 10, 2019 at 10:28:02PM +0200, Arnd Bergmann wrote:
>>> The contents are available for testing in
>>>
>>> git://kernel.org:/pub/scm/linux/kernel/git/arnd/playground.git s3c-multiplatform
>> When sending v2, can you Cc:
>>
>> Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
>> Lihua Yao <ylhuajnu@outlook.com>
>> (or Lihua Yao <ylhuajnu@163.com> if outlook.com bounces)

You could reach me by e-mail to Lihua Yao <lihua.yao@gmx.com>.

Neither 163.com nor outlook.com e-mail server cooperates well with

vger.kernel.org mail list.

>> Sergio Prado <sergio.prado@e-labworks.com>
>> Sylwester Nawrocki <s.nawrocki@samsung.com>
>>
>> These are folks which to my knowledge had working S3C and S5P boards
>> so maybe they could provide testing.
> Ok, will do. I've uploaded the modified version based on your comments to
> the above URL for now.
>
> I'll probably give it a little more time before resending, but they
> could already
> start testing that version.

Nice!  Sadly I am on vocation and will test it until Nov 15.

Best Regards

Lihua

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2019-10-23 15:17 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-10 20:28 [PATCH 00/36] ARM: samsung platform cleanup Arnd Bergmann
     [not found] ` <20191010203043.1241612-1-arnd@arndb.de>
2019-10-10 20:29   ` [PATCH 08/36] ARM: exynos: stop selecting PLAT_SAMSUNG Arnd Bergmann
2019-10-15 14:12     ` Ulf Hansson
2019-10-23 10:57     ` Krzysztof Kozlowski
2019-10-23 12:43       ` Arnd Bergmann
2019-10-10 20:29   ` [PATCH 11/36] ARM: s5pv210: split from plat-samsung Arnd Bergmann
2019-10-11  5:51     ` Uwe Kleine-König
2019-10-22 14:01       ` Arnd Bergmann
2019-10-22 15:53         ` Uwe Kleine-König
2019-10-22 16:20           ` Arnd Bergmann
2019-10-15 14:13     ` Ulf Hansson
2019-10-15 14:23     ` Thierry Reding
2019-10-23 12:14     ` Krzysztof Kozlowski
2019-10-23 13:17       ` Arnd Bergmann
2019-10-23 14:12         ` Krzysztof Kozlowski
2019-10-10 20:30   ` [PATCH 23/36] ARM: s3c: move s3cmci pinctrl handling into board files Arnd Bergmann
2019-10-15 14:12     ` Ulf Hansson
2019-10-16 13:12     ` Linus Walleij
2019-10-23 13:10 ` [PATCH 00/36] ARM: samsung platform cleanup Krzysztof Kozlowski
2019-10-23 13:39   ` Arnd Bergmann
2019-10-23 15:17     ` Lihua Yao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).