Skip to content

Commit bc6f387

Browse files
Jeff Skirvindjbw
authored andcommitted
isci: Device reset should request sas_phy_reset(phy, true)
The hard_reset parameter passed to the LLDD in the direct-attached phy control case allows the LLDD to filter link failure events while the direct-attached device reset is executing. Signed-off-by: Jeff Skirvin <[email protected]> Signed-off-by: Dan Williams <[email protected]>
1 parent a8a0a13 commit bc6f387

File tree

1 file changed

+6
-12
lines changed

1 file changed

+6
-12
lines changed

drivers/scsi/isci/task.c

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1563,7 +1563,7 @@ static void isci_wait_for_smp_phy_reset(struct isci_remote_device *idev, int phy
15631563
}
15641564

15651565
static int isci_reset_device(struct isci_host *ihost,
1566-
struct isci_remote_device *idev, int hard_reset)
1566+
struct isci_remote_device *idev)
15671567
{
15681568
struct sas_phy *phy = sas_find_local_phy(idev->domain_dev);
15691569
struct isci_port *iport = idev->isci_port;
@@ -1593,7 +1593,7 @@ static int isci_reset_device(struct isci_host *ihost,
15931593
if (!scsi_is_sas_phy_local(phy))
15941594
set_bit(IPORT_BCN_BLOCKED, &iport->flags);
15951595

1596-
rc = sas_phy_reset(phy, hard_reset);
1596+
rc = sas_phy_reset(phy, true);
15971597

15981598
/* Terminate in-progress I/O now. */
15991599
isci_remote_device_nuke_requests(ihost, idev);
@@ -1633,8 +1633,8 @@ int isci_task_I_T_nexus_reset(struct domain_device *dev)
16331633
{
16341634
struct isci_host *ihost = dev_to_ihost(dev);
16351635
struct isci_remote_device *idev;
1636-
int ret, hard_reset = 1;
16371636
unsigned long flags;
1637+
int ret;
16381638

16391639
spin_lock_irqsave(&ihost->scic_lock, flags);
16401640
idev = isci_lookup_device(dev);
@@ -1645,10 +1645,7 @@ int isci_task_I_T_nexus_reset(struct domain_device *dev)
16451645
goto out;
16461646
}
16471647

1648-
if (dev->dev_type == SATA_DEV || (dev->tproto & SAS_PROTOCOL_STP))
1649-
hard_reset = 0;
1650-
1651-
ret = isci_reset_device(ihost, idev, hard_reset);
1648+
ret = isci_reset_device(ihost, idev);
16521649
out:
16531650
isci_put_device(idev);
16541651
return ret;
@@ -1659,11 +1656,8 @@ int isci_bus_reset_handler(struct scsi_cmnd *cmd)
16591656
struct domain_device *dev = sdev_to_domain_dev(cmd->device);
16601657
struct isci_host *ihost = dev_to_ihost(dev);
16611658
struct isci_remote_device *idev;
1662-
int ret, hard_reset = 1;
16631659
unsigned long flags;
1664-
1665-
if (dev->dev_type == SATA_DEV || (dev->tproto & SAS_PROTOCOL_STP))
1666-
hard_reset = 0;
1660+
int ret;
16671661

16681662
spin_lock_irqsave(&ihost->scic_lock, flags);
16691663
idev = isci_lookup_device(dev);
@@ -1674,7 +1668,7 @@ int isci_bus_reset_handler(struct scsi_cmnd *cmd)
16741668
goto out;
16751669
}
16761670

1677-
ret = isci_reset_device(ihost, idev, hard_reset);
1671+
ret = isci_reset_device(ihost, idev);
16781672
out:
16791673
isci_put_device(idev);
16801674
return ret;

0 commit comments

Comments
 (0)