[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130109174922.GA31211@redhat.com>
Date: Wed, 9 Jan 2013 18:49:22 +0100
From: Oleg Nesterov <oleg@...hat.com>
To: Michel Lespinasse <walken@...gle.com>
Cc: David Howells <dhowells@...hat.com>,
Thomas Gleixner <tglx@...utronix.de>,
Salman Qazi <sqazi@...gle.com>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: rwlock_t unfairness and tasklist_lock
On 01/08, Michel Lespinasse wrote:
>
> Like others before me, I have discovered how easy it is to DOS a
> system by abusing the rwlock_t unfairness and causing the
> tasklist_lock read side to be continuously held
Yes. Plus it has perfomance problems.
It should die. We still need the global lock to protect, say,
init_task.tasks list, but otherwise we need the per-process locking.
> - Would there be any fundamental objection to implementing a fair
> rwlock_t and dealing with the reentrancy issues in tasklist_lock ? My
> proposal there would be along the lines of:
I don't really understand your proposal in details, but until we kill
tasklist_lock, perhaps it makes sense to implement something simple, say,
write-biased rwlock and add "int task_struct->tasklist_read_lock_counter"
to avoid the read-write-read deadlock.
Oleg.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists