[openib-general] SRP device management client (and a few opensmglitches)
halr at voltaire.com
Thu Nov 17 17:15:05 PST 2005
On Tue, 2005-11-15 at 18:18, Roland Dreier wrote:
> Eitan> Hi Roland, Now I get it ! In the port info record there is
> Eitan> a field named LocalPortNumber. This field is NOT the port
> Eitan> number the data is about. It is the port number the packet
> Eitan> of the query came from. (see table 145 p823 l-38). When
> Eitan> OpenSM obtains the PortInfo associated with that particular
> Eitan> port it did so through port 2 of the switch. So the
> Eitan> LocalPortNum is set to 2.
> Eitan> If you are interested with the real port number, it is
> Eitan> located in the RID second field, of the PortInfoRecord
> Eitan> returned by the SA GetTable query.
> OK, I guess that makes sense (although how to interpret the
> LocalPortNumber of the attribute when it is contained in the SA record
> seems slightly unclear).
> It seems that if I want to get a list of (say) all the HCA port 2s in
> the network, I have to do a get table query of the SA PortInfoRecord
> with component mask set so that I get ports with LocalPortNumber 2,
> and then filter out switch ports (since the port number field in the
> RID is not defined for HCA ports). Do you think this is really what
> was intended?
It's not LocalPortNum. I don't see any easy way to query all port 2s in
the network as for HCAs and routers the PortNum component is reserved
(and you need to supply port LID). Doing that would only get you all the
switch port 2s. Perhaps the spec should be amended if this is useful. If
the spec were amended like this, you would get all the port 2s in the
network and would then need to determine whether they were on a switch
on xCA. Do you think this is useful ? Shall I file a comment on this ?
We need to move fast to get this into 1.2 errata.
I think OpenSM is actually doing what you did ask (with LocalPortNum = 2
and that component mask bit on).
More information about the general