Thread (53 messages) 53 messages, 6 authors, 2015-10-21

Re: [PATCH v5 01/34] cxlflash: Fix to avoid invalid port_sel value

From: Tomas Henzl <hidden>
Date: 2015-10-02 12:43:31
Also in: linux-scsi

On 1.10.2015 17:54, Matthew R. Ochs wrote:
From: Manoj Kumar <redacted>

If two concurrent MANAGE_LUN ioctls are issued with the same
WWID parameter, it would result in an incorrect value of port_sel.

This is because port_sel is modified without any locks being
held. If the first caller stalls after the return from
find_and_create_lun(), the value of port_sel will be set
incorrectly to indicate a single port, though in this case
it should have been set to both ports.

To fix, use the global mutex to serialize the lookup of the
WWID and the subsequent modification of port_sel.

Signed-off-by: Matthew R. Ochs <redacted>
Signed-off-by: Manoj N. Kumar <redacted>
Reviewed-by: Brian King <redacted>
Reviewed-by: Tomas Henzl <redacted>

Tomas
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help