From: Christoph Hellwig <hch@infradead.org>
To: Matthew Wilcox <willy@debian.org>
Cc: Andrew Morton <akpm@osdl.org>,
linux-scsi@vger.kernel.org, kaos@sgi.com,
linux-kernel@vger.kernel.org, linux-ia64@vger.kernel.org
Subject: Re: Fw: 2.6.6-rc3 ia64 smp_call_function() called with interrupts disabled
Date: Tue, 4 May 2004 10:41:43 +0100 [thread overview]
Message-ID: <20040504104143.A21207@infradead.org> (raw)
In-Reply-To: <20040503203512.GP2281@parcelfarce.linux.theplanet.co.uk>; from willy@debian.org on Mon, May 03, 2004 at 09:35:13PM +0100
On Mon, May 03, 2004 at 09:35:13PM +0100, Matthew Wilcox wrote:
> That patch is crap -- it only frees the memory on the error path, not
> the normal exit. Since I got confused by this function, it struck me
> as not unreasonable that somebody else might also get confused by it
> and split it into two parts.
>
> I simplified some of the code. The old code took the lock, scanned
> through looking for a free slot, dropped the lock, allocated an sdp,
> grabbed the lock and checked the slot was still free, branching back
> if it had raced. This rewrite assumes that we will find a slot and
> allocates an sdp in advance.
>
> Does anybody like this patch? It survived booting on my test box which
> only has one scsi device. More testing welcomed.
Better than what was there, but I still don't like it. A global array
of devices is just utter crap. Every entry point from scsi already has
struct scsi_device from which we can derive the sg-specific portion easily,
and for anything else (from a quick look that seems to be only procfs
stuff which should fade out anyway) a linear search on a linked list
is okay.
btw, why are we vmalloc()ing Sg_device?
next prev parent reply other threads:[~2004-05-04 9:41 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-05-03 4:45 Fw: 2.6.6-rc3 ia64 smp_call_function() called with interrupts disabled Andrew Morton
2004-05-03 12:29 ` Matthew Wilcox
2004-05-03 20:35 ` Matthew Wilcox
2004-05-04 9:41 ` Christoph Hellwig [this message]
2004-05-14 20:00 ` Patrick Mansfield
2004-05-13 11:56 ` Douglas Gilbert
2004-05-13 14:43 ` Patrick Mansfield
2004-05-16 2:21 ` [PATCH] sg driver against lk 2.6.6 Douglas Gilbert
2004-06-04 15:21 ` Patrick Mansfield
2004-06-04 15:28 ` James Bottomley
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=20040504104143.A21207@infradead.org \
--to=hch@infradead.org \
--cc=akpm@osdl.org \
--cc=kaos@sgi.com \
--cc=linux-ia64@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=willy@debian.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