Linux 3.4.69-rt86-rc1
Subsystems (6)
cover Linux 3.4.69-rt86-rc1
Dear RT Folks,
This is the RT stable review cycle of patch 3.4.69-rt86-rc1.
Please scream at me if I messed something up. Please test the patches too.
The -rc release will be uploaded to kernel.org and will be deleted when the final release is out. This is just a review release (or release candidate).
The pre-releases will not be pushed to the git repository, only the final release is.
If all goes well, this patch will be converted to the next main release on 11/25/2013.
Enjoy,
-- Steve
To build 3.4.69-rt86-rc1 directly, the following patches should be applied:
http://www.kernel.org/pub/linux/kernel/v3.x/linux-3.4.tar.xz
http://www.kernel.org/pub/linux/kernel/v3.x/patch-3.4.69.xz
http://www.kernel.org/pub/linux/kernel/projects/rt/3.4/patch-3.4.69-rt86-rc1.patch.xz
You can also build from 3.4.69-rt85 by applying the incremental patch:
http://www.kernel.org/pub/linux/kernel/projects/rt/3.4/incr/patch-3.4.69-rt85-rt86-rc1.patch.xz
Changes from 3.4.69-rt85:
---
Mike Galbraith (1):
hwlat-detector: Don't ignore threshold module parameter
Sebastian Andrzej Siewior (1):
drm: remove preempt_disable() from drm_calc_vbltimestamp_from_scanoutpos()
Steven Rostedt (Red Hat) (1):
Linux 3.4.69-rt86-rc1
Thomas Pfaff (1):
genirq: Set the irq thread policy without checking CAP_SYS_NICE
Yang Shi (1):
mm/memcontrol: Don't call schedule_work_on in preemption disabled context
----
drivers/gpu/drm/drm_irq.c | 7 ------- drivers/misc/hwlat_detector.c | 2 +- kernel/irq/manage.c | 2 +- localversion-rt | 2 +- mm/memcontrol.c | 4 ++-- 5 files changed, 5 insertions(+), 12 deletions(-)
PATCH 1/5 genirq: Set the irq thread policy without checking CAP_SYS_NICE
3.4.69-rt86-rc1 stable review patch.
If anyone has any objections, please let me know.
------------------
From: Thomas Pfaff <[email protected]>
In commit ee23871389 ("genirq: Set irq thread to RT priority on creation") we moved the assigment of the thread's priority from the thread's function into __setup_irq(). That function may run in user context for instance if the user opens an UART node and then driver calls requests in the ->open() callback. That user may not have CAP_SYS_NICE and so the irq thread won't run with the SCHED_OTHER policy.
This patch uses sched_setscheduler_nocheck() so we omit the CAP_SYS_NICE check which is otherwise required for the SCHED_OTHER policy.
--- kernel/irq/manage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/irq/manage.c +1 -1
@@ -1024,7 +1024,7 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new) goto out_mput; } -sched_setscheduler (t,SCHED_FIFO , ¶m); +sched_setscheduler_nocheck (t,SCHED_FIFO , ¶m);/* * We keep the reference to the task struct even if
Signature · 1 line
1.8.4.rc3
PATCH 2/5 hwlat-detector: Dont ignore threshold module parameter
In reply to Steven Rostedt3.4.69-rt86-rc1 stable review patch.
If anyone has any objections, please let me know.
------------------
From: Mike Galbraith <[email protected]>
If the user specified a threshold at module load time, use it.
--- drivers/misc/hwlat_detector.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/misc/hwlat_detector.c +1 -1
@@ -413,7 +413,7 @@ static int init_stats(void) goto out;__reset_stats (); - data.threshold =DEFAULT_LAT_THRESHOLD ;/* threshold us */ + data.threshold = threshold ?:DEFAULT_LAT_THRESHOLD ;/* threshold us */ data.sample_window =DEFAULT_SAMPLE_WINDOW ;/* window us */ data.sample_width =DEFAULT_SAMPLE_WIDTH ;/* width us */
Signature · 1 line
1.8.4.rc3
PATCH 3/5 mm/memcontrol: Dont call schedule_work_on in preemption disabled context
In reply to Steven Rostedt3.4.69-rt86-rc1 stable review patch.
If anyone has any objections, please let me know.
------------------
From: Yang Shi <[email protected]>
The following trace is triggered when running ltp oom test cases:
BUG: sleeping function called from invalid context at kernel/rtmutex.c:659
in_atomic(): 1, irqs_disabled(): 0, pid: 17188, name: oom03 Preemption disabled at:[<ffffffff8112ba70>] mem_cgroup_reclaim+0x90/0xe0
CPU: 2 PID: 17188 Comm: oom03 Not tainted 3.10.10-rt3 #2 Hardware name: Intel Corporation Calpella platform/MATXM-CORE-411-B, BIOS 4.6.3 08/18/2010 ffff88007684d730 ffff880070df9b58 ffffffff8169918d ffff880070df9b70 ffffffff8106db31 ffff88007688b4a0 ffff880070df9b88 ffffffff8169d9c0 ffff88007688b4a0 ffff880070df9bc8 ffffffff81059da1 0000000170df9bb0 Call Trace: [<ffffffff8169918d>] dump_stack+0x19/0x1b [<ffffffff8106db31>] __might_sleep+0xf1/0x170 [<ffffffff8169d9c0>] rt_spin_lock+0x20/0x50 [<ffffffff81059da1>] queue_work_on+0x61/0x100 [<ffffffff8112b361>] drain_all_stock+0xe1/0x1c0 [<ffffffff8112ba70>] mem_cgroup_reclaim+0x90/0xe0 [<ffffffff8112beda>] __mem_cgroup_try_charge+0x41a/0xc40 [<ffffffff810f1c91>] ? release_pages+0x1b1/0x1f0 [<ffffffff8106f200>] ? sched_exec+0x40/0xb0 [<ffffffff8112cc87>] mem_cgroup_charge_common+0x37/0x70 [<ffffffff8112e2c6>] mem_cgroup_newpage_charge+0x26/0x30 [<ffffffff8110af68>] handle_pte_fault+0x618/0x840 [<ffffffff8103ecf6>] ? unpin_current_cpu+0x16/0x70 [<ffffffff81070f94>] ? migrate_enable+0xd4/0x200 [<ffffffff8110cde5>] handle_mm_fault+0x145/0x1e0 [<ffffffff810301e1>] __do_page_fault+0x1a1/0x4c0 [<ffffffff8169c9eb>] ? preempt_schedule_irq+0x4b/0x70 [<ffffffff8169e3b7>] ? retint_kernel+0x37/0x40 [<ffffffff8103053e>] do_page_fault+0xe/0x10 [<ffffffff8169e4c2>] page_fault+0x22/0x30
So, to prevent schedule_work_on from being called in preempt disabled context, replace the pair of get/put_cpu() to get/put_cpu_light().
--- mm/memcontrol.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
mm/memcontrol.c +2 -2
@@ -2082,7 +2082,7 @@ static void drain_all_stock(struct mem_cgroup *root_memcg, bool sync)/* Notify other cpus that system-wide "drain" is running */ get_online_cpus (); - curcpu =get_cpu (); + curcpu =get_cpu_light ();for_each_online_cpu (cpu) {struct memcg_stock_pcp *stock = &per_cpu (memcg_stock, cpu);struct mem_cgroup *memcg;
@@ -2099,7 +2099,7 @@ static void drain_all_stock(struct mem_cgroup *root_memcg, bool sync)schedule_work_on (cpu, &stock->work); } } -put_cpu (); +put_cpu_light ();if (!sync) goto out;
Signature · 1 line
1.8.4.rc3
PATCH 4/5 drm: remove preempt_disable() from drm_calc_vbltimestamp_from_scanoutpos()
In reply to Steven Rostedt3.4.69-rt86-rc1 stable review patch.
If anyone has any objections, please let me know.
------------------
From: Sebastian Andrzej Siewior <[email protected]>
Luis captured the following:
| BUG: sleeping function called from invalid context at kernel/rtmutex.c:659
| in_atomic(): 1, irqs_disabled(): 0, pid: 517, name: Xorg
| 2 locks held by Xorg/517:
| #0:
| (
| &dev->vbl_lock
| ){......}
| , at:
| [<ffffffffa0024c60>] drm_vblank_get+0x30/0x2b0 [drm]
| #1:
| (
| &dev->vblank_time_lock
| ){......}
| , at:
| [<ffffffffa0024ce1>] drm_vblank_get+0xb1/0x2b0 [drm]
| Preemption disabled at:
| [<ffffffffa008bc95>] i915_get_vblank_timestamp+0x45/0xa0 [i915]
| CPU: 3 PID: 517 Comm: Xorg Not tainted 3.10.10-rt7+ #5
| Call Trace:
| [<ffffffff8164b790>] dump_stack+0x19/0x1b
| [<ffffffff8107e62f>] __might_sleep+0xff/0x170
| [<ffffffff81651ac4>] rt_spin_lock+0x24/0x60
| [<ffffffffa0084e67>] i915_read32+0x27/0x170 [i915]
| [<ffffffffa008a591>] i915_pipe_enabled+0x31/0x40 [i915]
| [<ffffffffa008a6be>] i915_get_crtc_scanoutpos+0x3e/0x1b0 [i915]
| [<ffffffffa00245d4>] drm_calc_vbltimestamp_from_scanoutpos+0xf4/0x430 [drm]
| [<ffffffffa008bc95>] i915_get_vblank_timestamp+0x45/0xa0 [i915]
| [<ffffffffa0024998>] drm_get_last_vbltimestamp+0x48/0x70 [drm]
| [<ffffffffa0024db5>] drm_vblank_get+0x185/0x2b0 [drm]
| [<ffffffffa0025d03>] drm_wait_vblank+0x83/0x5d0 [drm]
| [<ffffffffa00212a2>] drm_ioctl+0x552/0x6a0 [drm]
| [<ffffffff811a0095>] do_vfs_ioctl+0x325/0x5b0
| [<ffffffff811a03a1>] SyS_ioctl+0x81/0xa0
| [<ffffffff8165a342>] tracesys+0xdd/0xe2After a longer thread it was decided to drop the preempt_disable()/ enable() invocations which were meant for -RT and Mario Kleiner looks for a replacement.
--- drivers/gpu/drm/drm_irq.c | 7 ------- 1 file changed, 7 deletions(-)
drivers/gpu/drm/drm_irq.c +0 -7
@@ -619,11 +619,6 @@ int drm_calc_vbltimestamp_from_scanoutpos(struct drm_device *dev, int crtc,* code gets preempted or delayed for some reason. */ for (i =0 ; i <DRM_TIMESTAMP_MAXRETRIES ; i++) { -/* Disable preemption to make it very likely to -* succeed in the first iteration even on PREEMPT_RT kernel. -*/ -preempt_disable (); -/* Get system timestamp before query. */ do_gettimeofday (&stime);
@@ -633,8 +628,6 @@ int drm_calc_vbltimestamp_from_scanoutpos(struct drm_device *dev, int crtc,/* Get system timestamp after query. */ do_gettimeofday (&raw_time); -preempt_enable (); -/* Return as no-op if scanout query unsupported or failed. */ if (!(vbl_status &DRM_SCANOUTPOS_VALID )) { DRM_DEBUG("crtc %d : scanoutpos query failed [%d].\n",
Signature · 1 line
1.8.4.rc3
PATCH 5/5 Linux 3.4.69-rt86-rc1
In reply to Steven Rostedt3.4.69-rt86-rc1 stable review patch.
If anyone has any objections, please let me know.
------------------
From: "Steven Rostedt (Red Hat)" <[email protected]>
--- localversion-rt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
localversion-rt +1 -1
@@ -1 +1 @@ --rt85 +-rt86-rc1
Signature · 1 line
1.8.4.rc3
Hi Steven
Quoted 1 line
This is the RT stable review cycle of patch 3.4.69-rt86-rc1.
Thanks for this release, unfortunatly i am only able to test this stuff in indeterministic time slices... I am currently testing this stuff. No news is good news.
Quoted 11 lines
Please scream at me if I messed something up. Please test the patches too.
The -rc release will be uploaded to kernel.org and will be deleted when the final release is out. This is just a review release (or release candidate).
The pre-releases will not be pushed to the git repository, only the final release is.
If all goes well, this patch will be converted to the next main release on 11/25/2013.
I don't want to nag you but as this date is in the past i just wanted to know if anything has not gone well besides that the non-rc version is not available? Which would be just a "cosmetic" issue.
Best regards
Tim
Quoted 5 lines · On Mon, 02 Dec 2013 14:32:13 +0100 Tim Sander <[email protected]> wrote:
Quoted 2 lines
If all goes well, this patch will be converted to the next main release on 11/25/2013.
I don't want to nag you but as this date is in the past i just wanted to know if anything has not gone well besides that the non-rc version is not available? Which would be just a "cosmetic" issue.
Nope, all went well, I just got side tracked by other things needing to get done by Turkey day. Thanks for the reminder.
I'll push these out today.
-- Steve