lkml.org 
[lkml]   [2006]   [Jul]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Ref counting for tty_struct and some locking clean up
On Fri, 7 Jul 2006 20:37:36 -0400 Jon Smirl wrote:

> This patch removes tty_mutex and replaces it with a ref counted
> tty_struct. A new spinlock, tty_lock, serializes tty
> creation/destruction. This code thoroughly audits everyone taking
> references to tty_struct and tracks them. I have been running it
> locally for a few days without any issues.
>
> If there is a refcount problem it will trigger a WARN_ON. If you hit
> one, defining DEBUG_TTY_REFCOUNT will provide plenty of debug info to
> help locate the missing reference. I definitely found multiple locking
> holes in the old tty_mutex code but they they look hard to hit.
>
> This is just a first step, if this code proves to be stable I'll do
> another round of cleanup. There is room for a lot more work to be
> done. Ultimately there may not even be a need for a tty refcount if
> everything is locked correctly. But that is a big step and we should
> take some smaller ones first.
>
> This is meant for mm until it gets some testing - I don't want to
> break anyone's console. If gmail wraps it let me know and I'll send
> you an attachment.

It has one wrapped line in it but does not apply cleanly to
2.6.18-rc1 or to 2.6.17-mm6. What was it diffed against?

---
~Randy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-07-08 03:33    [W:0.285 / U:0.320 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site