Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=4aa9ab67fb9c0dfdb1692f4ec413120832a22ddc
Commit:     4aa9ab67fb9c0dfdb1692f4ec413120832a22ddc
Parent:     5851fadce8824d5d4b8fd02c22ae098401f6489e
Author:     Tejun Heo <[EMAIL PROTECTED]>
AuthorDate: Mon Mar 12 17:24:08 2007 +0900
Committer:  Jeff Garzik <[EMAIL PROTECTED]>
CommitDate: Mon Mar 19 11:55:43 2007 -0400

    libata: don't whine if ->prereset() returns -ENOENT
    
    ->prereset() returns -ENOENT to tell libata that the port is empty and
    reset sequencing should be stopped.  This is not an error condition.
    Update ata_eh_reset() such that it sets device classes to ATA_DEV_NONE
    and return success in on -ENOENT.  This makes spurious error message
    go away.
    
    Signed-off-by: Tejun Heo <[EMAIL PROTECTED]>
    Signed-off-by: Jeff Garzik <[EMAIL PROTECTED]>
---
 drivers/ata/libata-eh.c |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c
index 7349c3d..361953a 100644
--- a/drivers/ata/libata-eh.c
+++ b/drivers/ata/libata-eh.c
@@ -1625,8 +1625,14 @@ static int ata_eh_reset(struct ata_port *ap, int 
classify,
                rc = prereset(ap);
                if (rc) {
                        if (rc == -ENOENT) {
-                               ata_port_printk(ap, KERN_DEBUG, "port disabled. 
ignoring.\n");
+                               ata_port_printk(ap, KERN_DEBUG,
+                                               "port disabled. ignoring.\n");
                                ap->eh_context.i.action &= ~ATA_EH_RESET_MASK;
+
+                               for (i = 0; i < ATA_MAX_DEVICES; i++)
+                                       classes[i] = ATA_DEV_NONE;
+
+                               rc = 0;
                        } else
                                ata_port_printk(ap, KERN_ERR,
                                        "prereset failed (errno=%d)\n", rc);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to