Re: [PATCH 1/2] IB/mlx4: fix the case of invalid speed value returned when the port is down

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


On 4/2/2012 2:39 PM, Hefty, Sean wrote:
>> On 4/2/2012 7:35 PM, Hal Rosenstock wrote:
>>> Rather than always overwriting active_speed in this case, wouldn't it
>>> be better to only do that for invalid values?
>>
>> Yes, I have thought about that, however, spotting invalid values would
>> make the code a bit ugly, so I took this approach, Roland?
> 
> Does the active speed even make sense if the port is down?  

When a port is DOWN, the only PortInfo components that are not
vendor dependent are PortState and PortPhysicalState:

IBA 1.2.1 vol 1 p.830 line 16 states:
C14-24.2.1: If PortInfo:Portstate=Down, then
• a SubnGet(PortInfo) shall produce valid data for PortInfo:PortState
and PortInfo:PortPhysicalState; whether any other component has
valid data is vendor-dependent

> If not, should we assume that any value returned by the FW is correct?

A reserved value should never be returned though so not all values are
"correct". Of course, it has limited meaning in this state.

-- Hal

> --
> To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Home]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]    [Yosemite Photos]    [Free Online Dating]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Devices]

Add to Google Powered by Linux