All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
To: penberg@cs.helsinki.fi
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	rdunlap@xenotime.net, mpm@selenic.com, tglx@linutronix.de,
	rostedt@goodmis.org, cl@linux-foundation.org,
	mathieu.desnoyers@polymtl.ca, tzanussi@gmail.com,
	Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
Subject: [PATCH 2/5] kmemtrace: Better alternative to "kmemtrace: fix printk format warnings".
Date: Tue, 19 Aug 2008 20:43:24 +0300	[thread overview]
Message-ID: <1219167807-5407-2-git-send-email-eduard.munteanu@linux360.ro> (raw)
In-Reply-To: <1219167807-5407-1-git-send-email-eduard.munteanu@linux360.ro>

Fix the problem "kmemtrace: fix printk format warnings" attempted to fix,
but resulted in marker-probe format mismatch warnings. Instead of carrying
size_t into probes, we get rid of it by casting to unsigned long, just as
we did with gfp_t.

This way, we don't need to change marker format strings and we don't have
to rely on other format specifiers like "%zu", making for consistent use
of more generic data types (since there are no format specifiers for
gfp_t, for example).

Signed-off-by: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
---
 include/linux/kmemtrace.h |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/include/linux/kmemtrace.h b/include/linux/kmemtrace.h
index 2c33201..5bea8ea 100644
--- a/include/linux/kmemtrace.h
+++ b/include/linux/kmemtrace.h
@@ -33,7 +33,8 @@ static inline void kmemtrace_mark_alloc_node(enum kmemtrace_type_id type_id,
 	trace_mark(kmemtrace_alloc, "type_id %d call_site %lu ptr %lu "
 		   "bytes_req %lu bytes_alloc %lu gfp_flags %lu node %d",
 		   type_id, call_site, (unsigned long) ptr,
-		   bytes_req, bytes_alloc, (unsigned long) gfp_flags, node);
+		   (unsigned long) bytes_req, (unsigned long) bytes_alloc,
+		   (unsigned long) gfp_flags, node);
 }
 
 static inline void kmemtrace_mark_free(enum kmemtrace_type_id type_id,
-- 
1.5.6.1


WARNING: multiple messages have this Message-ID (diff)
From: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
To: penberg@cs.helsinki.fi
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	rdunlap@xenotime.net, mpm@selenic.com, tglx@linutronix.de,
	rostedt@goodmis.org, cl@linux-foundation.org,
	mathieu.desnoyers@polymtl.ca, tzanussi@gmail.com,
	Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
Subject: [PATCH 2/5] kmemtrace: Better alternative to "kmemtrace: fix printk format warnings".
Date: Tue, 19 Aug 2008 20:43:24 +0300	[thread overview]
Message-ID: <1219167807-5407-2-git-send-email-eduard.munteanu@linux360.ro> (raw)
In-Reply-To: <1219167807-5407-1-git-send-email-eduard.munteanu@linux360.ro>

Fix the problem "kmemtrace: fix printk format warnings" attempted to fix,
but resulted in marker-probe format mismatch warnings. Instead of carrying
size_t into probes, we get rid of it by casting to unsigned long, just as
we did with gfp_t.

This way, we don't need to change marker format strings and we don't have
to rely on other format specifiers like "%zu", making for consistent use
of more generic data types (since there are no format specifiers for
gfp_t, for example).

Signed-off-by: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
---
 include/linux/kmemtrace.h |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/include/linux/kmemtrace.h b/include/linux/kmemtrace.h
index 2c33201..5bea8ea 100644
--- a/include/linux/kmemtrace.h
+++ b/include/linux/kmemtrace.h
@@ -33,7 +33,8 @@ static inline void kmemtrace_mark_alloc_node(enum kmemtrace_type_id type_id,
 	trace_mark(kmemtrace_alloc, "type_id %d call_site %lu ptr %lu "
 		   "bytes_req %lu bytes_alloc %lu gfp_flags %lu node %d",
 		   type_id, call_site, (unsigned long) ptr,
-		   bytes_req, bytes_alloc, (unsigned long) gfp_flags, node);
+		   (unsigned long) bytes_req, (unsigned long) bytes_alloc,
+		   (unsigned long) gfp_flags, node);
 }
 
 static inline void kmemtrace_mark_free(enum kmemtrace_type_id type_id,
-- 
1.5.6.1

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2008-08-19 17:47 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-19 17:43 [PATCH 1/5] Revert "kmemtrace: fix printk format warnings" Eduard - Gabriel Munteanu
2008-08-19 17:43 ` Eduard - Gabriel Munteanu
2008-08-19 17:43 ` Eduard - Gabriel Munteanu [this message]
2008-08-19 17:43   ` [PATCH 2/5] kmemtrace: Better alternative to " Eduard - Gabriel Munteanu
2008-08-19 17:43   ` [PATCH 3/5] SLUB: Replace __builtin_return_address(0) with _RET_IP_ Eduard - Gabriel Munteanu
2008-08-19 17:43     ` Eduard - Gabriel Munteanu
2008-08-19 17:43     ` [PATCH 4/5] kmemtrace: SLUB hooks Eduard - Gabriel Munteanu
2008-08-19 17:43       ` Eduard - Gabriel Munteanu
2008-08-19 17:43       ` [PATCH 5/5] kmemtrace: Fix 2 typos in documentation Eduard - Gabriel Munteanu
2008-08-19 17:43         ` Eduard - Gabriel Munteanu
2008-08-19 19:10         ` Pekka Enberg
2008-08-19 19:10           ` Pekka Enberg
2008-08-19 19:10       ` [PATCH 4/5] kmemtrace: SLUB hooks Pekka Enberg
2008-08-19 19:10         ` Pekka Enberg
2008-08-19 18:14     ` [PATCH 3/5] SLUB: Replace __builtin_return_address(0) with _RET_IP_ Christoph Lameter
2008-08-19 18:14       ` Christoph Lameter
2008-08-19 18:24       ` Eduard - Gabriel Munteanu
2008-08-19 18:24         ` Eduard - Gabriel Munteanu
2008-08-19 18:56         ` Christoph Lameter
2008-08-19 18:56           ` Christoph Lameter
2008-08-19 18:59           ` Pekka Enberg
2008-08-19 18:59             ` Pekka Enberg
2008-08-19 19:05           ` Eduard - Gabriel Munteanu
2008-08-19 19:05             ` Eduard - Gabriel Munteanu
2008-08-19 19:09             ` Pekka Enberg
2008-08-19 19:09               ` Pekka Enberg
2008-08-19 19:09           ` Pekka Enberg
2008-08-19 19:09             ` Pekka Enberg
2008-08-19 20:17             ` Christoph Lameter
2008-08-19 20:17               ` Christoph Lameter
2008-08-19 20:16               ` Pekka Enberg
2008-08-19 20:16                 ` Pekka Enberg
2008-08-19 20:23                 ` Christoph Lameter
2008-08-19 20:23                   ` Christoph Lameter
2008-08-19 20:47                   ` Pekka Enberg
2008-08-19 20:47                     ` Pekka Enberg
2008-08-19 18:50       ` Pekka J Enberg
2008-08-19 18:50         ` Pekka J Enberg
2008-08-19 19:24   ` [PATCH 2/5] kmemtrace: Better alternative to "kmemtrace: fix printk format warnings" Pekka Enberg
2008-08-19 19:24     ` Pekka Enberg
2008-08-19 17:51 ` [PATCH 1/5] Revert " Randy.Dunlap
2008-08-19 17:51   ` Randy.Dunlap
2008-08-19 17:54   ` Eduard - Gabriel Munteanu
2008-08-19 17:54     ` Eduard - Gabriel Munteanu
2008-08-19 18:16     ` Mathieu Desnoyers
2008-08-19 18:16       ` Mathieu Desnoyers
2008-08-19 18:32       ` Eduard - Gabriel Munteanu
2008-08-19 18:32         ` Eduard - Gabriel Munteanu
2008-08-19 19:25         ` Pekka Enberg
2008-08-19 19:25           ` Pekka Enberg
2008-08-19 20:23           ` Mathieu Desnoyers
2008-08-19 20:23             ` Mathieu Desnoyers
2008-08-19 18:47       ` Frank Ch. Eigler
2008-08-19 18:47         ` Frank Ch. Eigler
2008-08-19 19:32     ` Randy.Dunlap
2008-08-19 19:32       ` Randy.Dunlap
2008-08-19 21:37       ` Eduard - Gabriel Munteanu
2008-08-19 21:37         ` Eduard - Gabriel Munteanu
2008-08-19 19:27 ` Pekka Enberg
2008-08-19 19:27   ` Pekka Enberg

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=1219167807-5407-2-git-send-email-eduard.munteanu@linux360.ro \
    --to=eduard.munteanu@linux360.ro \
    --cc=cl@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mathieu.desnoyers@polymtl.ca \
    --cc=mpm@selenic.com \
    --cc=penberg@cs.helsinki.fi \
    --cc=rdunlap@xenotime.net \
    --cc=rostedt@goodmis.org \
    --cc=tglx@linutronix.de \
    --cc=tzanussi@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.