15 Replies Latest reply on Nov 16, 2016 12:14 AM by DJL

    i210 Driver for VxWorks 5.5.1

    DJL Green Belt

      Hi,

       

      I am trying to get the i210 to work with the existing driver for the 82574 on VxWorks 5.5.1 which is built on the original 82643 driver.  Everything looks good (to me) but no data is actually transmitted.  The device appears to be able to receive ok as there is evidence in the counters and these match reasonably well with the counters in the Cisco switch for the port it is connected to. We have a link at both ends and auto-negotiation is successful.

       

      The VxWorks driver uses queue 0 only and it creates the context on each send.

       

      Below are the main registers of interest - VxWorks only modifies registers 0, 4 and 9 in the PHY.

       

      10:02:38 gei82543EndStart:Link is up

      10:02:38 phy  reg 0: 00001000

      10:02:38 phy  reg 1: 0000796d

      10:02:38 phy  reg 2: 00000141

      10:02:38 phy  reg 3: 00000c00

      10:02:38 phy  reg 4: 00000de1

      10:02:38 phy  reg 5: 000043e1

      10:02:38 phy  reg 6: 00000005

      10:02:38 phy  reg 7: 00002001

      10:02:38 phy  reg 8: 00000000

      10:02:38 phy  reg 9: 00000300

      10:02:38 phy  reg 10: 00004000

      10:02:38 phy  reg 15: 00003000

      10:02:38 phy  reg 17: 00007c08

      10:02:38 gei82543EndStart: TCTL is: a40400fa

      10:02:38 gei82543EndStart: STATUS is: 00280743

      10:02:38 gei82543EndStart: CTRL_EXT is: 101c0000

      10:02:38 gei82543EndStart: CTRL is: 00001941

      10:02:38 gei82543EndStart: IPCNFG is: 0000000f

      10:02:38 gei82543EndStart: PHPM is: 0000019d

      10:02:38 gei82543EndStart: TXDCTL is: 02010000

       

      I would appreciate any ideas as to what may cause this behaviour.

       

      Thank you.

        • Re: i210 Driver for VxWorks 5.5.1
          Carlos_A Brown Belt

          Hello DJL,

           

          Thank you for contacting the Intel Embedded Community.

           

          The VXWorks drivers are generally supported by their developer. You can confirm this information as a reference on page 3 of the Intel(R) BayTrail Product Brief.

           

          By the way, this Operating System (OS) is unlisted as a supported  by the Intel(R) Ethernet Controller I210 and Intel(R) 82574L/82574IT Gigabit Ethernet Controller. You can confirm this information at their Product Briefs that can be found at the following web sites:


          http://www.intel.com/content/dam/www/public/us/en/documents/product-briefs/i210-ethernet-controller-family-brief.pdf


          http://www.intel.com/content/dam/doc/product-brief/82574l-82574it-gbe-controller-brief.pdf

           

          Due to these facts, we suggest you contact the manufacturer of the cited driver to received further answers to your questions of this kind.

           

          On the other hand, could you please confirm that the 82643 part number is related to an Intel product? In case that your answer is affirmative, could you please send us documentation related to this device?

           

          Thanks in advance for your collaboration to solve this inconvenience.

           

          Best Regards,

          Carlos_A.

            • Re: i210 Driver for VxWorks 5.5.1
              DJL Green Belt

              Hello Carlos_A,

               

              Thank you for the information.

               

              The version of VxWorks that we are using in obsolete and no longer supported, hence the reason I am looking at adapting the existing driver to support the i210.

              The driver that we have is based on the original 82543 (not 82643 which was a typo) and has been developed (by Windriver) to include many Intel devices.  The source code for the drivers is supplied with the kernel to enable users to add to and modify as required.  Therefore, it is up to me get it working.

               

              I have now succeeded in transmitting (ARP requests) but for an as yet unknown reason the received data isn't populating the receive descriptor.  The VxWorks driver only uses legacy descriptors, so the devices are very similar.  I just need to find the write "spell" to complete the loop.  I had hoped that the Intel embedded community would be the best place to look for advice getting the i210 configured.

               

              Best regards,

               

              DJL

                • Re: i210 Driver for VxWorks 5.5.1
                  Carlos_A Brown Belt

                  Hello DJL,

                   

                  Thanks for your update.


                  In this instance, since you are trying to adapt an old driver on an unsupported OS to a new part, all we can suggest is that you look at the Linux driver that supports the i210 and compare to the driver you are attempting to modify as we have suggested. It’s fairly well documented within the code itself.


                  We suggest to address the questions related to this forum at the following mail list: e1000-devel@lists.sourceforge.net, where they may help you. 


                  Please let us know if this information is useful to you.


                  Best Regards,

                  Carlos_A.

                • Re: i210 Driver for VxWorks 5.5.1
                  xuxiong517 Community Member

                  Hello Carlos_A

                  I got the same problem like DJL,my i210 netcard can not receive,and when I send data to it, it can not cause trigger receive interrupt.

                  but i210 can trigger link and send interrupt.

                  can you solve the problem for me, thanks a lot!

                  Best Regards.

                • Re: i210 Driver for VxWorks 5.5.1
                  daiwei@0701 Community Member

                  Hello, DJL

                   

                  Thank you for your update. I am now trying to make the mpc8241 work with 82574 on the Vxworks5.5. The probem I am facing to is simliar to you. the status of phy and mac  is ok. the software have writed packet into the Context Transmit Descriptor, the STA.DD is set by 82574. but the packet isn't transmitted. How can you slove you probem.

                   

                  Thank you !

                    • Re: i210 Driver for VxWorks 5.5.1
                      DJL Green Belt

                      Hello daiwei@0701,

                       

                      Firstly I apologise for this delayed response - I have been a bit busy.

                      I am using x86 architecture so the driver I have may be different, although it does have a big endian option so could be the same.

                      For me the main problem for transmitting was the descriptor type definition - the i210 is completely different. 
                      I don't think this is your problem, however.


                      One thing I noticed in our driver is that the driver uses extended transmit descriptors, but the check sum offload is
                      disabled (there is a typedef missing so it can never by enabled!) and therefore no context descriptors were ever setup.
                      This could be an issue for you, but it didn't seem to have a detrimental affect for us.I tried it in legacy mode and it worked just fine.

                      The 82574 looks to be pretty much identical to the 82573, so if your driver supports this then you could try this option.

                      Adlink Technology did have a BSP for their (now obsolete) cPCI6870.  It may be possible to download it from their website - just a thought.

                      Best regards,

                      DJL

                        • Re: i210 Driver for VxWorks 5.5.1
                          xuxiong517 Community Member

                          Hello DJL,

                           

                          I am doing the similar works like you.The OS is vxworks5.5,original driver is 82574.Now, the driver with i210 can transmit data,but it can not receive data.

                          The key problem is that,i210 can't go to interrupt model when I send data to it. I set interrupt register IMS,receive register RXDCTL.But it can't cause interrupt.

                          I sure PCI interrupt is good,because link and send interrupt are both good.

                           

                          SO, can you tell me if there is some other register need to be set. How do you configure the i210 register.

                           

                          Best regards,

                          Xu Xiong

                            • Re: i210 Driver for VxWorks 5.5.1
                              DJL Green Belt

                              Hi Xu Xiong,

                               

                              The most important thing is that the receiver queue 0 must be enabled before writing to the RDT register (INTEL_82543GC_RDT).  The VxWorks driver can only use queue 0 and writes to RDT are ignored if the queue is not enabled first.

                               

                              You also need to enable the receive filter on queue zero in function gei82543EtherRxAdrSet

                               

                               

                              The i210 has a different interrupt delay timer.  I set EITR to 175us (175 << 2).

                               

                              Hope this helps.

                               

                              Best regards,

                               

                              DJL

                                • Re: i210 Driver for VxWorks 5.5.1
                                  xuxiong517 Community Member

                                  Hi DJL,

                                   

                                  Thank you very much.My problem has been solved according to your advise. The receiver queue 0 must be enabled before writing to the RDT register.

                                   

                                  Thanks again.

                                   

                                  Best regards,

                                   

                                  Xu Xiong

                                    • Re: i210 Driver for VxWorks 5.5.1
                                      DJL Green Belt

                                      Hi Xu Xiong,

                                       

                                      That's great, glad to help.

                                       

                                      Best regards,

                                       

                                      DJL

                                        • Re: i210 Driver for VxWorks 5.5.1
                                          xuxiong517 Community Member

                                          Hi DJL,

                                           

                                          I got a problem again.When I test i210 dirver for TCP socket,it can't communicate with PC server correctly.

                                           

                                          The client use connect() function connect to server.

                                           

                                          Wireshark capture tcp packet sent by i210 successfully. but it just can't connect.

                                           

                                          I guess I set the TCP/IP Context TX descriptor incorretly.

                                           

                                          Below is my configure.

                                           

                                          IPLEN : 20

                                          MACLEN :14

                                          Both values are got from mBlk structrue.

                                          L4T:1

                                          IPV4:1

                                          DTYP: 0010b

                                          DEXT:1

                                          IDX,L4LEN,MSS are not set.Because I don't use TCP Segmentation

                                           

                                          If I miss something else important for configuring the Context TX descriptor.

                                           

                                          Can you solve the problem for me.

                                           

                                          Thanks a lot

                                           

                                          Best regards,

                                           

                                          Xu Xiong

                                           

                                            • Re: i210 Driver for VxWorks 5.5.1
                                              DJL Green Belt

                                              Hi Xu Xiong,

                                               

                                              Sorry for the delay in response, but I have been away.

                                               

                                              You have to use the legacy tx data descriptor (DTYP = 0x3) as the Advanced descriptors are not supported by the rather old driver.  The 82574L uses Extended descriptors but these are completely different to the Advanced i210 descriptors and are not compatible.

                                               

                                              You need to modify "LOCAL void gei82543LoanTransmit" .  You will need to set TX_CMD_IFCS at the start too and there is no need to set TXD_CMD_IDE or TXD_CMD_DEXT either for the i210.

                                               

                                              At the end of this function you will need to set TXD_CMD_EOP and ensure that TXD_CMD_RS is set too.

                                               

                                              I set the TCTL_PSP_BIT in INTEL_82543GC_TCTL but not TCTL_MULR_BIT or TX_COLLISION_THRESHOLD  as the i210 does not have these.

                                               

                                              Hope this helps,

                                               

                                              DJL