说明
板子——skyEmbed,imx6q-sabresd
移植——kernel:4.1.3,uboot:3.14.28
具体情况
我想利用修改dts文件内容实现驱动移植,先上参考文档:http: //blog.csdn.net/girlkoo/article/details/45652209[/url]
我按照博客所介绍的内容操作,其他的驱动移植没有问题,唯独usb host驱动移植测试不通过(插入u盘没有反应),在自己的dts文件中添加的代码是(reg_usb_h1_vbus、reg_usb_otg_vbus和):
/{
。。。
regulators {
compatible = "simple-bus";
#address-cells = <1>;
#size-cells = <0>;
reg_usb_otg_vbus: regulator@0 {
compatible = "regulator-fixed";
reg = <0>;
regulator-name = "usb_otg_vbus";
regulator-min-microvolt = <5000000>;
regulator-max-microvolt = <5000000>;
gpio = <&gpio7 1 0>;
enable-active-high;
vin-supply = <&swbst_reg>;
};
reg_usb_h1_vbus: regulator@1 {
compatible = "regulator-fixed";
reg = <1>;
regulator-name = "usb_h1_vbus";
regulator-min-microvolt = <5000000>;
regulator-max-microvolt = <5000000>;
gpio = <&gpio1 20 0>;
enable-active-high;
vin-supply = <&swbst_reg>;
};
};
};
&usbh1 {
vbus-supply = <®_usb_h1_vbus>;
status = "okay";
};
&usbotg {
vbus-supply = <®_usb_otg_vbus>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_usbotg>;
disable-over-current;
status = "okay";
};
&iomuxc {
pinctrl-names = "default";
imx6qdl-sabresd {
pinctrl_usbotg: usbotggrp {
fsl,pins = <
MX6QDL_PAD_ENET_RX_ER__USB_OTG_ID 0x17059
>;
};
};
};
启动kernel时提示内容为
//截取部分
input: gpio-keys as /devices/soc0/gpio-keys/input/input0
hctosys: unable to open rtc device (rtc0)
usb_h1_vbus: disabling
usb_otg_vbus: disabling
我基础小白,请大神指点,谢谢。 |