public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Inki Dae <inki.dae@samsung.com>
To: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org,
	dri-devel@lists.freedesktop.org, Inki Dae <inki.dae@samsung.com>
Subject: [PATCH] module: fix mutiple defined issue
Date: Mon, 29 Apr 2013 14:32:01 +0900	[thread overview]
Message-ID: <1367213521-26795-1-git-send-email-inki.dae@samsung.com> (raw)

This patch fixes mutiple defined issue to MODULE_DEVICE_TABLE

The issue could be induced when some framework which includes two
more sub drivers, is built as one moudle because those sub drivers
could have their own MODULE_DEVICE_TABLE.

And 'struct of_device_id' isn't needed to be determined by type
argument because the definition of 'of_device_id' should be fixed.
So this patch makes 'of_devce_id' definition to be fixed and
only its instance name to be defined by type.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
---
 include/linux/module.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/include/linux/module.h b/include/linux/module.h
index 46f1ea0..ac5d79f 100644
--- a/include/linux/module.h
+++ b/include/linux/module.h
@@ -84,7 +84,7 @@ void trim_init_extable(struct module *m);
 
 #ifdef MODULE
 #define MODULE_GENERIC_TABLE(gtype,name)			\
-extern const struct gtype##_id __mod_##gtype##_table		\
+extern const struct of_device_id __mod_##gtype##_table		\
   __attribute__ ((unused, alias(__stringify(name))))
 
 #else  /* !MODULE */
-- 
1.7.5.4


             reply	other threads:[~2013-04-29  5:32 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-29  5:32 Inki Dae [this message]
2013-04-29  7:35 ` [PATCH] module: fix mutiple defined issue Uwe Kleine-König
2013-04-29  7:56   ` Inki Dae
2013-04-29  9:51 ` Russell King - ARM Linux
2013-04-29 10:06   ` Inki Dae

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=1367213521-26795-1-git-send-email-inki.dae@samsung.com \
    --to=inki.dae@samsung.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --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