From: Thomas Renninger <trenn@suse.de>
To: trenn@suse.de
Cc: bjorn.helgaas@hp.com, gregkh@suse.de, jbaron@redhat.com,
linux-kernel@vger.kernel.org
Subject: [PATCH 4/4] kernel/module.c: Fix compiler warnings if debug is compiled in
Date: Thu, 16 Sep 2010 00:11:48 +0200 [thread overview]
Message-ID: <1284588708-54170-5-git-send-email-trenn@suse.de> (raw)
In-Reply-To: <1284588708-54170-1-git-send-email-trenn@suse.de>
Fixes these warnings:
kernel/module.c: In function ‘layout_sections’:
kernel/module.c:1776: error: ‘name’ undeclared (first use in this function)
kernel/module.c:1776: error: (Each undeclared identifier is reported only once
kernel/module.c:1776: error: for each function it appears in.)
kernel/module.c: In function ‘move_module’:
kernel/module.c:2394: warning: format ‘%lx’ expects type ‘long unsigned int’,
but argument 2 has type ‘Elf64_Addr’
if DEBUGP is defined in kernel/module.c
Signed-off-by: Thomas Renninger <trenn@suse.de>
CC: Greg KH <gregkh@suse.de>
CC: jbaron@redhat.com
CC: lkml <linux-kernel@vger.kernel.org>
---
kernel/module.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/kernel/module.c b/kernel/module.c
index 3912e12..66e4361 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -1773,7 +1773,6 @@ static void layout_sections(struct module *mod, struct load_info *info)
|| strstarts(sname, ".init"))
continue;
s->sh_entsize = get_offset(mod, &mod->core_size, s, i);
- DEBUGP("\t%s\n", name);
}
if (m == 0)
mod->core_text_size = mod->core_size;
@@ -2390,8 +2389,8 @@ static int move_module(struct module *mod, struct load_info *info)
memcpy(dest, (void *)shdr->sh_addr, shdr->sh_size);
/* Update sh_addr to point to copy in image. */
shdr->sh_addr = (unsigned long)dest;
- DEBUGP("\t0x%lx %s\n",
- shdr->sh_addr, info->secstrings + shdr->sh_name);
+ DEBUGP("\t0x%p %s\n",
+ (void *)shdr->sh_addr, info->secstrings + shdr->sh_name);
}
return 0;
--
1.6.0.2
prev parent reply other threads:[~2010-09-15 22:12 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-15 22:11 Dynamic Debug module.ddebug fake param enhancements Thomas Renninger
2010-09-15 22:11 ` [PATCH 1/4] Dynamic Debug: Introduce global fake module param module.ddebug - V3 Thomas Renninger
2010-09-17 19:54 ` Jason Baron
2010-09-17 21:52 ` Thomas Renninger
2010-09-20 18:44 ` Jason Baron
2010-09-24 12:18 ` Thomas Renninger
2010-09-24 12:28 ` Dynamic Debug module.ddebug fake param enhancements V4 Thomas Renninger
2010-09-24 14:56 ` Bjorn Helgaas
2010-09-27 8:25 ` Thomas Renninger
2010-09-27 15:09 ` Bjorn Helgaas
2010-09-28 12:25 ` Thomas Renninger
2010-09-28 14:22 ` Bjorn Helgaas
2010-10-06 20:59 ` Greg KH
2010-09-24 12:28 ` [PATCH 1/4] Dynamic Debug: Introduce global fake module param module.ddebug - V4 Thomas Renninger
2010-10-06 21:16 ` Greg KH
2010-10-06 21:40 ` Thomas Renninger
2010-10-06 21:51 ` Greg KH
2010-09-24 12:28 ` [PATCH 2/4] PNP: Compile all pnp built-in stuff in one module namespace Thomas Renninger
2010-09-24 12:28 ` [PATCH 3/4] PNP: Use dev_dbg instead of dev_printk(KERN_DEBUG.. if DYNAMIC_DEBUG is compiled in Thomas Renninger
2010-09-24 12:28 ` [PATCH 4/4] kernel/module.c: Fix compiler warnings if debug " Thomas Renninger
2010-09-15 22:11 ` [PATCH 2/4] PNP: Compile all pnp built-in stuff in one module namespace Thomas Renninger
2010-09-15 22:11 ` [PATCH 3/4] PNP: Use dev_dbg instead of dev_printk(KERN_DEBUG.. if DYNAMIC_DEBUG is compiled in Thomas Renninger
2010-09-15 22:11 ` Thomas Renninger [this message]
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=1284588708-54170-5-git-send-email-trenn@suse.de \
--to=trenn@suse.de \
--cc=bjorn.helgaas@hp.com \
--cc=gregkh@suse.de \
--cc=jbaron@redhat.com \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®