public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] cleanup of ipc/msg.c
@ 2004-07-03 22:09 Manfred Spraul
  2004-07-04 11:49 ` Manfred Spraul
  0 siblings, 1 reply; 2+ messages in thread
From: Manfred Spraul @ 2004-07-03 22:09 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-kernel

Hi,

Attached is a cleanup of the main loops in sys_msgrcv and sys_msgsnd, 
based on ipc_lock_by_ptr(). Most backward gotos are gone, instead normal 
"for(;;)" loops until a suitable message is found.

Additionally, the patch
- reintroduces lockless receive, same implementation as in ipc/mqueue.c.
- fixes a rare BUG(): if queue settings are changed with 
msgctl(,IPC_SET,) while a thread is sleeping in msgrcv() and the queue 
is then destroyed with msgctl(,IPC_RMID,) before the sleeping thread 
noticed the new configuration, then the BUG() is line 764 would trigger.

Andrew, could you add it to -mm? If it's too large then I'll split out 
the bugfix, it's a oneliner [remove the BUG()].

Signed-Off-By: Manfred Spraul <manfred@colorfullife.com>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-07-04 11:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-07-03 22:09 [PATCH] cleanup of ipc/msg.c Manfred Spraul
2004-07-04 11:49 ` Manfred Spraul

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox