linux-rt-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: linux-kernel@vger.kernel.org,
	linux-rt-users <linux-rt-users@vger.kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>,
	Carsten Emde <C.Emde@osadl.org>,
	Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
	John Kacur <jkacur@redhat.com>,
	Paul Gortmaker <paul.gortmaker@windriver.com>,
	Mike Galbraith <umgwanakikbuti@gmail.com>
Subject: [PATCH RT 07/20] mm/zsmalloc: Use get/put_cpu_light in zs_map_object()/zs_unmap_object()
Date: Tue, 12 Jul 2016 10:24:12 -0400	[thread overview]
Message-ID: <20160712142418.554914309@goodmis.org> (raw)
In-Reply-To: 20160712142405.634544943@goodmis.org

[-- Attachment #1: 0007-mm-zsmalloc-Use-get-put_cpu_light-in-zs_map_object-z.patch --]
[-- Type: text/plain, Size: 1229 bytes --]

4.1.27-rt31-rc1 stable review patch.
If anyone has any objections, please let me know.

------------------

From: Mike Galbraith <umgwanakikbuti@gmail.com>

Otherwise, we get a ___might_sleep() splat.

Signed-off-by: Mike Galbraith <umgwanakikbuti@gmail.com>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 mm/zsmalloc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mm/zsmalloc.c b/mm/zsmalloc.c
index fb1ec10ce449..e819dffd142c 100644
--- a/mm/zsmalloc.c
+++ b/mm/zsmalloc.c
@@ -1289,7 +1289,7 @@ void *zs_map_object(struct zs_pool *pool, unsigned long handle,
 	class = pool->size_class[class_idx];
 	off = obj_idx_to_offset(page, obj_idx, class->size);
 
-	area = &get_cpu_var(zs_map_area);
+	area = per_cpu_ptr(&zs_map_area, get_cpu_light());
 	area->vm_mm = mm;
 	if (off + class->size <= PAGE_SIZE) {
 		/* this object is contained entirely within a page */
@@ -1342,7 +1342,7 @@ void zs_unmap_object(struct zs_pool *pool, unsigned long handle)
 
 		__zs_unmap_object(area, pages, off, class->size);
 	}
-	put_cpu_var(zs_map_area);
+	put_cpu_light();
 	unpin_tag(handle);
 }
 EXPORT_SYMBOL_GPL(zs_unmap_object);
-- 
2.8.1

  parent reply	other threads:[~2016-07-12 14:24 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-12 14:24 [PATCH RT 00/20] Linux 4.1.27-rt31-rc1 Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 01/20] ARM: at91: pm: simply call at91_pm_init Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 02/20] ARM: at91: pm: find and remap the pmc Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 03/20] ARM: at91: pm: move idle functions to pm.c Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 04/20] ARM: at91: remove useless includes and function prototypes Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 05/20] usb: gadget: atmel: access the PMC using regmap Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 06/20] kvm, rt: change async pagefault code locking for PREEMPT_RT Steven Rostedt
2016-07-12 14:24 ` Steven Rostedt [this message]
2016-07-12 14:24 ` [PATCH RT 08/20] net: dev: always take qdiscs busylock in __dev_xmit_skb() Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 09/20] drivers/block/zram: Replace bit spinlocks with rtmutex for -rt Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 10/20] list_bl: fixup bogus lockdep warning Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 11/20] ARM: imx: always use TWD on IMX6Q Steven Rostedt
2016-07-12 20:04   ` Sebastian Andrzej Siewior
2016-07-12 20:25     ` Steven Rostedt
2016-07-18 17:18     ` Grygorii Strashko
2016-07-12 14:24 ` [PATCH RT 12/20] drivers/block/zram: fixup compile for !RT Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 13/20] perf/x86/intel/rapl: Make PMU lock raw Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 14/20] sched,preempt: Fix preempt_count manipulations Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 15/20] kernel/printk: Dont try to print from IRQ/NMI region Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 16/20] arm: lazy preempt: correct resched condition Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 17/20] locallock: add local_lock_on() Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 18/20] mm: perform lru_add_drain_all() remotely Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 19/20] trace: correct off by one while recording the trace-event Steven Rostedt
2016-07-12 14:24 ` [PATCH RT 20/20] Linux 4.1.27-rt31-rc1 Steven Rostedt
2016-07-12 23:18 ` Linux 4.1.27-rt31-rc2 Steven Rostedt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160712142418.554914309@goodmis.org \
    --to=rostedt@goodmis.org \
    --cc=C.Emde@osadl.org \
    --cc=bigeasy@linutronix.de \
    --cc=jkacur@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rt-users@vger.kernel.org \
    --cc=paul.gortmaker@windriver.com \
    --cc=tglx@linutronix.de \
    --cc=umgwanakikbuti@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).