Versatile family cleanups step 1:

- Finalize RealView the PB1176 and PB11MPCore device trees
 - Move Versatile to use the power/reset driver instead of a
   custom restart hook
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJWwZOHAAoJEEEQszewGV1zsg8P/3xtEDPR9GJAuzzgV8o8hmpA
 psFc4PmdQcp1e19gb2oi0oKcv9xDzsKGavy/BYMMn9HQ6v4wTmtM9qMwNgRyTWZq
 RyAtnPxUP543Qiae1tdPBp700cyg8UsEcL56qhwemCOucjwD6wZNiAAs6bUh9mYa
 J1liSaarw+XOhzUdfqffk0JUac1oqnvdiiOLwAXsdWbCfNdkJGbfZ0N5TuUANMhM
 RXeqq8giEZAbvQtqumZv6c7Qk02zeG6tYq6R7lsW65IIvOhVk2rxYdC8ZhPTojxR
 V7jMLnA4xYn5IaLE4l7Z32AqKWGnsThmdP4OEMLnRhEduutHWUVj3XHlPAlS1pN1
 cD+mHuP48+5AscEL6Xf6+jeVYFkdER3RX9DgGZxUgLENw9T4g0/vq2DSGijwPuDN
 NB++vroPQoFEoPzCOx+JvO88VctabzuV7Z6rIvSLcIwPAhHvzMk1G+gy6hrUz5Bc
 cfovCqw1C8Y15srcIRhNr8dxDyZ3bpsatbSQNgPly4cHnAHLB8olTpXdfBzKIbKO
 FQmiAh+aPljOXxJT5yTg+3isIWA2tkc67WNiuX3+aKp38Ux2TNvDYCGf+LXF0RsU
 hgLGe3f4Bqw9xIMPYqQZM2UBl91p48ErhhmNJCWjceVgLEDHsCxaIvCx+oqLyYdv
 00TEPFLVtam4SJbqgJwq
 =NvEo
 -----END PGP SIGNATURE-----

Merge tag 'versatile-dt-cleanup-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator into next/dt

Versatile DT cleanups from Linus Walleij:

"this is a first pull request for my cleanups for the Versatile, as
the finished stuff should not be sitting in my tree but in ARM SoC.
This completes the ARM RealView PB1176 and PB11MPCore device trees,
and moves the Versatile to use power/reset.

The idea is to keep working on this cleanup branch and send additional
patches on top of this one as the prerequisites are merged into the MTD
and FBDEV subsystems. So please create a special versatile cleanup branch
(or suggest another approach).

As it happens, board files and device trees need to change at the same
time to make logical sense, especially for Versatile where auxdata is
replaced with DT entries, such as when reset is moved in the last patch
in this set. The MTD and CLCD changes will share this characteristic."

Versatile family cleanups step 1:
- Finalize RealView the PB1176 and PB11MPCore device trees
- Move Versatile to use the power/reset driver instead of a
  custom restart hook

* tag 'versatile-dt-cleanup-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator:
  ARM: versatile: move restart to the device tree
  ARM: realview: add the DS1338 RTC to PB1176 DT
  ARM: pb1176: add ethernet to devicetree
  ARM: pb1176: add ISP1761 USB OTG host controller
  ARM: pb1176: add AACI to the device tree
  ARM: pb1176: add ICST307 clocks to the device tree
  ARM: realview: fix up PB11MP flash compat strings
  ARM: realview: add flash devices to the PB1176 DTS

Signed-off-by: Olof Johansson <olof@lixom.net>
This commit is contained in:
Olof Johansson 2016-02-24 16:03:21 -08:00
commit 5dab9f62a4
4 changed files with 123 additions and 17 deletions

View file

@ -53,6 +53,14 @@
regulator-boot-on;
};
veth: fixedregulator@0 {
compatible = "regulator-fixed";
regulator-name = "veth";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-boot-on;
};
xtal24mhz: xtal24mhz@24M {
#clock-cells = <0>;
compatible = "fixed-clock";
@ -106,6 +114,53 @@
clock-frequency = <0>;
};
flash@30000000 {
compatible = "arm,versatile-flash", "cfi-flash";
reg = <0x30000000 0x4000000>;
bank-width = <4>;
};
fpga_flash@38000000 {
compatible = "arm,versatile-flash", "cfi-flash";
reg = <0x38000000 0x800000>;
bank-width = <4>;
};
/*
* The "secure flash" contains things like the boot
* monitor so we don't want people to accidentally
* screw this up. Mark the device tree node disabled
* by default.
*/
secflash@3c000000 {
compatible = "arm,versatile-flash", "cfi-flash";
reg = <0x3c000000 0x4000000>;
bank-width = <4>;
status = "disabled";
};
/* SMSC 9118 ethernet with PHY and EEPROM */
ethernet@3a000000 {
compatible = "smsc,lan9118", "smsc,lan9115";
reg = <0x3a000000 0x10000>;
interrupt-parent = <&intc_fpga1176>;
interrupts = <0 10 IRQ_TYPE_LEVEL_HIGH>;
phy-mode = "mii";
reg-io-width = <4>;
smsc,irq-active-high;
smsc,irq-push-pull;
vdd33a-supply = <&veth>;
vddvario-supply = <&veth>;
};
usb@3b000000 {
compatible = "nxp,usb-isp1761";
reg = <0x3b000000 0x20000>;
interrupt-parent = <&intc_fpga1176>;
interrupts = <0 11 IRQ_TYPE_LEVEL_HIGH>;
port1-otg;
};
soc {
#address-cells = <1>;
#size-cells = <1>;
@ -176,6 +231,41 @@
label = "versatile:7";
default-state = "off";
};
oscclk0: osc0@0c {
compatible = "arm,syscon-icst307";
#clock-cells = <0>;
lock-offset = <0x20>;
vco-offset = <0x0C>;
clocks = <&xtal24mhz>;
};
oscclk1: osc1@10 {
compatible = "arm,syscon-icst307";
#clock-cells = <0>;
lock-offset = <0x20>;
vco-offset = <0x10>;
clocks = <&xtal24mhz>;
};
oscclk2: osc2@14 {
compatible = "arm,syscon-icst307";
#clock-cells = <0>;
lock-offset = <0x20>;
vco-offset = <0x14>;
clocks = <&xtal24mhz>;
};
oscclk3: osc3@18 {
compatible = "arm,syscon-icst307";
#clock-cells = <0>;
lock-offset = <0x20>;
vco-offset = <0x18>;
clocks = <&xtal24mhz>;
};
oscclk4: osc4@1c {
compatible = "arm,syscon-icst307";
#clock-cells = <0>;
lock-offset = <0x20>;
vco-offset = <0x1c>;
clocks = <&xtal24mhz>;
};
};
/* Primary DevChip GIC synthesized with the CPU */
@ -297,6 +387,13 @@
clocks = <&uartclk>, <&pclk>;
clock-names = "uartclk", "apb_pclk";
};
/* Direct-mapped development chip ROM */
pb1176_rom@10200000 {
compatible = "direct-mapped";
reg = <0x10200000 0x4000>;
bank-width = <1>;
};
};
/* These peripherals are inside the FPGA rather than the DevChip */
@ -306,6 +403,27 @@
compatible = "simple-bus";
ranges;
i2c0: i2c@10002000 {
#address-cells = <1>;
#size-cells = <0>;
compatible = "arm,versatile-i2c";
reg = <0x10002000 0x1000>;
rtc@68 {
compatible = "dallas,ds1338";
reg = <0x68>;
};
};
fpga_aaci: aaci@10004000 {
compatible = "arm,pl041", "arm,primecell";
reg = <0x10004000 0x1000>;
interrupt-parent = <&intc_fpga1176>;
interrupts = <0 19 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&pclk>;
clock-names = "apb_pclk";
};
fpga_mci: mmcsd@10005000 {
compatible = "arm,pl18x", "arm,primecell";
reg = <0x10005000 0x1000>;

View file

@ -230,14 +230,14 @@
flash0@40000000 {
/* 2 * 32MiB NOR Flash memory */
compatible = "arm,vexpress-flash", "cfi-flash";
compatible = "arm,versatile-flash", "cfi-flash";
reg = <0x40000000 0x04000000>;
bank-width = <4>;
};
flash1@44000000 {
// 2 * 32MiB NOR Flash memory
compatible = "arm,vexpress-flash", "cfi-flash";
compatible = "arm,versatile-flash", "cfi-flash";
reg = <0x44000000 0x04000000>;
bank-width = <4>;
};

View file

@ -8,8 +8,11 @@ config ARCH_VERSATILE
select COMMON_CLK_VERSATILE
select CPU_ARM926T
select ICST
select MFD_SYSCON
select MIGHT_HAVE_PCI
select PLAT_VERSATILE
select POWER_RESET
select POWER_RESET_VERSATILE
select VERSATILE_FPGA_IRQ
help
This enables support for ARM Ltd Versatile board.

View file

@ -52,8 +52,6 @@
* Versatile Registers
* ------------------------------------------------------------------------
*/
#define VERSATILE_SYS_LOCK_OFFSET 0x20
#define VERSATILE_SYS_RESETCTL_OFFSET 0x40
#define VERSATILE_SYS_PCICTL_OFFSET 0x44
#define VERSATILE_SYS_MCI_OFFSET 0x48
#define VERSATILE_SYS_FLASH_OFFSET 0x4C
@ -345,18 +343,6 @@ static void __init versatile_init_early(void)
__io_address(VERSATILE_SCTL_BASE));
}
static void versatile_restart(enum reboot_mode mode, const char *cmd)
{
u32 val;
val = readl(versatile_sys_base + VERSATILE_SYS_RESETCTL_OFFSET);
val |= 0x105;
writel(0xa05f, versatile_sys_base + VERSATILE_SYS_LOCK_OFFSET);
writel(val, versatile_sys_base + VERSATILE_SYS_RESETCTL_OFFSET);
writel(0, versatile_sys_base + VERSATILE_SYS_LOCK_OFFSET);
}
static void __init versatile_dt_pci_init(void)
{
u32 val;
@ -420,5 +406,4 @@ DT_MACHINE_START(VERSATILE_PB, "ARM-Versatile (Device Tree Support)")
.init_early = versatile_init_early,
.init_machine = versatile_dt_init,
.dt_compat = versatile_dt_match,
.restart = versatile_restart,
MACHINE_END