Commit 77579afc authored by Arnd Bergmann's avatar Arnd Bergmann

Merge tag 'at91-dt3' of git://github.com/at91linux/linux-at91 into next/dt

3.16 third DT series:
- move of both at91sam9n12 and at91sam9x5 to CCF

* tag 'at91-dt3' of git://github.com/at91linux/linux-at91:
  ARM: at91: move sam9n12 SoC to the CCF
  ARM: at91/dt: define sam9n12ek crystal frequencies
  ARM: at91/dt: define sam9n12 clocks
  ARM: at91: prepare common clk transition for sam9n12 SoC
  ARM: at91: move sam9x5 SoCs to the CCF
  ARM: at91/dt: define sam9x5ek's crystal frequencies
  ARM: at91/dt: define sam9x5 clocks
  ARM: at91: prepare common clk transition for sam9x5 SoCs
  dt-bindings: clock: Move at91.h to dt-bindigs/clock
  ARM: at91: fix spi cs on sama5d3 Xplained board
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parents d5cd8605 b4a86b38
...@@ -139,7 +139,7 @@ Required properties for PMC node: ...@@ -139,7 +139,7 @@ Required properties for PMC node:
- interrupt-controller : tell that the PMC is an interrupt controller. - interrupt-controller : tell that the PMC is an interrupt controller.
- #interrupt-cells : must be set to 1. The first cell encodes the interrupt id, - #interrupt-cells : must be set to 1. The first cell encodes the interrupt id,
and reflect the bit position in the PMC_ER/DR/SR registers. and reflect the bit position in the PMC_ER/DR/SR registers.
You can use the dt macros defined in dt-bindings/clk/at91.h. You can use the dt macros defined in dt-bindings/clock/at91.h.
0 (AT91_PMC_MOSCS) -> main oscillator ready 0 (AT91_PMC_MOSCS) -> main oscillator ready
1 (AT91_PMC_LOCKA) -> PLL A ready 1 (AT91_PMC_LOCKA) -> PLL A ready
2 (AT91_PMC_LOCKB) -> PLL B ready 2 (AT91_PMC_LOCKB) -> PLL B ready
......
...@@ -42,7 +42,7 @@ slot@0 { ...@@ -42,7 +42,7 @@ slot@0 {
}; };
spi0: spi@f0004000 { spi0: spi@f0004000 {
cs-gpios = <&pioD 13 0>; cs-gpios = <&pioD 13 0>, <0>, <0>, <&pioD 16 0>;
status = "okay"; status = "okay";
}; };
...@@ -136,7 +136,7 @@ slot@0 { ...@@ -136,7 +136,7 @@ slot@0 {
}; };
spi1: spi@f8008000 { spi1: spi@f8008000 {
cs-gpios = <&pioC 25 0>, <0>, <0>, <&pioD 16 0>; cs-gpios = <&pioC 25 0>;
status = "okay"; status = "okay";
}; };
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
#include <dt-bindings/pinctrl/at91.h> #include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/gpio/gpio.h> #include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/clk/at91.h> #include <dt-bindings/clock/at91.h>
/ { / {
model = "Atmel AT91SAM9261 family SoC"; model = "Atmel AT91SAM9261 family SoC";
......
This diff is collapsed.
...@@ -21,6 +21,14 @@ memory { ...@@ -21,6 +21,14 @@ memory {
reg = <0x20000000 0x8000000>; reg = <0x20000000 0x8000000>;
}; };
slow_xtal {
clock-frequency = <32768>;
};
main_xtal {
clock-frequency = <16000000>;
};
clocks { clocks {
#address-cells = <1>; #address-cells = <1>;
#size-cells = <1>; #size-cells = <1>;
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
#include "skeleton.dtsi" #include "skeleton.dtsi"
#include <dt-bindings/pinctrl/at91.h> #include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/clk/at91.h> #include <dt-bindings/clock/at91.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/gpio/gpio.h> #include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/pwm/pwm.h> #include <dt-bindings/pwm/pwm.h>
......
This diff is collapsed.
/*
* at91sam9x5_macb0.dtsi - Device Tree Include file for AT91SAM9x5 SoC with 1
* Ethernet interface.
*
* Copyright (C) 2013 Boris BREZILLON <b.brezillon@overkiz.com>
*
* Licensed under GPLv2.
*/
#include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h>
/ {
ahb {
apb {
pmc: pmc@fffffc00 {
periphck {
can0_clk: can0_clk {
#clock-cells = <0>;
reg = <29>;
};
can1_clk: can1_clk {
#clock-cells = <0>;
reg = <30>;
};
};
};
};
};
};
/*
* at91sam9x5_isi.dtsi - Device Tree Include file for AT91SAM9x5 SoC with an
* Image Sensor Interface.
*
* Copyright (C) 2013 Boris BREZILLON <b.brezillon@overkiz.com>
*
* Licensed under GPLv2.
*/
#include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h>
/ {
ahb {
apb {
pmc: pmc@fffffc00 {
periphck {
isi_clk: isi_clk {
#clock-cells = <0>;
reg = <25>;
};
};
};
};
};
};
/*
* at91sam9x5_lcd.dtsi - Device Tree Include file for AT91SAM9x5 SoC with an
* LCD controller.
*
* Copyright (C) 2013 Boris BREZILLON <b.brezillon@overkiz.com>
*
* Licensed under GPLv2.
*/
#include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h>
/ {
ahb {
apb {
pmc: pmc@fffffc00 {
periphck {
lcdc_clk: lcdc_clk {
#clock-cells = <0>;
reg = <25>;
};
};
};
};
};
};
...@@ -43,12 +43,23 @@ AT91_PIOB 16 AT91_PERIPH_A AT91_PINCTRL_NONE /* PB16 periph A */ ...@@ -43,12 +43,23 @@ AT91_PIOB 16 AT91_PERIPH_A AT91_PINCTRL_NONE /* PB16 periph A */
}; };
}; };
pmc: pmc@fffffc00 {
periphck {
macb0_clk: macb0_clk {
#clock-cells = <0>;
reg = <24>;
};
};
};
macb0: ethernet@f802c000 { macb0: ethernet@f802c000 {
compatible = "cdns,at32ap7000-macb", "cdns,macb"; compatible = "cdns,at32ap7000-macb", "cdns,macb";
reg = <0xf802c000 0x100>; reg = <0xf802c000 0x100>;
interrupts = <24 IRQ_TYPE_LEVEL_HIGH 3>; interrupts = <24 IRQ_TYPE_LEVEL_HIGH 3>;
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&pinctrl_macb0_rmii>; pinctrl-0 = <&pinctrl_macb0_rmii>;
clocks = <&macb0_clk>, <&macb0_clk>;
clock-names = "hclk", "pclk";
status = "disabled"; status = "disabled";
}; };
}; };
......
...@@ -31,12 +31,23 @@ AT91_PIOC 30 AT91_PERIPH_B AT91_PINCTRL_NONE /* PC30 periph B */ ...@@ -31,12 +31,23 @@ AT91_PIOC 30 AT91_PERIPH_B AT91_PINCTRL_NONE /* PC30 periph B */
}; };
}; };
pmc: pmc@fffffc00 {
periphck {
macb1_clk: macb1_clk {
#clock-cells = <0>;
reg = <27>;
};
};
};
macb1: ethernet@f8030000 { macb1: ethernet@f8030000 {
compatible = "cdns,at32ap7000-macb", "cdns,macb"; compatible = "cdns,at32ap7000-macb", "cdns,macb";
reg = <0xf8030000 0x100>; reg = <0xf8030000 0x100>;
interrupts = <27 IRQ_TYPE_LEVEL_HIGH 3>; interrupts = <27 IRQ_TYPE_LEVEL_HIGH 3>;
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&pinctrl_macb1_rmii>; pinctrl-0 = <&pinctrl_macb1_rmii>;
clocks = <&macb1_clk>, <&macb1_clk>;
clock-names = "hclk", "pclk";
status = "disabled"; status = "disabled";
}; };
}; };
......
...@@ -42,12 +42,23 @@ pinctrl_usart3_sck: usart3_sck-0 { ...@@ -42,12 +42,23 @@ pinctrl_usart3_sck: usart3_sck-0 {
}; };
}; };
pmc: pmc@fffffc00 {
periphck {
usart3_clk: usart3_clk {
#clock-cells = <0>;
reg = <8>;
};
};
};
usart3: serial@f8028000 { usart3: serial@f8028000 {
compatible = "atmel,at91sam9260-usart"; compatible = "atmel,at91sam9260-usart";
reg = <0xf8028000 0x200>; reg = <0xf8028000 0x200>;
interrupts = <8 IRQ_TYPE_LEVEL_HIGH 5>; interrupts = <8 IRQ_TYPE_LEVEL_HIGH 5>;
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&pinctrl_usart3>; pinctrl-0 = <&pinctrl_usart3>;
clocks = <&usart3_clk>;
clock-names = "usart";
status = "disabled"; status = "disabled";
}; };
}; };
......
...@@ -23,6 +23,14 @@ main_clock: clock@0 { ...@@ -23,6 +23,14 @@ main_clock: clock@0 {
}; };
}; };
slow_xtal {
clock-frequency = <32768>;
};
main_xtal {
clock-frequency = <12000000>;
};
ahb { ahb {
apb { apb {
pinctrl@fffff400 { pinctrl@fffff400 {
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
#include <dt-bindings/pinctrl/at91.h> #include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/gpio/gpio.h> #include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/clk/at91.h> #include <dt-bindings/clock/at91.h>
/ { / {
model = "Atmel SAMA5D3 family SoC"; model = "Atmel SAMA5D3 family SoC";
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
#include <dt-bindings/pinctrl/at91.h> #include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/clk/at91.h> #include <dt-bindings/clock/at91.h>
/ { / {
ahb { ahb {
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
#include <dt-bindings/pinctrl/at91.h> #include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/clk/at91.h> #include <dt-bindings/clock/at91.h>
/ { / {
aliases { aliases {
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
#include <dt-bindings/pinctrl/at91.h> #include <dt-bindings/pinctrl/at91.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/clk/at91.h> #include <dt-bindings/clock/at91.h>
/ { / {
aliases { aliases {
......
...@@ -167,7 +167,6 @@ config SOC_AT91SAM9X5 ...@@ -167,7 +167,6 @@ config SOC_AT91SAM9X5
select HAVE_AT91_DBGU0 select HAVE_AT91_DBGU0
select HAVE_FB_ATMEL select HAVE_FB_ATMEL
select SOC_AT91SAM9 select SOC_AT91SAM9
select AT91_USE_OLD_CLK
select HAVE_AT91_UTMI select HAVE_AT91_UTMI
select HAVE_AT91_SMD select HAVE_AT91_SMD
select HAVE_AT91_USB_CLK select HAVE_AT91_USB_CLK
...@@ -183,7 +182,6 @@ config SOC_AT91SAM9N12 ...@@ -183,7 +182,6 @@ config SOC_AT91SAM9N12
select HAVE_AT91_DBGU0 select HAVE_AT91_DBGU0
select HAVE_FB_ATMEL select HAVE_FB_ATMEL
select SOC_AT91SAM9 select SOC_AT91SAM9
select AT91_USE_OLD_CLK
select HAVE_AT91_USB_CLK select HAVE_AT91_USB_CLK
help help
Select this if you are using Atmel's AT91SAM9N12 SoC. Select this if you are using Atmel's AT91SAM9N12 SoC.
......
...@@ -19,9 +19,10 @@ ...@@ -19,9 +19,10 @@
#include "board.h" #include "board.h"
#include "soc.h" #include "soc.h"
#include "generic.h" #include "generic.h"
#include "clock.h"
#include "sam9_smc.h" #include "sam9_smc.h"
#if defined(CONFIG_OLD_CLK_AT91)
#include "clock.h"
/* -------------------------------------------------------------------- /* --------------------------------------------------------------------
* Clocks * Clocks
* -------------------------------------------------------------------- */ * -------------------------------------------------------------------- */
...@@ -215,6 +216,9 @@ static void __init at91sam9n12_register_clocks(void) ...@@ -215,6 +216,9 @@ static void __init at91sam9n12_register_clocks(void)
ARRAY_SIZE(periph_clocks_lookups)); ARRAY_SIZE(periph_clocks_lookups));
} }
#else
#define at91sam9n12_register_clocks NULL
#endif
/* -------------------------------------------------------------------- /* --------------------------------------------------------------------
* AT91SAM9N12 processor initialization * AT91SAM9N12 processor initialization
......
...@@ -19,9 +19,10 @@ ...@@ -19,9 +19,10 @@
#include "board.h" #include "board.h"
#include "soc.h" #include "soc.h"
#include "generic.h" #include "generic.h"
#include "clock.h"
#include "sam9_smc.h" #include "sam9_smc.h"
#if defined(CONFIG_OLD_CLK_AT91)
#include "clock.h"
/* -------------------------------------------------------------------- /* --------------------------------------------------------------------
* Clocks * Clocks
* -------------------------------------------------------------------- */ * -------------------------------------------------------------------- */
...@@ -313,6 +314,9 @@ static void __init at91sam9x5_register_clocks(void) ...@@ -313,6 +314,9 @@ static void __init at91sam9x5_register_clocks(void)
clk_register(&pck0); clk_register(&pck0);
clk_register(&pck1); clk_register(&pck1);
} }
#else
#define at91sam9x5_register_clocks NULL
#endif
/* -------------------------------------------------------------------- /* --------------------------------------------------------------------
* AT91SAM9x5 processor initialization * AT91SAM9x5 processor initialization
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment