Operating System - HP-UX
1834017 Members
2105 Online
110063 Solutions
New Discussion

DLPI device for second card

 
SOLVED
Go to solution
JUP
Regular Advisor

DLPI device for second card

I'm running HPUX 11.23i on a rx2620 box with 2 network cards. I have a program that opens up each network card device and reads transmits messages.

lanscan shows:

Hardware Station Crd Hdw Net-Interface NM MAC HP-DLPI DLPI
Path Address In# State NamePPA ID Type Support Mjr#
0/1/2/0 0x0013215B4608 0 UP lan0 snap0 1 ETHER Yes 119
0/1/2/1 0x0013215B4609 1 UP lan1 snap1 2 ETHER Yes 119

ls -l /dev/dlpi* shows

crw-rw-rw- 1 root sys 72 0x000077 Apr 2 09:13 /dev/dlpi
crw-rw-rw- 1 root sys 119 0x000000 Apr 2 09:13 /dev/dlpi0
crw-rw-rw- 1 root sys 119 0x000001 Apr 2 09:13 /dev/dlpi1
crw-rw-rw- 1 root sys 119 0x000002 Apr 2 09:13 /dev/dlpi2
crw-rw-rw- 1 root sys 119 0x000003 Apr 2 09:13 /dev/dlpi3
crw-rw-rw- 1 root sys 119 0x000004 Apr 2 09:13 /dev/dlpi4


I can open the device for the first card (/dev/dlpi). I am trying to open the device for the second card - what is the device. I think its /dev/dlpi also but with a PPA (Physical Point of Access) of 1 not 0.

Is that correct ? Can anyone please help out here.

Thanks in advance
JUP
3 REPLIES 3
Ermin Borovac
Honored Contributor
Solution

Re: DLPI device for second card

LAN interfaces are named as lan, so you are right, PPA for the second card is 1.

You can access all LAN interfaces through single device file /dev/dlpi.

More information including some sample programs (in Appendix A) can be found in HP DLPI Programmer's Guide: HP-UX 11i v2 at

http://docs.hp.com/en/B2355-90871/index.html

Re: DLPI device for second card

No, as I understand it, you should be using just /dev/dlpi. The difference between /dev/dlpi and /dev/dlpiN is that /dev/dlpi supports seperate streams for each open request wherease every /dev/dlpiN doesn't.

What I understand you are supposed to do is open /dev/dlpi and get a list of all available PPAs - have a look at the function attach() in the code here:

http://docs.hp.com/en/B2355-90138/ch02s01.html

HTH

Duncan

I am an HPE Employee
Accept or Kudo
JUP
Regular Advisor

Re: DLPI device for second card

Thanks all - its been resolved.

/dev/dlpi for all devices and use PPA 0 for the first device, PPA 1 for second and so on.

Thanks again
JUP