From: Guenter Roeck <linux@roeck-us.net>
To: Josh Boyer <jwboyer@redhat.com>
Cc: linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: Re: [PATCH] usb: usb_phy_gen: refine conditional declaration of usb_nop_xceiv_register
Date: Thu, 17 Oct 2013 13:31:47 -0700 [thread overview]
Message-ID: <20131017203147.GA22947@roeck-us.net> (raw)
In-Reply-To: <20131017172548.GM16287@hansolo.jdub.homelinux.org>
On Thu, Oct 17, 2013 at 01:25:48PM -0400, Josh Boyer wrote:
> On Wed, Oct 16, 2013 at 07:18:41PM -0700, Guenter Roeck wrote:
> > Commit 3fa4d734 (usb: phy: rename nop_usb_xceiv => usb_phy_gen_xceiv)
> > changed the conditional around the declaration of usb_nop_xceiv_register
> > from
> > #if defined(CONFIG_NOP_USB_XCEIV) ||
> > (defined(CONFIG_NOP_USB_XCEIV_MODULE) && defined(MODULE))
> > to
> > #if IS_ENABLED(CONFIG_NOP_USB_XCEIV)
> >
> > While that looks the same, it is semantically different. The first expression
> > is true if CONFIG_NOP_USB_XCEIV is built as module and if the including
> > code is built as module. The second expression is true if code depending on
> > CONFIG_NOP_USB_XCEIV if built as module or into the kernel.
> >
> > As a result, the arm:allmodconfig build fails with
> >
> > arch/arm/mach-omap2/built-in.o: In function `omap3_evm_init':
> > arch/arm/mach-omap2/board-omap3evm.c:703: undefined reference to
> > `usb_nop_xceiv_register'
> >
> > Fix the problem by reverting to the old conditional.
> >
> > Cc: Josh Boyer <jwboyer@redhat.com>
> > Signed-off-by: Guenter Roeck <linux@roeck-us.net>
>
> I'm not entirely sure why I was CC'd on this one, but the patch looks
> good to me. I do wonder how many other uses of IS_ENABLED aren't taking
> this into account though.
>
Unless I am wrong, you submitted a different patch to fix the same problem,
which went nowhere, so I figured it was appropriate to Cc: you on this one.
If not, my apologies.
As for other use cases of IS_ENABLED, agreed, that may be an ongoing concern.
That will have to be addressed individually, though.
Thanks,
Guenter
next prev parent reply other threads:[~2013-10-17 20:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-17 2:18 [PATCH] usb: usb_phy_gen: refine conditional declaration of usb_nop_xceiv_register Guenter Roeck
2013-10-17 17:25 ` Josh Boyer
2013-10-17 20:31 ` Guenter Roeck [this message]
2013-10-18 1:05 ` Josh Boyer
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=20131017203147.GA22947@roeck-us.net \
--to=linux@roeck-us.net \
--cc=gregkh@linuxfoundation.org \
--cc=jwboyer@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@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