lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Tue, 10 Jul 2007 03:50:04 -0400 (EDT)
From:	"Robert P. J. Day" <rpjday@...dspring.com>
To:	Oleg Nesterov <oleg@...sign.ru>
cc:	Al Viro <viro@...iv.linux.org.uk>, linux-kernel@...r.kernel.org
Subject: Re: schedule_timeout() called with state TASK_RUNNING from fs/select.c

On Sun, 8 Jul 2007, Oleg Nesterov wrote:

> Robert P. J. Day wrote:
> >
> >  as i understand it, schedule_timeout() should always be called with
> > a current->state of TASK_INTERRUPTIBLE or TASK_UNINTERRUPTIBLE, no?
>
> No.
>
> Yes, it is pointless to call schedule() if it is known that ->state ==
> TASK_RUNNING, but sometimes the task doesn't know its state when it
> calls schedule/schedule_timeout, the state could be changed by
> try_to_wake_up().
>
> See wait_event_timeout() as an example.

fair enough.  i already knew that, technically, it wasn't an error to
call schedule_timeout() with state == TASK_RUNNING.  i was just
following up on something out of love's kernel book, and i got curious
as to whether the above ever happened.  now i know.

rday
--
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry
Waterloo, Ontario, CANADA

http://fsdev.net/wiki/index.php?title=Main_Page
========================================================================
-
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ