* Dereferencing semaphores and atomic_t's
@ 2002-10-02 10:16 Russell King
2002-10-02 10:32 ` David S. Miller
2002-10-02 13:21 ` Alan Cox
0 siblings, 2 replies; 4+ messages in thread
From: Russell King @ 2002-10-02 10:16 UTC (permalink / raw)
To: linux-kernel
drivers/scsi/scsi_error.c:
SCSI_LOG_ERROR_RECOVERY(3, printk("Wake up parent %d\n",
shost->eh_notify->count.counter));
up(shost->eh_notify);
drivers/scsi/hosts.c:
up(shost->eh_wait);
SCSI_LOG_ERROR_RECOVERY(5, printk("Waking error handler"
"thread (%d)\n",
atomic_read(&shost->eh_wait->count)));
up(shost->eh_wait);
SCSI_LOG_ERROR_RECOVERY(5, printk("Waking error handler"
"thread (%d)\n",
atomic_read(&shost->eh_wait->count)));
Do we really allow this type of layering violation?
(There appear to be some circumstances when obtaining the semaphore count is
useful, but shouldn't we provide an architecture helper function to do that
since a semaphore structure _is_ an architecture-defined opaque structure.)
--
Russell King (rmk@arm.linux.org.uk) The developer of ARM Linux
http://www.arm.linux.org.uk/personal/aboutme.html
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: Dereferencing semaphores and atomic_t's
2002-10-02 10:16 Dereferencing semaphores and atomic_t's Russell King
@ 2002-10-02 10:32 ` David S. Miller
2002-10-02 13:21 ` Alan Cox
1 sibling, 0 replies; 4+ messages in thread
From: David S. Miller @ 2002-10-02 10:32 UTC (permalink / raw)
To: rmk; +Cc: linux-kernel
From: Russell King <rmk@arm.linux.org.uk>
Date: Wed, 2 Oct 2002 11:16:26 +0100
Do we really allow this type of layering violation?
No, it should be killed :-)
(There appear to be some circumstances when obtaining the semaphore count is
useful, but shouldn't we provide an architecture helper function to do that
since a semaphore structure _is_ an architecture-defined opaque structure.)
Feel free to make one.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Dereferencing semaphores and atomic_t's
2002-10-02 10:16 Dereferencing semaphores and atomic_t's Russell King
2002-10-02 10:32 ` David S. Miller
@ 2002-10-02 13:21 ` Alan Cox
2002-10-02 16:46 ` Mike Anderson
1 sibling, 1 reply; 4+ messages in thread
From: Alan Cox @ 2002-10-02 13:21 UTC (permalink / raw)
To: Russell King; +Cc: linux-kernel
On Wed, 2002-10-02 at 11:16, Russell King wrote:
> drivers/scsi/scsi_error.c:
>
> SCSI_LOG_ERROR_RECOVERY(3, printk("Wake up parent %d\n",
> shost->eh_notify->count.counter));
>
This is already fixed in 2.4 - just forward port the fixes
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: Dereferencing semaphores and atomic_t's
2002-10-02 13:21 ` Alan Cox
@ 2002-10-02 16:46 ` Mike Anderson
0 siblings, 0 replies; 4+ messages in thread
From: Mike Anderson @ 2002-10-02 16:46 UTC (permalink / raw)
To: Alan Cox; +Cc: Russell King, linux-kernel
Alan Cox [alan@lxorguk.ukuu.org.uk] wrote:
> On Wed, 2002-10-02 at 11:16, Russell King wrote:
> > drivers/scsi/scsi_error.c:
> >
> > SCSI_LOG_ERROR_RECOVERY(3, printk("Wake up parent %d\n",
> > shost->eh_notify->count.counter));
> >
>
> This is already fixed in 2.4 - just forward port the fixes
I added sem_getcount to my scsi_error.c update and my scsi_hosts update
patch. I should have these out soon.
Sorry Russell that it has taken longer than I said to get the updated
scsi_error patch out. I am still investigating an issue with getting
door lock to work post fault insertion.
-andmike
--
Michael Anderson
andmike@us.ibm.com
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2002-10-02 16:41 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-10-02 10:16 Dereferencing semaphores and atomic_t's Russell King
2002-10-02 10:32 ` David S. Miller
2002-10-02 13:21 ` Alan Cox
2002-10-02 16:46 ` Mike Anderson
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.