Message ID | 1370327958-19776-3-git-send-email-mturquette@linaro.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
* Mike Turquette <mturquette@linaro.org> [130603 23:45]: > This is a first pass at creating a unique node for each clock in the > OMAP4 power, reset and & clock manager (PRCM). So far I have only > converted mux clocks & fixed-rate clocks, which coexist with the current > clock data in the kernel. The rest needs to be done but better to > publish early and often to see what others think of this approach. > +/* FIXME need to print the address directly */ > +/* > +#include "../../mach-omap2/prm44xx.h" > +#include "../../mach-omap2/cm2_44xx.h" > +#include "../../mach-omap2/cm1_44xx.h" > +*/ I don't think you're using the above includes any longer in this file? Regards, Tony
Quoting Tony Lindgren (2013-06-04 07:55:43) > * Mike Turquette <mturquette@linaro.org> [130603 23:45]: > > This is a first pass at creating a unique node for each clock in the > > OMAP4 power, reset and & clock manager (PRCM). So far I have only > > converted mux clocks & fixed-rate clocks, which coexist with the current > > clock data in the kernel. The rest needs to be done but better to > > publish early and often to see what others think of this approach. > > > +/* FIXME need to print the address directly */ > > +/* > > +#include "../../mach-omap2/prm44xx.h" > > +#include "../../mach-omap2/cm2_44xx.h" > > +#include "../../mach-omap2/cm1_44xx.h" > > +*/ > > I don't think you're using the above includes any longer > in this file? > Correct. I actually spotted this before emailing the patches out at midnight, but by then I didn't care to fix it. The benefits of marking a patch as "RFC" ;-) I had a mind to use the new preprocessor capabilities of dtc for the PRCM bit masks and shift values, but instead I ended up using the raw hex values. I've actually come to prefer using the raw hex values for DT, which I think makes more sense for a description of the hardware which is not tied to any Linux implementation. Regards, Mike > Regards, > > Tony
* Mike Turquette <mturquette@linaro.org> [130604 11:40]: > Quoting Tony Lindgren (2013-06-04 07:55:43) > > * Mike Turquette <mturquette@linaro.org> [130603 23:45]: > > > This is a first pass at creating a unique node for each clock in the > > > OMAP4 power, reset and & clock manager (PRCM). So far I have only > > > converted mux clocks & fixed-rate clocks, which coexist with the current > > > clock data in the kernel. The rest needs to be done but better to > > > publish early and often to see what others think of this approach. > > > > > +/* FIXME need to print the address directly */ > > > +/* > > > +#include "../../mach-omap2/prm44xx.h" > > > +#include "../../mach-omap2/cm2_44xx.h" > > > +#include "../../mach-omap2/cm1_44xx.h" > > > +*/ > > > > I don't think you're using the above includes any longer > > in this file? > > > > Correct. I actually spotted this before emailing the patches out at > midnight, but by then I didn't care to fix it. The benefits of marking > a patch as "RFC" ;-) :) > I had a mind to use the new preprocessor capabilities of dtc for the > PRCM bit masks and shift values, but instead I ended up using the raw > hex values. I've actually come to prefer using the raw hex values for > DT, which I think makes more sense for a description of the hardware > which is not tied to any Linux implementation. Agreed, especially if the value is only used once. Regards, Tony
diff --git a/arch/arm/boot/dts/omap4-clocks.dtsi b/arch/arm/boot/dts/omap4-clocks.dtsi new file mode 100644 index 0000000..664e100 --- /dev/null +++ b/arch/arm/boot/dts/omap4-clocks.dtsi @@ -0,0 +1,128 @@ +/* + * Copyright (C) 2013 Linaro Incorporated - http://www.linaro.org/ + * + * Mike Turquette <mturquette@linaro.org> + * + * Data is automatically generated from the OMAP hardware databases. If + * changes need to be made, do not edit this file directly. Instead contact + * the following developers who will update the code generator: + * + * Benoit Cousson <benoit.cousson@linaro.org> + * Rajendra Nayak <rnayak@ti.com> + * Mike Turquette <mturquette@linaro.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +/* FIXME need to print the address directly */ +/* +#include "../../mach-omap2/prm44xx.h" +#include "../../mach-omap2/cm2_44xx.h" +#include "../../mach-omap2/cm1_44xx.h" +*/ + + +/* Root clocks */ + +extalt_clkin_ck: extalt_clkin_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <59000000>; +}; + +pad_slimbus_core_clks_ck: pad_slimbus_core_clks_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <12000000>; +}; + +secure_32k_clk_src_ck: secure_32k_clk_src_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <32768>; +}; + +virt_12000000_ck: virt_12000000_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <12000000>; +}; + +virt_13000000_ck: virt_13000000_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <13000000>; +}; + +virt_16800000_ck: virt_16800000_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <16800000>; +}; + +virt_19200000_ck: virt_19200000_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <19200000>; +}; + +virt_26000000_ck: virt_26000000_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <26000000>; +}; + +virt_27000000_ck: virt_27000000_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <27000000>; +}; + +virt_38400000_ck: virt_38400000_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <38400000>; +}; + +sys_clkin_dt: sys_clkin_dt@4a306110 { + #clock-cells = <0>; + compatible = "mux-clock"; + clocks = <&virt_12000000_ck>, <&virt_13000000_ck>, <&virt_16800000_ck>, <&virt_19200000_ck>, <&virt_26000000_ck>, <&virt_27000000_ck>, <&virt_38400000_ck>; + reg = <0x4a306110 0x4>; + mask = <0x7>; + shift = <0>; + index_one; +}; + +tie_low_clock_ck: tie_low_clock_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <0>; +}; + +utmi_phy_clkout_ck: utmi_phy_clkout_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <60000000>; +}; + +xclk60mhsp1_ck: xclk60mhsp1_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <60000000>; +}; + +xclk60mhsp2_ck: xclk60mhsp2_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <60000000>; +}; + +xclk60motg_ck: xclk60motg_ck { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <60000000>; +}; + diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi index 2a56428..70608db 100644 --- a/arch/arm/boot/dts/omap4.dtsi +++ b/arch/arm/boot/dts/omap4.dtsi @@ -106,6 +106,8 @@ ti,hwmods = "counter_32k"; }; + /include/ "omap4-clocks.dtsi" + omap4_pmx_core: pinmux@4a100040 { compatible = "ti,omap4-padconf", "pinctrl-single"; reg = <0x4a100040 0x0196>;
This is a first pass at creating a unique node for each clock in the OMAP4 power, reset and & clock manager (PRCM). So far I have only converted mux clocks & fixed-rate clocks, which coexist with the current clock data in the kernel. The rest needs to be done but better to publish early and often to see what others think of this approach. Cc: Benoit Cousson <b-cousson@ti.com> Cc: Rajendra Nayak <rnayak@ti.com> Cc: Joel A Fernandes <joelagnel@ti.com> Cc: Nishanth Menon <nm@ti.com> Cc: Paul Walmsley <paul@pwsan.com> Cc: Tony Lindgren <tony@atomide.com> Signed-off-by: Mike Turquette <mturquette@linaro.org> --- arch/arm/boot/dts/omap4-clocks.dtsi | 128 ++++++++++++++++++++++++++++++++++++ arch/arm/boot/dts/omap4.dtsi | 2 + 2 files changed, 130 insertions(+) create mode 100644 arch/arm/boot/dts/omap4-clocks.dtsi