dm: core: Replace of_offset with accessor
authorSimon Glass <sjg@chromium.org>
Tue, 17 Jan 2017 23:52:55 +0000 (16:52 -0700)
committerSimon Glass <sjg@chromium.org>
Wed, 8 Feb 2017 13:12:14 +0000 (06:12 -0700)
commite160f7d430f163bc42757aff3bf2bcac0a459f02
treece006f94b4a52f6fff567eacd86922c3be6df706
parent8aa41363ebf46b9ff63b311bd2aa793c67a49def
dm: core: Replace of_offset with accessor

At present devices use a simple integer offset to record the device tree
node associated with the device. In preparation for supporting a live
device tree, which uses a node pointer instead, refactor existing code to
access this field through an inline function.

Signed-off-by: Simon Glass <sjg@chromium.org>
220 files changed:
arch/arm/mach-aspeed/ast2500/sdram_ast2500.c
arch/arm/mach-rockchip/rk3288/sdram_rk3288.c
arch/nios2/cpu/cpu.c
arch/x86/cpu/broadwell/cpu.c
arch/x86/cpu/broadwell/pch.c
arch/x86/cpu/broadwell/pinctrl_broadwell.c
arch/x86/cpu/broadwell/sata.c
arch/x86/cpu/cpu_x86.c
arch/x86/cpu/intel_common/lpc.c
arch/x86/cpu/intel_common/mrc.c
arch/x86/cpu/irq.c
arch/x86/cpu/ivybridge/lpc.c
arch/x86/cpu/ivybridge/model_206ax.c
arch/x86/cpu/ivybridge/sata.c
arch/x86/cpu/mp_init.c
arch/x86/lib/mpspec.c
arch/x86/lib/pinctrl_ich6.c
board/qualcomm/dragonboard410c/dragonboard410c.c
doc/driver-model/README.txt
doc/driver-model/of-plat.txt
doc/driver-model/spi-howto.txt
drivers/adc/adc-uclass.c
drivers/clk/at91/clk-generated.c
drivers/clk/at91/pmc.c
drivers/clk/clk-uclass.c
drivers/clk/clk_fixed_rate.c
drivers/clk/clk_pic32.c
drivers/core/device.c
drivers/core/regmap.c
drivers/core/root.c
drivers/core/simple-bus.c
drivers/core/uclass.c
drivers/demo/demo-shape.c
drivers/demo/demo-uclass.c
drivers/gpio/74x164_gpio.c
drivers/gpio/altera_pio.c
drivers/gpio/atmel_pio4.c
drivers/gpio/dwapb_gpio.c
drivers/gpio/gpio-uclass.c
drivers/gpio/intel_broadwell_gpio.c
drivers/gpio/intel_ich6_gpio.c
drivers/gpio/lpc32xx_gpio.c
drivers/gpio/mpc85xx_gpio.c
drivers/gpio/msm_gpio.c
drivers/gpio/omap_gpio.c
drivers/gpio/pca953x_gpio.c
drivers/gpio/pcf8575_gpio.c
drivers/gpio/pic32_gpio.c
drivers/gpio/pm8916_gpio.c
drivers/gpio/s5p_gpio.c
drivers/gpio/sandbox.c
drivers/gpio/sunxi_gpio.c
drivers/gpio/tegra186_gpio.c
drivers/gpio/tegra_gpio.c
drivers/gpio/vybrid_gpio.c
drivers/i2c/at91_i2c.c
drivers/i2c/cros_ec_tunnel.c
drivers/i2c/exynos_hs_i2c.c
drivers/i2c/fsl_i2c.c
drivers/i2c/i2c-gpio.c
drivers/i2c/i2c-uclass.c
drivers/i2c/muxes/i2c-arb-gpio-challenge.c
drivers/i2c/muxes/i2c-mux-uclass.c
drivers/i2c/muxes/pca954x.c
drivers/i2c/mvtwsi.c
drivers/i2c/mxc_i2c.c
drivers/i2c/s3c24x0_i2c.c
drivers/i2c/tegra186_bpmp_i2c.c
drivers/input/cros_ec_keyb.c
drivers/input/i8042.c
drivers/input/tegra-kbc.c
drivers/led/led_gpio.c
drivers/mailbox/mailbox-uclass.c
drivers/misc/cros_ec.c
drivers/misc/cros_ec_sandbox.c
drivers/misc/i2c_eeprom_emul.c
drivers/misc/tegra186_bpmp.c
drivers/misc/tegra_car.c
drivers/mmc/atmel_sdhci.c
drivers/mmc/exynos_dw_mmc.c
drivers/mmc/fsl_esdhc.c
drivers/mmc/msm_sdhci.c
drivers/mmc/omap_hsmmc.c
drivers/mmc/pic32_sdhci.c
drivers/mmc/rockchip_dw_mmc.c
drivers/mmc/rockchip_sdhci.c
drivers/mmc/s5p_sdhci.c
drivers/mmc/socfpga_dw_mmc.c
drivers/mmc/tegra_mmc.c
drivers/mmc/uniphier-sd.c
drivers/mmc/xenon_sdhci.c
drivers/mtd/altera_qspi.c
drivers/mtd/cfi_flash.c
drivers/mtd/pic32_flash.c
drivers/mtd/spi/sandbox.c
drivers/mtd/spi/spi_flash.c
drivers/net/ag7xxx.c
drivers/net/altera_tse.c
drivers/net/cpsw-common.c
drivers/net/cpsw.c
drivers/net/designware.c
drivers/net/fec_mxc.c
drivers/net/gmac_rockchip.c
drivers/net/keystone_net.c
drivers/net/macb.c
drivers/net/mvneta.c
drivers/net/mvpp2.c
drivers/net/phy/micrel.c
drivers/net/phy/ti.c
drivers/net/phy/xilinx_phy.c
drivers/net/pic32_eth.c
drivers/net/sandbox-raw.c
drivers/net/sandbox.c
drivers/net/sun8i_emac.c
drivers/net/tsec.c
drivers/net/xilinx_axi_emac.c
drivers/net/xilinx_emaclite.c
drivers/net/zynq_gem.c
drivers/pci/pci-uclass.c
drivers/pci/pci_tegra.c
drivers/pci/pcie_layerscape.c
drivers/pci/pcie_xilinx.c
drivers/phy/marvell/comphy_core.c
drivers/pinctrl/ath79/pinctrl_ar933x.c
drivers/pinctrl/ath79/pinctrl_qca953x.c
drivers/pinctrl/exynos/pinctrl-exynos.c
drivers/pinctrl/meson/pinctrl-meson.c
drivers/pinctrl/mvebu/pinctrl-mvebu.c
drivers/pinctrl/nxp/pinctrl-imx.c
drivers/pinctrl/pinctrl-at91-pio4.c
drivers/pinctrl/pinctrl-generic.c
drivers/pinctrl/pinctrl-uclass.c
drivers/pinctrl/pinctrl_pic32.c
drivers/pinctrl/rockchip/pinctrl_rk3036.c
drivers/pinctrl/rockchip/pinctrl_rk3288.c
drivers/pinctrl/rockchip/pinctrl_rk3399.c
drivers/power/domain/power-domain-uclass.c
drivers/power/pmic/act8846.c
drivers/power/pmic/i2c_pmic_emul.c
drivers/power/pmic/lp873x.c
drivers/power/pmic/max77686.c
drivers/power/pmic/palmas.c
drivers/power/pmic/pfuze100.c
drivers/power/pmic/pmic-uclass.c
drivers/power/pmic/rk808.c
drivers/power/pmic/s5m8767.c
drivers/power/pmic/sandbox.c
drivers/power/pmic/tps65090.c
drivers/power/regulator/fixed.c
drivers/power/regulator/gpio-regulator.c
drivers/power/regulator/pwm_regulator.c
drivers/power/regulator/regulator-uclass.c
drivers/remoteproc/rproc-uclass.c
drivers/remoteproc/ti_power_proc.c
drivers/reset/reset-uclass.c
drivers/serial/altera_uart.c
drivers/serial/ns16550.c
drivers/serial/sandbox.c
drivers/serial/serial_arc.c
drivers/serial/serial_bcm283x_mu.c
drivers/serial/serial_msm.c
drivers/serial/serial_mxc.c
drivers/serial/serial_pic32.c
drivers/serial/serial_pl01x.c
drivers/serial/serial_s5p.c
drivers/serial/serial_sh.c
drivers/serial/serial_uniphier.c
drivers/spi/cadence_qspi.c
drivers/spi/davinci_spi.c
drivers/spi/designware_spi.c
drivers/spi/exynos_spi.c
drivers/spi/fsl_dspi.c
drivers/spi/fsl_qspi.c
drivers/spi/ich.c
drivers/spi/mvebu_a3700_spi.c
drivers/spi/omap3_spi.c
drivers/spi/pic32_spi.c
drivers/spi/rk_spi.c
drivers/spi/soft_spi.c
drivers/spi/spi-uclass.c
drivers/spi/stm32_qspi.c
drivers/spi/tegra114_spi.c
drivers/spi/tegra20_sflash.c
drivers/spi/tegra20_slink.c
drivers/spi/tegra210_qspi.c
drivers/spi/ti_qspi.c
drivers/spi/zynq_qspi.c
drivers/spi/zynq_spi.c
drivers/spmi/spmi-msm.c
drivers/sysreset/sysreset_sandbox.c
drivers/timer/timer-uclass.c
drivers/usb/emul/sandbox_flash.c
drivers/usb/emul/sandbox_hub.c
drivers/usb/host/dwc2.c
drivers/usb/host/ehci-exynos.c
drivers/usb/host/ehci-fsl.c
drivers/usb/host/ehci-mx6.c
drivers/usb/host/ehci-tegra.c
drivers/usb/host/ehci-vf.c
drivers/usb/host/usb-uclass.c
drivers/usb/host/xhci-exynos5.c
drivers/usb/host/xhci-rockchip.c
drivers/usb/musb-new/pic32.c
drivers/usb/musb-new/ti-musb.c
drivers/video/atmel_lcdfb.c
drivers/video/bridge/ps862x.c
drivers/video/broadwell_igd.c
drivers/video/exynos/exynos_dp.c
drivers/video/exynos/exynos_fb.c
drivers/video/ivybridge_igd.c
drivers/video/pwm_backlight.c
drivers/video/rockchip/rk_lvds.c
drivers/video/rockchip/rk_vop.c
drivers/video/sandbox_sdl.c
drivers/video/tegra.c
drivers/video/tegra124/display.c
drivers/video/tegra124/sor.c
include/dm/device.h
test/dm/spi.c
test/dm/test-fdt.c