您的位置:首页 > 移动开发 > Android开发

TW6869 drivers porting for freescaleandroid

2017-09-18 15:04 991 查看
TW6869调试

驱动代码见附件patch.

配置内核参数config----------imx_v7_android_defconfig

t

修改设备树

#

# Bus support

#

CONFIG_ARM_AMBA=y

CONFIG_PCI=y

CONFIG_PCI_DOMAINS=y

CONFIG_PCI_SYSCALL=y

# CONFIG_PCI_MSI is not set

# CONFIG_PCI_DEBUG is not set

# CONFIG_PCI_REALLOC_ENABLE_AUTO is not set

# CONFIG_PCI_STUB is not set

# CONFIG_PCI_IOV is not set

# CONFIG_PCI_PRI is not set

# CONFIG_PCI_PASID is not set

#

# PCI host controller drivers

#

CONFIG_PCIE_DW=y

CONFIG_PCI_IMX6=y

# CONFIG_EP_MODE_IN_EP_RC_SYS is not set

# CONFIG_RC_MODE_IN_EP_RC_SYS is not set

# CONFIG_PCI_HOST_GENERIC is not set

CONFIG_PCIEPORTBUS=y

# CONFIG_PCIEAER is not set

# CONFIG_PCIEASPM is not set

CONFIG_PCIE_PME=y

# CONFIG_PCCARD is not se


 --------------for imx6qdl-sabresd-roadj.dtsi          

&pcie {

//power-on-gpio = <&gpio6 8 0>; //no power control-pin

reset-gpio = <&gpio3 30 0>;

status = "okay";

};


---------------for imx6qdl.dtsi                                                                                                                                                                                                                                                                                                                                                                           
 

intc: interrupt-controller@00a01000 {

compatible = "arm,cortex-a9-gic";

#interrupt-cells = <3>;

//#address-cells = <1>; -----------------canceled by lqy for tw6869 irq request------------------

//#size-cells = <1>; -----------------canceled by lqy for tw6869 irq request------------------

interrupt-controller;

reg = <0x00a01000 0x1000>,

<0x00a00100 0x100>;

};

....

pcie: pcie@0x01000000 {

compatible = "fsl,imx6q-pcie", "snps,dw-pcie";

reg = <0x01ffc000 0x4000>, <0x01f00000 0x80000>;

reg-names = "dbi", "config";

#address-cells = <3>;

#size-cells = <2>;

device_type = "pci";

ranges = <0x81000000 0 0          0x01f80000 0 0x00010000 /* downstream I/O */

0x82000000 0 0x01000000 0x01000000 0 0x00f00000>; /* non-prefetchable memory */

num-lanes = <1>;

interrupts = <0 120 IRQ_TYPE_LEVEL_HIGH>;

//interrupt-names = "msi"; -----------------canceled by lqy for tw6869 irq request------------------

#interrupt-cells = <1>;

interrupt-map-mask = <0 0 0 0x7>;

interrupt-map = <0 0 0 1 &intc 0 123 IRQ_TYPE_LEVEL_HIGH>,

<0 0 0 2 &intc 0 122 IRQ_TYPE_LEVEL_HIGH>,

<0 0 0 3 &intc 0 121 IRQ_TYPE_LEVEL_HIGH>,

<0 0 0 4 &intc 0 120 IRQ_TYPE_LEVEL_HIGH>;

clocks = <&clks IMX6QDL_CLK_PCIE_REF_125M>,

<&clks IMX6QDL_CLK_SATA_REF_100M>,

<&clks IMX6QDL_CLK_LVDS1_GATE>, <&clks IMX6QDL_CLK_PCIE_AXI>;

clock-names = "pcie_phy", "ref_100m", "pcie_bus", "pcie";

status = "disabled";

};


测试代码及命令

见附件main.cpp 测试代码为模块编译,未加入到系统中。

cd data

./v4l2_test -d /dev/video4

测试代码详见http://download.csdn.net/download/sunny_hu92/10119162

TW6869驱动http://download.csdn.net/download/sunny_hu92/10119218
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: