Second set of devicetree changes for omaps for v4.12 merge window

to configure various devices:
 
 - Enable DCAN on am57xx-idk
 
 - Enable CPSW ethernet0 and 1 on am335x-icev2
 
 - Non-critical fix for droid 4 PMIC interrupt triggering
 
 - Stop disabling SRAM and GPMC on droid 4
 
 - Configure CPCAP PMIC related devices on droid 4 for ADC, charger
   and USB PHY. The charger and USB PHY drivers are still being
   discussed, but the binding for them has been acked by Rob and
   Sebastian so they should be safe to merge together with the ADC
   driver in Linux next that they depend on
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEkgNvrZJU/QSQYIcQG9Q+yVyrpXMFAljruX4RHHRvbnlAYXRv
 bWlkZS5jb20ACgkQG9Q+yVyrpXM16g/8DeQMUItFTVrUBfvlHYAakL3hCJKGJQoU
 8vL+4N6oGhPzFje65ifX90GuPidKJDffkExbzBZn5K1JapuuafQDZ75QyxkM2tx2
 fESMgKNpXe78K+0GQ3sLESB6DQMQCai6H3XUKjXKi/dcG3NG6J9BQJJXdM2jFLsT
 OxIDVtHmwAJwx/BclmjCPsAKZVW/3HiqMXoiovXb0aQQXNjBqlmhBQUL+YO8Kxwq
 VOlGhsxzHPubAEv98VQeTUpZR4G+1JljmDP4UW4H2HHdWMzNvZIyd7Tk/6Tr+ek1
 GPr89zm9QqpvzVXvLqwRG27EF9EpYbMbcrUn+02YV6Z0Wrbh6m6Hm0fg3nqGrkdC
 l4DG0SExzGzi/Vxgfw71JyXcyEabF4gOMMLGcVFcAA/83PaRFB5kFENOW0gMLQ5e
 9G6zesj/0ET7m/qMAVcExA+gREXOjCswc3twrYx9vYeS03Ma4Jzg7pzmS+Af+Wcn
 leNviCjVb4aArBAxvEEId0ajVicftc0by61HviRacm1TUL4Gh0mvyJtN3sjRD+8w
 dFSFVzGpBs9WQWuf82OVss1c4vLN/0I6sTa3RQT2PNUBAA+4GFFWJxrlDTXH8+tp
 oN2Ubc9JKt8hPJUY3AeXgC35kqloTUIPJARhIbmjeWKTJ1h/FXHBVEEyp3ut/vuE
 7/oCbfeW7k0=
 =Jna8
 -----END PGP SIGNATURE-----

Merge tag 'omap-for-v4.12/dt-pt2-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/dt

Second set of devicetree changes for omaps for v4.12 merge window
to configure various devices:

- Enable DCAN on am57xx-idk

- Enable CPSW ethernet0 and 1 on am335x-icev2

- Non-critical fix for droid 4 PMIC interrupt triggering

- Stop disabling SRAM and GPMC on droid 4

- Configure CPCAP PMIC related devices on droid 4 for ADC, charger
  and USB PHY. The charger and USB PHY drivers are still being
  discussed, but the binding for them has been acked by Rob and
  Sebastian so they should be safe to merge together with the ADC
  driver in Linux next that they depend on

* tag 'omap-for-v4.12/dt-pt2-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: dts: omap4-droid4: Add CPCAP PMIC OTG PHY configuration
  ARM: dts: omap4-droid4: Add CPCAP PMIC battery charger configuration
  ARM: dts: omap4-droid4: Add CPCAP PMIC ADC configuration
  ARM: dts: omap4-droid4: Stop disabling SRAM and GPMC
  ARM: dts: omap4-droid4: Fix interrupt triggering for cpcap
  ARM: dts: am335x-icev2: Add CPSW ethernet0 and ethernet1
  ARM: dts: am57xx-idk: Add DCAN support

Signed-off-by: Olof Johansson <olof@lixom.net>
This commit is contained in:
Olof Johansson 2017-04-19 06:48:32 -07:00
commit 16101f0510
4 changed files with 196 additions and 13 deletions

View File

@ -201,6 +201,69 @@ AM33XX_IOPAD(0x934, PIN_INPUT_PULLUP | MUX_MODE1) /* (L17) gmii1_rxd3.uart3_rxd
AM33XX_IOPAD(0x938, PIN_OUTPUT_PULLUP | MUX_MODE1) /* (L16) gmii1_rxd2.uart3_txd */
>;
};
cpsw_default: cpsw_default {
pinctrl-single,pins = <
/* Slave 1, RMII mode */
AM33XX_IOPAD(0x90c, (PIN_INPUT_PULLUP | MUX_MODE1)) /* mii1_crs.rmii1_crs_dv */
AM33XX_IOPAD(0x944, (PIN_INPUT_PULLUP | MUX_MODE0)) /* rmii1_refclk.rmii1_refclk */
AM33XX_IOPAD(0x940, (PIN_INPUT_PULLUP | MUX_MODE1)) /* mii1_rxd0.rmii1_rxd0 */
AM33XX_IOPAD(0x93c, (PIN_INPUT_PULLUP | MUX_MODE1)) /* mii1_rxd1.rmii1_rxd1 */
AM33XX_IOPAD(0x910, (PIN_INPUT_PULLUP | MUX_MODE1)) /* mii1_rxerr.rmii1_rxerr */
AM33XX_IOPAD(0x928, (PIN_OUTPUT_PULLDOWN | MUX_MODE1)) /* mii1_txd0.rmii1_txd0 */
AM33XX_IOPAD(0x924, (PIN_OUTPUT_PULLDOWN | MUX_MODE1)) /* mii1_txd1.rmii1_txd1 */
AM33XX_IOPAD(0x914, (PIN_OUTPUT_PULLDOWN | MUX_MODE1)) /* mii1_txen.rmii1_txen */
/* Slave 2, RMII mode */
AM33XX_IOPAD(0x870, (PIN_INPUT_PULLUP | MUX_MODE3)) /* gpmc_wait0.rmii2_crs_dv */
AM33XX_IOPAD(0x908, (PIN_INPUT_PULLUP | MUX_MODE1)) /* mii1_col.rmii2_refclk */
AM33XX_IOPAD(0x86c, (PIN_INPUT_PULLUP | MUX_MODE3)) /* gpmc_a11.rmii2_rxd0 */
AM33XX_IOPAD(0x868, (PIN_INPUT_PULLUP | MUX_MODE3)) /* gpmc_a10.rmii2_rxd1 */
AM33XX_IOPAD(0x874, (PIN_INPUT_PULLUP | MUX_MODE3)) /* gpmc_wpn.rmii2_rxerr */
AM33XX_IOPAD(0x854, (PIN_OUTPUT_PULLDOWN | MUX_MODE3)) /* gpmc_a5.rmii2_txd0 */
AM33XX_IOPAD(0x850, (PIN_OUTPUT_PULLDOWN | MUX_MODE3)) /* gpmc_a4.rmii2_txd1 */
AM33XX_IOPAD(0x840, (PIN_OUTPUT_PULLDOWN | MUX_MODE3)) /* gpmc_a0.rmii2_txen */
>;
};
cpsw_sleep: cpsw_sleep {
pinctrl-single,pins = <
/* Slave 1 reset value */
AM33XX_IOPAD(0x90c, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x944, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x940, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x93c, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x910, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x928, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x924, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x914, (PIN_INPUT_PULLDOWN | MUX_MODE7))
/* Slave 2 reset value */
AM33XX_IOPAD(0x870, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x908, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x86c, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x868, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x874, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x854, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x850, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x840, (PIN_INPUT_PULLDOWN | MUX_MODE7))
>;
};
davinci_mdio_default: davinci_mdio_default {
pinctrl-single,pins = <
/* MDIO */
AM33XX_IOPAD(0x948, (PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE0)) /* mdio_data.mdio_data */
AM33XX_IOPAD(0x94c, (PIN_OUTPUT_PULLUP | MUX_MODE0)) /* mdio_clk.mdio_clk */
>;
};
davinci_mdio_sleep: davinci_mdio_sleep {
pinctrl-single,pins = <
/* MDIO reset value */
AM33XX_IOPAD(0x948, (PIN_INPUT_PULLDOWN | MUX_MODE7))
AM33XX_IOPAD(0x94c, (PIN_INPUT_PULLDOWN | MUX_MODE7))
>;
};
};
&i2c0 {
@ -383,3 +446,61 @@ &uart3 {
pinctrl-0 = <&uart3_pins_default>;
status = "okay";
};
&gpio3 {
p4 {
gpio-hog;
gpios = <4 GPIO_ACTIVE_HIGH>;
output-high;
line-name = "PR1_MII_CTRL";
};
p10 {
gpio-hog;
gpios = <10 GPIO_ACTIVE_HIGH>;
/* ETH1 mux: Low for MII-PRU, high for RMII-CPSW */
output-high;
line-name = "MUX_MII_CTL1";
};
};
&cpsw_emac0 {
phy-handle = <&ethphy0>;
phy-mode = "rmii";
dual_emac_res_vlan = <1>;
};
&cpsw_emac1 {
phy-handle = <&ethphy1>;
phy-mode = "rmii";
dual_emac_res_vlan = <2>;
};
&mac {
pinctrl-names = "default", "sleep";
pinctrl-0 = <&cpsw_default>;
pinctrl-1 = <&cpsw_sleep>;
status = "okay";
dual_emac;
};
&phy_sel {
rmii-clock-ext;
};
&davinci_mdio {
pinctrl-names = "default", "sleep";
pinctrl-0 = <&davinci_mdio_default>;
pinctrl-1 = <&davinci_mdio_sleep>;
status = "okay";
reset-gpios = <&gpio2 5 GPIO_ACTIVE_LOW>;
reset-delay-us = <2>; /* PHY datasheet states 1uS min */
ethphy0: ethernet-phy@1 {
reg = <1>;
};
ethphy1: ethernet-phy@3 {
reg = <3>;
};
};

View File

@ -101,6 +101,22 @@ led-out7 {
};
};
&dra7_pmx_core {
dcan1_pins_default: dcan1_pins_default {
pinctrl-single,pins = <
DRA7XX_CORE_IOPAD(0x37d0, PIN_OUTPUT_PULLUP | MUX_MODE0) /* dcan1_tx */
DRA7XX_CORE_IOPAD(0x37d4, PIN_INPUT_PULLUP | MUX_MODE0) /* dcan1_rx */
>;
};
dcan1_pins_sleep: dcan1_pins_sleep {
pinctrl-single,pins = <
DRA7XX_CORE_IOPAD(0x37d0, MUX_MODE15 | PULL_UP) /* dcan1_tx.off */
DRA7XX_CORE_IOPAD(0x37d4, MUX_MODE15 | PULL_UP) /* dcan1_rx.off */
>;
};
};
&i2c1 {
status = "okay";
clock-frequency = <400000>;
@ -391,6 +407,14 @@ &mmc2 {
max-frequency = <96000000>;
};
&dcan1 {
status = "okay";
pinctrl-names = "default", "sleep", "active";
pinctrl-0 = <&dcan1_pins_sleep>;
pinctrl-1 = <&dcan1_pins_sleep>;
pinctrl-2 = <&dcan1_pins_default>;
};
&qspi {
status = "okay";

View File

@ -11,7 +11,7 @@ cpcap: pmic@0 {
compatible = "motorola,cpcap", "st,6556002";
reg = <0>; /* cs0 */
interrupt-parent = <&gpio1>;
interrupts = <7 IRQ_TYPE_EDGE_RISING>;
interrupts = <7 IRQ_TYPE_LEVEL_HIGH>;
interrupt-controller;
#interrupt-cells = <2>;
#address-cells = <1>;
@ -19,6 +19,32 @@ cpcap: pmic@0 {
spi-max-frequency = <3000000>;
spi-cs-high;
cpcap_adc: adc {
compatible = "motorola,mapphone-cpcap-adc";
interrupts-extended = <&cpcap 8 0>;
interrupt-names = "adcdone";
#io-channel-cells = <1>;
};
cpcap_charger: charger {
compatible = "motorola,mapphone-cpcap-charger";
interrupts-extended = <
&cpcap 13 0 &cpcap 12 0 &cpcap 29 0 &cpcap 28 0
&cpcap 22 0 &cpcap 20 0 &cpcap 19 0 &cpcap 54 0
>;
interrupt-names =
"chrg_det", "rvrs_chrg", "chrg_se1b", "se0conn",
"rvrs_mode", "chrgcurr1", "vbusvld", "battdetb";
mode-gpios = <&gpio3 29 GPIO_ACTIVE_LOW
&gpio3 23 GPIO_ACTIVE_LOW>;
io-channels = <&cpcap_adc 0 &cpcap_adc 1
&cpcap_adc 2 &cpcap_adc 5
&cpcap_adc 6>;
io-channel-names = "battdetb", "battp",
"vbus", "chg_isense",
"batti";
};
cpcap_regulator: regulator {
compatible = "motorola,mapphone-cpcap-regulator";
@ -39,6 +65,29 @@ power_button: button {
interrupts = <23 IRQ_TYPE_NONE>;
};
cpcap_usb2_phy: phy {
compatible = "motorola,mapphone-cpcap-usb-phy";
pinctrl-0 = <&usb_gpio_mux_sel1 &usb_gpio_mux_sel2>;
pinctrl-1 = <&usb_ulpi_pins>;
pinctrl-2 = <&usb_utmi_pins>;
pinctrl-3 = <&uart3_pins>;
pinctrl-names = "default", "ulpi", "utmi", "uart";
#phy-cells = <0>;
interrupts-extended = <
&cpcap 15 0 &cpcap 14 0 &cpcap 28 0 &cpcap 19 0
&cpcap 18 0 &cpcap 17 0 &cpcap 16 0 &cpcap 49 0
&cpcap 48 1
>;
interrupt-names =
"id_ground", "id_float", "se0conn", "vbusvld",
"sessvld", "sessend", "se1", "dm", "dp";
mode-gpios = <&gpio2 28 GPIO_ACTIVE_HIGH
&gpio1 0 GPIO_ACTIVE_HIGH>;
io-channels = <&cpcap_adc 2>, <&cpcap_adc 7>;
io-channel-names = "vbus", "id";
vusb-supply = <&vusb>;
};
led_red: led-red {
compatible = "motorola,cpcap-led-red";
vdd-supply = <&sw5>;

View File

@ -24,8 +24,7 @@ aliases {
/*
* We seem to have only 1021 MB accessible, 1021 - 1022 is locked,
* then 1023 - 1024 seems to contain mbm. For SRAM, see the notes
* below about SRAM and L3_ICLK2 being unused by default,
* then 1023 - 1024 seems to contain mbm.
*/
memory {
device_type = "memory";
@ -176,11 +175,6 @@ lcd0_in: endpoint {
};
};
/* L3_2 interconnect is unused, SRAM, GPMC and L3_ICLK2 disabled */
&gpmc {
status = "disabled";
};
&hdmi {
status = "okay";
pinctrl-0 = <&dss_hdmi_pins>;
@ -356,11 +350,6 @@ tsp@4a {
};
};
/* L3_2 interconnect is unused, SRAM, GPMC and L3_ICLK2 disabled */
&ocmcram {
status = "disabled";
};
&omap4_pmx_core {
/* hdmi_hpd.gpio_63 */