Project Home
Project Home
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Re: mpc8572 tsec driver: (1 Item)
   
Re: mpc8572 tsec driver  
The only way to overcome this would be to have a shared memory object that
both instances of io-pkt can access.
The question is, why do you need to run 2 separate instances of io-pkt?




On 2015/1/22, 5:21 PM, "Shawn Steenhagen" <community-noreply@qnx.com>
wrote:

>This is a fairly old modification whose comment within the mpc85xx device
>driver is still around in mii.c
>
>// PR 62747 - multiple interfaces requires mii access locking
>static pthread_mutex_t  mii_mutex = PTHREAD_MUTEX_INITIALIZER;
>
>My question is this:  Is it correct to say that this mutex object added
>to mii.c will be known only to one particular instance of the device
>driver and will not operate as expected if I run more than one instance?
>For example if I do something like:
>
>io-pkt-v4 -i1 -d /lib/devnp-mpc85xx.so
>syspage,speed=100,duplex=1,verbose=5 -ptcpip prefix=/sock1 -v
>SOCK=/sock1 ifconfig tsec0 192.168.4.1 netmask 0xffffff00 broadcast
>192.168.4.255 up
>
>io-pkt-v4 -i1 -d /lib/devnp-mpc85xx.so
>syspage,speed=100,duplex=1,verbose=5 -ptcpip prefix=/sock2 -v
>SOCK=/sock2 ifconfig tsec0 192.168.5.3 netmask 0xffffff00 broadcast
>192.168.5.255 up
>
>Each instance of the device driver will have no knowledge of the others
>static mutex object? (which can cause collisions of the single MDIO
>resource).  What's the most straight forward way to make the mutex object
>shared among all instances of the driver that might be brought up?
>
>Thanks
>Shawn
>
>
>
>
>_______________________________________________
>
>Networking Drivers
>http://community.qnx.com/sf/go/post113042
>To cancel your subscription to this discussion, please e-mail
>drivers-networking-unsubscribe@community.qnx.com