From: Jeff Garzik <jeff@garzik.org>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: akpm@osdl.org, linux-ide@vger.kernel.org
Subject: Re: [PATCH] libata-core: auditting chk_status v check_status
Date: Tue, 23 Oct 2007 21:25:27 -0400 [thread overview]
Message-ID: <471E9F07.3070802@garzik.org> (raw)
In-Reply-To: <20071023165002.15a7b09e@the-village.bc.nu>
Alan Cox wrote:
> Did a complete audit of these and found we have another error case.
>
> ata_bus_softreset calls ata_check_status which means that it tries to do
> an ioread8 on the port blindly and check versus 0xFF for an error.
>
> It should of course be using the ap->ops method for this via chk_status,
> and this bug causes a wrog status call on the NS87415 at least.
>
> Signed-off-by: Alan Cox <alan@redhat.com>
>
> diff -u --exclude-from /usr/src/exclude --new-file --recursive linux.vanilla-2.6.23-mm1/drivers/ata/libata-core.c linux-2.6.23-mm1/drivers/ata/libata-core.c
> --- linux.vanilla-2.6.23-mm1/drivers/ata/libata-core.c 2007-10-15 15:03:26.000000000 +0100
> +++ linux-2.6.23-mm1/drivers/ata/libata-core.c 2007-10-23 13:39:25.861931504 +0100
> @@ -3305,7 +3323,7 @@
> * the bus shows 0xFF because the odd clown forgets the D7
> * pulldown resistor.
> */
> - if (ata_check_status(ap) == 0xFF)
> + if (ata_chk_status(ap) == 0xFF)
> return -ENODEV;
applied
prev parent reply other threads:[~2007-10-24 1:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-23 15:50 [PATCH] libata-core: auditting chk_status v check_status Alan Cox
2007-10-24 1:25 ` Jeff Garzik [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=471E9F07.3070802@garzik.org \
--to=jeff@garzik.org \
--cc=akpm@osdl.org \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=linux-ide@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.