summaryrefslogtreecommitdiffstats
path: root/fs/ocfs2
diff options
context:
space:
mode:
authorAndrew Morton <akpm@linux-foundation.org>2015-06-25 01:54:56 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2015-06-25 02:49:39 +0200
commite327284abb8aee3206cef3b790a283fea213a174 (patch)
treec6c5ee017e368ae056e567d11b867776411e9d54 /fs/ocfs2
parentocfs2: reduce object size of mlog uses (diff)
downloadlinux-e327284abb8aee3206cef3b790a283fea213a174.tar.xz
linux-e327284abb8aee3206cef3b790a283fea213a174.zip
ocfs2: remove __mlog_cpu_guess
raw_smp_processor_id() is the means of avoiding the runtime preemptibility check. [akpm@linux-foundation.org: fix printk warning] Cc: Joe Perches <joe@perches.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Mark Fasheh <mfasheh@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ocfs2')
-rw-r--r--fs/ocfs2/cluster/masklog.c19
1 files changed, 3 insertions, 16 deletions
diff --git a/fs/ocfs2/cluster/masklog.c b/fs/ocfs2/cluster/masklog.c
index c2182ba1013c..dfe162f5fd4c 100644
--- a/fs/ocfs2/cluster/masklog.c
+++ b/fs/ocfs2/cluster/masklog.c
@@ -64,19 +64,6 @@ static ssize_t mlog_mask_store(u64 mask, const char *buf, size_t count)
return count;
}
-/*
- * smp_processor_id() "helpfully" screams when called outside preemptible
- * regions in current kernels. sles doesn't have the variants that don't
- * scream. just do this instead of trying to guess which we're building
- * against.. *sigh*.
- */
-#define __mlog_cpu_guess \
-({ \
- unsigned long _cpu = get_cpu(); \
- put_cpu(); \
- _cpu; \
-})
-
void __mlog_printk(const u64 *mask, const char *func, int line,
const char *fmt, ...)
{
@@ -103,9 +90,9 @@ void __mlog_printk(const u64 *mask, const char *func, int line,
vaf.fmt = fmt;
vaf.va = &args;
- printk("%s(%s,%u,%lu):%s:%d %s%pV",
- level, current->comm, task_pid_nr(current), __mlog_cpu_guess,
- func, line, prefix, &vaf);
+ printk("%s(%s,%u,%u):%s:%d %s%pV",
+ level, current->comm, task_pid_nr(current),
+ raw_smp_processor_id(), func, line, prefix, &vaf);
va_end(args);
}