linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] target/cxgbit: add INET dependency
@ 2016-02-29 11:14 Arnd Bergmann
  2016-03-01  5:28 ` Nicholas A. Bellinger
  0 siblings, 1 reply; 4+ messages in thread
From: Arnd Bergmann @ 2016-02-29 11:14 UTC (permalink / raw)
  To: Nicholas A. Bellinger
  Cc: linux-arm-kernel, Arnd Bergmann, Varun Prakash, linux-scsi,
	target-devel, linux-kernel

The newly added cxgbit driver directly calls functions of the
IPv4 network stack, which fails if that is disabled:

ERROR: "ip_route_output_flow" [drivers/target/iscsi/cxgbit/cxgbit.ko] undefined!
ERROR: "__ip_dev_find" [drivers/target/iscsi/cxgbit/cxgbit.ko] undefined!

This adds a Kconfig dependency to ensure we can't enable this
driver without the complete network stack it needs.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: b7ca3321e114 ("cxgbit: add Kconfig and Makefile")
---
 drivers/target/iscsi/cxgbit/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/target/iscsi/cxgbit/Kconfig b/drivers/target/iscsi/cxgbit/Kconfig
index cf335b4dbb4e..ce6f5cca315d 100644
--- a/drivers/target/iscsi/cxgbit/Kconfig
+++ b/drivers/target/iscsi/cxgbit/Kconfig
@@ -1,6 +1,7 @@
 config ISCSI_TARGET_CXGB4
 	tristate "Chelsio iSCSI target offload driver"
 	depends on ISCSI_TARGET && CHELSIO_T4
+	depends on INET
 	select CHELSIO_T4_UWIRE
 	---help---
 	To compile this driver as module, choose M here: the module
-- 
2.7.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] target/cxgbit: add INET dependency
  2016-02-29 11:14 [PATCH] target/cxgbit: add INET dependency Arnd Bergmann
@ 2016-03-01  5:28 ` Nicholas A. Bellinger
  2016-03-01  7:28   ` Varun Prakash
  2016-03-01 21:21   ` Arnd Bergmann
  0 siblings, 2 replies; 4+ messages in thread
From: Nicholas A. Bellinger @ 2016-03-01  5:28 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: linux-arm-kernel, Varun Prakash, linux-scsi, target-devel,
	linux-kernel

Hi Arnd,

On Mon, 2016-02-29 at 12:14 +0100, Arnd Bergmann wrote:
> The newly added cxgbit driver directly calls functions of the
> IPv4 network stack, which fails if that is disabled:
> 
> ERROR: "ip_route_output_flow" [drivers/target/iscsi/cxgbit/cxgbit.ko] undefined!
> ERROR: "__ip_dev_find" [drivers/target/iscsi/cxgbit/cxgbit.ko] undefined!
> 
> This adds a Kconfig dependency to ensure we can't enable this
> driver without the complete network stack it needs.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> Fixes: b7ca3321e114 ("cxgbit: add Kconfig and Makefile")
> ---
>  drivers/target/iscsi/cxgbit/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/target/iscsi/cxgbit/Kconfig b/drivers/target/iscsi/cxgbit/Kconfig
> index cf335b4dbb4e..ce6f5cca315d 100644
> --- a/drivers/target/iscsi/cxgbit/Kconfig
> +++ b/drivers/target/iscsi/cxgbit/Kconfig
> @@ -1,6 +1,7 @@
>  config ISCSI_TARGET_CXGB4
>  	tristate "Chelsio iSCSI target offload driver"
>  	depends on ISCSI_TARGET && CHELSIO_T4
> +	depends on INET
>  	select CHELSIO_T4_UWIRE
>  	---help---
>  	To compile this driver as module, choose M here: the module

Odd, ISCSI_TARGET already depends on NET, but I guess that's not enough
for cxgbit..  ;)

Varun, please pick this up and fold it into the original commit, with
proper credit to Arnd for finding this in the commit log.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] target/cxgbit: add INET dependency
  2016-03-01  5:28 ` Nicholas A. Bellinger
@ 2016-03-01  7:28   ` Varun Prakash
  2016-03-01 21:21   ` Arnd Bergmann
  1 sibling, 0 replies; 4+ messages in thread
From: Varun Prakash @ 2016-03-01  7:28 UTC (permalink / raw)
  To: Nicholas A. Bellinger
  Cc: Arnd Bergmann, linux-arm-kernel@lists.infradead.org,
	linux-scsi@vger.kernel.org, target-devel@vger.kernel.org,
	linux-kernel@vger.kernel.org

On Tue, Mar 01, 2016 at 10:58:28AM +0530, Nicholas A. Bellinger wrote:
> Hi Arnd,
> 
> On Mon, 2016-02-29 at 12:14 +0100, Arnd Bergmann wrote:
> > The newly added cxgbit driver directly calls functions of the
> > IPv4 network stack, which fails if that is disabled:
> > 
> > ERROR: "ip_route_output_flow" [drivers/target/iscsi/cxgbit/cxgbit.ko] undefined!
> > ERROR: "__ip_dev_find" [drivers/target/iscsi/cxgbit/cxgbit.ko] undefined!
> > 
> > This adds a Kconfig dependency to ensure we can't enable this
> > driver without the complete network stack it needs.
> > 
> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> > Fixes: b7ca3321e114 ("cxgbit: add Kconfig and Makefile")
> > ---
> >  drivers/target/iscsi/cxgbit/Kconfig | 1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/drivers/target/iscsi/cxgbit/Kconfig b/drivers/target/iscsi/cxgbit/Kconfig
> > index cf335b4dbb4e..ce6f5cca315d 100644
> > --- a/drivers/target/iscsi/cxgbit/Kconfig
> > +++ b/drivers/target/iscsi/cxgbit/Kconfig
> > @@ -1,6 +1,7 @@
> >  config ISCSI_TARGET_CXGB4
> >  	tristate "Chelsio iSCSI target offload driver"
> >  	depends on ISCSI_TARGET && CHELSIO_T4
> > +	depends on INET
> >  	select CHELSIO_T4_UWIRE
> >  	---help---
> >  	To compile this driver as module, choose M here: the module
> 
> Odd, ISCSI_TARGET already depends on NET, but I guess that's not enough
> for cxgbit..  ;)
> 
> Varun, please pick this up and fold it into the original commit, with
> proper credit to Arnd for finding this in the commit log.

I will update the original commit in v2 series, thanks Arnd for
finding this.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] target/cxgbit: add INET dependency
  2016-03-01  5:28 ` Nicholas A. Bellinger
  2016-03-01  7:28   ` Varun Prakash
@ 2016-03-01 21:21   ` Arnd Bergmann
  1 sibling, 0 replies; 4+ messages in thread
From: Arnd Bergmann @ 2016-03-01 21:21 UTC (permalink / raw)
  To: Nicholas A. Bellinger
  Cc: linux-arm-kernel, Varun Prakash, linux-scsi, target-devel,
	linux-kernel

On Monday 29 February 2016 21:28:28 Nicholas A. Bellinger wrote:
> > diff --git a/drivers/target/iscsi/cxgbit/Kconfig b/drivers/target/iscsi/cxgbit/Kconfig
> > index cf335b4dbb4e..ce6f5cca315d 100644
> > --- a/drivers/target/iscsi/cxgbit/Kconfig
> > +++ b/drivers/target/iscsi/cxgbit/Kconfig
> > @@ -1,6 +1,7 @@
> >  config ISCSI_TARGET_CXGB4
> >       tristate "Chelsio iSCSI target offload driver"
> >       depends on ISCSI_TARGET && CHELSIO_T4
> > +     depends on INET
> >       select CHELSIO_T4_UWIRE
> >       ---help---
> >       To compile this driver as module, choose M here: the module
> 
> Odd, ISCSI_TARGET already depends on NET, but I guess that's not enough
> for cxgbit..  ;)
> 

The problem is that you can have CONFIG_NET=y but CONFIG_INET=n

It would probably be reasonable to make the ISCSI_TARGET option depend
on CONFIG_INET directly, which would solve the problem as well.

	Arnd

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-03-01 21:22 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-29 11:14 [PATCH] target/cxgbit: add INET dependency Arnd Bergmann
2016-03-01  5:28 ` Nicholas A. Bellinger
2016-03-01  7:28   ` Varun Prakash
2016-03-01 21:21   ` Arnd Bergmann

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).