<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/include/linux/wait.h, branch v2.6.26-rc5</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>include/linux: Remove all users of FASTCALL() macro</title>
<updated>2008-02-14T00:21:18+00:00</updated>
<author>
<name>Harvey Harrison</name>
<email>harvey.harrison@gmail.com</email>
</author>
<published>2008-02-13T23:03:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=b3c97528689619fc66569b30bf83d09d9929521a'/>
<id>b3c97528689619fc66569b30bf83d09d9929521a</id>
<content type='text'>
FASTCALL() is always expanded to empty, remove it.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Harvey Harrison &lt;harvey.harrison@gmail.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
FASTCALL() is always expanded to empty, remove it.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Harvey Harrison &lt;harvey.harrison@gmail.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>lockdep: annotate epoll</title>
<updated>2008-02-05T17:44:07+00:00</updated>
<author>
<name>Peter Zijlstra</name>
<email>a.p.zijlstra@chello.nl</email>
</author>
<published>2008-02-05T06:27:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=0ccf831cbee94df9c5006dd46248c0f07847dd7c'/>
<id>0ccf831cbee94df9c5006dd46248c0f07847dd7c</id>
<content type='text'>
On Sat, 2008-01-05 at 13:35 -0800, Davide Libenzi wrote:

&gt; I remember I talked with Arjan about this time ago. Basically, since 1)
&gt; you can drop an epoll fd inside another epoll fd 2) callback-based wakeups
&gt; are used, you can see a wake_up() from inside another wake_up(), but they
&gt; will never refer to the same lock instance.
&gt; Think about:
&gt;
&gt; 	dfd = socket(...);
&gt; 	efd1 = epoll_create();
&gt; 	efd2 = epoll_create();
&gt; 	epoll_ctl(efd1, EPOLL_CTL_ADD, dfd, ...);
&gt; 	epoll_ctl(efd2, EPOLL_CTL_ADD, efd1, ...);
&gt;
&gt; When a packet arrives to the device underneath "dfd", the net code will
&gt; issue a wake_up() on its poll wake list. Epoll (efd1) has installed a
&gt; callback wakeup entry on that queue, and the wake_up() performed by the
&gt; "dfd" net code will end up in ep_poll_callback(). At this point epoll
&gt; (efd1) notices that it may have some event ready, so it needs to wake up
&gt; the waiters on its poll wait list (efd2). So it calls ep_poll_safewake()
&gt; that ends up in another wake_up(), after having checked about the
&gt; recursion constraints. That are, no more than EP_MAX_POLLWAKE_NESTS, to
&gt; avoid stack blasting. Never hit the same queue, to avoid loops like:
&gt;
&gt; 	epoll_ctl(efd2, EPOLL_CTL_ADD, efd1, ...);
&gt; 	epoll_ctl(efd3, EPOLL_CTL_ADD, efd2, ...);
&gt; 	epoll_ctl(efd4, EPOLL_CTL_ADD, efd3, ...);
&gt; 	epoll_ctl(efd1, EPOLL_CTL_ADD, efd4, ...);
&gt;
&gt; The code "if (tncur-&gt;wq == wq || ..." prevents re-entering the same
&gt; queue/lock.

Since the epoll code is very careful to not nest same instance locks
allow the recursion.

Signed-off-by: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Tested-by: Stefan Richter &lt;stefanr@s5r6.in-berlin.de&gt;
Acked-by: Davide Libenzi &lt;davidel@xmailserver.org&gt;
Cc: &lt;stable@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On Sat, 2008-01-05 at 13:35 -0800, Davide Libenzi wrote:

&gt; I remember I talked with Arjan about this time ago. Basically, since 1)
&gt; you can drop an epoll fd inside another epoll fd 2) callback-based wakeups
&gt; are used, you can see a wake_up() from inside another wake_up(), but they
&gt; will never refer to the same lock instance.
&gt; Think about:
&gt;
&gt; 	dfd = socket(...);
&gt; 	efd1 = epoll_create();
&gt; 	efd2 = epoll_create();
&gt; 	epoll_ctl(efd1, EPOLL_CTL_ADD, dfd, ...);
&gt; 	epoll_ctl(efd2, EPOLL_CTL_ADD, efd1, ...);
&gt;
&gt; When a packet arrives to the device underneath "dfd", the net code will
&gt; issue a wake_up() on its poll wake list. Epoll (efd1) has installed a
&gt; callback wakeup entry on that queue, and the wake_up() performed by the
&gt; "dfd" net code will end up in ep_poll_callback(). At this point epoll
&gt; (efd1) notices that it may have some event ready, so it needs to wake up
&gt; the waiters on its poll wait list (efd2). So it calls ep_poll_safewake()
&gt; that ends up in another wake_up(), after having checked about the
&gt; recursion constraints. That are, no more than EP_MAX_POLLWAKE_NESTS, to
&gt; avoid stack blasting. Never hit the same queue, to avoid loops like:
&gt;
&gt; 	epoll_ctl(efd2, EPOLL_CTL_ADD, efd1, ...);
&gt; 	epoll_ctl(efd3, EPOLL_CTL_ADD, efd2, ...);
&gt; 	epoll_ctl(efd4, EPOLL_CTL_ADD, efd3, ...);
&gt; 	epoll_ctl(efd1, EPOLL_CTL_ADD, efd4, ...);
&gt;
&gt; The code "if (tncur-&gt;wq == wq || ..." prevents re-entering the same
&gt; queue/lock.

Since the epoll code is very careful to not nest same instance locks
allow the recursion.

Signed-off-by: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Tested-by: Stefan Richter &lt;stefanr@s5r6.in-berlin.de&gt;
Acked-by: Davide Libenzi &lt;davidel@xmailserver.org&gt;
Cc: &lt;stable@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Add wait_event_killable</title>
<updated>2007-12-06T22:40:14+00:00</updated>
<author>
<name>Matthew Wilcox</name>
<email>matthew@wil.cx</email>
</author>
<published>2007-12-06T17:00:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=1411d5a7fbe7dce1568b6f0a94c7cbc69eed1bfe'/>
<id>1411d5a7fbe7dce1568b6f0a94c7cbc69eed1bfe</id>
<content type='text'>
Signed-off-by: Matthew Wilcox &lt;willy@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Matthew Wilcox &lt;willy@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>wait: Use TASK_NORMAL</title>
<updated>2007-12-06T22:34:36+00:00</updated>
<author>
<name>Matthew Wilcox</name>
<email>matthew@wil.cx</email>
</author>
<published>2007-12-06T22:34:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e64d66c8edf11629aa203328daf898775ee27dd4'/>
<id>e64d66c8edf11629aa203328daf898775ee27dd4</id>
<content type='text'>
Also move wake_up_locked() to be with the related functions

Signed-off-by: Matthew Wilcox &lt;willy@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Also move wake_up_locked() to be with the related functions

Signed-off-by: Matthew Wilcox &lt;willy@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>sched: clean up sleep_on() APIs</title>
<updated>2007-07-09T16:52:01+00:00</updated>
<author>
<name>Ingo Molnar</name>
<email>mingo@elte.hu</email>
</author>
<published>2007-07-09T16:52:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=0fec171cdbd7763ef86cbaccb91f3708de6a9003'/>
<id>0fec171cdbd7763ef86cbaccb91f3708de6a9003</id>
<content type='text'>
clean up the sleep_on() APIs:

 - do not use fastcall
 - replace fragile macro magic with proper inline functions

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
clean up the sleep_on() APIs:

 - do not use fastcall
 - replace fragile macro magic with proper inline functions

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] lockdep: annotate DECLARE_WAIT_QUEUE_HEAD</title>
<updated>2006-10-30T20:08:40+00:00</updated>
<author>
<name>Peter Zijlstra</name>
<email>a.p.zijlstra@chello.nl</email>
</author>
<published>2006-10-30T06:46:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=7259f0d05d595b73ef312a082e628627c6414969'/>
<id>7259f0d05d595b73ef312a082e628627c6414969</id>
<content type='text'>
kernel: INFO: trying to register non-static key.
kernel: the code is fine but needs lockdep annotation.
kernel: turning off the locking correctness validator.
kernel:  [&lt;c04051ed&gt;] show_trace_log_lvl+0x58/0x16a
kernel:  [&lt;c04057fa&gt;] show_trace+0xd/0x10
kernel:  [&lt;c0405913&gt;] dump_stack+0x19/0x1b
kernel:  [&lt;c043b1e2&gt;] __lock_acquire+0xf0/0x90d
kernel:  [&lt;c043bf70&gt;] lock_acquire+0x4b/0x6b
kernel:  [&lt;c061472f&gt;] _spin_lock_irqsave+0x22/0x32
kernel:  [&lt;c04363d3&gt;] prepare_to_wait+0x17/0x4b
kernel:  [&lt;f89a24b6&gt;] lpfc_do_work+0xdd/0xcc2 [lpfc]
kernel:  [&lt;c04361b9&gt;] kthread+0xc3/0xf2
kernel:  [&lt;c0402005&gt;] kernel_thread_helper+0x5/0xb

Another case of non-static lockdep keys; duplicate the paradigm set by
DECLARE_COMPLETION_ONSTACK and introduce DECLARE_WAIT_QUEUE_HEAD_ONSTACK.

Signed-off-by: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Greg KH &lt;gregkh@suse.de&gt;
Cc: Markus Lidel &lt;markus.lidel@shadowconnect.com&gt;
Acked-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Cc: Arjan van de Ven &lt;arjan@infradead.org&gt;
Cc: James Bottomley &lt;James.Bottomley@steeleye.com&gt;
Cc: Marcel Holtmann &lt;marcel@holtmann.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
kernel: INFO: trying to register non-static key.
kernel: the code is fine but needs lockdep annotation.
kernel: turning off the locking correctness validator.
kernel:  [&lt;c04051ed&gt;] show_trace_log_lvl+0x58/0x16a
kernel:  [&lt;c04057fa&gt;] show_trace+0xd/0x10
kernel:  [&lt;c0405913&gt;] dump_stack+0x19/0x1b
kernel:  [&lt;c043b1e2&gt;] __lock_acquire+0xf0/0x90d
kernel:  [&lt;c043bf70&gt;] lock_acquire+0x4b/0x6b
kernel:  [&lt;c061472f&gt;] _spin_lock_irqsave+0x22/0x32
kernel:  [&lt;c04363d3&gt;] prepare_to_wait+0x17/0x4b
kernel:  [&lt;f89a24b6&gt;] lpfc_do_work+0xdd/0xcc2 [lpfc]
kernel:  [&lt;c04361b9&gt;] kthread+0xc3/0xf2
kernel:  [&lt;c0402005&gt;] kernel_thread_helper+0x5/0xb

Another case of non-static lockdep keys; duplicate the paradigm set by
DECLARE_COMPLETION_ONSTACK and introduce DECLARE_WAIT_QUEUE_HEAD_ONSTACK.

Signed-off-by: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Greg KH &lt;gregkh@suse.de&gt;
Cc: Markus Lidel &lt;markus.lidel@shadowconnect.com&gt;
Acked-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Cc: Arjan van de Ven &lt;arjan@infradead.org&gt;
Cc: James Bottomley &lt;James.Bottomley@steeleye.com&gt;
Cc: Marcel Holtmann &lt;marcel@holtmann.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] uninline init_waitqueue_head()</title>
<updated>2006-07-10T20:24:25+00:00</updated>
<author>
<name>Ingo Molnar</name>
<email>mingo@elte.hu</email>
</author>
<published>2006-07-10T11:45:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=21d71f513b6221f482ed6ad45e05f073ae67f319'/>
<id>21d71f513b6221f482ed6ad45e05f073ae67f319</id>
<content type='text'>
allyesconfig vmlinux size delta:

  text            data    bss     dec          filename
  20736884        6073834 3075176 29885894     vmlinux.before
  20721009        6073966 3075176 29870151     vmlinux.after

~18 bytes per callsite, 15K of text size (~0.1%) saved.

(as an added bonus this also removes a lockdep annotation.)

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
allyesconfig vmlinux size delta:

  text            data    bss     dec          filename
  20736884        6073834 3075176 29885894     vmlinux.before
  20721009        6073966 3075176 29870151     vmlinux.after

~18 bytes per callsite, 15K of text size (~0.1%) saved.

(as an added bonus this also removes a lockdep annotation.)

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] lockdep: annotate waitqueues</title>
<updated>2006-07-03T22:27:07+00:00</updated>
<author>
<name>Ingo Molnar</name>
<email>mingo@elte.hu</email>
</author>
<published>2006-07-03T07:25:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=eb4542b98c81e22e08587b747b21986a45360999'/>
<id>eb4542b98c81e22e08587b747b21986a45360999</id>
<content type='text'>
Create one lock class for all waitqueue locks in the kernel.  Has no effect on
non-lockdep kernels.

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Create one lock class for all waitqueue locks in the kernel.  Has no effect on
non-lockdep kernels.

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] lockdep: locking init debugging improvement</title>
<updated>2006-07-03T22:27:02+00:00</updated>
<author>
<name>Ingo Molnar</name>
<email>mingo@elte.hu</email>
</author>
<published>2006-07-03T07:24:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e4d919188554a77c798a267e098059bc9aa39726'/>
<id>e4d919188554a77c798a267e098059bc9aa39726</id>
<content type='text'>
Locking init improvement:

 - introduce and use __SPIN_LOCK_UNLOCKED for array initializations,
   to pass in the name string of locks, used by debugging

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Locking init improvement:

 - introduce and use __SPIN_LOCK_UNLOCKED for array initializations,
   to pass in the name string of locks, used by debugging

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Don't include linux/config.h from anywhere else in include/</title>
<updated>2006-04-26T11:56:16+00:00</updated>
<author>
<name>David Woodhouse</name>
<email>dwmw2@infradead.org</email>
</author>
<published>2006-04-26T11:56:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=62c4f0a2d5a188f73a94f2cb8ea0dba3e7cf0a7f'/>
<id>62c4f0a2d5a188f73a94f2cb8ea0dba3e7cf0a7f</id>
<content type='text'>
Signed-off-by: David Woodhouse &lt;dwmw2@infradead.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: David Woodhouse &lt;dwmw2@infradead.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
