From: Johannes Weiner <hnazfoo@googlemail.com>
To: Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: via sata oops on init
Date: Sat, 29 Jul 2006 19:04:02 +0200 [thread overview]
Message-ID: <20060729170402.GA20649@leiferikson.dystopia.lan> (raw)
In-Reply-To: <20060729164115.GA16946@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 957 bytes --]
Hi,
On Sat, Jul 29, 2006 at 12:41:15PM -0400, Dave Jones wrote:
> --- linux-2.6/drivers/scsi/libata-core.c~ 2006-07-29 12:35:32.000000000 -0400
> +++ linux-2.6/drivers/scsi/libata-core.c 2006-07-29 12:39:08.000000000 -0400
> @@ -5419,10 +5419,10 @@ int ata_device_add(const struct ata_prob
> unsigned long xfer_mode_mask;
>
> ap = ata_host_add(ent, host_set, i);
> + host_set->ports[i] = ap;
> if (!ap)
> goto err_out;
>
> - host_set->ports[i] = ap;
> xfer_mode_mask =(ap->udma_mask << ATA_SHIFT_UDMA) |
> (ap->mwdma_mask << ATA_SHIFT_MWDMA) |
> (ap->pio_mask << ATA_SHIFT_PIO);
> @@ -5532,6 +5532,8 @@ int ata_device_add(const struct ata_prob
>
> err_out:
> for (i = 0; i < count; i++) {
> + if (!host_set->ports[i])
> + break;
> ata_host_remove(host_set->ports[i], 1);
> scsi_host_put(host_set->ports[i]->host);
> }
You jump into loop just to skip it.
Signed-off-by: Johannes Weiner <hanzfoo@gmail.com>
[-- Attachment #2: libata-core.goto.patch --]
[-- Type: text/plain, Size: 408 bytes --]
diff --git a/drivers/scsi/libata-core.c b/drivers/scsi/libata-core.c
index 386e5f2..064ee85 100644
--- a/drivers/scsi/libata-core.c
+++ b/drivers/scsi/libata-core.c
@@ -5420,7 +5420,7 @@ int ata_device_add(const struct ata_prob
ap = ata_host_add(ent, host_set, i);
if (!ap)
- goto err_out;
+ goto err_free_ret;
host_set->ports[i] = ap;
xfer_mode_mask =(ap->udma_mask << ATA_SHIFT_UDMA) |
next prev parent reply other threads:[~2006-07-29 17:05 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-28 23:39 Dave Jones
2006-07-29 14:45 ` Johannes Weiner
2006-07-29 16:41 ` Dave Jones
2006-07-29 17:04 ` Johannes Weiner [this message]
2006-07-29 17:10 ` Dave Jones
2006-07-29 19:30 ` Johannes Weiner
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=20060729170402.GA20649@leiferikson.dystopia.lan \
--to=hnazfoo@googlemail.com \
--cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®