Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.1 ti pwm #14

Open
wants to merge 18 commits into
base: 4.4-ti
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions include/dt-bindings/genpd/k2g.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,4 +72,5 @@
#define K2G_DEV_CGEM0 0x0046
#define K2G_DEV_MSMC0 0x0047
#define K2G_DEV_CBASS0 0x0049
#define K2G_DEV_BOARD0 0x004c
#endif
22 changes: 22 additions & 0 deletions include/dt-bindings/reset/k2g.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/*
* TI K2G SoC reset definitions
*
* Copyright (C) 2015 Texas Instruments Incorporated - http://www.ti.com/
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* 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 __DT_BINDINGS_RESET_K2G_H__
#define __DT_BINDINGS_RESET_K2G_H__

#define K2G_DEV_CGEM0_DSP0_RESET 0x1

#endif
13 changes: 13 additions & 0 deletions include/dt-bindings/sound/ti-mcasp.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#ifndef _DT_BINDINGS_TI_MCASP_H
#define _DT_BINDINGS_TI_MCASP_H

/* Source of High-frequency transmit/receive clock */
#define MCASP_CLK_HCLK_AHCLK 0 /* AHCLKX/R */
#define MCASP_CLK_HCLK_AUXCLK 1 /* Internal functional clock */

/* clock divider IDs */
#define MCASP_CLKDIV_AUXCLK 0 /* HCLK divider from AUXCLK */
#define MCASP_CLKDIV_BCLK 1 /* BCLK divider from HCLK */
#define MCASP_CLKDIV_BCLK_FS_RATIO 2 /* to set BCLK FS ration */

#endif /* _DT_BINDINGS_TI_MCASP_H */
1 change: 1 addition & 0 deletions src/arm/am335x-abbbi.dts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "Arrow BeagleBone Black Industrial";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-bone.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone";
Expand Down
2 changes: 2 additions & 0 deletions src/arm/am335x-boneblack-bbbmini.dts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

#include <dt-bindings/board/am335x-bbw-bbb-base.h>
#include <dt-bindings/pinctrl/am33xx.h>

Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack-emmc-overlay.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack-hdmi-overlay.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack-nhdmi-overlay.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack-overlay.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack-replicape.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack-spi0.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
2 changes: 2 additions & 0 deletions src/arm/am335x-boneblack-ttyS2.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

#include <dt-bindings/board/am335x-bbw-bbb-base.h>
#include <dt-bindings/pinctrl/am33xx.h>

Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack-wl1835mod.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-boneblack.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Black";
Expand Down
1 change: 1 addition & 0 deletions src/arm/am335x-bonegreen-overlay.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Green";
Expand Down
52 changes: 52 additions & 0 deletions src/arm/am335x-bonegreen-wireless.dts
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
/*
* Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/
*
* 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.
*/
/dts-v1/;

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am335x-bonegreen-wl1835.dtsi"


/ {
model = "TI AM335x BeagleBone Green";
compatible = "ti,am335x-bone-green", "ti,am335x-bone-black", "ti,am335x-bone", "ti,am33xx";
};


&ldo3_reg {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-always-on;
};

&mmc1 {
vmmc-supply = <&vmmcsd_fixed>;
};

&mmc2 {
vmmc-supply = <&vmmcsd_fixed>;
pinctrl-names = "default";
pinctrl-0 = <&emmc_pins>;
bus-width = <8>;
status = "okay";
};
&uart3 {
status = "okay";
};

&mmc3 {
status = "okay";
};

&mac {
status = "disabled";
};

&sgx {
status = "okay";
};
138 changes: 138 additions & 0 deletions src/arm/am335x-bonegreen-wl1835.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@

#include <dt-bindings/interrupt-controller/irq.h>

/ {
wlan_en_reg: fixedregulator@2 {
compatible = "regulator-fixed";
regulator-name = "wlan-en-regulator";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;

/* WL_EN */
//gpio = <&gpio0 26 1>;
//enable-active-high;
};

tibt {
compatible = "tibt";
nshutdown_gpio = <60>;
dev_name = "/dev/ttyO3";
flow_cntrl = <1>;
baud_rate = <3000000>;
};
btwilink {
compatible = "btwilink";
};
};

&am33xx_pinmux {
bt_pins: pinmux_bt_pins {
pinctrl-single,pins = <
0x78 (PIN_OUTPUT_PULLUP | MUX_MODE7) /* gpmc_ad12.gpio1_28 BT_EN*/
>;
};

mmc3_pins: pinmux_mmc3_pins {
pinctrl-single,pins = <
0x8c ( PIN_INPUT_PULLUP | MUX_MODE3 ) /* gpio2_1 gpmc_clk.mmc2_clk */
0x88 ( PIN_INPUT_PULLUP | MUX_MODE3) /* gpio2_0 gpmc_csn3.mmc2_cmd */
0x30 ( PIN_INPUT_PULLUP | MUX_MODE3 ) /* gpio1_12 gpmc_ad12.mmc2_dat0 */
0x34 ( PIN_INPUT_PULLUP | MUX_MODE3 ) /* gpio1_13 gpmc_ad13.mmc2_dat1 */
0x38 ( PIN_INPUT_PULLUP | MUX_MODE3 ) /* gpio1_14 gpmc_ad14.mmc2_dat2 */
0x3c ( PIN_INPUT_PULLUP | MUX_MODE3 ) /* gpio1_15 gpmc_ad15.mmc2_dat3 */
>;
};

mmc3_pins_sleep: pinmux_mmc3_pins_sleep {
pinctrl-single,pins = <
0x8c (PIN_INPUT_PULLDOWN | MUX_MODE7) /* gpio2_1 gpmc_clk.mmc2_clk */
0x88 (PIN_INPUT_PULLDOWN | MUX_MODE7) /* gpio2_0 gpmc_csn3.mmc2_cmd */
0x30 (PIN_INPUT_PULLDOWN | MUX_MODE7) /* gpio1_12 gpmc_ad12.mmc2_dat0 */
0x34 (PIN_INPUT_PULLDOWN | MUX_MODE7) /* gpio1_13 gpmc_ad13.mmc2_dat1 */
0x38 (PIN_INPUT_PULLDOWN | MUX_MODE7) /* gpio1_14 gpmc_ad14.mmc2_dat2 */
0x3c (PIN_INPUT_PULLDOWN | MUX_MODE7) /* gpio1_15 gpmc_ad15.mmc2_dat3 */
>;
};

/* wl18xx card enable/irq GPIOs. */
wlan_pins: pinmux_wlan_pins {
pinctrl-single,pins = <
0x28 (PIN_OUTPUT_PULLDOWN | MUX_MODE7) /* gpmc_ad10.gpio0_26 WL_EN*/
0x2C (PIN_INPUT_PULLUP | MUX_MODE7) /* gpmc_ad11.gpio0_27 WL_IRQ*/
0x7C (PIN_OUTPUT_PULLUP | MUX_MODE0) /* gpmc_csn0.gpio1_29 Cape_Buffer_EN*/
>;
};

/* wl18xx card enable/irq GPIOs. */
wlan_pins_sleep: pinmux_wlan_pins_sleep {
pinctrl-single,pins = <
0x28 (PIN_OUTPUT_PULLUP | MUX_MODE7) /* gpmc_ad10.gpio0_26 WL_EN*/
0x2C (PIN_INPUT_PULLUP | MUX_MODE7) /* gpmc_ad11.gpio0_27 WL_IRQ*/
0x7C (PIN_OUTPUT_PULLUP | MUX_MODE0) /* gpmc_csn0.gpio1_29 Cape_Buffer_EN*/
>;
};

uart3_pins_default: pinmux_uart3_pins_default {
pinctrl-single,pins = <
0x134 ( PIN_INPUT_PULLUP | MUX_MODE1 ) /* (L17) gmii1_rxd3.uart3_rxd */
0x138 ( PIN_OUTPUT_PULLDOWN | MUX_MODE1 ) /* (L16) gmii1_rxd2.uart3_txd */
0x148 ( PIN_INPUT | MUX_MODE3 ) /* (M17) mdio_data.uart3_ctsn */
0x14c ( PIN_OUTPUT_PULLDOWN | MUX_MODE3 ) /* (M18) mdio_clk.uart3_rtsn */
>;
};

uart3_pins_sleep: pinmux_uart3_pins_sleep {
pinctrl-single,pins = <
0x134 (PIN_INPUT_PULLDOWN | MUX_MODE7) /* (L17) gmii1_rxd3.uart3_rxd */
0x138 (PIN_INPUT_PULLDOWN | MUX_MODE7) /* (L16) gmii1_rxd2.uart3_txd */
0x148 (PIN_INPUT_PULLDOWN | MUX_MODE7) /* (M17) mdio_data.uart3_ctsn */
0x14c (PIN_INPUT_PULLDOWN | MUX_MODE7) /* (M18) mdio_clk.uart3_rtsn */

>;
};
};

/* edma changed: in v4.1.x-ti branch: http://git.ti.com/gitweb/?p=ti-linux-kernel/ti-linux-kernel.git;a=commitdiff;h=bbbe675015664dc1e6fdac1421645a17f70afca6;hp=5b262677a892ca6da5486ece6cbb390af094df40 */

&mmc3 {

dmas = <&edma_xbar 12 0 1
&edma_xbar 13 0 2>;
dma-names = "tx", "rx";
status = "okay";
//vmmc-supply = <&wlan_en_reg>;
vmmc-supply = <&vmmcsd_fixed>;
bus-width = <4>;
pinctrl-names = "default", "sleep";
pinctrl-0 = <&mmc3_pins &wlan_pins>;
pinctrl-1 = <&mmc3_pins_sleep &wlan_pins_sleep>;
ti,non-removable;
ti,needs-special-hs-handling;
cap-power-off-card;
keep-power-in-suspend;

#address-cells = <1>;
#size-cells = <0>;
wlcore: wlcore@0 {
compatible = "ti,wl1835";
reg = <2>;
interrupt-parent = <&gpio0>;
interrupts = <27 IRQ_TYPE_LEVEL_HIGH>;
};
};

&gpio0 {
wl_en {
gpio-hog;
gpios = <26 GPIO_ACTIVE_HIGH>;
output-high;
line-name = "WL_EN";
};
};

&uart3 {
pinctrl-names = "default", "sleep";
pinctrl-0 = <&uart3_pins_default>;
pinctrl-1 = <&uart3_pins_sleep>;
status = "okay";
};
1 change: 1 addition & 0 deletions src/arm/am335x-bonegreen.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include "am33xx.dtsi"
#include "am335x-bone-common.dtsi"
#include "am33xx-overlay-edma-fix.dtsi"

/ {
model = "TI AM335x BeagleBone Green";
Expand Down
9 changes: 2 additions & 7 deletions src/arm/am335x-evm.dts
Original file line number Diff line number Diff line change
Expand Up @@ -855,8 +855,8 @@
&mmc3 {
/* these are on the crossbar and are outlined in the
xbar-event-map element */
dmas = <&edma 12
&edma 13>;
dmas = <&edma_xbar 12 0 1
&edma_xbar 13 0 2>;
dma-names = "tx", "rx";
status = "okay";
vmmc-supply = <&wlan_en_reg>;
Expand All @@ -879,11 +879,6 @@
};
};

&edma {
ti,edma-xbar-event-map = /bits/ 16 <1 12
2 13>;
};

&sham {
status = "okay";
};
Expand Down
Loading