On Tue, Dec 20, 2011 at 10:14:02PM +0000, Marcos Paulo de Souza wrote:
> This patch removes a useless function, because its just return a 0
> value.
> 
> Signed-off-by: Marcos Paulo de Souza <[email protected]>
> ---
> As Dan Carpenter said, this removed function must to be replaced by NULL, and 
> not by zero.
> 
>  drivers/staging/vt6656/iwctl.c |   18 +-----------------
>  1 files changed, 1 insertions(+), 17 deletions(-)
> 
> diff --git a/drivers/staging/vt6656/iwctl.c b/drivers/staging/vt6656/iwctl.c
> index 2121205..9dc5757 100644
> --- a/drivers/staging/vt6656/iwctl.c
> +++ b/drivers/staging/vt6656/iwctl.c
> @@ -100,21 +100,6 @@ struct iw_statistics *iwctl_get_wireless_stats(struct 
> net_device *dev)
>       return &pDevice->wstats;
>  }
>  
> -
> -
> -/*------------------------------------------------------------------*/
> -
> -
> -static int iwctl_commit(struct net_device *dev,
> -                           struct iw_request_info *info,
> -                           void *wrq,
> -                           char *extra)
> -{
> -    DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO " SIOCSIWCOMMIT\n");
> -
> -     return 0;
> -}
> -
>  /*
>   * Wireless Handler : get protocol name
>   */
> @@ -1936,7 +1921,6 @@ int iwctl_siwmlme(struct net_device *dev,
>  /*
>  static const iw_handler              iwctl_handler[] =
>  {
> -     (iw_handler) iwctl_commit,      // SIOCSIWCOMMIT
>       (iw_handler) iwctl_giwname,     // SIOCGIWNAME

This is the same as before.  The other comment was just a style
issue but this change completely breaks everything.  :/  You can't
just shift all the array members off by one.


regards,
dan carpenter

>       (iw_handler) NULL,                              // SIOCSIWNWID
>       (iw_handler) NULL,                              // SIOCGIWNWID
> @@ -1998,7 +1982,7 @@ static const iw_handler         iwctl_handler[] =
>  
>  static const iw_handler              iwctl_handler[] =
>  {
> -     (iw_handler) iwctl_commit,      // SIOCSIWCOMMIT
> +     (iw_handler) NULL,      /* SIOCSIWCOMMIT */
>       (iw_handler) NULL,      // SIOCGIWNAME
>       (iw_handler) NULL,                              // SIOCSIWNWID
>       (iw_handler) NULL,                              // SIOCGIWNWID
> -- 
> 1.7.4.4
> 
> _______________________________________________
> devel mailing list
> [email protected]
> http://driverdev.linuxdriverproject.org/mailman/listinfo/devel

Attachment: signature.asc
Description: Digital signature

_______________________________________________
devel mailing list
[email protected]
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel

Reply via email to