diff options
author | Tom Peng <[email protected]> | 2009-07-01 20:37:26 +0800 |
---|---|---|
committer | James Bottomley <[email protected]> | 2009-07-16 12:50:44 -0500 |
commit | 5381837f125cc62ad703fbcdfcd7566fc81fd404 (patch) | |
tree | 872571a7a68dde3fd1f830c2d3ff62d5dbae3110 /tools/perf/util/scripting-engines/trace-event-perl.c | |
parent | 35b5c55fee08e6e4001ba98060a2d0b82f70b5f4 (diff) |
[SCSI] libsas: reuse the original port when hotplugging phys in wide ports
There's a hotplug problem in the way libsas allocates ports: it loops over the
available ports first trying to add to an existing for a wide port and
otherwise allocating the next free port. This scheme only works if the port
array is packed from zero, which fails if a port gets hot unplugged and the
array becomes sparse. In that case, a new port is formed even if there's a
wide port it should be part of. Fix this by creating two loops over all the
ports: the first to see if the phy should be part of a wide port and the
second to form a new port in an empty port slot.
Signed-off-by: Tom Peng <[email protected]>
Signed-off-by: Jack Wang <[email protected]>
Signed-off-by: Lindar Liu <[email protected]>
Cc: Stable Tree <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-perl.c')
0 files changed, 0 insertions, 0 deletions