jihongdang
驱动牛犊
驱动牛犊
  • 注册日期2002-09-30
  • 最后登录2010-04-21
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
阅读:2799回复:2

我有WindRiver的Tech Tip,拿出来跟大家共享交流

楼主#
更多 发布于:2002-11-02 20:58
Configuring vxWorks with both a BSD and an END driver

Problem Description

1. To build a bootrom from which it is possible to boot from either a specific BSD 4.4 \"fei\" driver or \"elPCI\" END driver, and  

2. To attach a second BSD or END interface.

This procedure is specific to the x86 targets, but the principles can be applied to any BSP.

最新喜欢:

beamdavebeamda...
jihongdang
驱动牛犊
驱动牛犊
  • 注册日期2002-09-30
  • 最后登录2010-04-21
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
沙发#
发布于:2002-11-02 21:01
Problem Solution (1)
To configure a  bootrom and runtime image that supported both the BSD fei driver and elPci END driver, the following changes were made to the \"Network driver options\" section of config.h:

#define INCLUDE_BSD   /* Must be added for BSD44 support */
#define    INCLUDE_END
...

/* INCLUDE_FEI is normally defined by default
* Verify that it is defined.
*/

#define    INCLUDE_FEI /* include Intel Ether Express PRO100B PCI */
...

/* EL_3C90x_END was defined.  
* This card only as an END driver.
* All other network interfaces were undef\'ed.
*/

#define INCLUDE_EL_3C90X_END    /* 3com fast etherLink XL PCI */


/* Remove or comment the #ifdef INCLUDE_END
* Make sure COMM_TYPE is COMM_NETWORK
*/
/* #ifdef INCLUDE_END */

#   undef  WDB_COMM_TYPE
#   define WDB_COMM_TYPE    WDB_COMM_NETWORK  

/* Finally, comment out the following so the END driver
* is not used.  
* This is to demonstrate the target can boot with a
* BSD driver and that both BSD and END can co-exist.
*/
/*
#   ifdef INCLUDE_FEI
#    undef INCLUDE_FEI    
#    define INCLUDE_FEI_END    
#   endif
*/

No changes were made to configNet.h, although based on the specific BSD and configNet.h this might be necessary.


A project was built based on the BSD where the modified config.h lived. VxWorks was configured with a downloaded symbol table and shell, show routines and network debugging facilities.
jihongdang
驱动牛犊
驱动牛犊
  • 注册日期2002-09-30
  • 最后登录2010-04-21
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
板凳#
发布于:2002-11-02 21:02
Problem Solution (2)

The target was first booted using the BSD44 \"fei\" driver.


Press any key to stop auto-boot...
0
auto-booting...


boot device          : fei
unit number          : 0
processor number     : 0
host name            : thor
file name            : d:/T2FCS/x86/target/proj/BSDEND/default/vxWorks
inet on ethernet (e) : 192.11.48.133:ffffff00
host inet (h)        : 192.11.48.33
user (u)             : bill
ftp password (pw)    : cigar
flags (f)            : 0x0
target name (tn)     : t48-133

Attaching network interface fei0... done.
Attaching network interface lo0... done.
Loading... 648848 + 34800 + 50012
Starting at 0x108000...

CaCould not find fei0
Attaching network interface fei0... done.
Attaching interface lo0...done
Loading symbol table from thor:d:/T2FCS/x86/target/proj/BSDEND/default/vxWorks.s
ym ...done


                 VxWorks

Copyright 1984-1998  Wind River Systems, Inc.

            CPU: PC 486
        VxWorks: 5.4
    BSP version: 1.2/0
  Creation date: Feb 15 2000
            WDB: Ready.


ifShow displays the fei interface:

-> ifShow
fei (unit number 0):
     Flags: (0x8163) UP BROADCAST MULTICAST PROMISCUOUS ARP RUNNING
     Type: ETHERNET_CSMACD
     Internet address: 192.11.48.133
     Broadcast address: 192.11.48.255
     Netmask 0xffff0000 Subnetmask 0xffffff00
     Ethernet address is 00:08:c7:08:34:b8
     Metric is 0
     Maximum Transfer Unit size is 1500
     600 packets received; 157 packets sent
     310 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
lo (unit number 0):
     Flags: (0x8069) UP LOOPBACK MULTICAST ARP RUNNING
     Type: SOFTWARE_LOOPBACK
     Internet address: 127.0.0.1
     Netmask 0xff000000 Subnetmask 0xff000000
     Metric is 0
     Maximum Transfer Unit size is 32768
     0 packets received; 0 packets sent
     0 multicast packets received
     0 multicast packets sent
     0 -

muxShow displays the elPci was already initialized and that the elPci is an END device.

-> muxShow
Device: elPci Unit: 0
Description: 3COM 3c90X Fast Etherlink Endhanced Network Driver.
value = 0 = 0x0


Next, the elPci interface is attached using the commands ipAttach, ifMaskSet and ifAddrSet, in this specific order:

-> ipAttach 0, \"elPci\"
value = 0 = 0x0
-> ifMaskSet \"elPci0\", 0xffffff00
value = 0 = 0x0
-> ifAddrSet \"elPci0\", \"192.192.192.192\"
value = 0 = 0x0

Again, ifShow displays both the \"fei\" and \"elPci\" interfaces.

-> ifShow
fei (unit number 0):
     Flags: (0x8163) UP BROADCAST MULTICAST PROMISCUOUS ARP RUNNING
     Type: ETHERNET_CSMACD
     Internet address: 192.11.48.133
     Broadcast address: 192.11.48.255
     Netmask 0xffff0000 Subnetmask 0xffffff00
     Ethernet address is 00:08:c7:08:34:b8
     Metric is 0
     Maximum Transfer Unit size is 1500
     839 packets received; 157 packets sent
     549 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
lo (unit number 0):
     Flags: (0x8069) UP LOOPBACK MULTICAST ARP RUNNING
     Type: SOFTWARE_LOOPBACK
     Type: SOFTWARE_LOOPBACK
     Netmask 0xff000000 Subnetmask 0xff000000
     Metric is 0
     Maximum Transfer Unit size is 32768
     0 packets received; 0 packets sent
     0 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
elPci (unit number 0):
     Flags: (0x8863) UP BROADCAST MULTICAST ARP RUNNING
     Type: ETHERNET_CSMACD
     Internet address: 192.192.192.192
     Broadcast address: 192.192.192.255
     Netmask 0xffffff00 Subnetmask 0xffffff00
     Ethernet address is 00:10:5a:7c:09:8d
     Metric is 0
     Maximum Transfer Unit size is 1500
     47 packets received; 1 packets sent
     47 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
value = 29 = 0x1d
->input errors; 0 output errors
     0 collisions; 0 dropped
value = 29 = 0x1d


Next, we\'ll demonstrate the target can boot with the same bootrom over the elPci END interface and the same vxWorks image can support an additional BSD interface as well.

boot device          : elPci
unit number          : 0
processor number     : 0
host name            : thor
file name            : d:/T2FCS/x86/target/proj/BSDEND/default/vxWorks
inet on ethernet (e) : 192.11.48.133:ffffff00
host inet (h)        : 192.11.48.33
user (u)             : babybush
ftp password (pw)    : cokehead
flags (f)            : 0x0
target name (tn)     : t48-133

Attached TCP/IP interface to elPci0.
Attaching network interface lo0... done.
Loading... 648848 + 34800 + 50012
Starting at 0x108000...

CaAttached TCP/IP interface to elPci unit 0
Attaching interface lo0...done
Loading symbol table from thor:d:/T2FCS/x86/target/proj/BSDEND/default/vxWorks.s
ym ...done


                 VxWorks

Copyright 1984-1998  Wind River Systems, Inc.

            CPU: PC 486
        VxWorks: 5.4
    BSP version: 1.2/0
  Creation date: Feb 15 2000
            WDB: Ready.


-> muxShow
Device: elPci Unit: 0
Description: 3COM 3c90X Fast Etherlink Endhanced Network Driver.
Protocol: IP 4.4 ARP    Type: 2054      Recv 0x131258   Shutdown 0x1314c8
Protocol: IP 4.4 TCP/IP Type: 2048      Recv 0x131258   Shutdown 0x1313d8
value = 0 = 0x0


-> ifShow
elPci (unit number 0):
     Flags: (0x8863) UP BROADCAST MULTICAST ARP RUNNING
     Type: ETHERNET_CSMACD
     Internet address: 192.11.48.133
     Broadcast address: 192.11.48.255
     Netmask 0xffff0000 Subnetmask 0xffffff00
     Ethernet address is 00:10:5a:7c:09:8d
     Metric is 0
     Maximum Transfer Unit size is 1500
     389 packets received; 157 packets sent
     99 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
lo (unit number 0):
     Flags: (0x8069) UP LOOPBACK MULTICAST ARP RUNNING
     Type: SOFTWARE_LOOPBACK
     Internet address: 127.0.0.1
     Netmask 0xff000000 Subnetmask 0xff000000
     Metric is 0
     Maximum Transfer Unit size is 32768
     0 packets received; 0 packets sent
     0 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
value = 29 = 0x1d


This time, the additional interface is a BSD4.4 device, and usrNetIfAttach and usrNetIfConfig are used to attach the \"fei\" interface and assign an IP address and subnetmask.


-> usrNetIfAttach \"fei\",0,\"192.192.192.192\"
Attaching network interface fei0... done.
value = 0 = 0x0
-> usrNetIfConfig \"fei\", 0, \"192.192.192.192\", \"t48-133\", 0xffffff00
value = 0 = 0x0

ifShow displays all interfaces:

-> ifShow
elPci (unit number 0):
     Flags: (0x8863) UP BROADCAST MULTICAST ARP RUNNING
     Type: ETHERNET_CSMACD
     Internet address: 192.11.48.133
     Broadcast address: 192.11.48.255
     Netmask 0xffff0000 Subnetmask 0xffffff00
     Ethernet address is 00:10:5a:7c:09:8d
     Metric is 0
     Maximum Transfer Unit size is 1500
     1314 packets received; 157 packets sent
     1024 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
lo (unit number 0):
     Flags: (0x8069) UP LOOPBACK MULTICAST ARP RUNNING
     Type: SOFTWARE_LOOPBACK
     Internet address: 127.0.0.1
     Netmask 0xff000000 Subnetmask 0xff000000
     Metric is 0
     Maximum Transfer Unit size is 32768
     0 packets received; 0 packets sent
     0 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
fei (unit number 0):
     Flags: (0x8163) UP BROADCAST MULTICAST PROMISCUOUS ARP RUNNING
     Type: ETHERNET_CSMACD
     Internet address: 192.192.192.192
     Broadcast address: 192.192.192.255
     Netmask 0xffffff00 Subnetmask 0xffffff00
     Ethernet address is 00:08:c7:08:34:b8
     Metric is 0
     Maximum Transfer Unit size is 1500
     132 packets received; 2 packets sent
     132 multicast packets received
     0 multicast packets sent
     0 input errors; 0 output errors
     0 collisions; 0 dropped
value = 29 = 0x1d
->
游客

返回顶部