#17997: [PATCH] lantiq - vgv7519 fix gphy0 led, enable pci-bus, make minipci
visible
-------------------------+----------------------------------
 Reporter:  anonymous    |      Owner:  developers
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Chaos Calmer (trunk)
Component:  base system  |    Version:  Trunk
 Keywords:               |
-------------------------+----------------------------------
 vgv7519 dts have some issue with open-drain configuration and gpio7
 configured as function pci while should be gphy.

 By fixing this, pci bus start workning.

 Please apply following patch that make minipci wifi card visible.

 Still need some work to get wifi running.

 {{{
 root@OpenWrt:/lib/firmware# lspci
 00:0e.0 Class 0280: 1814:3091

 dmesg | grep pci
 [    1.204000] PCI host bridge to bus 0000:00
 [    1.208000] pci_bus 0000:00: root bus resource [mem
 0x18000000-0x19ffffff]
 [    1.212000] pci_bus 0000:00: root bus resource [io
 0x1ae00000-0x1affffff]
 [    1.216000] pci_bus 0000:00: No busn resource found for root bus, will
 use [bus 00-ff]
 [    1.220000] pci 0000:00:0e.0: [1814:3091] type 00 class 0x028000
 [    1.220000] pci 0000:00:0e.0: reg 0x10: [mem 0xffff0000-0xffffffff]
 [    1.220000] pci_bus 0000:00: busn_res: [bus 00-ff] end is updated to 00
 [    1.220000] pci 0000:00:0e.0: BAR 0: assigned [mem
 0x18000000-0x1800ffff]
 [    1.224000] ifx_pcie_bios_map_irq port 0 dev 0000:00:0e.0 slot 14 pin 1
 [    1.228000] ifx_pcie_bios_map_irq dev 0000:00:0e.0 irq 144 assigned
 [    1.284000] PCI: CLS 0 bytes, default 32
 [    8.040000] PCI: Enabling device 0000:00:0e.0 (0000 -> 0002)

 root@OpenWrt:/lib/firmware# iw dev wlan0 info
 Interface wlan0
         ifindex 6
         wdev 0x100000001
         addr 00:0c:43:30:92:00
         type managed
         wiphy 1

 dmesg | tail
 [  111.056000] rt2800pci 0000:00:0e.0: failed to load eeprom property
 [  111.060000] ieee80211 phy1: rt2x00lib_request_eeprom_file: Info -
 Loading EEPROM data from 'RT2860.eeprom'.
 [  111.072000] ieee80211 phy1: rt2x00_set_rt: Info - RT chipset 5392, rev
 0223 detected
 [  111.080000] ieee80211 phy1: rt2x00_set_rf: Info - RF chipset 5392
 detected
 [  111.088000] ieee80211 phy1: Selected rate control algorithm
 'minstrel_ht'
 [  178.296000] ieee80211 phy1: rt2x00lib_request_firmware: Info - Loading
 firmware file 'rt2860.bin'
 [  178.304000] ieee80211 phy1: rt2x00lib_request_firmware: Info - Firmware
 detected - version: 0.34

 root@OpenWrt:/lib/firmware# iw dev wlan0 scan
 [  785.124000] ieee80211 phy1: rt2x00queue_flush_queue: Warning - Queue 0
 failed to flush
 [  785.288000] ieee80211 phy1: rt2x00queue_flush_queue: Warning - Queue 0
 failed to flush
 root@OpenWrt:/lib/firmware# [  786.512000] ieee80211 phy1:
 rt2x00queue_flush_queue: Warning - Queue 0 failed to flush


 }}}


 {{{
 diff --git a/target/linux/lantiq/xrx200/config-3.14
 b/target/linux/lantiq/xrx200/config-3.14
 index 959bf6a..3d525a4 100644
 --- a/target/linux/lantiq/xrx200/config-3.14
 +++ b/target/linux/lantiq/xrx200/config-3.14
 @@ -44,7 +44,7 @@ CONFIG_MTD_UBI_GLUEBI=y
  CONFIG_MTD_UBI_WL_THRESHOLD=4096
  CONFIG_NLS=y
  CONFIG_PCIE_LANTIQ=y
 -# CONFIG_PCI_LANTIQ is not set
 +CONFIG_PCI_LANTIQ=y
  # CONFIG_PROC_DEVICETREE is not set
  # CONFIG_RCU_STALL_COMMON is not set
  CONFIG_RTL8306_PHY=y
 diff --git a/target/linux/lantiq/dts/VGV7519.dtsi
 b/target/linux/lantiq/dts/VGV7519.dtsi
 index 3f56d82..52f9402 100644
 --- a/target/linux/lantiq/dts/VGV7519.dtsi
 +++ b/target/linux/lantiq/dts/VGV7519.dtsi
 @@ -63,12 +63,19 @@
                                                         "io21",
                                                         "io33",
                                                         "io7", "io44"; /*
 Internal ethernet phy leds */
 -                                       lantiq,open-drain;
                                         lantiq,pull = <0>;
                                         lantiq,output = <1>;
                                 };
 -                               pcie-rst {
 -                                       lantiq,pins = "io38";
 +                               pci-rst {
 +                                       lantiq,pins = "io21";
 +                                       lantiq,open-drain = <0>;
 +                                       lantiq,pull = <0>;
 +                                       lantiq,output = <1>;
 +                               };
 +                               gphy-leds {
 +                                       lantiq,groups = "gphy0 led1";
 +                                       lantiq,function = "gphy";
 +                                       lantiq,open-drain = <0>;
                                         lantiq,pull = <0>;
                                         lantiq,output = <1>;
                                 };
 @@ -90,6 +97,7 @@
                         >;
                         interrupt-parent = <&icu0>;
                         interrupts = <73 72>;
 +                       lantiq,nostripfcs;

                         lan: interface@0 {
                                 compatible = "lantiq,xrx200-pdi";
 @@ -192,10 +200,11 @@
                 };

                 pci@E105400 {
 +                       status = "okay";
                         #address-cells = <3>;
                         #size-cells = <2>;
                         #interrupt-cells = <1>;
 -                       compatible = "lantiq,pci-xway1";
 +                       compatible = "lantiq,pci-xway";
 |
                         bus-range = <0x0 0x0>;
 |
                         ranges = <0x2000000 0 0x8000000 0x8000000 0
 0x2000000   /* pci memory */
 |
                                 0x1000000 0 0x00000000 0xAE00000 0
 0x200000>; /* io space */
 |
 @@ -209,7 +218,7 @@
 |
                         interrupt-map = <
 |
                                 0x7000 0 0 1 &icu0 29 1 // slot 14, irq 29
 |
                                 >;
 |
 -                       gpios-reset = <&gpio 21 0>;
 |
 +                       gpio-reset = <&gpio 21 0>;
 |
                         req-mask = <0x1>;       /* GNT1 */
 |
                 };
 |
         };
 |
 @@ -220,6 +229,11 @@
 |
                 phys = [ 00 01 ];
 |
         };
 |
 |
 +       ralink_eep {
 |
 +               compatible = "ralink,eeprom";
 |
 +               ralink,eeprom = "RT2860.eeprom";
 |
 +       };
 |
 +
 |
         gpio-keys-polled {
 |
                 compatible = "gpio-keys-polled";
 |
                 #address-cells = <1>;
 }}}

--
Ticket URL: <https://dev.openwrt.org/ticket/17997>
OpenWrt <http://openwrt.org>
Opensource Wireless Router Technology
_______________________________________________
openwrt-tickets mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-tickets

Reply via email to