This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

USB RNDIS network up! : *** ERROR: serverip not set

Other Parts Discussed in Thread: UNIFLASH, FLASHTOOL

Hi Team,

am using beagle bone black and kernel 3.12 my task is to emmc flash through uniflash,i fallow the steps fallow links :

all images saved in one folder in my windows pc and started the flashing after some time flashing progress will 27% after it will stop and u-boot prompt will get .


u-boot log file ::

CCCCCCCC
U-Boot SPL 2013.10-00189-g78d8ebd-dirty (Apr 20 2015 - 11:45:02)
Using default environment

usb_ether
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC d0:39:72:4b:b4:37
HOST MAC de:ad:be:af:00:00
RNDIS ready
musb-hdrc: peripheral reset irq lost!
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
BOOTP broadcast 1
BOOTP broadcast 2
Using usb_ether device
TFTP from server 192.168.2.1; our IP address is 192.168.2.4
Filename 'u-boot-restore.img'.
Load address: 0x807fffc0
Loading: ###########################
         731.4 KiB/s
done
Bytes transferred = 389780 (5f294 hex)


U-Boot 2013.10-00189-g78d8ebd-dirty (Apr 20 2015 - 11:45:02)

I2C:   ready
DRAM:  512 MiB
NAND:  0 MiB
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
*** Error - No Valid Environment Area found
*** Warning - bad CRC, using default environment

Net:   <ethaddr> not set. Validating first E-fuse MAC
cpsw, usb_ether
Hit any key to stop autoboot:  0
Card did not respond to voltage select!
mmc0(part 0) is current device
Scanning mmc 0...
Card did not respond to voltage select!
** Bad device mmc 0 **
Card did not respond to voltage select!
mmc0(part 0) is current device
Card did not respond to voltage select!
mmc1(part 0) is current device
SD/MMC found on device 1
Failed to mount ext2 filesystem...
** Unrecognized filesystem type **
** Invalid partition 2 **
Booting from nand ...

no devices available

no devices available
Bad Linux ARM zImage magic!

****************************************************************************************

After this in u-bot prompt attempt some commands give below :

U-Boot# setenv ethact usb_ether


U-Boot# dhcp
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC d0:39:72:4b:b4:39
HOST MAC de:ad:be:af:00:00
RNDIS ready
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
BOOTP broadcast 1
BOOTP broadcast 2
DHCP client bound to address 192.168.2.5
Using usb_ether device
TFTP from server 192.168.2.1; our IP address is 192.168.2.5
Filename 'uImage'.
Load address: 0x80200000
Loading: *
TFTP error: 'File not found or No Access' (1)
Not retrying...


U-Boot# run findfdt


U-Boot# tftp ${fdtaddr} ${fdtfile}
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC d0:39:72:4b:b4:39
HOST MAC de:ad:be:af:00:00
RNDIS ready
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
*** ERROR: `serverip' not set
U-Boot# bootz ${loadaddr} - ${fdtaddr}
Bad Linux ARM zImage magic!
U-Boot#

******************************************************************************************

i have enter command it will not work but i did not get any idea about this problem

*** After getting  u-boot prompt in window pc ,  i check in device manager disappear ip address and ethernet/rndis device name....... why it will disable directly ???????

** if any changes needed in u-boot or kernel ???

please reply me ....

Regards,

Naveen.

  • Moving this to the Sitara forum.
  • Naveen,

    It looks like your u-boot is configured to download "uImage" within the dhcp command. That is failing. Try to tftp the kernel with:

    tftp ${loadaddr} zImage

    I'm not sure why you are getting the serverip not set. I believe that is done by the dhcp command. If you have to, you can always set it:

    setenv serverip 192.168.2.1

    The bootz command is failing because neither the kernel (zImage) nor the devicetree file were successfully transferred.

  • Hi RonB,

    Thanks for your suggestions.

    once u-boot successfully come up the RNDIS Network port is disconnection  from host pc because of this unable to load

    zImage . i have defined   the following in u-boot (include/configs/am335x_evm.h). 

    CONFIG_SPL_MUSB_NEW_SUPPORT

    CONFIG_MUSB_GADGET
     CONFIG_USB_ETHER
     CONFIG_USB_ETH_RNDIS
     CONFIG_USBNET_HOST_ADDR "de:ad:be:af:00:00"

    Is there anything needs to be defined or set ?

    Regards,

    Naveen

  • Hi Team,

    Regarding above question it urgent requirement please reply me ...


    Regards,

    Naven

  • Naveen,

    You should be able to stop U-Boot at the prompt? If so, it will bring USB back up if needed, in order to run the commands that I suggested.

  • Hi RonB,

    Thanks for your suggestions.


    i run below commands in u-boot prompt  :

    U-Boot# setenv serverip 192.168.2.1
    U-Boot# setenv ethact usb_ether
    U-Boot# run findfdt
    U-Boot# tftp ${fdtaddr} ${fdtfile}
                   using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
                   MAC d0:39:72:3b:89:50
                   HOST MAC de:ad:be:af:00:00
                   RNDIS ready
                   musb-hdrc: peripheral reset irq lost!
                   high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
                   USB RNDIS network up!
                  *** ERROR: `ipaddr' not set
    U-Boot# bootz ${loadaddr} - ${fdtaddr}
                    Bad Linux ARM zImage magic!

    when i run dhcp command in u-boot prompt :::

     U-Boot# dhcp

                     using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
                     MAC d0:39:72:3b:89:50
                     HOST MAC de:ad:be:af:00:00
                     RNDIS ready
                      high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
                      USB RNDIS network up!
                      BOOTP broadcast 1
                      BOOTP broadcast 2
                     DHCP client bound to address 192.168.2.4
                     Using usb_ether device
                     TFTP from server 192.168.2.1; our IP address is 192.168.2.4
                     Filename 'uImage'.
                    Load address: 0x80200000
                    Loading: *
                    TFTP error: 'File not found or No Access' (1)
                     Not retrying...

    *******    u-boot prompt comes because of some failure conditions  check error log file below ::

    U-Boot SPL 2013.10-00189-g78d8ebd-dirty (Apr 22 2015 - 13:13:01)
    Using default environment

    usb_ether
    using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
    MAC d0:39:72:3b:89:4e
    HOST MAC de:ad:be:af:00:00
    RNDIS ready
    musb-hdrc: peripheral reset irq lost!
    high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
    USB RNDIS network up!
    BOOTP broadcast 1
    BOOTP broadcast 2
    Using usb_ether device
    TFTP from server 192.168.2.1; our IP address is 192.168.2.2
    Filename 'u-boot-restore.img'.
    Load address: 0x807fffc0
    Loading: #######################
             431.6 KiB/s
    done
    Bytes transferred = 323380 (4ef34 hex)


    U-Boot 2013.10-00189-g78d8ebd-dirty (Apr 22 2015 - 13:13:01)

    I2C:   ready
    DRAM:  512 MiB
    MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
    Using default environment

    Net:   <ethaddr> not set. Validating first E-fuse MAC
    cpsw, usb_ether
    Hit any key to stop autoboot:  0
    Card did not respond to voltage select!
    mmc0(part 0) is current device
    Scanning mmc 0...
    Card did not respond to voltage select!
    ** Bad device mmc 0 **
    Card did not respond to voltage select!
    mmc0(part 0) is current device
    Card did not respond to voltage select!
    mmc1(part 0) is current device
    SD/MMC found on device 1
    Failed to mount ext2 filesystem...
    ** Unrecognized filesystem type **
    ** No partition table - mmc 1 **

    i send all log files can u check once ,if any find problem reply me .one more thing after u-boot prompt the windows pc disable the ip address (192.168.2.1).

    Regards,

    Naven

  • Naveen,

    Before you run dhcp, can you run this at a u-boot prompt:

    setenv autoload no

    This will stop trying to get the uImage and allow you to tftp the zImage and fdt file.
  • Hi RonB,

    Thanks for Reply,

    After set  command "setenv autoload no"  working properly.

    but problem is usb0 is not configured in kernel  when i check ifconfig command it will shows only eth0 and lo.

    i build the kernel given link :

    statically build the kernel but not shown in usb0 and dynamically build the kernel and load  "insmod g_ether.ko"

    but it will get error ::

    root@am335x-evm:/home# insmod g_ether.ko
    [  216.523760] g_ether: Unknown symbol usb_get_function_instance (err 0)
    [  216.531227] g_ether: Unknown symbol usb_string_ids_tab (err 0)
    [  216.537371] g_ether: Unknown symbol usb_get_function (err 0)
    [  216.543583] g_ether: Unknown symbol usb_composite_unregister (err 0)
    [  216.550475] g_ether: Unknown symbol gether_set_dev_addr (err 0)
    [  216.556701] g_ether: Unknown symbol usb_put_function (err 0)
    [  216.562831] g_ether: Unknown symbol rndis_borrow_net (err 0)
    [  216.568898] g_ether: Unknown symbol usb_add_function (err 0)
    [  216.574846] g_ether: Unknown symbol usb_composite_probe (err 0)
    [  216.581219] g_ether: Unknown symbol gether_register_netdev (err 0)
    [  216.587824] g_ether: Unknown symbol usb_composite_overwrite_options (err 0)
    [  216.595140] g_ether: Unknown symbol gether_set_qmult (err 0)
    [  216.601235] g_ether: Unknown symbol gether_set_gadget (err 0)
    [  216.607280] g_ether: Unknown symbol usb_put_function_instance (err 0)
    [  216.614231] g_ether: Unknown symbol gether_set_host_addr (err 0)
    [  216.620658] g_ether: Unknown symbol usb_add_config (err 0)
    insmod: can't insert 'g_ether.ko': unknown symbol in module, or unknown parameter


    * my kernel is 3.12 and Sitara Flasher Initramfs  kernel ()

    so how solve this problem and how usb0 will get ,when i configure usb0 it will get error :

    root@am335x-evm:/home# ifconfig usb0 192.168.2.1  netmask 255.255.255.0 up
    ifconfig: SIOCSIFADDR: No such device

    Regards,

    Naveen.

  • Naveen,

    p naveen kumar said:
    statically build the kernel but not shown in usb0

    Currently kernel 3.12+ has an issue that USB gadget driver built into the kernel is broken, which means usb0 interface will not show up if statically build g_ether into the kernel.

    p naveen kumar said:

    dynamically build the kernel and load  "insmod g_ether.ko" but it will get error ::

    Please use command 'modprobe g_ether' instead.

    g_ether.ko depends on other kernel modules which will be loaded automatically if use modprobe command.

  • Hi Bin Liu,

    when i use modprobe command :

    root@am335x-evm:/home# modprobe g_ether
    modprobe: chdir(3.12.10): No such file or directory

    Regards,
    Naveen
  • Naveen,

    I never saw modprobe complains about chdir, so not sure what it means. But are you sure you installed all the kernel modules correctly? How did you populate the kernel modules?

    After build the kernel you have to run '.... make module_install INSTALL_MOD_PATH=<your target filesystem location>'.
  • 1. make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- modules

    LD [M] drivers/usb/gadget/usb_f_ecm_subset.o

    LD [M] drivers/usb/gadget/usb_f_rndis.o

    LD [M] drivers/usb/gadget/g_ether.o

    2.sudo make ARCH=arm INSTALL_MOD_PATH=/home/naveen/Linux_TI modules_install

    INSTALL drivers/usb/gadget/g_ether.ko

    INSTALL drivers/usb/gadget/libcomposite.ko

    INSTALL drivers/usb/gadget/u_ether.ko

    INSTALL drivers/usb/gadget/u_rndis.ko

    INSTALL drivers/usb/gadget/usb_f_ecm.ko

    INSTALL drivers/usb/gadget/usb_f_ecm_subset.ko

    INSTALL drivers/usb/gadget/usb_f_rndis.ko

    INSTALL drivers/usb/misc/usbtest.ko

    After this steps i copied zImage and dtb file into " C:\AM335x_Flashtool\images " location

    i run uniflash tool ,After u-boot prompt run commands

    ex : setenv ethact usb_ether

    setenv autoload no; dhcp

    run findfdt; tftp ${fdtaddr} ${fdtfile}

    tftp 0x80200000 zImage

    bootz 0x80200000 - 0x88000000.

    after kernel up i run the command "modprobe g_ether"

    error :

    root@am335x-evm:/home# modprobe u_ether

    modprobe: chdir(3.12.10): No such file or directory
  • p naveen kumar said:
    after kernel up i run the command "modprobe g_ether"

    error :

    root@am335x-evm:/home# modprobe u_ether

    modprobe: chdir(3.12.10): No such file or directory

    Please attach your kernel boot log and the output of the following command in kernel prompt.

    root@am335x-evm:~# find /lib/modules -name g_ether.ko

  • Naveen,

    Since you are having to build modules, you'll need to rebuild the kernel again after installing the modules. The initramfs packages an archive inside the kernel and uses that for the file system. Since the modules haven't been built with the first kernel build, you need to re-run the make for the zImage to pick-up the changes to the filesystem after you do the make modules and make modules_install with the filesystem directory.

    The instructions on the wiki assumed that the modules were built into the kernel. I'm in the process of updating them now to account for using modules.
  • Hi RonB,

    Thanks for reply ....

    i fallow the above given steps now working properly .

    usb0 Link encap:Ethernet  HWaddr 66:7E:DB:7F:6C:AE
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:55 errors:0 dropped:0 overruns:0 frame:0
              TX packets:3 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000
              RX bytes:6751 (6.5 KiB)  TX bytes:1098 (1.0 KiB)

    After small changes in flasher scripts the load the images into emmc .

    but the problem is i manually every time apply the commands in u-boot level.

    Error :

    U-Boot 2013.10-00189-g78d8ebd-dirty (Apr 30 2015 - 16:26:10)

    I2C:   ready
    DRAM:  512 MiB
    MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
    Net:   cpsw, usb_ether
    Hit any key to stop autoboot:  0
    mmc1(part 0) is current device
    SD/MMC found on device 1
    Failed to mount ext2 filesystem...
    ** Unrecognized filesystem type **
    ** No partition table - mmc 1 **
    mmc1(part 0) is current device
    SD/MMC found on device 1
    Failed to mount ext2 filesystem...
    ** Unrecognized filesystem type **
    ** No partition table - mmc 1 **
    ## Error: "nandboot" not defined

    After this error u-boot prompt comes so i apply the below commands :

    setenv ethact usb_ether

    setenv autoload no; dhcp

    run findfdt; tftp ${fdtaddr} ${fdtfile}

    tftp 0x80200000 zImage

    bootz 0x80200000 - 0x88000000

    ***how to set default arguments in u-boot ,i try to change in "/include/configs/ti_armv7_common.h " file but it not set,

    without halt in u-boot prompt directly boot so which file i can change ???

    Regards,

    Naveen

     

  • Naven said:

    ***how to set default arguments in u-boot ,i try to change in "/include/configs/ti_armv7_common.h " file but it not set,

    without halt in u-boot prompt directly boot so which file i can change ???

    Naveen, it is great to see your progress. This question is specifically addressed for the document for SDK v7.0 here:

    http://processors.wiki.ti.com/index.php/Sitara_Linux_Program_the_eMMC_on_Beaglebone_Black#Modify_U-Boot_to_Boot_from_TFTP_Automatically

    A patch is provided to make these changes...

  • Hi RonB,

    Thanks for reply .........

    i fallow the  link :http://processors.wiki.ti.com/index.php/Sitara_Linux_Program_the_eMMC_on_Beaglebone_Black#Modify_U-Boot_to_Boot_from_TFTP_Automatically

    error log :

    CCCCCCCC
    U-Boot SPL 2013.10-00189-g78d8ebd-dirty (May 04 2015 - 10:58:56)
    Using default environment

    usb_ether
    using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
    MAC d0:39:72:4b:b4:37
    HOST MAC de:ad:be:af:00:00
    RNDIS ready
    musb-hdrc: peripheral reset irq lost!
    high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
    USB RNDIS network up!
    BOOTP broadcast 1
    BOOTP broadcast 2
    Using usb_ether device
    TFTP from server 192.168.2.1; our IP address is 192.168.2.3
    Filename 'u-boot-restore.img'.
    Load address: 0x807fffc0
    Loading: #######################
             498 KiB/s
    done
    Bytes transferred = 323628 (4f02c hex)


    U-Boot 2013.10-00189-g78d8ebd-dirty (May 04 2015 - 10:58:56)

    I2C:   ready
    DRAM:  512 MiB
    MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
    Net:   <ethaddr> not set. Validating first E-fuse MAC
    cpsw, usb_ether
    Hit any key to stop autoboot:  0
    Card did not respond to voltage select!
    mmc0(part 0) is current device
    Scanning mmc 0...
    Card did not respond to voltage select!
    ** Bad device mmc 0 **
    Card did not respond to voltage select!
    mmc0(part 0) is current device
    Card did not respond to voltage select!
    mmc1(part 0) is current device
    SD/MMC found on device 1
    Failed to mount ext2 filesystem...
    ** Unrecognized filesystem type **
    ** No partition table - mmc 1 **

    After apply patch same behavior and how to solve this problem and any changes needed .

    Regards,

    Naven

  • Hi RonB,

    Above error patch file not properly added .
    after adding patch file error log .

    I2C: ready
    DRAM: 512 MiB
    NAND: 0 MiB
    MMC: OMAP SD/MMC: 0, OMAP SD/MMC: 1
    *** Error - No Valid Environment Area found
    *** Warning - bad CRC, using default environment

    Net: <ethaddr> not set. Validating first E-fuse MAC
    cpsw, usb_ether
    Hit any key to stop autoboot: 0
    Boot from TFTP 1...
    using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
    MAC d0:39:72:4b:b4:39
    HOST MAC de:ad:be:af:00:00
    RNDIS ready
    musb-hdrc: peripheral reset irq lost!
    high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
    USB RNDIS network up!
    BOOTP broadcast 1
    BOOTP broadcast 2
    DHCP client bound to address 192.168.2.5
    using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
    MAC d0:39:72:4b:b4:39
    HOST MAC de:ad:be:af:00:00
    RNDIS ready
    ERROR: The remote end did not respond in time.
    at ether.c:2392/usb_eth_init()
    cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    Using cpsw device
    TFTP from server 192.168.2.1; our IP address is 192.168.2.5
    Filename 'am335x-boneblack.dtb'.
    Load address: 0x80f80000
    Loading: cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    T cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    T cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
    cpsw Waiting for PHY auto negotiation to complete......... TIMEOUT !
  • Hi Team,

    above posted query its urgent requirement for production please reply me ....

    Regards,
    Naven
  • The above problem because of timing issues so i added sleep in boot parameters .
    solve this problem.