All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dave Jones <davej@redhat.com>
To: Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: via sata oops on init
Date: Sat, 29 Jul 2006 13:10:44 -0400	[thread overview]
Message-ID: <20060729171044.GE16946@redhat.com> (raw)
In-Reply-To: <20060729170402.GA20649@leiferikson.dystopia.lan>

On Sat, Jul 29, 2006 at 07:04:02PM +0200, Johannes Weiner wrote:

 > You jump into loop just to skip it.

You have to. Look at the allocation again. It's in a loop.
The first of which may have succeeded.  Your patch will introduce
a memory leak.

		Dave

 > 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) |



-- 
http://www.codemonkey.org.uk

  reply	other threads:[~2006-07-29 17:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-28 23:39 via sata oops on init Dave Jones
2006-07-29 14:45 ` Johannes Weiner
2006-07-29 16:41   ` Dave Jones
2006-07-29 17:04     ` Johannes Weiner
2006-07-29 17:10       ` Dave Jones [this message]
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=20060729171044.GE16946@redhat.com \
    --to=davej@redhat.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 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.