Re: [Freedreno] [PATCH v3] of_device: removed #include that caused a recursion in included headers
On Mon, 20 Apr 2020, Hadar Gat wrote: > Both of_platform.h and of_device.h were included each other. > In of_device.h, removed unneeded #include to of_platform.h > and added include to of_platform.h in the files that needs it. > > Signed-off-by: Hadar Gat > Reported-by: kbuild test robot > Acked-by: Jonathan Cameron #for-iio > Acked-by: Stephen Boyd # clk > --- > v3: add include to of_platform.h in more files. (reported due other builds) > v2: add include to of_platform.h in more files. (reported due other builds) > > arch/sparc/kernel/pci.c | 1 + > arch/sparc/kernel/pci_sabre.c | 1 + > arch/sparc/kernel/pci_schizo.c| 1 + > arch/sparc/kernel/sbus.c | 1 + > arch/sparc/mm/io-unit.c | 1 + > arch/sparc/mm/iommu.c | 1 + > drivers/base/platform.c | 1 + > drivers/bus/imx-weim.c| 1 + > drivers/bus/vexpress-config.c | 1 + > drivers/clk/mediatek/clk-mt7622-aud.c | 1 + > drivers/dma/at_hdmac.c| 1 + > drivers/dma/stm32-dmamux.c| 1 + > drivers/dma/ti/dma-crossbar.c | 1 + > drivers/gpu/drm/msm/adreno/a6xx_gmu.c | 1 + > drivers/gpu/drm/msm/hdmi/hdmi.c | 1 + > drivers/gpu/drm/msm/msm_drv.c | 1 + > drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c | 1 + > drivers/gpu/drm/sun4i/sun4i_tcon.c| 1 + > drivers/iio/adc/stm32-adc-core.c | 1 + > drivers/iio/adc/stm32-dfsdm-adc.c | 1 + > drivers/iio/adc/stm32-dfsdm-core.c| 1 + > drivers/iommu/tegra-smmu.c| 1 + > drivers/media/platform/coda/coda-common.c | 1 + > drivers/memory/atmel-ebi.c| 1 + > drivers/mfd/palmas.c | 1 + > drivers/mfd/ssbi.c| 1 + Acked-by: Lee Jones > drivers/mtd/nand/raw/omap2.c | 1 + > drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 1 + > drivers/net/ethernet/ti/cpsw.c| 1 + > drivers/phy/tegra/xusb.c | 1 + > drivers/pinctrl/freescale/pinctrl-imx1-core.c | 1 + > drivers/pinctrl/nomadik/pinctrl-nomadik.c | 1 + > drivers/soc/samsung/exynos-pmu.c | 1 + > drivers/soc/sunxi/sunxi_sram.c| 1 + > include/linux/of_device.h | 2 -- > lib/genalloc.c| 1 + > 36 files changed, 35 insertions(+), 2 deletions(-) -- Lee Jones [李琼斯] Linaro Services Technical Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog ___ Freedreno mailing list Freedreno@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/freedreno
Re: [Freedreno] [PATCH v3] of_device: removed #include that caused a recursion in included headers
Hi Hadar, Thank you for the patch! Yet something to improve: [auto build test ERROR on sparc/master] [also build test ERROR on stm32/stm32-next linus/master v5.7-rc2 next-20200422] [cannot apply to sparc-next/master] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Hadar-Gat/of_device-removed-include-that-caused-a-recursion-in-included-headers/20200423-040844 base: https://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc.git master config: arm64-defconfig (attached as .config) compiler: aarch64-linux-gcc (GCC) 9.3.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=arm64 If you fix the issue, kindly add following tag as appropriate Reported-by: kbuild test robot All errors (new ones prefixed by >>): drivers/firmware/ti_sci.c: In function 'ti_sci_probe': >> drivers/firmware/ti_sci.c:3520:9: error: implicit declaration of function >> 'of_platform_populate' [-Werror=implicit-function-declaration] 3520 | return of_platform_populate(dev->of_node, NULL, NULL, dev); | ^~~~ drivers/firmware/ti_sci.c: In function 'ti_sci_remove': >> drivers/firmware/ti_sci.c:3536:2: error: implicit declaration of function >> 'of_platform_depopulate' [-Werror=implicit-function-declaration] 3536 | of_platform_depopulate(dev); | ^~ cc1: some warnings being treated as errors -- drivers/firmware/tegra/bpmp.c: In function 'tegra_bpmp_get': >> drivers/firmware/tegra/bpmp.c:51:9: error: implicit declaration of function >> 'of_find_device_by_node'; did you mean 'bus_find_device_by_fwnode'? >> [-Werror=implicit-function-declaration] 51 | pdev = of_find_device_by_node(np); | ^~ | bus_find_device_by_fwnode drivers/firmware/tegra/bpmp.c:51:7: warning: assignment to 'struct platform_device *' from 'int' makes pointer from integer without a cast [-Wint-conversion] 51 | pdev = of_find_device_by_node(np); | ^ drivers/firmware/tegra/bpmp.c: In function 'tegra_bpmp_probe': >> drivers/firmware/tegra/bpmp.c:759:8: error: implicit declaration of function >> 'of_platform_default_populate' [-Werror=implicit-function-declaration] 759 | err = of_platform_default_populate(pdev->dev.of_node, NULL, >dev); |^~~~ cc1: some warnings being treated as errors -- drivers/gpu/drm/sun4i/sun8i_dw_hdmi.c: In function 'sun8i_dw_hdmi_find_connector_pdev': >> drivers/gpu/drm/sun4i/sun8i_dw_hdmi.c:115:9: error: implicit declaration of >> function 'of_find_device_by_node'; did you mean >> 'of_find_i2c_device_by_node'? [-Werror=implicit-function-declaration] 115 | pdev = of_find_device_by_node(remote); | ^~ | of_find_i2c_device_by_node drivers/gpu/drm/sun4i/sun8i_dw_hdmi.c:115:7: warning: assignment to 'struct platform_device *' from 'int' makes pointer from integer without a cast [-Wint-conversion] 115 | pdev = of_find_device_by_node(remote); | ^ cc1: some warnings being treated as errors vim +/of_platform_populate +3520 drivers/firmware/ti_sci.c aa276781a64a5f Nishanth Menon 2016-10-18 3385 aa276781a64a5f Nishanth Menon 2016-10-18 3386 static int ti_sci_probe(struct platform_device *pdev) aa276781a64a5f Nishanth Menon 2016-10-18 3387 { aa276781a64a5f Nishanth Menon 2016-10-18 3388 struct device *dev = >dev; aa276781a64a5f Nishanth Menon 2016-10-18 3389 const struct of_device_id *of_id; aa276781a64a5f Nishanth Menon 2016-10-18 3390 const struct ti_sci_desc *desc; aa276781a64a5f Nishanth Menon 2016-10-18 3391 struct ti_sci_xfer *xfer; aa276781a64a5f Nishanth Menon 2016-10-18 3392 struct ti_sci_info *info = NULL; aa276781a64a5f Nishanth Menon 2016-10-18 3393 struct ti_sci_xfers_info *minfo; aa276781a64a5f Nishanth Menon 2016-10-18 3394 struct mbox_client *cl; aa276781a64a5f Nishanth Menon 2016-10-18 3395 int ret = -EINVAL; aa276781a64a5f Nishanth Menon 2016-10-18 3396 int i; 912cffb4ed8612 Nishanth Menon 2016-10-18 3397 int reboot = 0; e69a35531589a2 Nishanth Menon 2018-08-28 3398 u32 h_id; aa276781a64a5f Nishanth Menon 2016-10-18 3399 aa276781a64a5f Nishanth Menon 2016-10-18 3400 of_id = of_match_device(ti_sci_of_match, dev); aa276781a64a5f Nishanth Menon 2016-10-18 3401 if (!of_id) { aa276781a64a5f Nishanth Menon 2016-10-18 3402
[Freedreno] [PATCH v3] of_device: removed #include that caused a recursion in included headers
Both of_platform.h and of_device.h were included each other. In of_device.h, removed unneeded #include to of_platform.h and added include to of_platform.h in the files that needs it. Signed-off-by: Hadar Gat Reported-by: kbuild test robot Acked-by: Jonathan Cameron #for-iio Acked-by: Stephen Boyd # clk --- v3: add include to of_platform.h in more files. (reported due other builds) v2: add include to of_platform.h in more files. (reported due other builds) arch/sparc/kernel/pci.c | 1 + arch/sparc/kernel/pci_sabre.c | 1 + arch/sparc/kernel/pci_schizo.c| 1 + arch/sparc/kernel/sbus.c | 1 + arch/sparc/mm/io-unit.c | 1 + arch/sparc/mm/iommu.c | 1 + drivers/base/platform.c | 1 + drivers/bus/imx-weim.c| 1 + drivers/bus/vexpress-config.c | 1 + drivers/clk/mediatek/clk-mt7622-aud.c | 1 + drivers/dma/at_hdmac.c| 1 + drivers/dma/stm32-dmamux.c| 1 + drivers/dma/ti/dma-crossbar.c | 1 + drivers/gpu/drm/msm/adreno/a6xx_gmu.c | 1 + drivers/gpu/drm/msm/hdmi/hdmi.c | 1 + drivers/gpu/drm/msm/msm_drv.c | 1 + drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c | 1 + drivers/gpu/drm/sun4i/sun4i_tcon.c| 1 + drivers/iio/adc/stm32-adc-core.c | 1 + drivers/iio/adc/stm32-dfsdm-adc.c | 1 + drivers/iio/adc/stm32-dfsdm-core.c| 1 + drivers/iommu/tegra-smmu.c| 1 + drivers/media/platform/coda/coda-common.c | 1 + drivers/memory/atmel-ebi.c| 1 + drivers/mfd/palmas.c | 1 + drivers/mfd/ssbi.c| 1 + drivers/mtd/nand/raw/omap2.c | 1 + drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 1 + drivers/net/ethernet/ti/cpsw.c| 1 + drivers/phy/tegra/xusb.c | 1 + drivers/pinctrl/freescale/pinctrl-imx1-core.c | 1 + drivers/pinctrl/nomadik/pinctrl-nomadik.c | 1 + drivers/soc/samsung/exynos-pmu.c | 1 + drivers/soc/sunxi/sunxi_sram.c| 1 + include/linux/of_device.h | 2 -- lib/genalloc.c| 1 + 36 files changed, 35 insertions(+), 2 deletions(-) diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c index 5ed4382..89ea658 100644 --- a/arch/sparc/kernel/pci.c +++ b/arch/sparc/kernel/pci.c @@ -21,6 +21,7 @@ #include #include #include +#include #include #include diff --git a/arch/sparc/kernel/pci_sabre.c b/arch/sparc/kernel/pci_sabre.c index 3c38ca4..16761d0 100644 --- a/arch/sparc/kernel/pci_sabre.c +++ b/arch/sparc/kernel/pci_sabre.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #include diff --git a/arch/sparc/kernel/pci_schizo.c b/arch/sparc/kernel/pci_schizo.c index 421aba0..733f069 100644 --- a/arch/sparc/kernel/pci_schizo.c +++ b/arch/sparc/kernel/pci_schizo.c @@ -12,6 +12,7 @@ #include #include #include +#include #include #include diff --git a/arch/sparc/kernel/sbus.c b/arch/sparc/kernel/sbus.c index 32141e1..2f4051f 100644 --- a/arch/sparc/kernel/sbus.c +++ b/arch/sparc/kernel/sbus.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include diff --git a/arch/sparc/mm/io-unit.c b/arch/sparc/mm/io-unit.c index 289276b..5638399 100644 --- a/arch/sparc/mm/io-unit.c +++ b/arch/sparc/mm/io-unit.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include diff --git a/arch/sparc/mm/iommu.c b/arch/sparc/mm/iommu.c index b00dde1..9cbb2e7 100644 --- a/arch/sparc/mm/iommu.c +++ b/arch/sparc/mm/iommu.c @@ -16,6 +16,7 @@ #include #include #include +#include #include #include diff --git a/drivers/base/platform.c b/drivers/base/platform.c index 520..f549274b 100644 --- a/drivers/base/platform.c +++ b/drivers/base/platform.c @@ -12,6 +12,7 @@ #include #include #include +#include #include #include #include diff --git a/drivers/bus/imx-weim.c b/drivers/bus/imx-weim.c index 28bb65a..8c786da 100644 --- a/drivers/bus/imx-weim.c +++ b/drivers/bus/imx-weim.c @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include diff --git a/drivers/bus/vexpress-config.c b/drivers/bus/vexpress-config.c index ff70575..12b8b0b 100644 --- a/drivers/bus/vexpress-config.c +++ b/drivers/bus/vexpress-config.c @@ -8,6 +8,7 @@ #include #include #include +#include #include diff --git a/drivers/clk/mediatek/clk-mt7622-aud.c b/drivers/clk/mediatek/clk-mt7622-aud.c index 2bd4295..8cbb68f 100644 --- a/drivers/clk/mediatek/clk-mt7622-aud.c +++