Skip to contentSkip to conversation

omap plat header removal for v3.8 merge window, part1

GIT PULL Tony Lindgren 3 participants 11 messages Oct 19, 2012 – Oct 30, 2012

Subsystems (8)
lore
Share & tools
lore

Tony Lindgren

author maintainer
#0 lore raw

Hi Arnd & Olof,

Here's the first set of omap plat header removal for v3.8 merge window. I have at least one more related set coming, but I wanted to get these into linux next before driver patches add more things for me to chase down and fix.

Oh, forgot to mention in the tag that the increase in diffstat is mostly because plat-omap/clock shared clock code is duplicated as that's also needed for the common clock framework patches coming up.

Regards,

Tony

The following changes since commit ddffeb8c4d0331609ef2581d84de4d763607bd37:

Linux 3.7-rc1 (2012-10-14 14:41:04 -0700)

are available in the git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap tags/omap-for-v3.8/cleanup-headers-signed

for you to fetch changes up to e4c060db2c13f10de09101afc564763f9fd0019a:

ARM: OMAP: Split plat/cpu.h into local soc.h for mach-omap1 and mach-omap2 (2012-10-18 16:23:46 -0700)

----------------------------------------------------------------
This is the first set of omap cleanup patches for v3.8 merge window to remove most of the remaining plat includes to get us closer to ARM common zImage support.

To avoid a huge amount of trivial merge conflicts with includes, this branch is based on several small topic branches coordinated with the driver subsystem maintainers. These branches are based on v3.7-rc1 and can also be merged into the related driver subsystem branches as needed:

omap-for-v3.8/cleanup-headers-prepare   few trivial driver changes
omap-for-v3.8/cleanup-headers-dma       move of the DMA header
omap-for-v3.8/cleanup-headers-gpmc      GPMC and MTD changes
omap-for-v3.8/cleanup-headers-mmc       MMC related changes
omap-for-v3.8/cleanup-headers-dss       DSS related changes
omap-for-v3.8/cleanup-headers-asoc      ASoC related changes

Note that for the dma-omap.h, it was decided that it should be is completed. For the related discussion, please see:

https://patchwork.kernel.org/patch/1519591/#

After these patches we still have a few plat headers remaining that will be handled in later pull requests.

----------------------------------------------------------------
Afzal Mohammed (16):
ARM: OMAP2+: nand: unify init functions
ARM: OMAP2+: onenand: refactor for clarity
ARM: OMAP2+: gpmc: remove cs# in sync clk div calc
mtd: onenand: omap: cleanup gpmc dependency
mtd: nand: omap: free region as per resource size
mtd: nand: omap: read nand using register address
ARM: OMAP2+: onenand: connected soc info in pdata
mtd: onenand: omap: use pdata info instead of cpu_is
ARM: OMAP2+: onenand: header cleanup
ARM: OMAP2+: nand: header cleanup
mtd: nand: omap: bring in gpmc nand macros
ARM: OMAP2+: nand: bch capability check
ARM: OMAP2+: gpmc: nand register helper bch update
mtd: nand: omap: handle gpmc bch[48]
ARM: OMAP2+: gpmc: remove exported nand functions
ARM: OMAP2+: gpmc: localize gpmc header

Jon Hunter (1):
ARM: OMAP2+: GPMC: Remove unused OneNAND get_freq() platform function

Lokesh Vutla (7):
ARM: OMAP: DMA: Removing plat/dma-44xx.h
ARM: OMAP1: DMA: Moving OMAP1 DMA channel definitions to mach-omap1
ARM: OMAP2+: DMA: Moving OMAP2+ DMA channel definitions to mach-omap2
ARM: OMAP: DMA: Move plat/dma.h to plat-omap/dma-omap.h
ARM: OMAP1: Remove omap_reserve() callback for all omap1 boards
ARM: OMAP2+: Move omap_reserve() locally to mach-omap2
ARM: OMAP: Move plat/omap-secure.h locally to mach-omap2

Paul Walmsley (5):
staging: tidspbridge: remove unnecessary include of <plat/clock.h>
ARM: OMAP: move plat-omap/include/plat/sdrc.h into mach-omap2/sdrc.h
ARM: OMAP: duplicate plat-omap/clock.c into mach-omap[12]/clock.c
ARM: OMAP: remove plat/clock.h
ARM: OMAP: clock: split plat/clkdev_omap.h into OMAP1/2 files

Peter Ujfalusi (2):
ASoC: omap-abe-twl6040: Fix typo of Vibrator
ASoC: omap-mcpdm: Remove OMAP revision check

Tomi Valkeinen (11):
OMAPDSS: add omapdss_version
OMAPDSS: use omapdss_version in dss_features.c
OMAPDSS: DISPC: use omapdss_version
OMAPDSS: DSS: use omapdss_version
OMAPDSS: HDMI: use omapdss_version
OMAPDSS: remove <plat/cpu.h> includes
OMAP: VRFB: convert vrfb to platform device
OMAP: move arch/arm/plat-omap/include/plat/vrfb.h
OMAP: SDRC: remove VRFB code
OMAPDSS: VRFB: add omap_vrfb_supported()
OMAPFB: use omap_vrfb_supported()

Tony Lindgren (23):
ASoC: Fix wrong include for McPDM
ARM: OMAP: Split plat/mmc.h into local headers and platform_data
mmc: omap: Remove cpu_is_omap usage from the driver
ARM: OMAP: Trivial driver changes to remove include plat/cpu.h
Merge tag 'gpmc-czimage' of git://gitorious.org/x0148406-public/linux-kernel into omap-for-v3.8/cleanup-headers-gpmc Merge remote-tracking branch 'tomi/3.8/vrfb-conversion' into omap-for-v3.8/cleanup-headers-dss Merge branch 'omap-for-v3.8/cleanup-headers-dma' into omap-for-v3.8/cleanup-headers
Merge branch 'omap-for-v3.8/cleanup-headers-gpmc' into omap-for-v3.8/cleanup-headers
Merge branch 'omap-for-v3.8/cleanup-headers-mmc' into omap-for-v3.8/cleanup-headers
Merge branch 'omap-for-v3.8/cleanup-headers-dss' into omap-for-v3.8/cleanup-headers
ARM: OMAP: Make plat/fpga.h local to arch/arm/plat-omap
ARM: OMAP1: Move plat/tc.h to mach/tc.h for omap1
ARM: OMAP2+: Make board-zoom.h local
ARM: OMAP: Split plat-omap/i2c.c into mach-omap1 and mach-omap2
ARM: OMAP: Make plat/common.h local to mach-omap1 and mach-omap2
ARM: OMAP: Move plat/led.h to include/linux/platform_data
ARM: OMAP: Make plat/sram.h local to plat-omap
ARM: OMAP: Make omap_device local to mach-omap2
Merge branch 'omap-for-v3.8/cleanup-headers-asoc' into omap-for-v3.8/cleanup-headers
ARM: OMAP: Make plat/omap_hwmod.h local to mach-omap2
ARM: OMAP: Merge plat/multi.h into plat/cpu.h
ARM: OMAP: Make plat/omap-pm.h local to mach-omap2
ARM: OMAP: Split plat/cpu.h into local soc.h for mach-omap1 and mach-omap2

 arch/arm/mach-omap1/board-ams-delta.c              |    1 -
 arch/arm/mach-omap1/board-fsample.c                |    9 +-
 arch/arm/mach-omap1/board-generic.c                |    1 -
 arch/arm/mach-omap1/board-h2-mmc.c                 |    5 +-
 arch/arm/mach-omap1/board-h2.c                     |    6 +-
 arch/arm/mach-omap1/board-h3-mmc.c                 |    3 +-
 arch/arm/mach-omap1/board-h3.c                     |    5 +-
 arch/arm/mach-omap1/board-htcherald.c              |    3 +-
 arch/arm/mach-omap1/board-innovator.c              |   31 +-
 arch/arm/mach-omap1/board-nokia770.c               |    5 +-
 arch/arm/mach-omap1/board-osk.c                    |    3 +-
 arch/arm/mach-omap1/board-palmte.c                 |    6 +-
 arch/arm/mach-omap1/board-palmtt.c                 |    8 +-
 arch/arm/mach-omap1/board-palmz71.c                |    6 +-
 arch/arm/mach-omap1/board-perseus2.c               |    9 +-
 arch/arm/mach-omap1/board-sx1-mmc.c                |    3 +-
 arch/arm/mach-omap1/board-sx1.c                    |    6 +-
 arch/arm/mach-omap1/board-voiceblue.c              |    3 +-
 arch/arm/mach-omap1/clock.c                        |  506 +++++++++++++++++-
 arch/arm/mach-omap1/clock.h                        |  178 ++++++-
 arch/arm/mach-omap1/clock_data.c                   |   17 +-
 arch/arm/mach-omap1/common.h                       |    6 +-
 arch/arm/mach-omap1/devices.c                      |   15 +-
 arch/arm/mach-omap1/dma.c                          |    6 +-
 arch/arm/mach-omap1/dma.h                          |   83 +++
 arch/arm/mach-omap1/flash.c                        |    2 +-
 arch/arm/mach-omap1/fpga.c                         |    2 +-
 arch/arm/mach-omap1/i2c.c                          |   61 ++-
 arch/arm/mach-omap1/id.c                           |    2 +-
 arch/arm/mach-omap1/include/mach/hardware.h        |    4 +-
 arch/arm/mach-omap1/include/mach/memory.h          |    2 +-
 arch/arm/mach-omap1/include/mach/omap1510.h        |  113 ++++
 .../include/plat => mach-omap1/include/mach}/tc.h  |    0
 arch/arm/mach-omap1/io.c                           |    4 +-
 arch/arm/mach-omap1/irq.c                          |    2 +-
 arch/arm/mach-omap1/lcd_dma.c                      |    4 +-
 arch/arm/mach-omap1/mcbsp.c                        |    5 +-
 arch/arm/mach-omap1/mmc.h                          |   18 +
 arch/arm/mach-omap1/opp_data.c                     |    2 +-
 arch/arm/mach-omap1/pm.c                           |   10 +-
 arch/arm/mach-omap1/pm_bus.c                       |    3 -
 arch/arm/mach-omap1/serial.c                       |    1 -
 arch/arm/mach-omap1/soc.h                          |  229 ++++++++
 arch/arm/mach-omap2/Makefile                       |    3 +-
 arch/arm/mach-omap2/am35xx-emac.c                  |    2 +-
 arch/arm/mach-omap2/board-2430sdp.c                |    2 +-
 arch/arm/mach-omap2/board-3430sdp.c                |    5 +-
 arch/arm/mach-omap2/board-3630sdp.c                |    2 +-
 arch/arm/mach-omap2/board-4430sdp.c                |    2 +-
 arch/arm/mach-omap2/board-apollon.c                |    4 +-
 arch/arm/mach-omap2/board-cm-t35.c                 |    5 +-
 arch/arm/mach-omap2/board-cm-t3517.c               |    5 +-
 arch/arm/mach-omap2/board-devkit8000.c             |   10 +-
 arch/arm/mach-omap2/board-flash.c                  |   52 +-
 arch/arm/mach-omap2/board-flash.h                  |    8 +-
 arch/arm/mach-omap2/board-h4.c                     |    4 +-
 arch/arm/mach-omap2/board-igep0020.c               |    5 +-
 arch/arm/mach-omap2/board-ldp.c                    |    8 +-
 arch/arm/mach-omap2/board-n8x0.c                   |    3 +-
 arch/arm/mach-omap2/board-omap3beagle.c            |   13 +-
 arch/arm/mach-omap2/board-omap3evm.c               |    9 +-
 arch/arm/mach-omap2/board-omap3logic.c             |    5 +-
 arch/arm/mach-omap2/board-omap3pandora.c           |    3 +-
 arch/arm/mach-omap2/board-omap3stalker.c           |    2 +-
 arch/arm/mach-omap2/board-omap3touchbook.c         |   10 +-
 arch/arm/mach-omap2/board-omap4panda.c             |    2 +-
 arch/arm/mach-omap2/board-overo.c                  |    9 +-
 arch/arm/mach-omap2/board-rm680.c                  |    6 +-
 arch/arm/mach-omap2/board-rx51-peripherals.c       |    7 +-
 arch/arm/mach-omap2/board-rx51.c                   |    6 +-
 arch/arm/mach-omap2/board-zoom-debugboard.c        |    4 +-
 arch/arm/mach-omap2/board-zoom-display.c           |    3 +-
 arch/arm/mach-omap2/board-zoom-peripherals.c       |    2 +-
 arch/arm/mach-omap2/board-zoom.c                   |    7 +-
 .../arm/mach-omap2/{include/mach => }/board-zoom.h |    0
 arch/arm/mach-omap2/clkt2xxx_apll.c                |    1 -
 arch/arm/mach-omap2/clkt2xxx_dpll.c                |    2 -
 arch/arm/mach-omap2/clkt2xxx_dpllcore.c            |    5 +-
 arch/arm/mach-omap2/clkt2xxx_osc.c                 |    2 -
 arch/arm/mach-omap2/clkt2xxx_sys.c                 |    2 -
 arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c       |    5 +-
 arch/arm/mach-omap2/clkt34xx_dpll3m2.c             |    4 +-
 arch/arm/mach-omap2/clkt_clksel.c                  |    2 -
 arch/arm/mach-omap2/clkt_dpll.c                    |    2 -
 arch/arm/mach-omap2/clkt_iclk.c                    |    1 -
 arch/arm/mach-omap2/clock.c                        |  518 ++++++++++++++++++-
 arch/arm/mach-omap2/clock.h                        |  317 +++++++++++-
 arch/arm/mach-omap2/clock2420_data.c               |    4 -
 arch/arm/mach-omap2/clock2430.c                    |    2 -
 arch/arm/mach-omap2/clock2430_data.c               |    4 -
 arch/arm/mach-omap2/clock2xxx.c                    |    2 -
 arch/arm/mach-omap2/clock33xx_data.c               |    5 +-
 arch/arm/mach-omap2/clock34xx.c                    |    2 -
 arch/arm/mach-omap2/clock3517.c                    |    2 -
 arch/arm/mach-omap2/clock36xx.c                    |    2 -
 arch/arm/mach-omap2/clock3xxx.c                    |    2 -
 arch/arm/mach-omap2/clock3xxx_data.c               |    4 -
 arch/arm/mach-omap2/clock44xx_data.c               |    4 -
 arch/arm/mach-omap2/clockdomain.c                  |    3 +-
 arch/arm/mach-omap2/clockdomain.h                  |    5 +-
 arch/arm/mach-omap2/clockdomain2xxx_3xxx.c         |    2 +
 arch/arm/mach-omap2/clockdomains2420_data.c        |    1 +
 arch/arm/mach-omap2/clockdomains2430_data.c        |    1 +
 arch/arm/mach-omap2/clockdomains3xxx_data.c        |    1 +
 arch/arm/mach-omap2/cm33xx.c                       |    2 +-
 arch/arm/mach-omap2/common-board-devices.c         |   46 --
 arch/arm/mach-omap2/common-board-devices.h         |    1 -
 arch/arm/mach-omap2/common.c                       |   22 +-
 arch/arm/mach-omap2/common.h                       |    9 +-
 arch/arm/mach-omap2/control.c                      |    4 +-
 arch/arm/mach-omap2/devices.c                      |    8 +-
 arch/arm/mach-omap2/display.c                      |   45 +-
 arch/arm/mach-omap2/dma.c                          |    8 +-
 arch/arm/mach-omap2/dma.h                          |  131 +++++
 arch/arm/mach-omap2/dpll3xxx.c                     |    2 -
 arch/arm/mach-omap2/dpll44xx.c                     |    2 -
 arch/arm/mach-omap2/drm.c                          |    4 +-
 arch/arm/mach-omap2/dsp.c                          |    2 +-
 arch/arm/mach-omap2/gpio.c                         |    6 +-
 arch/arm/mach-omap2/gpmc-nand.c                    |   85 +--
 arch/arm/mach-omap2/gpmc-nand.h                    |   27 +
 arch/arm/mach-omap2/gpmc-onenand.c                 |  214 ++++----
 arch/arm/mach-omap2/gpmc-onenand.h                 |   24 +
 arch/arm/mach-omap2/gpmc-smc91x.c                  |    2 +-
 arch/arm/mach-omap2/gpmc-smsc911x.c                |    2 +-
 arch/arm/mach-omap2/gpmc.c                         |  464 +----------------
 .../{plat-omap/include/plat => mach-omap2}/gpmc.h  |   61 +--
 arch/arm/mach-omap2/hdq1w.c                        |    4 +-
 arch/arm/mach-omap2/hdq1w.h                        |    2 +-
 arch/arm/mach-omap2/hsmmc.c                        |    7 +-
 arch/arm/mach-omap2/hwspinlock.c                   |    4 +-
 arch/arm/mach-omap2/i2c.c                          |   53 +-
 .../{plat-omap/include/plat => mach-omap2}/i2c.h   |   25 +-
 arch/arm/mach-omap2/io.c                           |   12 +-
 arch/arm/mach-omap2/mcbsp.c                        |    7 +-
 arch/arm/mach-omap2/mmc.h                          |   23 +
 arch/arm/mach-omap2/msdi.c                         |    7 +-
 arch/arm/mach-omap2/mux.c                          |    3 +-
 arch/arm/mach-omap2/omap-mpuss-lowpower.c          |    1 +
 .../include/plat => mach-omap2}/omap-pm.h          |    0
 arch/arm/mach-omap2/omap-secure.c                  |    1 -
 arch/arm/mach-omap2/omap-secure.h                  |    7 +
 arch/arm/mach-omap2/omap4-common.c                 |    7 +-
 arch/arm/{plat-omap => mach-omap2}/omap_device.c   |    5 +-
 .../include/plat => mach-omap2}/omap_device.h      |    2 +-
 arch/arm/mach-omap2/omap_hwmod.c                   |    4 +-
 .../include/plat => mach-omap2}/omap_hwmod.h       |    1 -
 arch/arm/mach-omap2/omap_hwmod_2420_data.c         |   12 +-
 arch/arm/mach-omap2/omap_hwmod_2430_data.c         |   12 +-
 .../omap_hwmod_2xxx_3xxx_interconnect_data.c       |    3 +-
 .../mach-omap2/omap_hwmod_2xxx_3xxx_ipblock_data.c |   10 +-
 .../mach-omap2/omap_hwmod_2xxx_interconnect_data.c |    3 +-
 arch/arm/mach-omap2/omap_hwmod_2xxx_ipblock_data.c |    5 +-
 arch/arm/mach-omap2/omap_hwmod_33xx_data.c         |   10 +-
 arch/arm/mach-omap2/omap_hwmod_3xxx_data.c         |   13 +-
 arch/arm/mach-omap2/omap_hwmod_44xx_data.c         |   13 +-
 arch/arm/mach-omap2/omap_hwmod_common_data.c       |    2 +-
 arch/arm/mach-omap2/omap_hwmod_common_data.h       |    2 +-
 arch/arm/mach-omap2/omap_opp_data.h                |    2 +-
 arch/arm/mach-omap2/omap_twl.c                     |    1 +
 arch/arm/mach-omap2/opp.c                          |    2 +-
 arch/arm/mach-omap2/opp3xxx_data.c                 |    1 +
 arch/arm/mach-omap2/pm-debug.c                     |    5 +-
 arch/arm/mach-omap2/pm.c                           |    5 +-
 arch/arm/mach-omap2/pm24xx.c                       |    8 +-
 arch/arm/mach-omap2/pm34xx.c                       |    9 +-
 arch/arm/mach-omap2/pm44xx.c                       |    1 +
 arch/arm/mach-omap2/pmu.c                          |    5 +-
 arch/arm/mach-omap2/powerdomain.h                  |    2 -
 arch/arm/mach-omap2/powerdomains2xxx_data.c        |    1 +
 arch/arm/mach-omap2/prcm.c                         |    1 +
 arch/arm/mach-omap2/prm33xx.c                      |    2 +-
 arch/arm/mach-omap2/prm_common.c                   |    2 +-
 arch/arm/mach-omap2/sdram-hynix-h8mbx00u0mer-0em.h |    2 +-
 arch/arm/mach-omap2/sdram-micron-mt46h32m32lf-6.h  |    2 +-
 arch/arm/mach-omap2/sdram-nokia.c                  |    4 +-
 arch/arm/mach-omap2/sdram-numonyx-m65kxxxxam.h     |    2 +-
 .../mach-omap2/sdram-qimonda-hyb18m512160af-6.h    |    2 +-
 arch/arm/mach-omap2/sdrc.c                         |   23 +-
 arch/arm/mach-omap2/sdrc.h                         |  146 +++++-
 arch/arm/mach-omap2/sdrc2xxx.c                     |    4 +-
 arch/arm/mach-omap2/serial.c                       |   11 +-
 arch/arm/mach-omap2/sleep34xx.S                    |    2 +-
 arch/arm/mach-omap2/soc.h                          |  468 ++++++++++++++++-
 arch/arm/mach-omap2/sr_device.c                    |    4 +-
 arch/arm/mach-omap2/timer.c                        |    6 +-
 arch/arm/mach-omap2/twl-common.c                   |    1 -
 arch/arm/mach-omap2/usb-host.c                     |    3 +-
 arch/arm/mach-omap2/usb-musb.c                     |    5 +-
 arch/arm/mach-omap2/usb-tusb6010.c                 |    2 +-
 arch/arm/mach-omap2/wd_timer.c                     |    2 +-
 arch/arm/mach-omap2/wd_timer.h                     |    2 +-
 arch/arm/plat-omap/Makefile                        |    3 +-
 arch/arm/plat-omap/clock.c                         |  544 --------------------
 arch/arm/plat-omap/common.c                        |   25 +-
 arch/arm/plat-omap/{include/plat => }/common.h     |   10 +-
 arch/arm/plat-omap/counter_32k.c                   |    3 +-
 arch/arm/plat-omap/debug-leds.c                    |    2 +-
 arch/arm/plat-omap/dma.c                           |   30 +-
 arch/arm/plat-omap/dmtimer.c                       |    3 +-
 arch/arm/plat-omap/fb.c                            |   61 +++
 arch/arm/plat-omap/fpga.h                          |   74 +++
 arch/arm/plat-omap/i2c.c                           |  133 +----
 arch/arm/plat-omap/i2c.h                           |   47 ++
 .../include/{plat/dma.h => plat-omap/dma-omap.h}   |  181 +------
 arch/arm/plat-omap/include/plat/clkdev_omap.h      |   51 --
 arch/arm/plat-omap/include/plat/clock.h            |  309 -----------
 arch/arm/plat-omap/include/plat/cpu.h              |  468 +----------------
 arch/arm/plat-omap/include/plat/dma-44xx.h         |  147 ------
 arch/arm/plat-omap/include/plat/fpga.h             |  193 -------
 arch/arm/plat-omap/include/plat/multi.h            |  120 -----
 arch/arm/plat-omap/include/plat/omap-secure.h      |   14 -
 arch/arm/plat-omap/include/plat/sdrc.h             |  164 ------
 arch/arm/plat-omap/include/plat/sram.h             |  105 ----
 arch/arm/plat-omap/omap-pm-noop.c                  |    5 +-
 arch/arm/plat-omap/sram.c                          |    4 +-
 arch/arm/plat-omap/sram.h                          |  109 +++-
 drivers/char/hw_random/omap-rng.c                  |    2 -
 drivers/crypto/omap-aes.c                          |    8 +-
 drivers/crypto/omap-sham.c                         |   10 +-
 drivers/dma/omap-dma.c                             |   11 +-
 drivers/media/platform/omap/omap_vout.c            |    4 +-
 drivers/media/platform/omap/omap_vout_vrfb.c       |    6 +-
 drivers/media/platform/omap/omap_voutdef.h         |    2 +-
 drivers/media/platform/omap3isp/isphist.c          |    2 +
 drivers/media/platform/omap3isp/ispstat.h          |    2 +-
 drivers/media/platform/soc_camera/omap1_camera.c   |    3 +-
 drivers/media/rc/ir-rx51.c                         |    1 -
 drivers/mmc/host/omap.c                            |   35 +-
 drivers/mmc/host/omap_hsmmc.c                      |    4 +-
 drivers/mtd/nand/omap2.c                           |  129 ++++-
 drivers/mtd/onenand/omap2.c                        |   11 +-
 drivers/pcmcia/omap_cf.c                           |    2 +-
 .../tidspbridge/include/dspbridge/host_os.h        |    1 -
 drivers/usb/gadget/omap_udc.c                      |    4 +-
 drivers/usb/host/ohci-omap.c                       |    5 +-
 drivers/usb/musb/tusb6010_omap.c                   |    9 +-
 drivers/video/omap/lcd_inn1510.c                   |    7 +-
 drivers/video/omap/lcdc.c                          |    2 +-
 drivers/video/omap/omapfb_main.c                   |    2 +-
 drivers/video/omap/sossi.c                         |    2 +-
 drivers/video/omap2/dss/core.c                     |    2 +-
 drivers/video/omap2/dss/dispc.c                    |   43 +-
 drivers/video/omap2/dss/dss.c                      |   39 +-
 drivers/video/omap2/dss/dss_features.c             |   64 ++-
 drivers/video/omap2/dss/dss_features.h             |    5 +-
 drivers/video/omap2/dss/hdmi.c                     |    3 +-
 drivers/video/omap2/omapfb/omapfb-ioctl.c          |    2 +-
 drivers/video/omap2/omapfb/omapfb-main.c           |    8 +-
 drivers/video/omap2/omapfb/omapfb-sysfs.c          |    2 +-
 drivers/video/omap2/vrfb.c                         |  142 ++++-
 .../linux/platform_data/leds-omap.h                |    2 -
 .../linux/platform_data/mmc-omap.h                 |   48 +-
 include/linux/platform_data/mtd-nand-omap2.h       |   46 +-
 include/linux/platform_data/mtd-onenand-omap2.h    |   28 +-
 include/video/omapdss.h                            |   14 +
 .../plat/vrfb.h => include/video/omapvrfb.h        |    2 +
 sound/soc/omap/omap-abe-twl6040.c                  |    2 +-
 sound/soc/omap/omap-mcpdm.c                        |    9 +-
 sound/soc/omap/omap-pcm.c                          |    9 +-
 260 files changed, 4351 insertions(+), 3860 deletions(-)
 create mode 100644 arch/arm/mach-omap1/dma.h
 rename arch/arm/{plat-omap/include/plat => mach-omap1/include/mach}/tc.h (100%)
 create mode 100644 arch/arm/mach-omap1/mmc.h
 create mode 100644 arch/arm/mach-omap1/soc.h
 rename arch/arm/mach-omap2/{include/mach => }/board-zoom.h (100%)
 create mode 100644 arch/arm/mach-omap2/dma.h
 create mode 100644 arch/arm/mach-omap2/gpmc-nand.h
 create mode 100644 arch/arm/mach-omap2/gpmc-onenand.h
 rename arch/arm/{plat-omap/include/plat => mach-omap2}/gpmc.h (67%)
 rename arch/arm/{plat-omap/include/plat => mach-omap2}/i2c.h (66%)
 create mode 100644 arch/arm/mach-omap2/mmc.h
 rename arch/arm/{plat-omap/include/plat => mach-omap2}/omap-pm.h (100%)
 rename arch/arm/{plat-omap => mach-omap2}/omap_device.c (99%)
 rename arch/arm/{plat-omap/include/plat => mach-omap2}/omap_device.h (99%)
 rename arch/arm/{plat-omap/include/plat => mach-omap2}/omap_hwmod.h (99%)
 delete mode 100644 arch/arm/plat-omap/clock.c
 rename arch/arm/plat-omap/{include/plat => }/common.h (89%)
 create mode 100644 arch/arm/plat-omap/fpga.h
 create mode 100644 arch/arm/plat-omap/i2c.h
 rename arch/arm/plat-omap/include/{plat/dma.h => plat-omap/dma-omap.h} (61%)
 delete mode 100644 arch/arm/plat-omap/include/plat/clkdev_omap.h
 delete mode 100644 arch/arm/plat-omap/include/plat/clock.h
 delete mode 100644 arch/arm/plat-omap/include/plat/dma-44xx.h
 delete mode 100644 arch/arm/plat-omap/include/plat/fpga.h
 delete mode 100644 arch/arm/plat-omap/include/plat/multi.h
 delete mode 100644 arch/arm/plat-omap/include/plat/omap-secure.h
 delete mode 100644 arch/arm/plat-omap/include/plat/sdrc.h
 delete mode 100644 arch/arm/plat-omap/include/plat/sram.h
 rename arch/arm/plat-omap/include/plat/led.h => include/linux/platform_data/leds-omap.h (91%)
 rename arch/arm/plat-omap/include/plat/mmc.h => include/linux/platform_data/mmc-omap.h (80%)
 rename arch/arm/plat-omap/include/plat/vrfb.h => include/video/omapvrfb.h (95%)
#1 lore raw
Quoted 11 lines · Tony Lindgren

Hi Arnd & Olof,

Here's the first set of omap plat header removal for v3.8 merge window. I have at least one more related set coming, but I wanted to get these into linux next before driver patches add more things for me to chase down and fix.

Oh, forgot to mention in the tag that the increase in diffstat is mostly because plat-omap/clock shared clock code is duplicated as that's also needed for the common clock framework patches coming up.

Hi Tony,

This is very cool, great work! I'm sorry for taking so long before we processed them, I wasn't coordinating well with Olof for the last week.

I've applied all of it to a new next/headers branch. I thought about using the next/cleanup branch, but since it touches a lot of files outside of arch/arm, I decided to keep it separate. We might decide to merge it later after all.

I tried running my old multiplatform scripts again and have a few comments, but none of them serious:

$ git grep include.*mach-omap2
arch/arm/plat-omap/debug-devices.c:#include "../mach-omap2/debug-devices.h"
arch/arm/plat-omap/dma.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/dmtimer.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/i2c.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/include/plat/cpu.h:#include "../../mach-omap2/soc.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap_device.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/iomap.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/prm2xxx_3xxx.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/sdrc.h"

I don't like the relative include paths too much. I would have preferred adding the mach-omap2/include/mach path in the plat-omap Makefile, but I suppose you want to leave it like it is now since you mention you have already built on top of it.

drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/powerdomain.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/clockdomain.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/cm2xxx_3xxx.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/prm-regbits-34xx.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/cm-regbits-34xx.h> drivers/staging/tidspbridge/core/tiomap3430_pwr.c:#include <mach-omap2/prm-regbits-34xx.h> drivers/staging/tidspbridge/core/tiomap3430_pwr.c:#include <mach-omap2/cm-regbits-34xx.h> drivers/staging/tidspbridge/rmgr/drv_interface.c:#include <mach-omap2/omap3-opp.h>

This code is broken now. I wonder whether it's time to remove it from staging since we now have rpmsg/remoteproc, rather than getting it to compile again.

sound/soc/omap/am3517evm.c:#include <mach-omap2/hardware.h> sound/soc/omap/am3517evm.c:#include <mach-omap2/gpio.h> sound/soc/omap/ams-delta.c:#include <mach-omap2/board-ams-delta.h> sound/soc/omap/n810.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/hardware.h> sound/soc/omap/zoom2.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/board-zoom.h>

Not sure if you were just missing these or if you already have other patch lined up for them.

$ git grep include.*mach-omap1
drivers/video/omap/lcd_ams_delta.c:#include <mach-omap1/board-ams-delta.h>
drivers/video/omap/lcd_inn1510.c:#include <mach-omap1/hardware.h>
drivers/video/omap/lcd_osk.c:#include <mach-omap1/mux.h>
drivers/video/omap/lcdc.c:#include <mach-omap1/lcdc.h>
sound/soc/omap/osk5912.c:#include <mach-omap1/hardware.h>

Same thing here.

Arnd

author maintainer
#2 lore raw
Quoted 15 lines · Arnd Bergmann
Quoted 11 lines · Tony Lindgren

Hi Arnd & Olof,

Here's the first set of omap plat header removal for v3.8 merge window. I have at least one more related set coming, but I wanted to get these into linux next before driver patches add more things for me to chase down and fix.

Oh, forgot to mention in the tag that the increase in diffstat is mostly because plat-omap/clock shared clock code is duplicated as that's also needed for the common clock framework patches coming up.

Hi Tony,

Quoted 8 lines

This is very cool, great work! I'm sorry for taking so long before we processed them, I wasn't coordinating well with Olof for the last week.

I've applied all of it to a new next/headers branch. I thought about using the next/cleanup branch, but since it touches a lot of files outside of arch/arm, I decided to keep it separate. We might decide to merge it later after all.

OK thanks, yes it's OK to keep it separate as I have few more pull requests coming to this as I get acks. It should all merge fine with other branches, let me know if that's not the case.

Quoted 16 lines

I tried running my old multiplatform scripts again and have a few comments, but none of them serious:

$ git grep include.*mach-omap2
arch/arm/plat-omap/debug-devices.c:#include "../mach-omap2/debug-devices.h"
arch/arm/plat-omap/dma.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/dmtimer.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/i2c.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/include/plat/cpu.h:#include "../../mach-omap2/soc.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap_device.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/iomap.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/prm2xxx_3xxx.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/sdrc.h"
Quoted 4 lines

I don't like the relative include paths too much. I would have preferred adding the mach-omap2/include/mach path in the plat-omap Makefile, but I suppose you want to leave it like it is now since you mention you have already built on top of it.

Well I wanted to keep them local to arch/arm/*omap*/ directories, and not have them exposed at all for drivers.

Other than that I don't have an issue using non-relative paths, except mach-omap2/include/mach traditionally has been exposed to drivers as the legacy #include <mach/*.h>, so IMHO local headers in the arch/arm/*omap*/ directories are better.

But now I wonder if we can somehow have drivers not be able to include these local headers?

Quoted 9 lines

drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/powerdomain.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/clockdomain.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/cm2xxx_3xxx.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/prm-regbits-34xx.h> drivers/staging/tidspbridge/core/_tiomap.h:#include <mach-omap2/cm-regbits-34xx.h> drivers/staging/tidspbridge/core/tiomap3430_pwr.c:#include <mach-omap2/prm-regbits-34xx.h> drivers/staging/tidspbridge/core/tiomap3430_pwr.c:#include <mach-omap2/cm-regbits-34xx.h> drivers/staging/tidspbridge/rmgr/drv_interface.c:#include <mach-omap2/omap3-opp.h>

Quoted 3 lines

This code is broken now. I wonder whether it's time to remove it from staging since we now have rpmsg/remoteproc, rather than getting it to compile again.

Oh crap, I totally missed these :( The drivers _should_not_ include these files at all. Whatever they are doing with those includes is totally wrong and a bad layering violation.

If it's not fixed, then yeah, I'd say let's just remove the breaking pieces. Let's give Omar and Laurent a quick chance to fix it up before dropping it though, I've added them to cc.

Quoted 10 lines

sound/soc/omap/am3517evm.c:#include <mach-omap2/hardware.h> sound/soc/omap/am3517evm.c:#include <mach-omap2/gpio.h> sound/soc/omap/ams-delta.c:#include <mach-omap2/board-ams-delta.h> sound/soc/omap/n810.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/hardware.h> sound/soc/omap/zoom2.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/board-zoom.h>

Quoted 2 lines

Not sure if you were just missing these or if you already have other patch lined up for them.

In which branch do you see the above?

I'm not seeing them in v3.7-rc2, looks like all sound/soc/omap/*.c files have already been fixed up.

Quoted 8 lines
$ git grep include.*mach-omap1
drivers/video/omap/lcd_ams_delta.c:#include <mach-omap1/board-ams-delta.h>
drivers/video/omap/lcd_inn1510.c:#include <mach-omap1/hardware.h>
drivers/video/omap/lcd_osk.c:#include <mach-omap1/mux.h>
drivers/video/omap/lcdc.c:#include <mach-omap1/lcdc.h>
sound/soc/omap/osk5912.c:#include <mach-omap1/hardware.h>

Same thing here.

I'm not seeing these either, you're probably looking at some experimental branch modified with your automated scripts?

In any case, let's not have #include <mach-omap1/*.h> or #include <mach-omap2/*.h> includes in the drivers, they are wrong. Those headers are meant to be local, the legacy shared headers should be in #include <mach/*.h>. Whatever needs to be passed from arch/arm/*omap*/ to drivers, should be done using include/linux/platform_data/*.h files.

For omap1, we might as well keep the existing ones from #include <mach/*.h> as they are until somebody wants to fix up things properly for omap1 for CONFIG_MULTIPLATFORM.

Regards,

Tony

#3 lore raw
Quoted 26 lines · Tony Lindgren
Quoted 16 lines · Arnd Bergmann

I tried running my old multiplatform scripts again and have a few comments, but none of them serious:

$ git grep include.*mach-omap2
arch/arm/plat-omap/debug-devices.c:#include "../mach-omap2/debug-devices.h"
arch/arm/plat-omap/dma.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/dmtimer.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/i2c.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/include/plat/cpu.h:#include "../../mach-omap2/soc.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap_device.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/iomap.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/prm2xxx_3xxx.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/sdrc.h"
Quoted 4 lines

I don't like the relative include paths too much. I would have preferred adding the mach-omap2/include/mach path in the plat-omap Makefile, but I suppose you want to leave it like it is now since you mention you have already built on top of it.

Well I wanted to keep them local to arch/arm/*omap*/ directories, and not have them exposed at all for drivers.

Quoted 7 lines

Other than that I don't have an issue using non-relative paths, except mach-omap2/include/mach traditionally has been exposed to drivers as the legacy #include <mach/*.h>, so IMHO local headers in the arch/arm/*omap*/ directories are better.

But now I wonder if we can somehow have drivers not be able to include these local headers?

Well, once CONFIG_MULTIPLATFORM gets enabled, the mach/*.h files are not visible to drivers any more, but they are still visible to files in plat-omap if you add a line like

ccflags-$(CONFIG_ARCH_OMAP2) := -I$(srctree)/arch/arm/mach-omap2/include ccflags-$(CONFIG_ARCH_OMAP1) := -I$(srctree)/arch/arm/mach-omap1/include

to arch/arm/plat-omap/Makefile. That is how the other multiplatform Makefiles do it. If a driver writer really wants to cheat, they can of course do the same thing in their directory, but they can also do #include "../../../../arch/arm/mach-omap2/foo.h"

Quoted 10 lines
Quoted 10 lines

sound/soc/omap/am3517evm.c:#include <mach-omap2/hardware.h> sound/soc/omap/am3517evm.c:#include <mach-omap2/gpio.h> sound/soc/omap/ams-delta.c:#include <mach-omap2/board-ams-delta.h> sound/soc/omap/n810.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/hardware.h> sound/soc/omap/zoom2.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/board-zoom.h>

Quoted 7 lines
Quoted 2 lines

Not sure if you were just missing these or if you already have other patch lined up for them.

In which branch do you see the above?

I'm not seeing them in v3.7-rc2, looks like all sound/soc/omap/*.c files have already been fixed up.

I am looking at the arm-soc for-next branch, which is based on v3.7-rc2.

Note that before my script, this reads

#include <mach/hardware.h>

not

#include <mach-omap2/hardware.h>

but the effect is the same if the file is not available.

Quoted 6 lines

In any case, let's not have #include <mach-omap1/*.h> or #include <mach-omap2/*.h> includes in the drivers, they are wrong. Those headers are meant to be local, the legacy shared headers should be in #include <mach/*.h>. Whatever needs to be passed from arch/arm/*omap*/ to drivers, should be done using include/linux/platform_data/*.h files.

I'm not suggesting to use mach-omap2/*.h, it's just what my old script shows when hunting for platform header files that are used in device drivers.

Quoted 3 lines

For omap1, we might as well keep the existing ones from #include <mach/*.h> as they are until somebody wants to fix up things properly for omap1 for CONFIG_MULTIPLATFORM.

Fair enough.

Arnd

author maintainer
#4 lore raw
Quoted 39 lines · Arnd Bergmann
Quoted 26 lines · Tony Lindgren
Quoted 16 lines · Arnd Bergmann

I tried running my old multiplatform scripts again and have a few comments, but none of them serious:

$ git grep include.*mach-omap2
arch/arm/plat-omap/debug-devices.c:#include "../mach-omap2/debug-devices.h"
arch/arm/plat-omap/dma.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/dmtimer.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/i2c.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/include/plat/cpu.h:#include "../../mach-omap2/soc.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap_device.h"
arch/arm/plat-omap/omap-pm-noop.c:#include "../mach-omap2/omap-pm.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/soc.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/iomap.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/prm2xxx_3xxx.h"
arch/arm/plat-omap/sram.c:#include "../mach-omap2/sdrc.h"
Quoted 4 lines

I don't like the relative include paths too much. I would have preferred adding the mach-omap2/include/mach path in the plat-omap Makefile, but I suppose you want to leave it like it is now since you mention you have already built on top of it.

Well I wanted to keep them local to arch/arm/*omap*/ directories, and not have them exposed at all for drivers.

Quoted 7 lines

Other than that I don't have an issue using non-relative paths, except mach-omap2/include/mach traditionally has been exposed to drivers as the legacy #include <mach/*.h>, so IMHO local headers in the arch/arm/*omap*/ directories are better.

But now I wonder if we can somehow have drivers not be able to include these local headers?

Well, once CONFIG_MULTIPLATFORM gets enabled, the mach/*.h files are not visible to drivers any more, but they are still visible to files in plat-omap if you add a line like

Quoted 7 lines

ccflags-$(CONFIG_ARCH_OMAP2) := -I$(srctree)/arch/arm/mach-omap2/include ccflags-$(CONFIG_ARCH_OMAP1) := -I$(srctree)/arch/arm/mach-omap1/include

to arch/arm/plat-omap/Makefile. That is how the other multiplatform Makefiles do it. If a driver writer really wants to cheat, they can of course do the same thing in their directory, but they can also do #include "../../../../arch/arm/mach-omap2/foo.h"

OK thanks for clarifying that. Sounds like that can be used to fix up the relative includes for plat-omap. I'll do some patches for that after we have the #include <plat/*.h> and #include <mach/*.h> issue sorted out.

Quoted 22 lines
Quoted 10 lines
Quoted 10 lines

sound/soc/omap/am3517evm.c:#include <mach-omap2/hardware.h> sound/soc/omap/am3517evm.c:#include <mach-omap2/gpio.h> sound/soc/omap/ams-delta.c:#include <mach-omap2/board-ams-delta.h> sound/soc/omap/n810.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/hardware.h> sound/soc/omap/sdp3430.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/hardware.h> sound/soc/omap/zoom2.c:#include <mach-omap2/gpio.h> sound/soc/omap/zoom2.c:#include <mach-omap2/board-zoom.h>

Quoted 7 lines
Quoted 2 lines

Not sure if you were just missing these or if you already have other patch lined up for them.

In which branch do you see the above?

I'm not seeing them in v3.7-rc2, looks like all sound/soc/omap/*.c files have already been fixed up.

I am looking at the arm-soc for-next branch, which is based on v3.7-rc2.

Note that before my script, this reads

Quoted 7 lines

#include <mach/hardware.h>

not

#include <mach-omap2/hardware.h>

but the effect is the same if the file is not available.

Well for omap2+, drivers should no longer include anything with #include <mach/*.h> (or #include <mach-omap2/hardware.h>) and the drivers should be fixed instead.

For omap2+, mach/hardware.h is empty now. It still needs to be included for omap1, so that might require some conditional includes for the shared code between omap1 and omap2+ like sound/soc/omap/*mcbsp*.c. And that code should just be able to use platform_data for omap1, and not need hardware.h either eventually.

AFAIK, all the sound/soc/omap/*.c files are almost fixed up for omap2+, so let's not change those includes in arm-soc tree as that will just cause conflicts. All the remaining #include <mach/*.h> and #include <plat/*.h> under sound/soc/omap can eventually be just removed for omap2+.

For omap1, we can just leave them as they are for now. Those are the sound/soc/omap/ams-delta.c and sound/soc/omap/osk5912.c files for omap1.

Quoted 10 lines
Quoted 6 lines

In any case, let's not have #include <mach-omap1/*.h> or #include <mach-omap2/*.h> includes in the drivers, they are wrong. Those headers are meant to be local, the legacy shared headers should be in #include <mach/*.h>. Whatever needs to be passed from arch/arm/*omap*/ to drivers, should be done using include/linux/platform_data/*.h files.

I'm not suggesting to use mach-omap2/*.h, it's just what my old script shows when hunting for platform header files that are used in device drivers.

OK makes sense :) Well we should no have any of them after v3.8 merge window except for the legacy ones for omap1.

Your script found a real issue though, and that's the tidspbridge include of private headers from mach-omap2! That's something that needs to be fixed or removed to cut the dependency between core omap code and device drivers.

Quoted 5 lines
Quoted 3 lines

For omap1, we might as well keep the existing ones from #include <mach/*.h> as they are until somebody wants to fix up things properly for omap1 for CONFIG_MULTIPLATFORM.

Fair enough.

Sounds good.

Tony

author maintainer
#5 lore raw
Quoted 14 lines · Tony Lindgren
Quoted 5 lines · Arnd Bergmann

Well, once CONFIG_MULTIPLATFORM gets enabled, the mach/*.h files are not visible to drivers any more, but they are still visible to files in plat-omap if you add a line like

Quoted 7 lines

ccflags-$(CONFIG_ARCH_OMAP2) := -I$(srctree)/arch/arm/mach-omap2/include ccflags-$(CONFIG_ARCH_OMAP1) := -I$(srctree)/arch/arm/mach-omap1/include

to arch/arm/plat-omap/Makefile. That is how the other multiplatform Makefiles do it. If a driver writer really wants to cheat, they can of course do the same thing in their directory, but they can also do #include "../../../../arch/arm/mach-omap2/foo.h"

Quoted 4 lines

OK thanks for clarifying that. Sounds like that can be used to fix up the relative includes for plat-omap. I'll do some patches for that after we have the #include <plat/*.h> and #include <mach/*.h> issue sorted out.

Here's a patch for that. It's against what I have queued up in omap-for-v3.8/cleanup-headers. Does that look OK to you?

Regards,

Tony

From: Tony Lindgren <[email protected]>
Date: Fri, 26 Oct 2012 15:06:40 -0700
Subject: [PATCH] ARM: OMAP: Fix relative includes for plat-omap with ccflags

As suggested by Arnd Bergmann <[email protected]>, we can keep these headers local to arch/arm/*omap*/ by modifying the ccflags in plat/omap/Makefile.

Note that eventually even most of these will go away as things like SRAM and PRCM become just regular device drivers.

Also note that this will not fix plat/cpu.h, but that will be removed anyways as soon as the drivers are fixed.

While at it, also sort the includes the standard way.

arch/arm/mach-omap1/Makefile +2 -0
index cd169c3..03b1e80 100644
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_OMAP) := -I$(srctree)/arch/arm
+
 # Common support
 obj-y := io.o id.o sram.o time.o irq.o mux.o flash.o serial.o devices.o dma.o
 obj-y += clock.o clock_data.o opp_data.o reset.o pm_bus.o timer.o
arch/arm/mach-omap1/clock.c +1 -1
index 931f3f6..031fa3f 100644
@@ -24,7 +24,7 @@
 
 #include <mach/hardware.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "soc.h"
 #include "iomap.h"
arch/arm/mach-omap1/clock_data.c +2 -4
index 28aea55..96b2fa7d 100644
@@ -21,14 +21,12 @@
 #include <linux/delay.h>
 
 #include <asm/mach-types.h>  /* for machine_is_* */
-
-#include "soc.h"
-
 #include <mach/hardware.h>
 #include <mach/usb.h>   /* for OTG_BASE */
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
+#include "soc.h"
 #include "iomap.h"
 #include "clock.h"
 
arch/arm/mach-omap1/common.h +2 -2
index 26e19d3..acd1797 100644
@@ -26,11 +26,11 @@
 #ifndef __ARCH_ARM_MACH_OMAP1_COMMON_H
 #define __ARCH_ARM_MACH_OMAP1_COMMON_H
 
-#include "../plat-omap/common.h"
 #include <linux/mtd/mtd.h>
 #include <linux/i2c-omap.h>
 
-#include "../plat-omap/i2c.h"
+#include <plat-omap/common.h>
+#include <plat-omap/i2c.h>
 
 #if defined(CONFIG_ARCH_OMAP730) || defined(CONFIG_ARCH_OMAP850)
 void omap7xx_map_io(void);
arch/arm/mach-omap1/devices.c +1 -2
index 645668e..07e6065 100644
@@ -21,12 +21,11 @@
 
 #include <mach/tc.h>
 #include <mach/mux.h>
-
 #include <mach/omap7xx.h>
 #include <mach/camera.h>
 #include <mach/hardware.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "common.h"
 #include "clock.h"
arch/arm/mach-omap1/i2c.c +4 -2
index 32bcbb8..8ee5892e 100644
@@ -20,10 +20,12 @@
  */
 
 #include <linux/i2c-omap.h>
+
 #include <mach/mux.h>
-#include "soc.h"
 
-#include "../plat-omap/i2c.h"
+#include <plat-omap/i2c.h>
+
+#include "soc.h"
 
 #define OMAP_I2C_SIZE		0x3f
 #define OMAP1_I2C_BASE		0xfffb3800
arch/arm/mach-omap1/pm.c +1 -1
index b2c2328..d8b0c7d 100644
@@ -56,7 +56,7 @@
 
 #include <mach/irqs.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "iomap.h"
 #include "clock.h"
arch/arm/mach-omap2/Makefile +3 -1
index 46d9071..1a9d9b9 100644
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_OMAP) := -I$(srctree)/arch/arm
+
 # Common support
 obj-y := id.o io.o control.o mux.o devices.o serial.o gpmc.o timer.o pm.o \
 	 common.o gpio.o dma.o wd_timer.o display.o i2c.o hdq1w.o omap_hwmod.o \
@@ -75,7 +77,7 @@ obj-$(CONFIG_POWER_AVS_OMAP)		+= sr_device.o
 obj-$(CONFIG_POWER_AVS_OMAP_CLASS3)	+= smartreflex-class3.o
 
 AFLAGS_sleep24xx.o			:=-Wa,-march=armv6
-AFLAGS_sleep34xx.o			:=-Wa,-march=armv7-a$(plus_sec)
+AFLAGS_sleep34xx.o			:=-Wa,-march=armv7-a$(plus_sec) -I$(srctree)/arch/arm
 
 ifeq ($(CONFIG_PM_VERBOSE),y)
 CFLAGS_pm_bus.o				+= -DDEBUG
arch/arm/mach-omap2/clkt2xxx_dpllcore.c +1 -1
index 3432f91..9bd6ff4 100644
@@ -25,7 +25,7 @@
 #include <linux/clk.h>
 #include <linux/io.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "clock.h"
 #include "clock2xxx.h"
arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c +1 -1
index c66276b..ddf2e31 100644
@@ -33,7 +33,7 @@
 #include <linux/cpufreq.h>
 #include <linux/slab.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "soc.h"
 #include "clock.h"
arch/arm/mach-omap2/clkt34xx_dpll3m2.c +1 -1
index 5510d92..4f6e19e 100644
@@ -21,7 +21,7 @@
 #include <linux/clk.h>
 #include <linux/io.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "clock.h"
 #include "clock3xxx.h"
arch/arm/mach-omap2/cm33xx.c +1 -1
index b4938ab..b95c766 100644
@@ -22,7 +22,7 @@
 #include <linux/err.h>
 #include <linux/io.h>
 
-#include "../plat-omap/common.h"
+#include <plat-omap/common.h>
 
 #include "cm.h"
 #include "cm33xx.h"
arch/arm/mach-omap2/common.h +1 -1
index c925c80..0f461d6 100644
@@ -34,7 +34,7 @@
 
 #include <asm/proc-fns.h>
 
-#include "../plat-omap/common.h"
+#include <plat-omap/common.h>
 
 #include "i2c.h"
 #include "serial.h"
arch/arm/mach-omap2/i2c.h +1 -1
index 81dbb99..e8b3b72 100644
@@ -19,7 +19,7 @@
  *
  */
 
-#include "../plat-omap/i2c.h"
+#include <plat-omap/i2c.h>
 
 #ifndef __MACH_OMAP2_I2C_H
 #define __MACH_OMAP2_I2C_H
arch/arm/mach-omap2/io.c +1 -2
index 4fadc78..629f7af 100644
@@ -26,8 +26,7 @@
 #include <asm/mach/map.h>
 
 #include <plat-omap/dma-omap.h>
-
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "omap_hwmod.h"
 #include "soc.h"
arch/arm/mach-omap2/omap4-common.c +1 -1
index d25845c..d1cc30d 100644
@@ -25,7 +25,7 @@
 #include <asm/mach/map.h>
 #include <asm/memblock.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "omap-wakeupgen.h"
 #include "soc.h"
arch/arm/mach-omap2/omap_hwmod_2xxx_3xxx_ipblock_data.c +1 -2
index 05c6a59..4ecddad 100644
@@ -11,8 +11,7 @@
  */
 
 #include <plat-omap/dma-omap.h>
-
-#include "../plat-omap/common.h"
+#include <plat-omap/common.h>
 
 #include "omap_hwmod.h"
 #include "hdq1w.h"
arch/arm/mach-omap2/omap_hwmod_44xx_data.c +2 -3
index 5b9be73..2446a5e 100644
@@ -23,14 +23,13 @@
 #include <linux/power/smartreflex.h>
 #include <linux/i2c-omap.h>
 
-#include <plat-omap/dma-omap.h>
-
 #include <linux/platform_data/spi-omap2-mcspi.h>
 #include <linux/platform_data/asoc-ti-mcbsp.h>
 #include <plat/dmtimer.h>
 #include <plat/iommu.h>
 
-#include "../plat-omap/common.h"
+#include <plat-omap/common.h>
+#include <plat-omap/dma-omap.h>
 
 #include "omap_hwmod.h"
 #include "omap_hwmod_common_data.h"
arch/arm/mach-omap2/pm24xx.c +1 -2
index 6d17e044..7ff08f8 100644
@@ -37,8 +37,7 @@
 #include <asm/system_misc.h>
 
 #include <plat-omap/dma-omap.h>
-
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "soc.h"
 #include "common.h"
arch/arm/mach-omap2/pm34xx.c +2 -2
index 160fa25..541eda1 100644
@@ -38,9 +38,9 @@
 #include "clockdomain.h"
 #include "powerdomain.h"
 #include <plat/prcm.h>
-#include <plat-omap/dma-omap.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/dma-omap.h>
+#include <plat-omap/sram.h>
 
 #include "soc.h"
 #include "common.h"
arch/arm/mach-omap2/prm33xx.c +1 -1
index 624ade5..5df23da 100644
@@ -19,7 +19,7 @@
 #include <linux/err.h>
 #include <linux/io.h>
 
-#include "../plat-omap/common.h"
+#include <plat-omap/common.h>
 
 #include "common.h"
 #include "prm33xx.h"
arch/arm/mach-omap2/prm_common.c +2 -1
index 6fabbd8..6d96d95 100644
@@ -24,9 +24,10 @@
 #include <linux/interrupt.h>
 #include <linux/slab.h>
 
-#include "../plat-omap/common.h"
 #include <plat/prcm.h>
 
+#include <plat-omap/common.h>
+
 #include "prm2xxx_3xxx.h"
 #include "prm44xx.h"
 
arch/arm/mach-omap2/sdrc.c +1 -1
index 94d4082..e6bb257 100644
@@ -23,7 +23,7 @@
 #include <linux/clk.h>
 #include <linux/io.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "common.h"
 #include "clock.h"
arch/arm/mach-omap2/sdrc2xxx.c +1 -1
index 3b8bfdf..0012cb9 100644
@@ -24,7 +24,7 @@
 #include <linux/clk.h>
 #include <linux/io.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "soc.h"
 #include "iomap.h"
arch/arm/mach-omap2/sleep34xx.S +1 -1
index 75afe11..2eeac9f 100644
@@ -26,7 +26,7 @@
 
 #include <asm/assembler.h>
 
-#include "../plat-omap/sram.h"
+#include <plat-omap/sram.h>
 
 #include "omap34xx.h"
 #include "iomap.h"
arch/arm/plat-omap/Makefile +2 -0
index 4bd0ace..90ffae7 100644
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_OMAP) := -I$(srctree)/arch/arm
+
 # Common support
 obj-y := common.o sram.o dma.o fb.o counter_32k.o
 obj-m :=
arch/arm/plat-omap/debug-devices.c +2 -1
index 5a4678e..a53f09ab0 100644
@@ -16,7 +16,8 @@
 #include <linux/smc91x.h>
 
 #include <mach/hardware.h>
-#include "../mach-omap2/debug-devices.h"
+
+#include <mach-omap2/debug-devices.h>
 
 /* Many OMAP development platforms reuse the same "debug board"; these
  * platforms include H2, H3, H4, and Perseus2.
arch/arm/plat-omap/dma.c +2 -2
index 49803cc..99f437f 100644
@@ -38,8 +38,8 @@
 
 #include <plat-omap/dma-omap.h>
 
-#include "../mach-omap1/soc.h"
-#include "../mach-omap2/soc.h"
+#include <mach-omap1/soc.h>
+#include <mach-omap2/soc.h>
 
 /*
  * MAX_LOGICAL_DMA_CH_COUNT: the maximum number of logical DMA
arch/arm/plat-omap/dmtimer.c +1 -1
index 4a0b30a..2cd1b0d 100644
@@ -45,7 +45,7 @@
 
 #include <mach/hardware.h>
 
-#include "../mach-omap2/omap-pm.h"
+#include <mach-omap2/omap-pm.h>
 
 static u32 omap_reserved_systimers;
 static LIST_HEAD(omap_timer_list);
arch/arm/plat-omap/i2c.c +2 -2
index be6deb7..2c6c266 100644
@@ -33,8 +33,8 @@
 
 #include <mach/irqs.h>
 
-#include "../mach-omap1/soc.h"
-#include "../mach-omap2/soc.h"
+#include <mach-omap1/soc.h>
+#include <mach-omap2/soc.h>
 
 #include "i2c.h"
 
arch/arm/plat-omap/omap-pm-noop.c +2 -2
index 198685b..64e3ebc 100644
@@ -22,8 +22,8 @@
 #include <linux/device.h>
 #include <linux/platform_device.h>
 
-#include "../mach-omap2/omap_device.h"
-#include "../mach-omap2/omap-pm.h"
+#include <mach-omap2/omap_device.h>
+#include <mach-omap2/omap-pm.h>
 
 static bool off_mode_enabled;
 static int dummy_context_loss_counter;
arch/arm/plat-omap/sram.c +5 -7
index 70dcc22..e47a033 100644
@@ -25,16 +25,14 @@
 
 #include <asm/mach/map.h>
 
-#include "../mach-omap1/soc.h"
-#include "../mach-omap2/soc.h"
+#include <mach-omap1/soc.h>
+#include <mach-omap2/soc.h>
+#include <mach-omap2/iomap.h>
+#include <mach-omap2/prm2xxx_3xxx.h>
+#include <mach-omap2/sdrc.h>
 
 #include "sram.h"
 
-/* XXX These "sideways" includes will disappear when sram.c becomes a driver */
-#include "../mach-omap2/iomap.h"
-#include "../mach-omap2/prm2xxx_3xxx.h"
-#include "../mach-omap2/sdrc.h"
-
 #define OMAP1_SRAM_PA		0x20000000
 #define OMAP2_SRAM_PUB_PA	(OMAP2_SRAM_PA + 0xf800)
 #define OMAP3_SRAM_PUB_PA       (OMAP3_SRAM_PA + 0x8000)
#6 lore raw
Quoted 2 lines · Tony Lindgren

Here's a patch for that. It's against what I have queued up in omap-for-v3.8/cleanup-headers. Does that look OK to you?

Hi Tony,

thanks for the quick follow-up. Using the absolute #include statements again looks good, but now there is another problem:

arch/arm/mach-omap1/Makefile line 6

Quoted 10 lines
arch/arm/mach-omap1/Makefile +2 -0
index cd169c3..03b1e80 100644
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_OMAP) := -I$(srctree)/arch/arm
+

This is not what I meant, I don't think we want to have the entire arch/arm/ hierarchy visible in platform directories. Instead, I thought we'd keep using the existing arch/arm/mach-$foo/include/mach directories that are currently visible to all files and make them available only to platforms that explicitly add -I$(srctree)/arch/arm/include/mach-$foo/include to their local include path.

This of course requires moving all those headers back to where they just came from.

Arnd

author maintainer
#7 lore raw
Quoted 27 lines · Arnd Bergmann
Quoted 2 lines · Tony Lindgren

Here's a patch for that. It's against what I have queued up in omap-for-v3.8/cleanup-headers. Does that look OK to you?

Hi Tony,

thanks for the quick follow-up. Using the absolute #include statements again looks good, but now there is another problem:

arch/arm/mach-omap1/Makefile line 6

Quoted 10 lines
arch/arm/mach-omap1/Makefile +2 -0
index cd169c3..03b1e80 100644
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_OMAP) := -I$(srctree)/arch/arm
+

This is not what I meant, I don't think we want to have the entire arch/arm/ hierarchy visible in platform directories. Instead, I thought we'd keep using the existing arch/arm/mach-$foo/include/mach directories that are currently visible to all files and make them available only to platforms that explicitly add -I$(srctree)/arch/arm/include/mach-$foo/include to their local include path.

Quoted 2 lines

This of course requires moving all those headers back to where they just came from.

OK I'll take a look. Most of them should be local to mach-omap2, so it may not be that bad with the file moves.

Regards,

Tony

#8 lore raw
In reply to Tony Lindgren
Quoted 53 lines · Tony Lindgren
Quoted 14 lines · Tony Lindgren
Quoted 5 lines · Arnd Bergmann

Well, once CONFIG_MULTIPLATFORM gets enabled, the mach/*.h files are not visible to drivers any more, but they are still visible to files in plat-omap if you add a line like

Quoted 7 lines

ccflags-$(CONFIG_ARCH_OMAP2) := -I$(srctree)/arch/arm/mach-omap2/include ccflags-$(CONFIG_ARCH_OMAP1) := -I$(srctree)/arch/arm/mach-omap1/include

to arch/arm/plat-omap/Makefile. That is how the other multiplatform Makefiles do it. If a driver writer really wants to cheat, they can of course do the same thing in their directory, but they can also do #include "../../../../arch/arm/mach-omap2/foo.h"

Quoted 4 lines

OK thanks for clarifying that. Sounds like that can be used to fix up the relative includes for plat-omap. I'll do some patches for that after we have the #include <plat/*.h> and #include <mach/*.h> issue sorted out.

Here's a patch for that. It's against what I have queued up in omap-for-v3.8/cleanup-headers. Does that look OK to you?

Regards,

Tony

From: Tony Lindgren <[email protected]>
Date: Fri, 26 Oct 2012 15:06:40 -0700
Subject: [PATCH] ARM: OMAP: Fix relative includes for plat-omap with ccflags

As suggested by Arnd Bergmann <[email protected]>, we can keep these headers local to arch/arm/*omap*/ by modifying the ccflags in plat/omap/Makefile.

Note that eventually even most of these will go away as things like SRAM and PRCM become just regular device drivers.

Also note that this will not fix plat/cpu.h, but that will be removed anyways as soon as the drivers are fixed.

While at it, also sort the includes the standard way.

arch/arm/mach-omap1/Makefile +0 -0
index cd169c3..03b1e80 100644

arch/arm/mach-omap1/Makefile line 6

Quoted 5 lines
arch/arm/mach-omap1/Makefile +2 -0
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_OMAP) := -I$(srctree)/arch/arm
+

Rather than moving all the files from plat-omap/include/plat into plat-omap and then having all these totally disgusting relative includes, why don't you add to these makefiles:

ccflags += -I$(srctree)/arch/arm/plat-omap/include

and avoid all that include moving and all the include name fixup?

author maintainer
#9 lore raw
Quoted 8 lines · Russell King - ARM Linux

Rather than moving all the files from plat-omap/include/plat into plat-omap and then having all these totally disgusting relative includes, why don't you add to these makefiles:

ccflags += -I$(srctree)/arch/arm/plat-omap/include

and avoid all that include moving and all the include name fixup?

I'll take a look. Most of these headers should be local, so it should not be too many files to move for plat-omap to fix this.

Regards,

Tony

author maintainer
#10 lore raw
Quoted 6 lines · Tony Lindgren
Quoted 5 lines · Russell King - ARM Linux

Rather than moving all the files from plat-omap/include/plat into plat-omap and then having all these totally disgusting relative includes, why don't you add to these makefiles:

Quoted 7 lines
Quoted 3 lines

ccflags += -I$(srctree)/arch/arm/plat-omap/include

and avoid all that include moving and all the include name fixup?

I'll take a look. Most of these headers should be local, so it should not be too many files to move for plat-omap to fix this.

Posted a series to fix the issue with relative includes as "[PATCH 00/11] Fix relative includes for omaps introduced by recent clean-up".

Regards,

Tony