Project Home
Project Home
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Problem with configure MPC8313 MAC address: (19 Items)
   
Problem with configure MPC8313 MAC address  
I am trying to configure the MAC address for MPC8313 target.

The BSP of MPC8313 use a fixed MAC address in the syspage, I have found two possible way to configure the MAC address we
 specify, but none of them works properly.

1) io-pkt-v4-hc -d mpc85xx mac=00123456789a
2)ifconfig tsec0 link 00:12:34:56:78:9a active

after either of the configureation above, all the packet sending out by the target is correctly, but the target seems 
get problem when pick up the reply packet.

For example:
A: windows XP (fresh rebooted), Wireshark to capture the communication paket, IP:192.168.3.254/24
B: our MPC8313 target, IP:192.168.3.151/24

When I ping from B to A:
B send out:
Summary:CamilleB_56:78:9a	Broadcast	ARP	Who has 192.168.3.254?  Tell 192.168.3.151
A reply:
Summary: Belkin_e7:77:eb	CamilleB_56:78:9a	ARP	192.168.3.254 is at 00:11:50:e7:77:eb
B send out:
Summary:CamilleB_56:78:9a	Broadcast	ARP	Who has 192.168.3.254?  Tell 192.168.3.151
A reply:
Summary: Belkin_e7:77:eb	CamilleB_56:78:9a	ARP	192.168.3.254 is at 00:11:50:e7:77:eb

B send out:
Summary:CamilleB_56:78:9a	Broadcast	ARP	Who has 192.168.3.254?  Tell 192.168.3.151
A reply:
Summary: Belkin_e7:77:eb	CamilleB_56:78:9a	ARP	192.168.3.254 is at 00:11:50:e7:77:eb

But B will never update it is arp table and get the MAC address of A.
when I use arp -a, and alway get:

# arp -a
? (192.168.3.254) at (incomplete) on tsec0
RE: Problem with configure MPC8313 MAC address  
Your mac address looks fine to me.

From what information you have provided, it
looks like you can transmit packets, but not
receive them.  If you run any of the below:

  # nicinfo
  # ifconfig -v
  # netstat -p ip

you can confirm this.  If in fact you are
simply not receiving any packets, I would look
at the hardware interrupt - either it's not
firing, or you're attached to the wrong one.

--
aboyd
Re: RE: Problem with configure MPC8313 MAC address  
Hi Andrew:

the out put of "ifconfig -v" and "netstat -p ip"

ifconfig -v

lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 33192
	input: 2 packets, 132 bytes
	output: 2 packets, 132 bytes
	inet 127.0.0.1 netmask 0xff000000
tsec0: flags=8a43<UP,BROADCAST,RUNNING,ALLMULTI,SIMPLEX,MULTICAST> mtu 1500
	capabilities rx=7<IP4CSUM,TCP4CSUM,UDP4CSUM>
	capabilities tx=0
	enabled=0
	address: 00:12:34:56:78:9a
	media: Ethernet none
	input: 19 packets, 1064 bytes
	output: 77 packets, 4168 bytes, 53 multicasts
	inet 192.168.3.7 netmask 0xffffff00 broadcast 192.168.3.255
tsec1: flags=8a43<UP,BROADCAST,RUNNING,ALLMULTI,SIMPLEX,MULTICAST> mtu 1500
	capabilities rx=7<IP4CSUM,TCP4CSUM,UDP4CSUM>
	capabilities tx=0
	enabled=0
	address: 00:12:34:56:78:9b
	media: Ethernet none
	input: 19 packets, 1064 bytes
	output: 73 packets, 4000 bytes, 53 multicasts
	inet 192.168.255.7 netmask 0xffffff00 broadcast 192.168.255.255
# netstat -p ip

ip:
	42 total packets received
	0 bad header checksums
	0 with size smaller than minimum
	0 with data size < data length
	0 with length > max ip packet size
	0 with header length < data size
	0 with data length < header length
	0 with bad options
	0 with incorrect version number
	0 fragments received
	0 fragments dropped (dup or out of space)
	0 fragments dropped (out of ipqent)
	0 malformed fragments dropped
	0 fragments dropped after timeout
	0 packets reassembled ok
	42 packets for this host
	0 packets for unknown/unsupported protocol
	32 packets forwarded (0 packets fast forwarded)
	0 packets not forwardable
	0 redirects sent
	0 packets no matching gif found
	48 packets sent from this host
	80 packets sent with fabricated ip header
	0 output packets dropped due to no bufs, etc.
	10 output packets discarded due to no route
	0 output datagrams fragmented
	0 fragments created
	0 datagrams that can't be fragmented
	0 datagrams with bad address in header
# 

I have tried to use "io-pkt-v4-hc -d mpc85xx syspage" to bring the tcp/ip stack and driver, and it works quite happy 
until I use :
ifconfig tsec0 link 00:12:34:56:78:9a active
to override the MAC address, then it can send out the packets but can not recived packets any more.

But if I use ifconfig tsec0 link mac active to change the MAC address to the sameone write to the syspage, the ethernet 
start to work again.


RE: RE: Problem with configure MPC8313 MAC address  
> it works quite happy until I use :
>
> # ifconfig tsec0 link 00:12:34:56:78:9a active

Don't do that.  If you want a specific mac address
for an interface, use the "mac=XXX" command line option
to the driver.

--
aboyd
Re: RE: Problem with configure MPC8313 MAC address  
On Mon, Mar 30, 2009 at 09:32:07AM -0400, Andrew Boyd wrote:
> 
> > it works quite happy until I use :
> >
> > # ifconfig tsec0 link 00:12:34:56:78:9a active
> 
> Don't do that.  If you want a specific mac address
> for an interface, use the "mac=XXX" command line option
> to the driver.

This should work though.  I'll make a PR.

Regards,

-seanb
RE: RE: Problem with configure MPC8313 MAC address  
> This should work though.  I'll make a PR.

Sorry about that, Sean - I know you're incredibly
busy right now.

--
aboyd

Re: RE: Problem with configure MPC8313 MAC address  
On Mon, Mar 30, 2009 at 09:54:33AM -0400, Andrew Boyd wrote:
> 
> > This should work though.  I'll make a PR.
> 
> Sorry about that, Sean - I know you're incredibly
> busy right now.
> 

Never too busy for PRs :)  66857 has been created.

-seanb
RE: RE: Problem with configure MPC8313 MAC address  
Slight tangent:  many of our drivers have
"hard-coded" mac addresses (eg 00:11:22:33:44:55)
on hardware which does not have persistent hardware
memory to store a world-wide unique MAC address.

I realize that in such a circumstance, have a faked
up address such as the above is better than nothing - 
or having the driver choose to terminate - but what
follows, for those still reading this, is a slightly
better receipe for a faked-up mac address.  

Please feel free to distribute this code, and use it 
in qnx network drivers that do not have a mac address
stored in hardware:


// set default mac address
uint64_t val = ClockCycles();

// 00 C0 0F is owned by QNX software (I bought it, back in the 1980s)
cfg->current_address[0] = 0x00;
cfg->current_address[1] = 0xC0;
cfg->current_address[2] = 0x0F;

// pseudo-random create the lower 3 bytes
cfg->current_address[3] = ((val >> 56) & 0xff) + ((val >> 48) & 0xff) +
((val >>  0) & 0xff);

cfg->current_address[4] = ((val >> 40) & 0xff) + ((val >> 32) & 0xff) +
((val >> 24) & 0xff);

cfg->current_address[5] = ((val >> 16) & 0xff) + ((val >>  8) & 0xff) +
((val >>  0) & 0xff);


--
aboyd   www.pittspecials.com/movies/tumble.wmv
  
RE: Problem with configure MPC8313 MAC address  
Are you sure that the problem is with the MAC address or does the driver
just not work if you don't specify syspage?  It's possible that the PHY
address may also need to be specified for your board.  If you want to
change the MAC, try specifying both the syspage and MAC options and see
if that works.

io-pkt-v4 -dmpc85xx syspage,mac=00123456789a,verbose

And see what sloginfo reports if it doesn't work.

   R.

-----Original Message-----
From: Ji Dong [mailto:community-noreply@qnx.com] 
Sent: Monday, March 30, 2009 6:54 AM
To: drivers-networking
Subject: Problem with configure MPC8313 MAC address

I am trying to configure the MAC address for MPC8313 target.

The BSP of MPC8313 use a fixed MAC address in the syspage, I have found
two possible way to configure the MAC address we specify, but none of
them works properly.

1) io-pkt-v4-hc -d mpc85xx mac=00123456789a 2)ifconfig tsec0 link
00:12:34:56:78:9a active

after either of the configureation above, all the packet sending out by
the target is correctly, but the target seems get problem when pick up
the reply packet.

For example:
A: windows XP (fresh rebooted), Wireshark to capture the communication
paket, IP:192.168.3.254/24
B: our MPC8313 target, IP:192.168.3.151/24

When I ping from B to A:
B send out:
Summary:CamilleB_56:78:9a	Broadcast	ARP	Who has
192.168.3.254?  Tell 192.168.3.151
A reply:
Summary: Belkin_e7:77:eb	CamilleB_56:78:9a	ARP
192.168.3.254 is at 00:11:50:e7:77:eb
B send out:
Summary:CamilleB_56:78:9a	Broadcast	ARP	Who has
192.168.3.254?  Tell 192.168.3.151
A reply:
Summary: Belkin_e7:77:eb	CamilleB_56:78:9a	ARP
192.168.3.254 is at 00:11:50:e7:77:eb

B send out:
Summary:CamilleB_56:78:9a	Broadcast	ARP	Who has
192.168.3.254?  Tell 192.168.3.151
A reply:
Summary: Belkin_e7:77:eb	CamilleB_56:78:9a	ARP
192.168.3.254 is at 00:11:50:e7:77:eb

But B will never update it is arp table and get the MAC address of A.
when I use arp -a, and alway get:

# arp -a
? (192.168.3.254) at (incomplete) on tsec0

_______________________________________________
Networking Drivers
http://community.qnx.com/sf/go/post25511
Re: RE: Problem with configure MPC8313 MAC address  
Hi Craig:

I think you find the problem, after I compare the syslog I found when I have not specify the syspage, the Rx,Tx and Err 
IRQ is incorrect.
I have capture one of nic start log as below:
1) with syspage specified
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: Base register 0xE0024000
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: IRQ Tx 37 Rx 36 Err 35
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: MAC 00:01:12:34:56:78
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: PHY address 0
Jan 01 00:00:03    5    14     0 MPC85XX TSEC
Jan 01 00:00:03    5    14     0 Vendor .............. 0x0
Jan 01 00:00:03    5    14     0 Device .............. 0x0
Jan 01 00:00:03    5    14     0 Revision ............ 0x0
Jan 01 00:00:03    5    14     0 Memory base ......... 0xe0024000
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x25
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x24
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x23
Jan 01 00:00:03    5    14     0 MAC address ......... 001234 56789a
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): eTsec: yes
2) without syspage specified.
Jan 01 00:00:03    5    14     0 MPC85XX TSEC
Jan 01 00:00:03    5    14     0 Vendor .............. 0x0
Jan 01 00:00:03    5    14     0 Device .............. 0x0
Jan 01 00:00:03    5    14     0 Revision ............ 0x0
Jan 01 00:00:03    5    14     0 Memory base ......... 0xe0024000
Jan 01 00:00:03    5    14     0 Interrupt ........... 0xd
Jan 01 00:00:03    5    14     0 Interrupt ........... 0xe
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x12
Jan 01 00:00:03    5    14     0 MAC address ......... 001234 56789a
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): eTsec: yes

Now my question is:
How can I configure the interrupt address without specify the syspage, (I couldn't find any on http://www.qnx.com/
developers/docs/6.4.0/neutrino/utilities/d/devnp-mpc85xx.so.html)



Ji



> Are you sure that the problem is with the MAC address or does the driver
> just not work if you don't specify syspage?  It's possible that the PHY
> address may also need to be specified for your board.  If you want to
> change the MAC, try specifying both the syspage and MAC options and see
> if that works.
> 
> io-pkt-v4 -dmpc85xx syspage,mac=00123456789a,verbose
> 
> And see what sloginfo reports if it doesn't work.
> 
>    R.
RE: RE: Problem with configure MPC8313 MAC address  
Hi Ji:

The short answer is that you can't.  There are no options to specify the
interrupts from the command line.  If all that you want to do is change
the MAC, then you can either update the system page contents in the BSP
source (look in init_hwinfo.c for where the MAC is being set) or try
overriding the MAC address on the command line in combination with the
syspage option (and I can see from your nicinfo output that this worked
for you).

	Robert.
 

-----Original Message-----
From: Ji Dong [mailto:community-noreply@qnx.com] 
Sent: Monday, March 30, 2009 11:09 AM
To: drivers-networking
Subject: Re: RE: Problem with configure MPC8313 MAC address

Hi Craig:

I think you find the problem, after I compare the syslog I found when I
have not specify the syspage, the Rx,Tx and Err IRQ is incorrect.
I have capture one of nic start log as below:
1) with syspage specified
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: Base register
0xE0024000
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: IRQ Tx 37 Rx 36
Err 35
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: MAC
00:01:12:34:56:78
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: PHY address 0
Jan 01 00:00:03    5    14     0 MPC85XX TSEC
Jan 01 00:00:03    5    14     0 Vendor .............. 0x0
Jan 01 00:00:03    5    14     0 Device .............. 0x0
Jan 01 00:00:03    5    14     0 Revision ............ 0x0
Jan 01 00:00:03    5    14     0 Memory base ......... 0xe0024000
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x25
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x24
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x23
Jan 01 00:00:03    5    14     0 MAC address ......... 001234 56789a
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): eTsec: yes
2) without syspage specified.
Jan 01 00:00:03    5    14     0 MPC85XX TSEC
Jan 01 00:00:03    5    14     0 Vendor .............. 0x0
Jan 01 00:00:03    5    14     0 Device .............. 0x0
Jan 01 00:00:03    5    14     0 Revision ............ 0x0
Jan 01 00:00:03    5    14     0 Memory base ......... 0xe0024000
Jan 01 00:00:03    5    14     0 Interrupt ........... 0xd
Jan 01 00:00:03    5    14     0 Interrupt ........... 0xe
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x12
Jan 01 00:00:03    5    14     0 MAC address ......... 001234 56789a
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): eTsec: yes

Now my question is:
How can I configure the interrupt address without specify the syspage,
(I couldn't find any on
http://www.qnx.com/developers/docs/6.4.0/neutrino/utilities/d/devnp-mpc8
5xx.so.html)



Ji



> Are you sure that the problem is with the MAC address or does the 
> driver just not work if you don't specify syspage?  It's possible that

> the PHY address may also need to be specified for your board.  If you 
> want to change the MAC, try specifying both the syspage and MAC 
> options and see if that works.
> 
> io-pkt-v4 -dmpc85xx syspage,mac=00123456789a,verbose
> 
> And see what sloginfo reports if it doesn't work.
> 
>    R.


_______________________________________________
Networking Drivers
http://community.qnx.com/sf/go/post25550
Re: RE: RE: Problem with configure MPC8313 MAC address  
Hi Robert:

What I am trying to do is: configure the MAC address which is read from EPROM though I2C driver.

Before I start QNX i2c driver, I can not get the MAC address, so I think I can't write the correct MAC address to the 
syspage. 

On our target, we have 2 NIC
if i use"io-pkt-v4-hc -d mpc85xx syspage,mac=00123456789a", both nic is confiugred to the same MAC address, is there any
 way I can configure both NIC?

Ji


> Hi Ji:
> 
> The short answer is that you can't.  There are no options to specify the
> interrupts from the command line.  If all that you want to do is change
> the MAC, then you can either update the system page contents in the BSP
> source (look in init_hwinfo.c for where the MAC is being set) or try
> overriding the MAC address on the command line in combination with the
> syspage option (and I can see from your nicinfo output that this worked
> for you).
> 
> 	Robert.
RE: RE: RE: Problem with configure MPC8313 MAC address  
Hmmmm.... That's an interesting one.

There's a bug in there somewhere since the MAC address should be
incremented before being used by a second interface.

How about

io-pkt-v4 -dmpc85xx pci=0,syspage,mac=0x001122334455 -dmpc85xx
pci=1,syspage,max=0x001122334466

	Robert.

-----Original Message-----
From: Ji Dong [mailto:community-noreply@qnx.com] 
Sent: Monday, March 30, 2009 11:26 AM
To: drivers-networking
Subject: Re: RE: RE: Problem with configure MPC8313 MAC address

Hi Robert:

What I am trying to do is: configure the MAC address which is read from
EPROM though I2C driver.

Before I start QNX i2c driver, I can not get the MAC address, so I think
I can't write the correct MAC address to the syspage. 

On our target, we have 2 NIC
if i use"io-pkt-v4-hc -d mpc85xx syspage,mac=00123456789a", both nic is
confiugred to the same MAC address, is there any way I can configure
both NIC?

Ji


> Hi Ji:
> 
> The short answer is that you can't.  There are no options to specify 
> the interrupts from the command line.  If all that you want to do is 
> change the MAC, then you can either update the system page contents in

> the BSP source (look in init_hwinfo.c for where the MAC is being set) 
> or try overriding the MAC address on the command line in combination 
> with the syspage option (and I can see from your nicinfo output that 
> this worked for you).
> 
> 	Robert.


_______________________________________________
Networking Drivers
http://community.qnx.com/sf/go/post25555
Re: RE: RE: RE: Problem with configure MPC8313 MAC address  
Hi Robert:

I have tried and syslog is:
ouldn't initialize listen service: tcp (Address family not supported by protocol family)

If my understand is correct is pci=0/1 specify the PCI NIC location, actually the target is a MPC8313 based, have 2 on 
board CPU, so I have changed the command line to:
io-pkt-v4-hc -dmpc85xx syspage,mac=00123456789a,phy_addr=0,etsec=0,verbose -dmpc85xx syspage,mac=00123456789b,phy_addr=1
,etsec=0,verbose &

now, there are 4 tsec device comes out first two have  00123456789a MAC address, and the other two have 00123456789b as its MAC address.



Ji

> Hmmmm.... That's an interesting one.
> 
> There's a bug in there somewhere since the MAC address should be
> incremented before being used by a second interface.
> 
> How about
> 
> io-pkt-v4 -dmpc85xx pci=0,syspage,mac=0x001122334455 -dmpc85xx
> pci=1,syspage,max=0x001122334466
> 
> 	Robert.
RE: RE: RE: RE: Problem with configure MPC8313 MAC address  
Hi Ji:
	In this case "pci" actually means "use only interface x" and
doesn't actually refer to PCI.  It was a convenient (if confusing)
command line option to use.

Try the command line as specified first and see what it does.  The way
that you've specified the command line is starting multiple drivers with
the same hardware so it won't work.

	Robert.

-----Original Message-----
From: Ji Dong [mailto:community-noreply@qnx.com] 
Sent: Monday, March 30, 2009 11:44 AM
To: drivers-networking
Subject: Re: RE: RE: RE: Problem with configure MPC8313 MAC address

Hi Robert:

I have tried and syslog is:
ouldn't initialize listen service: tcp (Address family not supported by
protocol family)

If my understand is correct is pci=0/1 specify the PCI NIC location,
actually the target is a MPC8313 based, have 2 on board CPU, so I have
changed the command line to:
io-pkt-v4-hc -dmpc85xx
syspage,mac=00123456789a,phy_addr=0,etsec=0,verbose -dmpc85xx
syspage,mac=00123456789b,phy_addr=1,etsec=0,verbose &

now, there are 4 tsec device comes out first two have  00123456789a MAC
address, and the other two have 00123456789b as its MAC address.



Ji

> Hmmmm.... That's an interesting one.
> 
> There's a bug in there somewhere since the MAC address should be 
> incremented before being used by a second interface.
> 
> How about
> 
> io-pkt-v4 -dmpc85xx pci=0,syspage,mac=0x001122334455 -dmpc85xx
> pci=1,syspage,max=0x001122334466
> 
> 	Robert.


_______________________________________________
Networking Drivers
http://community.qnx.com/sf/go/post25561
Re: RE: RE: RE: RE: Problem with configure MPC8313 MAC address  
Hi Robert:

"io-pkt-v4-hc -dmpc85xx pci=0,syspage,mac=001122334455 -dmpc85xx"
can work as expected, will start the first NIC(phy address 0) and work.

then I tried to add the second in:
o-pkt-v4-hc -dmpc85xx pci=0,syspage,phy_addr=0,mac=001122334455 -dmpc85xx pci=1,syspage,phy_addr=1,max=001122334466
Jan 01 00:00:03    5    14     0 tcpip starting
Jan 01 00:00:03    3    14     0 Unable to attach to pci server: No such file or directory
Jan 01 00:00:03    3    14     0 Using pseudo random generator.  See "random" option
Jan 01 00:00:03    5    14     0 initializing IPsec... done
Jan 01 00:00:03    5    14     0 IPsec: Initialized Security Association Processing.
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: Base register 0xE0024000
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: IRQ Tx 37 Rx 36 Err 35
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: MAC 00:01:12:34:56:78
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: PHY address 0
Jan 01 00:00:03    5    14     0 MPC85XX TSEC
Jan 01 00:00:03    5    14     0 Vendor .............. 0x0
Jan 01 00:00:03    5    14     0 Device .............. 0x0
Jan 01 00:00:03    5    14     0 Revision ............ 0x0
Jan 01 00:00:03    5    14     0 Memory base ......... 0xe0024000
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x25
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x24
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x23
Jan 01 00:00:03    5    14     0 MAC address ......... 001122 334455
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): eTsec: yes
Jan 01 00:00:03    2    14     0 mpc85xx_parse_options(): unknown option max=001122334466
Jan 01 00:00:03    2    14     0 Unable to init devnp-mpc85xx.so: Invalid argument

Jan 01 00:00:03    2    14     0 mpc85xx_init(): rx dma buffer size 2048 bytes
Jan 01 00:00:03    2    14     0 mpc85xx_init_phy(): media_rate: -1, duplex: -1, PHY: 0
Jan 01 00:00:03    2    14     0 mpc85xx_init_phy(): PHY found at address 0
Jan 01 00:00:03    2    14     0 mpc85xx->rx_cap_mask: 0x0

Jan 01 00:00:03    2    14     0 mpc85xx->tx_cap_mask: 0x0

Mar 30 16:00:57    5    14     0 mpc85xx_mii_callback(): link up lan 0 idx 0 (100 BaseT Full Duplex)

FYI:
1)without specify the syspage, the MAC address do add 1 for the second NIC, but with the syspage, both MAC address will 
be the same

2) if I specify "io-pkt-v4-hc -dmpc85xx pci=0,syspage,phy_addr=1,mac=001122334455 -dmpc85xx" 
will start phy address 1 NIC, but still use NIC 0's IRQ

Ji


> Hi Ji:
> 	In this case "pci" actually means "use only interface x" and
> doesn't actually refer to PCI.  It was a convenient (if confusing)
> command line option to use.
> 
> Try the command line as specified first and see what it does.  The way
> that you've specified the command line is starting multiple drivers with
> the same hardware so it won't work.
> 
> 	Robert.
RE: RE: RE: RE: RE: Problem with configure MPC8313 MAC address  
Hi Ji:
	Two things.  You have a typo in your command line for the second
interface (max vs. mac) and you shouldn't have to specify the phy
address since this is handled by the system page information.

	R. 

-----Original Message-----
From: Ji Dong [mailto:community-noreply@qnx.com] 
Sent: Monday, March 30, 2009 12:09 PM
To: drivers-networking
Subject: Re: RE: RE: RE: RE: Problem with configure MPC8313 MAC address

Hi Robert:

"io-pkt-v4-hc -dmpc85xx pci=0,syspage,mac=001122334455 -dmpc85xx"
can work as expected, will start the first NIC(phy address 0) and work.

then I tried to add the second in:
o-pkt-v4-hc -dmpc85xx pci=0,syspage,phy_addr=0,mac=001122334455
-dmpc85xx pci=1,syspage,phy_addr=1,max=001122334466
Jan 01 00:00:03    5    14     0 tcpip starting
Jan 01 00:00:03    3    14     0 Unable to attach to pci server: No such
file or directory
Jan 01 00:00:03    3    14     0 Using pseudo random generator.  See
"random" option
Jan 01 00:00:03    5    14     0 initializing IPsec... done
Jan 01 00:00:03    5    14     0 IPsec: Initialized Security Association
Processing.
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: Base register
0xE0024000
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: IRQ Tx 37 Rx 36
Err 35
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: MAC
00:01:12:34:56:78
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: PHY address 0
Jan 01 00:00:03    5    14     0 MPC85XX TSEC
Jan 01 00:00:03    5    14     0 Vendor .............. 0x0
Jan 01 00:00:03    5    14     0 Device .............. 0x0
Jan 01 00:00:03    5    14     0 Revision ............ 0x0
Jan 01 00:00:03    5    14     0 Memory base ......... 0xe0024000
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x25
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x24
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x23
Jan 01 00:00:03    5    14     0 MAC address ......... 001122 334455
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): eTsec: yes
Jan 01 00:00:03    2    14     0 mpc85xx_parse_options(): unknown option
max=001122334466
Jan 01 00:00:03    2    14     0 Unable to init devnp-mpc85xx.so:
Invalid argument

Jan 01 00:00:03    2    14     0 mpc85xx_init(): rx dma buffer size 2048
bytes
Jan 01 00:00:03    2    14     0 mpc85xx_init_phy(): media_rate: -1,
duplex: -1, PHY: 0
Jan 01 00:00:03    2    14     0 mpc85xx_init_phy(): PHY found at
address 0
Jan 01 00:00:03    2    14     0 mpc85xx->rx_cap_mask: 0x0

Jan 01 00:00:03    2    14     0 mpc85xx->tx_cap_mask: 0x0

Mar 30 16:00:57    5    14     0 mpc85xx_mii_callback(): link up lan 0
idx 0 (100 BaseT Full Duplex)

FYI:
1)without specify the syspage, the MAC address do add 1 for the second
NIC, but with the syspage, both MAC address will be the same

2) if I specify "io-pkt-v4-hc -dmpc85xx
pci=0,syspage,phy_addr=1,mac=001122334455 -dmpc85xx" 
will start phy address 1 NIC, but still use NIC 0's IRQ

Ji


> Hi Ji:
> 	In this case "pci" actually means "use only interface x" and
doesn't 
> actually refer to PCI.  It was a convenient (if confusing) command 
> line option to use.
> 
> Try the command line as specified first and see what it does.  The way

> that you've specified the command line is starting multiple drivers 
> with the same hardware so it won't work.
> 
> 	Robert.


_______________________________________________
Networking Drivers
http://community.qnx.com/sf/go/post25564
Re: RE: RE: RE: RE: RE: Problem with configure MPC8313 MAC address  
Thanks Robert, it works like a dream........


> Hi Ji:
> 	Two things.  You have a typo in your command line for the second
> interface (max vs. mac) and you shouldn't have to specify the phy
> address since this is handled by the system page information.
> 
> 	R. 
> 
RE: RE: RE: RE: RE: Problem with configure MPC8313 MAC address  
(And yes...  I just noticed that the "max" was MY typo and not yours :>.
Sorry about that. )

	R. 

-----Original Message-----
From: Ji Dong [mailto:community-noreply@qnx.com] 
Sent: Monday, March 30, 2009 12:09 PM
To: drivers-networking
Subject: Re: RE: RE: RE: RE: Problem with configure MPC8313 MAC address

Hi Robert:

"io-pkt-v4-hc -dmpc85xx pci=0,syspage,mac=001122334455 -dmpc85xx"
can work as expected, will start the first NIC(phy address 0) and work.

then I tried to add the second in:
o-pkt-v4-hc -dmpc85xx pci=0,syspage,phy_addr=0,mac=001122334455
-dmpc85xx pci=1,syspage,phy_addr=1,max=001122334466
Jan 01 00:00:03    5    14     0 tcpip starting
Jan 01 00:00:03    3    14     0 Unable to attach to pci server: No such
file or directory
Jan 01 00:00:03    3    14     0 Using pseudo random generator.  See
"random" option
Jan 01 00:00:03    5    14     0 initializing IPsec... done
Jan 01 00:00:03    5    14     0 IPsec: Initialized Security Association
Processing.
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: Base register
0xE0024000
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: IRQ Tx 37 Rx 36
Err 35
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: MAC
00:01:12:34:56:78
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): IF 0: PHY address 0
Jan 01 00:00:03    5    14     0 MPC85XX TSEC
Jan 01 00:00:03    5    14     0 Vendor .............. 0x0
Jan 01 00:00:03    5    14     0 Device .............. 0x0
Jan 01 00:00:03    5    14     0 Revision ............ 0x0
Jan 01 00:00:03    5    14     0 Memory base ......... 0xe0024000
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x25
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x24
Jan 01 00:00:03    5    14     0 Interrupt ........... 0x23
Jan 01 00:00:03    5    14     0 MAC address ......... 001122 334455
Jan 01 00:00:03    2    14     0 mpc85xx_attach(): eTsec: yes
Jan 01 00:00:03    2    14     0 mpc85xx_parse_options(): unknown option
max=001122334466
Jan 01 00:00:03    2    14     0 Unable to init devnp-mpc85xx.so:
Invalid argument

Jan 01 00:00:03    2    14     0 mpc85xx_init(): rx dma buffer size 2048
bytes
Jan 01 00:00:03    2    14     0 mpc85xx_init_phy(): media_rate: -1,
duplex: -1, PHY: 0
Jan 01 00:00:03    2    14     0 mpc85xx_init_phy(): PHY found at
address 0
Jan 01 00:00:03    2    14     0 mpc85xx->rx_cap_mask: 0x0

Jan 01 00:00:03    2    14     0 mpc85xx->tx_cap_mask: 0x0

Mar 30 16:00:57    5    14     0 mpc85xx_mii_callback(): link up lan 0
idx 0 (100 BaseT Full Duplex)

FYI:
1)without specify the syspage, the MAC address do add 1 for the second
NIC, but with the syspage, both MAC address will be the same

2) if I specify "io-pkt-v4-hc -dmpc85xx
pci=0,syspage,phy_addr=1,mac=001122334455 -dmpc85xx" 
will start phy address 1 NIC, but still use NIC 0's IRQ

Ji


> Hi Ji:
> 	In this case "pci" actually means "use only interface x" and
doesn't 
> actually refer to PCI.  It was a convenient (if confusing) command 
> line option to use.
> 
> Try the command line as specified first and see what it does.  The way

> that you've specified the command line is starting multiple drivers 
> with the same hardware so it won't work.
> 
> 	Robert.


_______________________________________________
Networking Drivers
http://community.qnx.com/sf/go/post25564