Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1266881

Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration

From Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Newsgroups linux.kernel
Subject Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration
Date 2015-11-11 01:10 +0100
Message-ID <qtr97-3J0-3@gated-at.bofh.it> (permalink)
References <qtqPL-3lH-3@gated-at.bofh.it> <qtqPM-3lH-19@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, Nov 11, 2015 at 12:42:21AM +0100, Arnd Bergmann wrote:
> A recent cleanup added a reference to struct net_device, but
> that structure is not always visible in the context of the
> declaration, so we may get a compile-time error:
> 
> In file included from wilc1000/host_interface.c:5:0:
> wilc1000/host_interface.h:705:46: warning: 'struct net_device' declared inside parameter list
>  s32 wilc_init(struct net_device *dev, struct host_if_drv **phWFIDrv);
> 
> This adds a forward-declaration for the structure name to avoid
> that error.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> Fixes: d5382219138d ("staging: wilc1000: host_int_init: add argument net_device")
> ---
>  drivers/staging/wilc1000/host_interface.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/staging/wilc1000/host_interface.h b/drivers/staging/wilc1000/host_interface.h
> index 57e1d424afdc..29a92d690384 100644
> --- a/drivers/staging/wilc1000/host_interface.h
> +++ b/drivers/staging/wilc1000/host_interface.h
> @@ -369,6 +369,7 @@ s32 host_int_scan(struct host_if_drv *hWFIDrv, u8 u8ScanSource,
>  s32 hif_set_cfg(struct host_if_drv *hWFIDrv,
>  		struct cfg_param_val *pstrCfgParamVal);
>  s32 hif_get_cfg(struct host_if_drv *hWFIDrv, u16 u16WID, u16 *pu16WID_Value);
> +struct net_device;

I think this is already fixed in my staging-testing branch, right?

and as Joe said, a #include would be nicer.

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 00/20] staging/wilc1000: cleanups once again Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 07/20] staging/wilc1000: avoid static definitions in header Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 01/20] staging/wilc1000: add struct net_device declaration Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
    Re: [PATCH 01/20] staging/wilc1000: add struct net_device  declaration Joe Perches <joe@perches.com> - 2015-11-11 00:50 +0100
      Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration Arnd Bergmann <arnd@arndb.de> - 2015-11-11 01:00 +0100
    Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2015-11-11 01:10 +0100
      Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration Arnd Bergmann <arnd@arndb.de> - 2015-11-11 01:20 +0100
        Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2015-11-11 01:40 +0100
  [PATCH 17/20] staging/wilc1000: remove WILC_SDIO/WILC_SPI macros Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 10/20] staging/wilc1000: move init/exit functions to driver files Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 06/20] staging/wilc1000: use NO_SECURITY instead of NO_ENCRYPT Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 15/20] staging/wilc1000: pass hif operations through initialization Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
    Re: [PATCH 15/20] staging/wilc1000: pass hif operations through initialization glen lee <glen.lee@atmel.com> - 2015-11-12 11:10 +0100
      Re: [PATCH 15/20] staging/wilc1000: pass hif operations through initialization Arnd Bergmann <arnd@arndb.de> - 2015-11-12 12:40 +0100
        Re: [PATCH 15/20] staging/wilc1000: pass hif operations through initialization glen lee <glen.lee@atmel.com> - 2015-11-13 08:50 +0100
          Re: [PATCH 15/20] staging/wilc1000: pass hif operations through initialization Arnd Bergmann <arnd@arndb.de> - 2015-11-13 10:20 +0100
            Re: [PATCH 15/20] staging/wilc1000: pass hif operations through initialization glen lee <glen.lee@atmel.com> - 2015-11-16 02:40 +0100
  [PATCH 19/20] staging/wilc1000: use more regular probing Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
    Re: [PATCH 19/20] staging/wilc1000: use more regular probing Andy Shevchenko <andy.shevchenko@gmail.com> - 2015-11-11 09:00 +0100
      Re: [PATCH 19/20] staging/wilc1000: use more regular probing Arnd Bergmann <arnd@arndb.de> - 2015-11-11 10:00 +0100
  [PATCH 09/20] staging/wilc1000: move wilc_wlan_inp_t into struct wilc Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 20/20] staging/wilc1000: pass struct wilc to most linux_wlan.c functions Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 13/20] staging/wilc1000: use device pointer for phy creation Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 08/20] staging/wilc1000: remove linux_wlan_{device_power,device_detection} Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 11/20] staging/wilc1000: unify device pointer Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 14/20] staging/wilc1000: get rid of WILC_SDIO_IRQ_GPIO Arnd Bergmann <arnd@arndb.de> - 2015-11-11 00:50 +0100
  [PATCH 02/20] staging/wilc1000: remove unused functions Arnd Bergmann <arnd@arndb.de> - 2015-11-11 01:00 +0100

csiph-web