linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Felipe Balbi <balbi@ti.com>
To: Randy Dunlap <rdunlap@infradead.org>
Cc: akpm@linux-foundation.org, USB list <linux-usb@vger.kernel.org>,
	linux-kernel@vger.kernel.org, linux-next@vger.kernel.org
Subject: Re: mmotm 2014-01-02-14-35 uploaded (musb)
Date: Fri, 3 Jan 2014 14:02:26 -0600	[thread overview]
Message-ID: <20140103200226.GD18722@saruman.home> (raw)
In-Reply-To: <52C6FA1E.4030607@infradead.org>

[-- Attachment #1: Type: text/plain, Size: 2027 bytes --]

On Fri, Jan 03, 2014 at 09:57:50AM -0800, Randy Dunlap wrote:
> On 01/02/14 14:36, akpm@linux-foundation.org wrote:
> > The mm-of-the-moment snapshot 2014-01-02-14-35 has been uploaded to
> > 
> >    http://www.ozlabs.org/~akpm/mmotm/
> > 
> > mmotm-readme.txt says
> > 
> > README for mm-of-the-moment:
> > 
> > http://www.ozlabs.org/~akpm/mmotm/
> > 
> > This is a snapshot of my -mm patch queue.  Uploaded at random hopefully
> > more than once a week.
> 
> on x86_64:
> 
> when CONFIG_USB is not enabled:
> 
> drivers/built-in.o: In function `musb_init':
> musb_core.c:(.init.text+0x45fc): undefined reference to `usb_disabled'

already have a patch for that. Waiting for Greg to merge ;-)

commit 89f836a8c56bfea6585a09f7afff7094968a4fd0
Author: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
Date:   Thu Dec 26 09:24:52 2013 -0300

    usb: musb: Remove usb_disable() check in module_init()
    
    Removing the check to usb_disable() before registering the platform
    driver allows to build this driver when !USB && USB_GADGET, to be
    used in gadget-only mode.
    
    Also, use module_platform_driver() to register the platform driver.
    
    Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
    Signed-off-by: Felipe Balbi <balbi@ti.com>

diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c
index 0e7f4a0..5942f00 100644
--- a/drivers/usb/musb/musb_core.c
+++ b/drivers/usb/musb/musb_core.c
@@ -2325,19 +2325,4 @@ static struct platform_driver musb_driver = {
 	.shutdown	= musb_shutdown,
 };
 
-/*-------------------------------------------------------------------------*/
-
-static int __init musb_init(void)
-{
-	if (usb_disabled())
-		return 0;
-
-	return platform_driver_register(&musb_driver);
-}
-module_init(musb_init);
-
-static void __exit musb_cleanup(void)
-{
-	platform_driver_unregister(&musb_driver);
-}
-module_exit(musb_cleanup);
+module_platform_driver(musb_driver);

-- 
balbi

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2014-01-03 20:03 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-02 22:36 mmotm 2014-01-02-14-35 uploaded akpm
2014-01-03 17:57 ` mmotm 2014-01-02-14-35 uploaded (musb) Randy Dunlap
2014-01-03 20:02   ` Felipe Balbi [this message]
2014-01-03 20:47     ` Randy Dunlap
2014-01-03 18:26 ` mmotm 2014-01-02-14-35 uploaded (brocade/bna) Randy Dunlap
2014-01-06 22:24   ` David Miller
2014-01-07  1:38     ` David Miller
2014-01-07  1:58       ` Randy Dunlap

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=20140103200226.GD18722@saruman.home \
    --to=balbi@ti.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=rdunlap@infradead.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;
as well as URLs for NNTP newsgroup(s).