Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 21904
b: refs/heads/master
c: 2044470
h: refs/heads/master
v: v3
  • Loading branch information
Tejun Heo authored and Jeff Garzik committed Mar 12, 2006
1 parent eef31d6 commit b14af0c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 14 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4b10e559277de490bf5c257a1e3264a2bf51404b
refs/heads/master: 2044470cccec1bfe6bb819027975df302ff43bf8
24 changes: 11 additions & 13 deletions trunk/drivers/scsi/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1344,32 +1344,30 @@ static int ata_bus_probe(struct ata_port *ap)

ata_port_probe(ap);

/* reset */
if (ap->ops->probe_reset) {
for (i = 0; i < ATA_MAX_DEVICES; i++)
classes[i] = ATA_DEV_UNKNOWN;
/* reset and determine device classes */
for (i = 0; i < ATA_MAX_DEVICES; i++)
classes[i] = ATA_DEV_UNKNOWN;

if (ap->ops->probe_reset) {
rc = ap->ops->probe_reset(ap, classes);
if (rc) {
printk("ata%u: reset failed (errno=%d)\n", ap->id, rc);
return rc;
}

for (i = 0; i < ATA_MAX_DEVICES; i++)
if (classes[i] == ATA_DEV_UNKNOWN)
classes[i] = ATA_DEV_NONE;
} else {
ap->ops->phy_reset(ap);

for (i = 0; i < ATA_MAX_DEVICES; i++) {
if (!(ap->flags & ATA_FLAG_PORT_DISABLED))
if (!(ap->flags & ATA_FLAG_PORT_DISABLED))
for (i = 0; i < ATA_MAX_DEVICES; i++)
classes[i] = ap->device[i].class;
else
ap->device[i].class = ATA_DEV_UNKNOWN;
}

ata_port_probe(ap);
}

for (i = 0; i < ATA_MAX_DEVICES; i++)
if (classes[i] == ATA_DEV_UNKNOWN)
classes[i] = ATA_DEV_NONE;

/* read IDENTIFY page and configure devices */
for (i = 0; i < ATA_MAX_DEVICES; i++) {
struct ata_device *dev = &ap->device[i];
Expand Down

0 comments on commit b14af0c

Please sign in to comment.