Re: [PATCH v3 3/5] zynq: remove use of CLKDEV_LOOKUP
On Wed, Oct 24, 2012 at 09:32:32AM -0400, Nick Bowler wrote: > On 2012-10-23 19:34 -0500, Josh Cartwright wrote: > > The Zynq support in mainline does not (yet) make use of any of the > > generic clk or clk lookup functionality. Remove what is upstream for > > now, until the out-of-tree implementation is in suitable form for > > merging. > > > > An important side effect of this patch is that it allows the building of > > a Zynq kernel without running into unresolved symbol problems: > > > >drivers/built-in.o: In function `amba_get_enable_pclk': > >clkdev.c:(.text+0x444): undefined reference to `clk_enable' > > For the record, I think this was introduced by commit 56a34b03ff427 > ("ARM: versatile: Make plat-versatile clock optional") which forgot to > select PLAT_VERSATILE_CLOCK on Zynq. This is not all that surprising, > because the fact that Zynq "uses" PLAT_VERSATILE is secretly hidden in > the Makefile. Yes, indeed. I did try to fix my problems by having ARCH_ZYNQ select PLAT_VERSATILE_CLOCK, but I recall running into additional build problems... But now that I just tried it again, it all seems to work, barring Kconfig complaining I've selected PLAT_VERSATILE_CLOCK, but not PLAT_VERSATILE. (Having ARCH_ZYNQ select PLAT_VERSATILE, however, leads to additional build problems). > Nevertheless, the only feature from versatile that Zynq needed was the > clock support, so this patch should *also* delete the secret use of > plat-versatile by removing this line from arch/arm/Makefile: > > plat-$(CONFIG_ARCH_ZYNQ)+= versatile Yes, indeed it should. Thanks, Josh pgp0e8qmfxRrs.pgp Description: PGP signature
Re: [PATCH v3 3/5] zynq: remove use of CLKDEV_LOOKUP
On 2012-10-23 19:34 -0500, Josh Cartwright wrote: > The Zynq support in mainline does not (yet) make use of any of the > generic clk or clk lookup functionality. Remove what is upstream for > now, until the out-of-tree implementation is in suitable form for > merging. > > An important side effect of this patch is that it allows the building of > a Zynq kernel without running into unresolved symbol problems: > >drivers/built-in.o: In function `amba_get_enable_pclk': >clkdev.c:(.text+0x444): undefined reference to `clk_enable' For the record, I think this was introduced by commit 56a34b03ff427 ("ARM: versatile: Make plat-versatile clock optional") which forgot to select PLAT_VERSATILE_CLOCK on Zynq. This is not all that surprising, because the fact that Zynq "uses" PLAT_VERSATILE is secretly hidden in the Makefile. Nevertheless, the only feature from versatile that Zynq needed was the clock support, so this patch should *also* delete the secret use of plat-versatile by removing this line from arch/arm/Makefile: plat-$(CONFIG_ARCH_ZYNQ) += versatile > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig > index cce4f8d..de70d99 100644 > --- a/arch/arm/Kconfig > +++ b/arch/arm/Kconfig > @@ -946,7 +946,6 @@ config ARCH_ZYNQ > bool "Xilinx Zynq ARM Cortex A9 Platform" > select ARM_AMBA > select ARM_GIC > - select CLKDEV_LOOKUP > select CPU_V7 > select GENERIC_CLOCKEVENTS > select ICST I'd prefer if we just added "select COMMON_CLK" instead of removing this so we don't have to re-add this later, but I guess it doesn't really matter either way. Cheers, -- Nick Bowler, Elliptic Technologies (http://www.elliptictech.com/) -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH v3 3/5] zynq: remove use of CLKDEV_LOOKUP
On Wednesday 24 October 2012, Josh Cartwright wrote: > The Zynq support in mainline does not (yet) make use of any of the > generic clk or clk lookup functionality. Remove what is upstream for > now, until the out-of-tree implementation is in suitable form for > merging. > > An important side effect of this patch is that it allows the building of > a Zynq kernel without running into unresolved symbol problems: > >drivers/built-in.o: In function `amba_get_enable_pclk': >clkdev.c:(.text+0x444): undefined reference to `clk_enable' >drivers/built-in.o: In function `amba_remove': >clkdev.c:(.text+0x488): undefined reference to `clk_disable' >drivers/built-in.o: In function `amba_probe': >clkdev.c:(.text+0x540): undefined reference to `clk_disable' >drivers/built-in.o: In function `amba_device_add': >clkdev.c:(.text+0x77c): undefined reference to `clk_disable' >drivers/built-in.o: In function `enable_clock': >clkdev.c:(.text+0x29738): undefined reference to `clk_enable' >drivers/built-in.o: In function `disable_clock': >clkdev.c:(.text+0x29778): undefined reference to `clk_disable' >drivers/built-in.o: In function `__pm_clk_remove': >clkdev.c:(.text+0x297f8): undefined reference to `clk_disable' >drivers/built-in.o: In function `pm_clk_suspend': >clkdev.c:(.text+0x29bc8): undefined reference to `clk_disable' >drivers/built-in.o: In function `pm_clk_resume': >clkdev.c:(.text+0x29c28): undefined reference to `clk_enable' >make[2]: *** [vmlinux] Error 1 >make[1]: *** [sub-make] Error 2 >make: *** [all] Error 2 > > Signed-off-by: Josh Cartwright > Cc: John Linn Acked-by: Arnd Bergmann I think I forgot to mention in the previous review round that it would be nice to just enable CONFIG_COMMON_CLK right away. Not important though. Arnd -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH v3 3/5] zynq: remove use of CLKDEV_LOOKUP
The Zynq support in mainline does not (yet) make use of any of the generic clk or clk lookup functionality. Remove what is upstream for now, until the out-of-tree implementation is in suitable form for merging. An important side effect of this patch is that it allows the building of a Zynq kernel without running into unresolved symbol problems: drivers/built-in.o: In function `amba_get_enable_pclk': clkdev.c:(.text+0x444): undefined reference to `clk_enable' drivers/built-in.o: In function `amba_remove': clkdev.c:(.text+0x488): undefined reference to `clk_disable' drivers/built-in.o: In function `amba_probe': clkdev.c:(.text+0x540): undefined reference to `clk_disable' drivers/built-in.o: In function `amba_device_add': clkdev.c:(.text+0x77c): undefined reference to `clk_disable' drivers/built-in.o: In function `enable_clock': clkdev.c:(.text+0x29738): undefined reference to `clk_enable' drivers/built-in.o: In function `disable_clock': clkdev.c:(.text+0x29778): undefined reference to `clk_disable' drivers/built-in.o: In function `__pm_clk_remove': clkdev.c:(.text+0x297f8): undefined reference to `clk_disable' drivers/built-in.o: In function `pm_clk_suspend': clkdev.c:(.text+0x29bc8): undefined reference to `clk_disable' drivers/built-in.o: In function `pm_clk_resume': clkdev.c:(.text+0x29c28): undefined reference to `clk_enable' make[2]: *** [vmlinux] Error 1 make[1]: *** [sub-make] Error 2 make: *** [all] Error 2 Signed-off-by: Josh Cartwright Cc: John Linn --- arch/arm/Kconfig | 1 - arch/arm/mach-zynq/common.c | 1 - arch/arm/mach-zynq/include/mach/clkdev.h | 32 3 files changed, 34 deletions(-) delete mode 100644 arch/arm/mach-zynq/include/mach/clkdev.h diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index cce4f8d..de70d99 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -946,7 +946,6 @@ config ARCH_ZYNQ bool "Xilinx Zynq ARM Cortex A9 Platform" select ARM_AMBA select ARM_GIC - select CLKDEV_LOOKUP select CPU_V7 select GENERIC_CLOCKEVENTS select ICST diff --git a/arch/arm/mach-zynq/common.c b/arch/arm/mach-zynq/common.c index 056091a..ba48f06 100644 --- a/arch/arm/mach-zynq/common.c +++ b/arch/arm/mach-zynq/common.c @@ -31,7 +31,6 @@ #include #include -#include #include "common.h" static struct of_device_id zynq_of_bus_ids[] __initdata = { diff --git a/arch/arm/mach-zynq/include/mach/clkdev.h b/arch/arm/mach-zynq/include/mach/clkdev.h deleted file mode 100644 index c6e73d8..000 --- a/arch/arm/mach-zynq/include/mach/clkdev.h +++ /dev/null @@ -1,32 +0,0 @@ -/* - * arch/arm/mach-zynq/include/mach/clkdev.h - * - * Copyright (C) 2011 Xilinx, Inc. - * - * This software is licensed under the terms of the GNU General Public - * License version 2, as published by the Free Software Foundation, and - * may be copied, distributed, and modified under those terms. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ - -#ifndef __MACH_CLKDEV_H__ -#define __MACH_CLKDEV_H__ - -#include - -struct clk { - unsigned long rate; - const struct clk_ops*ops; - const struct icst_params *params; - void __iomem*vcoreg; -}; - -#define __clk_get(clk) ({ 1; }) -#define __clk_put(clk) do { } while (0) - -#endif -- 1.8.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/