<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/kernel, branch v2.6.29.2</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v2.6.29.2</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v2.6.29.2'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2009-04-27T17:37:00Z</updated>
<entry>
<title>hrtimer: fix rq-&gt;lock inversion (again)</title>
<updated>2009-04-27T17:37:00Z</updated>
<author>
<name>Peter Zijlstra</name>
<email>a.p.zijlstra@chello.nl</email>
</author>
<published>2009-03-13T11:21:27Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=7b457a610d6ab4d9bc654948da12968833510b2e'/>
<id>urn:sha1:7b457a610d6ab4d9bc654948da12968833510b2e</id>
<content type='text'>
upstream commit: 7f1e2ca9f04b02794597f60e7b1d43f0a1317939

It appears I inadvertly introduced rq-&gt;lock recursion to the
hrtimer_start() path when I delegated running already expired
timers to softirq context.

This patch fixes it by introducing a __hrtimer_start_range_ns()
method that will not use raise_softirq_irqoff() but
__raise_softirq_irqoff() which avoids the wakeup.

It then also changes schedule() to check for pending softirqs and
do the wakeup then, I'm not quite sure I like this last bit, nor
am I convinced its really needed.

Signed-off-by: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: paulus@samba.org
LKML-Reference: &lt;20090313112301.096138802@chello.nl&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Tested-by: Mikael Pettersson &lt;mikpe@it.uu.se&gt;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
</content>
</entry>
<entry>
<title>posix-timers: fix RLIMIT_CPU &amp;&amp; setitimer(CPUCLOCK_PROF)</title>
<updated>2009-04-27T17:36:59Z</updated>
<author>
<name>Oleg Nesterov</name>
<email>oleg@redhat.com</email>
</author>
<published>2009-04-09T18:20:08Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=55e3b46ded854d9fc2408d0d15a6a5aea4986333'/>
<id>urn:sha1:55e3b46ded854d9fc2408d0d15a6a5aea4986333</id>
<content type='text'>
upstream commit: 8f2e586567b1bad72dac7c3810fe9a2ef7117506

update_rlimit_cpu() tries to optimize out set_process_cpu_timer() in case
when we already have CPUCLOCK_PROF timer which should expire first. But it
uses cputime_lt() instead of cputime_gt().

Test case:

	int main(void)
	{
		struct itimerval it = {
			.it_value = { .tv_sec = 1000 },
		};

		assert(!setitimer(ITIMER_PROF, &amp;it, NULL));

		struct rlimit rl = {
			.rlim_cur = 1,
			.rlim_max = 1,
		};

		assert(!setrlimit(RLIMIT_CPU, &amp;rl));

		for (;;)
			;

		return 0;
	}

Without this patch, the task is not killed as RLIMIT_CPU demands.

Signed-off-by: Oleg Nesterov &lt;oleg@redhat.com&gt;
Acked-by: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Peter Lojkin &lt;ia6432@inbox.ru&gt;
Cc: Roland McGrath &lt;roland@redhat.com&gt;
Cc: stable@kernel.org
LKML-Reference: &lt;20090327000610.GA10108@redhat.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
</content>
</entry>
<entry>
<title>posix-timers: fix RLIMIT_CPU &amp;&amp; fork()</title>
<updated>2009-04-27T17:36:59Z</updated>
<author>
<name>Oleg Nesterov</name>
<email>oleg@redhat.com</email>
</author>
<published>2009-04-09T18:20:10Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=3fe90c4dc50b1c4030d73d196a5d812ea906a4c9'/>
<id>urn:sha1:3fe90c4dc50b1c4030d73d196a5d812ea906a4c9</id>
<content type='text'>
upstream commit: 6279a751fe096a21dc7704e918d570d3ff06e769

See http://bugzilla.kernel.org/show_bug.cgi?id=12911

copy_signal() copies signal-&gt;rlim, but RLIMIT_CPU is "lost". Because
posix_cpu_timers_init_group() sets cputime_expires.prof_exp = 0 and thus
fastpath_timer_check() returns false unless we have other expired cpu timers.

Change copy_signal() to set cputime_expires.prof_exp if we have RLIMIT_CPU.
Also, set cputimer.running = 1 in that case. This is not strictly necessary,
but imho makes sense.

Reported-by: Peter Lojkin &lt;ia6432@inbox.ru&gt;
Signed-off-by: Oleg Nesterov &lt;oleg@redhat.com&gt;
Acked-by: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Peter Lojkin &lt;ia6432@inbox.ru&gt;
Cc: Roland McGrath &lt;roland@redhat.com&gt;
Cc: stable@kernel.org
LKML-Reference: &lt;20090327000607.GA10104@redhat.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
</content>
</entry>
<entry>
<title>posixtimers, sched: Fix posix clock monotonicity</title>
<updated>2009-04-27T17:36:59Z</updated>
<author>
<name>Hidetoshi Seto</name>
<email>seto.hidetoshi@jp.fujitsu.com</email>
</author>
<published>2009-04-09T18:20:12Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=39cd13c96cfc4d9d5992e93625fe6d6cb4fe3991'/>
<id>urn:sha1:39cd13c96cfc4d9d5992e93625fe6d6cb4fe3991</id>
<content type='text'>
upstream commit: c5f8d99585d7b5b7e857fabf8aefd0174903a98c

Impact: Regression fix (against clock_gettime() backwarding bug)

This patch re-introduces a couple of functions, task_sched_runtime
and thread_group_sched_runtime, which was once removed at the
time of 2.6.28-rc1.

These functions protect the sampling of thread/process clock with
rq lock.  This rq lock is required not to update rq-&gt;clock during
the sampling.

i.e.
  The clock_gettime() may return
   ((accounted runtime before update) + (delta after update))
  that is less than what it should be.

v2 -&gt; v3:
	- Rename static helper function __task_delta_exec()
	  to do_task_delta_exec() since -tip tree already has
	  a __task_delta_exec() of different version.

v1 -&gt; v2:
	- Revises comments of function and patch description.
	- Add note about accuracy of thread group's runtime.

Signed-off-by: Hidetoshi Seto &lt;seto.hidetoshi@jp.fujitsu.com&gt;
Acked-by: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: stable@kernel.org	[2.6.28.x][2.6.29.x]
LKML-Reference: &lt;49D1CC93.4080401@jp.fujitsu.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
</content>
</entry>
<entry>
<title>kprobes: Fix locking imbalance in kretprobes</title>
<updated>2009-04-27T17:36:58Z</updated>
<author>
<name>Ananth N Mavinakayanahalli</name>
<email>ananth@in.ibm.com</email>
</author>
<published>2009-04-05T18:20:22Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=3b3e59f78d3bf0e0818a9b759484138d4300a72e'/>
<id>urn:sha1:3b3e59f78d3bf0e0818a9b759484138d4300a72e</id>
<content type='text'>
upstream commit: f02b8624fedca39886b0eef770dca70c2f0749b3

Fix locking imbalance in kretprobes:

=====================================
[ BUG: bad unlock balance detected! ]
-------------------------------------
kthreadd/2 is trying to release lock (&amp;rp-&gt;lock) at:
[&lt;c06b3080&gt;] pre_handler_kretprobe+0xea/0xf4
but there are no more locks to release!

other info that might help us debug this:
1 lock held by kthreadd/2:
 #0:  (rcu_read_lock){..--}, at: [&lt;c06b2b24&gt;] __atomic_notifier_call_chain+0x0/0x5a

stack backtrace:
Pid: 2, comm: kthreadd Not tainted 2.6.29-rc8 #1
Call Trace:
 [&lt;c06ae498&gt;] ? printk+0xf/0x17
 [&lt;c06b3080&gt;] ? pre_handler_kretprobe+0xea/0xf4
 [&lt;c044ce6c&gt;] print_unlock_inbalance_bug+0xc3/0xce
 [&lt;c0444d4b&gt;] ? clocksource_read+0x7/0xa
 [&lt;c04450a4&gt;] ? getnstimeofday+0x5f/0xf6
 [&lt;c044a9ca&gt;] ? register_lock_class+0x17/0x293
 [&lt;c044b72c&gt;] ? mark_lock+0x1e/0x30b
 [&lt;c0448956&gt;] ? tick_dev_program_event+0x4a/0xbc
 [&lt;c0498100&gt;] ? __slab_alloc+0xa5/0x415
 [&lt;c06b2fbe&gt;] ? pre_handler_kretprobe+0x28/0xf4
 [&lt;c06b3080&gt;] ? pre_handler_kretprobe+0xea/0xf4
 [&lt;c044cf1b&gt;] lock_release_non_nested+0xa4/0x1a5
 [&lt;c06b3080&gt;] ? pre_handler_kretprobe+0xea/0xf4
 [&lt;c044d15d&gt;] lock_release+0x141/0x166
 [&lt;c06b07dd&gt;] _spin_unlock_irqrestore+0x19/0x50
 [&lt;c06b3080&gt;] pre_handler_kretprobe+0xea/0xf4
 [&lt;c06b20b5&gt;] kprobe_exceptions_notify+0x1c9/0x43e
 [&lt;c06b2b02&gt;] notifier_call_chain+0x26/0x48
 [&lt;c06b2b5b&gt;] __atomic_notifier_call_chain+0x37/0x5a
 [&lt;c06b2b24&gt;] ? __atomic_notifier_call_chain+0x0/0x5a
 [&lt;c06b2b8a&gt;] atomic_notifier_call_chain+0xc/0xe
 [&lt;c0442d0d&gt;] notify_die+0x2d/0x2f
 [&lt;c06b0f9c&gt;] do_int3+0x1f/0x71
 [&lt;c06b0e84&gt;] int3+0x2c/0x34
 [&lt;c042d476&gt;] ? do_fork+0x1/0x288
 [&lt;c040221b&gt;] ? kernel_thread+0x71/0x79
 [&lt;c043ed1b&gt;] ? kthread+0x0/0x60
 [&lt;c043ed1b&gt;] ? kthread+0x0/0x60
 [&lt;c04040b8&gt;] ? kernel_thread_helper+0x0/0x10
 [&lt;c043ec7f&gt;] kthreadd+0xac/0x148
 [&lt;c043ebd3&gt;] ? kthreadd+0x0/0x148
 [&lt;c04040bf&gt;] kernel_thread_helper+0x7/0x10

Signed-off-by: Ananth N Mavinakayanahalli &lt;ananth@in.ibm.com&gt;
Tested-by: Bharata B Rao &lt;bharata@linux.vnet.ibm.com&gt;
Cc: Masami Hiramatsu &lt;mhiramat@redhat.com&gt;
Cc: Jim Keniston &lt;jkenisto@us.ibm.com&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Cc: &lt;stable@kernel.org&gt; [2.6.29.x, 2.6.28.x, 2.6.27.x]
LKML-Reference: &lt;20090318113621.GB4129@in.ibm.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
</content>
</entry>
<entry>
<title>sysctl: fix suid_dumpable and lease-break-time sysctls</title>
<updated>2009-04-27T17:36:55Z</updated>
<author>
<name>Matthew Wilcox</name>
<email>matthew@wil.cx</email>
</author>
<published>2009-04-03T04:35:07Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=037e58f985f0573b0dc7d2ee39b3a703d23efa13'/>
<id>urn:sha1:037e58f985f0573b0dc7d2ee39b3a703d23efa13</id>
<content type='text'>
upstream commit: 8e654fba4a376f436bdfe361fc5cdbc87ac09b35

Arne de Bruijn points out that commit
76fdbb25f963de5dc1e308325f0578a2f92b1c2d ("coredump masking: bound
suid_dumpable sysctl") mistakenly limits lease-break-time instead of
suid_dumpable.

Signed-off-by: Matthew Wilcox &lt;matthew@wil.cx&gt;
Reported-by: Arne de Bruijn &lt;kernelbt@arbruijn.dds.nl&gt;
Cc: Kawai, Hidehiro &lt;hidehiro.kawai.ez@hitachi.com&gt;
Cc: Alexey Dobriyan &lt;adobriyan@gmail.com&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;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
</content>
</entry>
<entry>
<title>tracing/core: fix early free of cpumasks</title>
<updated>2009-04-27T17:36:52Z</updated>
<author>
<name>Frederic Weisbecker</name>
<email>fweisbec@gmail.com</email>
</author>
<published>2009-03-16T00:45:03Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=69186bb21b2238901ccabd01f29669cf4e147f71'/>
<id>urn:sha1:69186bb21b2238901ccabd01f29669cf4e147f71</id>
<content type='text'>
upstream commit: 2fc1dfbe17e7705c55b7a99da995fa565e26f151

Impact: fix crashes when tracing cpumasks

While ring-buffer allocation, the cpumasks are allocated too,
including the tracing cpumask and the per-cpu file mask handler.
But these cpumasks are freed accidentally just after.
Fix it.

Reported-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
LKML-Reference: &lt;1237164303-11476-1-git-send-email-fweisbec@gmail.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
</content>
</entry>
<entry>
<title>fix ptrace slowness</title>
<updated>2009-03-23T16:22:31Z</updated>
<author>
<name>Miklos Szeredi</name>
<email>mszeredi@suse.cz</email>
</author>
<published>2009-03-23T15:07:24Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=53da1d9456fe7f87a920a78fdbdcf1225d197cb7'/>
<id>urn:sha1:53da1d9456fe7f87a920a78fdbdcf1225d197cb7</id>
<content type='text'>
This patch fixes bug #12208:

  Bug-Entry       : http://bugzilla.kernel.org/show_bug.cgi?id=12208
  Subject         : uml is very slow on 2.6.28 host

This turned out to be not a scheduler regression, but an already
existing problem in ptrace being triggered by subtle scheduler
changes.

The problem is this:

 - task A is ptracing task B
 - task B stops on a trace event
 - task A is woken up and preempts task B
 - task A calls ptrace on task B, which does ptrace_check_attach()
 - this calls wait_task_inactive(), which sees that task B is still on the runq
 - task A goes to sleep for a jiffy
 - ...

Since UML does lots of the above sequences, those jiffies quickly add
up to make it slow as hell.

This patch solves this by not rescheduling in read_unlock() after
ptrace_stop() has woken up the tracer.

Thanks to Oleg Nesterov and Ingo Molnar for the feedback.

Signed-off-by: Miklos Szeredi &lt;mszeredi@suse.cz&gt;
CC: stable@kernel.org
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>module: fix refptr allocation and release order</title>
<updated>2009-03-17T23:01:21Z</updated>
<author>
<name>Masami Hiramatsu</name>
<email>mhiramat@redhat.com</email>
</author>
<published>2009-03-16T22:13:36Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=6e2b75740bed35df98b8113300579e13ed2ce848'/>
<id>urn:sha1:6e2b75740bed35df98b8113300579e13ed2ce848</id>
<content type='text'>
Impact: fix ref-after-free crash on failed module load

Fix refptr bug: Change refptr allocation and release order not to access a module
data structure pointed by 'mod' after freeing mod-&gt;module_core.
This bug will cause kernel panic(e.g. failed to find undefined symbols).

This bug was reported on systemtap bugzilla.
http://sources.redhat.com/bugzilla/show_bug.cgi?id=9927

Signed-off-by: Masami Hiramatsu &lt;mhiramat@redhat.com&gt;
Cc: Eric Dumazet &lt;dada1@cosmosbay.com&gt;
Signed-off-by: Rusty Russell &lt;rusty@rustcorp.com.au&gt;
</content>
</entry>
<entry>
<title>kernel/user.c: fix a memory leak when freeing up non-init usernamespaces users</title>
<updated>2009-03-10T22:55:11Z</updated>
<author>
<name>Dhaval Giani</name>
<email>dhaval@linux.vnet.ibm.com</email>
</author>
<published>2009-03-10T19:55:56Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=be50b8342dead8cacf57d4839240106b225d31f5'/>
<id>urn:sha1:be50b8342dead8cacf57d4839240106b225d31f5</id>
<content type='text'>
We were returning early in the sysfs directory cleanup function if the
user belonged to a non init usernamespace.  Due to this a lot of the
cleanup was not done and we were left with a leak.  Fix the leak.

Reported-by: Serge Hallyn &lt;serue@linux.vnet.ibm.com&gt;
Signed-off-by: Dhaval Giani &lt;dhaval@linux.vnet.ibm.com&gt;
Acked-by: Serge Hallyn &lt;serue@us.ibm.com&gt;
Tested-by: Serge Hallyn &lt;serue@us.ibm.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>
</entry>
</feed>
