Skip to content

Commit f7b705c

Browse files
ipylypivmartinkpetersen
authored andcommitted
scsi: pm80xx: Set phy_attached to zero when device is gone
When a fatal error occurs, a phy down event may not be received to set phy->phy_attached to zero. Signed-off-by: Igor Pylypiv <[email protected]> Signed-off-by: Salomon Dushimirimana <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Martin K. Petersen <[email protected]>
1 parent 8a65b75 commit f7b705c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/scsi/pm8001/pm8001_sas.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -766,6 +766,7 @@ static void pm8001_dev_gone_notify(struct domain_device *dev)
766766
spin_lock_irqsave(&pm8001_ha->lock, flags);
767767
}
768768
PM8001_CHIP_DISP->dereg_dev_req(pm8001_ha, device_id);
769+
pm8001_ha->phy[pm8001_dev->attached_phy].phy_attached = 0;
769770
pm8001_free_dev(pm8001_dev);
770771
} else {
771772
pm8001_dbg(pm8001_ha, DISC, "Found dev has gone.\n");

0 commit comments

Comments
 (0)