All of lore.kernel.org
 help / color / mirror / Atom feed
* [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function
@ 2021-04-11 18:48 Fabio M. De Francesco
  2021-04-12  9:42 ` Greg KH
  2021-04-19 18:57   ` kernel test robot
  0 siblings, 2 replies; 7+ messages in thread
From: Fabio M. De Francesco @ 2021-04-11 18:48 UTC (permalink / raw)
  To: Greg KH, outreachy-kernel, linux-staging, linux-kernel
  Cc: Fabio M. De Francesco

Remove cmpk_handle_query_config_rx() because it just initializes a local
variable and then returns "void".

Signed-off-by: Fabio M. De Francesco <fmdefrancesco@gmail.com>
---
 drivers/staging/rtl8192u/r819xU_cmdpkt.c | 40 ------------------------
 1 file changed, 40 deletions(-)

diff --git a/drivers/staging/rtl8192u/r819xU_cmdpkt.c b/drivers/staging/rtl8192u/r819xU_cmdpkt.c
index 4cece40a92f6..d5a54c2d3086 100644
--- a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
+++ b/drivers/staging/rtl8192u/r819xU_cmdpkt.c
@@ -249,46 +249,6 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg)
 	DMESG("<---- cmpk_handle_interrupt_status()\n");
 }
 
-/*-----------------------------------------------------------------------------
- * Function:    cmpk_handle_query_config_rx()
- *
- * Overview:    The function is responsible for extract the message from
- *		firmware. It will contain dedicated info in
- *		ws-06-0063-rtl8190-command-packet-specification. Please
- *		refer to chapter "Beacon State Element".
- *
- * Input:       u8    *pmsg	-	Message Pointer of the command packet.
- *
- * Output:      NONE
- *
- * Return:      NONE
- *
- * Revised History:
- *  When		Who	Remark
- *  05/12/2008		amy	Create Version 0 porting from windows code.
- *
- *---------------------------------------------------------------------------
- */
-static void cmpk_handle_query_config_rx(struct net_device *dev, u8 *pmsg)
-{
-	struct cmpk_query_cfg	rx_query_cfg;
-
-	/* 1. Extract TX feedback info from RFD to temp structure buffer. */
-	/* It seems that FW use big endian(MIPS) and DRV use little endian in
-	 * windows OS. So we have to read the content byte by byte or transfer
-	 * endian type before copy the message copy.
-	 */
-	rx_query_cfg.cfg_action		= (pmsg[4] & 0x80) >> 7;
-	rx_query_cfg.cfg_type		= (pmsg[4] & 0x60) >> 5;
-	rx_query_cfg.cfg_size		= (pmsg[4] & 0x18) >> 3;
-	rx_query_cfg.cfg_page		= (pmsg[6] & 0x0F) >> 0;
-	rx_query_cfg.cfg_offset		= pmsg[7];
-	rx_query_cfg.value		= (pmsg[8]  << 24) | (pmsg[9]  << 16) |
-					  (pmsg[10] <<  8) | (pmsg[11] <<  0);
-	rx_query_cfg.mask		= (pmsg[12] << 24) | (pmsg[13] << 16) |
-					  (pmsg[14] <<  8) | (pmsg[15] <<  0);
-}
-
 /*-----------------------------------------------------------------------------
  * Function:	cmpk_count_tx_status()
  *
-- 
2.31.1


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

* Re: [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function
  2021-04-11 18:48 [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function Fabio M. De Francesco
@ 2021-04-12  9:42 ` Greg KH
  2021-04-12 10:12   ` Fabio M. De Francesco
  2021-04-19 18:57   ` kernel test robot
  1 sibling, 1 reply; 7+ messages in thread
From: Greg KH @ 2021-04-12  9:42 UTC (permalink / raw)
  To: Fabio M. De Francesco; +Cc: outreachy-kernel, linux-staging, linux-kernel

On Sun, Apr 11, 2021 at 08:48:13PM +0200, Fabio M. De Francesco wrote:
> Remove cmpk_handle_query_config_rx() because it just initializes a local
> variable and then returns "void".
> 
> Signed-off-by: Fabio M. De Francesco <fmdefrancesco@gmail.com>
> ---
>  drivers/staging/rtl8192u/r819xU_cmdpkt.c | 40 ------------------------
>  1 file changed, 40 deletions(-)
> 
> diff --git a/drivers/staging/rtl8192u/r819xU_cmdpkt.c b/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> index 4cece40a92f6..d5a54c2d3086 100644
> --- a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> +++ b/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> @@ -249,46 +249,6 @@ static void cmpk_handle_interrupt_status(struct net_device *dev, u8 *pmsg)
>  	DMESG("<---- cmpk_handle_interrupt_status()\n");
>  }
>  
> -/*-----------------------------------------------------------------------------
> - * Function:    cmpk_handle_query_config_rx()
> - *
> - * Overview:    The function is responsible for extract the message from
> - *		firmware. It will contain dedicated info in
> - *		ws-06-0063-rtl8190-command-packet-specification. Please
> - *		refer to chapter "Beacon State Element".
> - *
> - * Input:       u8    *pmsg	-	Message Pointer of the command packet.
> - *
> - * Output:      NONE
> - *
> - * Return:      NONE
> - *
> - * Revised History:
> - *  When		Who	Remark
> - *  05/12/2008		amy	Create Version 0 porting from windows code.
> - *
> - *---------------------------------------------------------------------------
> - */
> -static void cmpk_handle_query_config_rx(struct net_device *dev, u8 *pmsg)
> -{
> -	struct cmpk_query_cfg	rx_query_cfg;
> -
> -	/* 1. Extract TX feedback info from RFD to temp structure buffer. */
> -	/* It seems that FW use big endian(MIPS) and DRV use little endian in
> -	 * windows OS. So we have to read the content byte by byte or transfer
> -	 * endian type before copy the message copy.
> -	 */
> -	rx_query_cfg.cfg_action		= (pmsg[4] & 0x80) >> 7;
> -	rx_query_cfg.cfg_type		= (pmsg[4] & 0x60) >> 5;
> -	rx_query_cfg.cfg_size		= (pmsg[4] & 0x18) >> 3;
> -	rx_query_cfg.cfg_page		= (pmsg[6] & 0x0F) >> 0;
> -	rx_query_cfg.cfg_offset		= pmsg[7];
> -	rx_query_cfg.value		= (pmsg[8]  << 24) | (pmsg[9]  << 16) |
> -					  (pmsg[10] <<  8) | (pmsg[11] <<  0);
> -	rx_query_cfg.mask		= (pmsg[12] << 24) | (pmsg[13] << 16) |
> -					  (pmsg[14] <<  8) | (pmsg[15] <<  0);
> -}
> -
>  /*-----------------------------------------------------------------------------
>   * Function:	cmpk_count_tx_status()
>   *
> -- 
> 2.31.1
> 
> 

Always test-build your patches as they can not break the build.  You
obviously did not do that here, why not?

thanks,

greg k-h

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

* Re: [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function
  2021-04-12  9:42 ` Greg KH
@ 2021-04-12 10:12   ` Fabio M. De Francesco
  2021-04-12 10:22     ` Greg KH
  0 siblings, 1 reply; 7+ messages in thread
From: Fabio M. De Francesco @ 2021-04-12 10:12 UTC (permalink / raw)
  To: Greg KH; +Cc: outreachy-kernel, linux-staging, linux-kernel

On Monday, April 12, 2021 11:42:51 AM CEST Greg KH wrote:
> On Sun, Apr 11, 2021 at 08:48:13PM +0200, Fabio M. De Francesco wrote:
> > Remove cmpk_handle_query_config_rx() because it just initializes a
> > local
> > variable and then returns "void".
> > 
> > Signed-off-by: Fabio M. De Francesco <fmdefrancesco@gmail.com>
> > ---
> > 
> >  drivers/staging/rtl8192u/r819xU_cmdpkt.c | 40 ------------------------
> >  1 file changed, 40 deletions(-)
> > 
> > diff --git a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > b/drivers/staging/rtl8192u/r819xU_cmdpkt.c index
> > 4cece40a92f6..d5a54c2d3086 100644
> > --- a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > +++ b/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > @@ -249,46 +249,6 @@ static void cmpk_handle_interrupt_status(struct
> > net_device *dev, u8 *pmsg)> 
> >  	DMESG("<---- cmpk_handle_interrupt_status()\n");
> >  
> >  }
> > 
> > -/*--------------------------------------------------------------------
> > --------- - * Function:    cmpk_handle_query_config_rx()
> > - *
> > - * Overview:    The function is responsible for extract the message
> > from - *		firmware. It will contain dedicated info in
> > - *		ws-06-0063-rtl8190-command-packet-specification. 
Please
> > - *		refer to chapter "Beacon State Element".
> > - *
> > - * Input:       u8    *pmsg	-	Message Pointer of the 
command packet.
> > - *
> > - * Output:      NONE
> > - *
> > - * Return:      NONE
> > - *
> > - * Revised History:
> > - *  When		Who	Remark
> > - *  05/12/2008		amy	Create Version 0 porting from 
windows code.
> > - *
> > -
> > *---------------------------------------------------------------------
> > ------ - */
> > -static void cmpk_handle_query_config_rx(struct net_device *dev, u8
> > *pmsg) -{
> > -	struct cmpk_query_cfg	rx_query_cfg;
> > -
> > -	/* 1. Extract TX feedback info from RFD to temp structure 
buffer. */
> > -	/* It seems that FW use big endian(MIPS) and DRV use little 
endian in
> > -	 * windows OS. So we have to read the content byte by byte or
> > transfer
> > -	 * endian type before copy the message copy.
> > -	 */
> > -	rx_query_cfg.cfg_action		= (pmsg[4] & 0x80) >> 7;
> > -	rx_query_cfg.cfg_type		= (pmsg[4] & 0x60) >> 5;
> > -	rx_query_cfg.cfg_size		= (pmsg[4] & 0x18) >> 3;
> > -	rx_query_cfg.cfg_page		= (pmsg[6] & 0x0F) >> 0;
> > -	rx_query_cfg.cfg_offset		= pmsg[7];
> > -	rx_query_cfg.value		= (pmsg[8]  << 24) | 
(pmsg[9]  << 16) |
> > -					  (pmsg[10] <<  8) 
| (pmsg[11] <<  0);
> > -	rx_query_cfg.mask		= (pmsg[12] << 24) | 
(pmsg[13] << 16) |
> > -					  (pmsg[14] <<  8) 
| (pmsg[15] <<  0);
> > -}
> > -
> > 
> >  /*--------------------------------------------------------------------
> >  --------->  
> >   * Function:	cmpk_count_tx_status()
> >   *
> 
> Always test-build your patches as they can not break the build.  You
> obviously did not do that here, why not?
>
I can't see that where the build of rtl8192u is broken. 
The following lines are from the compilation log:

git/kernels/staging> make -j8 drivers/staging/rtl8192u/
 [...]
 CC [M]  drivers/staging/rtl8192u/r819xU_cmdpkt.o
 CC [M]  drivers/staging/rtl8192u/r819xU_cmdpkt.o
 [...]
 LD [M]  drivers/staging/rtl8192u/r8192u_usb.o

No errors are reported.

What am I missing?

Thanks,

Fabio
> 
> thanks,
> 
> greg k-h





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

* Re: [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function
  2021-04-12 10:12   ` Fabio M. De Francesco
@ 2021-04-12 10:22     ` Greg KH
  2021-04-12 10:42       ` Fabio M. De Francesco
  0 siblings, 1 reply; 7+ messages in thread
From: Greg KH @ 2021-04-12 10:22 UTC (permalink / raw)
  To: Fabio M. De Francesco; +Cc: outreachy-kernel, linux-staging, linux-kernel

On Mon, Apr 12, 2021 at 12:12:34PM +0200, Fabio M. De Francesco wrote:
> On Monday, April 12, 2021 11:42:51 AM CEST Greg KH wrote:
> > On Sun, Apr 11, 2021 at 08:48:13PM +0200, Fabio M. De Francesco wrote:
> > > Remove cmpk_handle_query_config_rx() because it just initializes a
> > > local
> > > variable and then returns "void".
> > > 
> > > Signed-off-by: Fabio M. De Francesco <fmdefrancesco@gmail.com>
> > > ---
> > > 
> > >  drivers/staging/rtl8192u/r819xU_cmdpkt.c | 40 ------------------------
> > >  1 file changed, 40 deletions(-)
> > > 
> > > diff --git a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > > b/drivers/staging/rtl8192u/r819xU_cmdpkt.c index
> > > 4cece40a92f6..d5a54c2d3086 100644
> > > --- a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > > +++ b/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > > @@ -249,46 +249,6 @@ static void cmpk_handle_interrupt_status(struct
> > > net_device *dev, u8 *pmsg)> 
> > >  	DMESG("<---- cmpk_handle_interrupt_status()\n");
> > >  
> > >  }
> > > 
> > > -/*--------------------------------------------------------------------
> > > --------- - * Function:    cmpk_handle_query_config_rx()
> > > - *
> > > - * Overview:    The function is responsible for extract the message
> > > from - *		firmware. It will contain dedicated info in
> > > - *		ws-06-0063-rtl8190-command-packet-specification. 
> Please
> > > - *		refer to chapter "Beacon State Element".
> > > - *
> > > - * Input:       u8    *pmsg	-	Message Pointer of the 
> command packet.
> > > - *
> > > - * Output:      NONE
> > > - *
> > > - * Return:      NONE
> > > - *
> > > - * Revised History:
> > > - *  When		Who	Remark
> > > - *  05/12/2008		amy	Create Version 0 porting from 
> windows code.
> > > - *
> > > -
> > > *---------------------------------------------------------------------
> > > ------ - */
> > > -static void cmpk_handle_query_config_rx(struct net_device *dev, u8
> > > *pmsg) -{
> > > -	struct cmpk_query_cfg	rx_query_cfg;
> > > -
> > > -	/* 1. Extract TX feedback info from RFD to temp structure 
> buffer. */
> > > -	/* It seems that FW use big endian(MIPS) and DRV use little 
> endian in
> > > -	 * windows OS. So we have to read the content byte by byte or
> > > transfer
> > > -	 * endian type before copy the message copy.
> > > -	 */
> > > -	rx_query_cfg.cfg_action		= (pmsg[4] & 0x80) >> 7;
> > > -	rx_query_cfg.cfg_type		= (pmsg[4] & 0x60) >> 5;
> > > -	rx_query_cfg.cfg_size		= (pmsg[4] & 0x18) >> 3;
> > > -	rx_query_cfg.cfg_page		= (pmsg[6] & 0x0F) >> 0;
> > > -	rx_query_cfg.cfg_offset		= pmsg[7];
> > > -	rx_query_cfg.value		= (pmsg[8]  << 24) | 
> (pmsg[9]  << 16) |
> > > -					  (pmsg[10] <<  8) 
> | (pmsg[11] <<  0);
> > > -	rx_query_cfg.mask		= (pmsg[12] << 24) | 
> (pmsg[13] << 16) |
> > > -					  (pmsg[14] <<  8) 
> | (pmsg[15] <<  0);
> > > -}
> > > -
> > > 
> > >  /*--------------------------------------------------------------------
> > >  --------->  
> > >   * Function:	cmpk_count_tx_status()
> > >   *
> > 
> > Always test-build your patches as they can not break the build.  You
> > obviously did not do that here, why not?
> >
> I can't see that where the build of rtl8192u is broken. 
> The following lines are from the compilation log:
> 
> git/kernels/staging> make -j8 drivers/staging/rtl8192u/
>  [...]
>  CC [M]  drivers/staging/rtl8192u/r819xU_cmdpkt.o
>  CC [M]  drivers/staging/rtl8192u/r819xU_cmdpkt.o
>  [...]
>  LD [M]  drivers/staging/rtl8192u/r8192u_usb.o
> 
> No errors are reported.
> 
> What am I missing?

The function is used elsewhere in this file :(


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

* Re: [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function
  2021-04-12 10:22     ` Greg KH
@ 2021-04-12 10:42       ` Fabio M. De Francesco
  0 siblings, 0 replies; 7+ messages in thread
From: Fabio M. De Francesco @ 2021-04-12 10:42 UTC (permalink / raw)
  To: Greg KH; +Cc: outreachy-kernel, linux-staging, linux-kernel

On Monday, April 12, 2021 12:22:03 PM CEST Greg KH wrote:
> On Mon, Apr 12, 2021 at 12:12:34PM +0200, Fabio M. De Francesco wrote:
> > On Monday, April 12, 2021 11:42:51 AM CEST Greg KH wrote:
> > > On Sun, Apr 11, 2021 at 08:48:13PM +0200, Fabio M. De Francesco 
wrote:
> > > > Remove cmpk_handle_query_config_rx() because it just initializes a
> > > > local
> > > > variable and then returns "void".
> > > > 
> > > > Signed-off-by: Fabio M. De Francesco <fmdefrancesco@gmail.com>
> > > > ---
> > > > 
> > > >  drivers/staging/rtl8192u/r819xU_cmdpkt.c | 40
> > > >  ------------------------
> > > >  1 file changed, 40 deletions(-)
> > > > 
> > > > diff --git a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > > > b/drivers/staging/rtl8192u/r819xU_cmdpkt.c index
> > > > 4cece40a92f6..d5a54c2d3086 100644
> > > > --- a/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > > > +++ b/drivers/staging/rtl8192u/r819xU_cmdpkt.c
> > > > @@ -249,46 +249,6 @@ static void
> > > > cmpk_handle_interrupt_status(struct
> > > > net_device *dev, u8 *pmsg)>
> > > > 
> > > >  	DMESG("<---- cmpk_handle_interrupt_status()\n");
> > > >  
> > > >  }
> > > > 
> > > > -/*----------------------------------------------------------------
> > > > ----
> > > > --------- - * Function:    cmpk_handle_query_config_rx()
> > > > - *
> > > > - * Overview:    The function is responsible for extract the
> > > > message
> > > > from - *		firmware. It will contain dedicated 
info in
> > > > - *		ws-06-0063-rtl8190-command-packet-specification.
> > 
> > Please
> > 
> > > > - *		refer to chapter "Beacon State Element".
> > > > - *
> > > > - * Input:       u8    *pmsg	-	Message Pointer of the
> > 
> > command packet.
> > 
> > > > - *
> > > > - * Output:      NONE
> > > > - *
> > > > - * Return:      NONE
> > > > - *
> > > > - * Revised History:
> > > > - *  When		Who	Remark
> > > > - *  05/12/2008		amy	Create Version 0 porting 
from
> > 
> > windows code.
> > 
> > > > - *
> > > > -
> > > > *------------------------------------------------------------------
> > > > ---
> > > > ------ - */
> > > > -static void cmpk_handle_query_config_rx(struct net_device *dev, u8
> > > > *pmsg) -{
> > > > -	struct cmpk_query_cfg	rx_query_cfg;
> > > > -
> > > > -	/* 1. Extract TX feedback info from RFD to temp structure
> > 
> > buffer. */
> > 
> > > > -	/* It seems that FW use big endian(MIPS) and DRV use little
> > 
> > endian in
> > 
> > > > -	 * windows OS. So we have to read the content byte by byte or
> > > > transfer
> > > > -	 * endian type before copy the message copy.
> > > > -	 */
> > > > -	rx_query_cfg.cfg_action		= (pmsg[4] & 0x80) >> 7;
> > > > -	rx_query_cfg.cfg_type		= (pmsg[4] & 0x60) >> 5;
> > > > -	rx_query_cfg.cfg_size		= (pmsg[4] & 0x18) >> 3;
> > > > -	rx_query_cfg.cfg_page		= (pmsg[6] & 0x0F) >> 0;
> > > > -	rx_query_cfg.cfg_offset		= pmsg[7];
> > > > -	rx_query_cfg.value		= (pmsg[8]  << 24) |
> > 
> > (pmsg[9]  << 16) |
> > 
> > > > -					  (pmsg[10] <<  8)
> > | 
> > | (pmsg[11] <<  0);
> > | 
> > > > -	rx_query_cfg.mask		= (pmsg[12] << 24) |
> > 
> > (pmsg[13] << 16) |
> > 
> > > > -					  (pmsg[14] <<  8)
> > | 
> > | (pmsg[15] <<  0);
> > | 
> > > > -}
> > > > -
> > > > 
> > > >  /*----------------------------------------------------------------
> > > >  ----
> > > >  --------->
> > > >  
> > > >   * Function:	cmpk_count_tx_status()
> > > >   *
> > > 
> > > Always test-build your patches as they can not break the build.  You
> > > obviously did not do that here, why not?
> > 
> > I can't see that where the build of rtl8192u is broken.
> > The following lines are from the compilation log:
> > 
> > git/kernels/staging> make -j8 drivers/staging/rtl8192u/
> > 
> >  [...]
> >  CC [M]  drivers/staging/rtl8192u/r819xU_cmdpkt.o
> >  CC [M]  drivers/staging/rtl8192u/r819xU_cmdpkt.o
> >  [...]
> >  LD [M]  drivers/staging/rtl8192u/r8192u_usb.o
> > 
> > No errors are reported.
> > 
> > What am I missing?
> 
> The function is used elsewhere in this file :(
>
You're right, it is used in a "switch" statement later in the file.
Now I've also understood why it built with no errors:
it built because, notwithstanding that modification, for some reason I have 
still the original version of the file.
I don't know why, maybe I've made some stupid error with Git...

Thanks,

Fabio




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

* Re: [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function
  2021-04-11 18:48 [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function Fabio M. De Francesco
@ 2021-04-19 18:57   ` kernel test robot
  2021-04-19 18:57   ` kernel test robot
  1 sibling, 0 replies; 7+ messages in thread
From: kernel test robot @ 2021-04-19 18:57 UTC (permalink / raw)
  To: Fabio M. De Francesco, Greg KH, outreachy-kernel, linux-staging,
	linux-kernel
  Cc: kbuild-all, Fabio M. De Francesco

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

Hi "Fabio,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on staging/staging-testing]

url:    https://github.com/0day-ci/linux/commits/Fabio-M-De-Francesco/staging-rtl8192u-Remove-function/20210412-024938
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git 1b9e18de8d43bf798622cc365f99b41f180b446f
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
        # https://github.com/0day-ci/linux/commit/499674dec8e01774889806d098bf9a12731930ee
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Fabio-M-De-Francesco/staging-rtl8192u-Remove-function/20210412-024938
        git checkout 499674dec8e01774889806d098bf9a12731930ee
        # save the attached .config to linux build tree
        make W=1 W=1 ARCH=x86_64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   drivers/staging/rtl8192u/r819xU_cmdpkt.c: In function 'cmpk_message_handle_rx':
>> drivers/staging/rtl8192u/r819xU_cmdpkt.c:477:4: error: implicit declaration of function 'cmpk_handle_query_config_rx' [-Werror=implicit-function-declaration]
     477 |    cmpk_handle_query_config_rx(dev, pcmd_buff);
         |    ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/cmpk_handle_query_config_rx +477 drivers/staging/rtl8192u/r819xU_cmdpkt.c

8fc8598e61f6f3 Jerry Chuang      2009-11-03  409  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  410  /*-----------------------------------------------------------------------------
8fc8598e61f6f3 Jerry Chuang      2009-11-03  411   * Function:    cmpk_message_handle_rx()
8fc8598e61f6f3 Jerry Chuang      2009-11-03  412   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  413   * Overview:    In the function, we will capture different RX command packet
8fc8598e61f6f3 Jerry Chuang      2009-11-03  414   *		info. Every RX command packet element has different message
8fc8598e61f6f3 Jerry Chuang      2009-11-03  415   *		length and meaning in content. We only support three type of RX
8fc8598e61f6f3 Jerry Chuang      2009-11-03  416   *		command packet now. Please refer to document
8fc8598e61f6f3 Jerry Chuang      2009-11-03  417   *		ws-06-0063-rtl8190-command-packet-specification.
8fc8598e61f6f3 Jerry Chuang      2009-11-03  418   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  419   * Input:       NONE
8fc8598e61f6f3 Jerry Chuang      2009-11-03  420   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  421   * Output:      NONE
8fc8598e61f6f3 Jerry Chuang      2009-11-03  422   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  423   * Return:      NONE
8fc8598e61f6f3 Jerry Chuang      2009-11-03  424   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  425   * Revised History:
8fc8598e61f6f3 Jerry Chuang      2009-11-03  426   *  When		Who	Remark
8fc8598e61f6f3 Jerry Chuang      2009-11-03  427   *  05/06/2008		amy	Create Version 0 porting from windows code.
8fc8598e61f6f3 Jerry Chuang      2009-11-03  428   *
70cd55d6755ee8 Derek Robson      2017-02-16  429   *---------------------------------------------------------------------------
70cd55d6755ee8 Derek Robson      2017-02-16  430   */
a115ee4175c3eb Teodora Baluta    2013-10-16  431  u32 cmpk_message_handle_rx(struct net_device *dev,
8fc8598e61f6f3 Jerry Chuang      2009-11-03  432  			   struct ieee80211_rx_stats *pstats)
8fc8598e61f6f3 Jerry Chuang      2009-11-03  433  {
8fc8598e61f6f3 Jerry Chuang      2009-11-03  434  	int			total_length;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  435  	u8			cmd_length, exe_cnt = 0;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  436  	u8			element_id;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  437  	u8			*pcmd_buff;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  438  
dc109dc597d7f4 simran singhal    2017-03-04  439  	/* 0. Check inpt arguments. It is a command queue message or
70cd55d6755ee8 Derek Robson      2017-02-16  440  	 * pointer is null.
70cd55d6755ee8 Derek Robson      2017-02-16  441  	 */
d6628e8cbe2047 Michael Straube   2020-09-19  442  	if (!pstats)
8fc8598e61f6f3 Jerry Chuang      2009-11-03  443  		return 0;	/* This is not a command packet. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  444  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  445  	/* 1. Read received command packet message length from RFD. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  446  	total_length = pstats->Length;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  447  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  448  	/* 2. Read virtual address from RFD. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  449  	pcmd_buff = pstats->virtual_address;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  450  
589b3d06fd1597 Justin P. Mattock 2012-04-30  451  	/* 3. Read command packet element id and length. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  452  	element_id = pcmd_buff[0];
8fc8598e61f6f3 Jerry Chuang      2009-11-03  453  
589b3d06fd1597 Justin P. Mattock 2012-04-30  454  	/* 4. Check every received command packet content according to different
70cd55d6755ee8 Derek Robson      2017-02-16  455  	 *    element type. Because FW may aggregate RX command packet to
70cd55d6755ee8 Derek Robson      2017-02-16  456  	 *    minimize transmit time between DRV and FW.
70cd55d6755ee8 Derek Robson      2017-02-16  457  	 */
6df9f669de3da5 Xenia Ragiadakou  2013-06-26  458  	/* Add a counter to prevent the lock in the loop from being held too
70cd55d6755ee8 Derek Robson      2017-02-16  459  	 * long
70cd55d6755ee8 Derek Robson      2017-02-16  460  	 */
05cdf47ac3374f Xenia Ragiadakou  2013-06-26  461  	while (total_length > 0 && exe_cnt++ < 100) {
6df9f669de3da5 Xenia Ragiadakou  2013-06-26  462  		/* We support aggregation of different cmd in the same packet */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  463  		element_id = pcmd_buff[0];
8fc8598e61f6f3 Jerry Chuang      2009-11-03  464  
05cdf47ac3374f Xenia Ragiadakou  2013-06-26  465  		switch (element_id) {
8fc8598e61f6f3 Jerry Chuang      2009-11-03  466  		case RX_TX_FEEDBACK:
8fc8598e61f6f3 Jerry Chuang      2009-11-03  467  			cmpk_handle_tx_feedback(dev, pcmd_buff);
8fc8598e61f6f3 Jerry Chuang      2009-11-03  468  			cmd_length = CMPK_RX_TX_FB_SIZE;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  469  			break;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  470  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  471  		case RX_INTERRUPT_STATUS:
8fc8598e61f6f3 Jerry Chuang      2009-11-03  472  			cmpk_handle_interrupt_status(dev, pcmd_buff);
17a16b769466e2 John Whitmore     2018-07-29  473  			cmd_length = sizeof(struct cmd_pkt_interrupt_status);
8fc8598e61f6f3 Jerry Chuang      2009-11-03  474  			break;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  475  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  476  		case BOTH_QUERY_CONFIG:
8fc8598e61f6f3 Jerry Chuang      2009-11-03 @477  			cmpk_handle_query_config_rx(dev, pcmd_buff);

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 65051 bytes --]

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

* Re: [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function
@ 2021-04-19 18:57   ` kernel test robot
  0 siblings, 0 replies; 7+ messages in thread
From: kernel test robot @ 2021-04-19 18:57 UTC (permalink / raw)
  To: kbuild-all

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

Hi "Fabio,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on staging/staging-testing]

url:    https://github.com/0day-ci/linux/commits/Fabio-M-De-Francesco/staging-rtl8192u-Remove-function/20210412-024938
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git 1b9e18de8d43bf798622cc365f99b41f180b446f
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
        # https://github.com/0day-ci/linux/commit/499674dec8e01774889806d098bf9a12731930ee
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Fabio-M-De-Francesco/staging-rtl8192u-Remove-function/20210412-024938
        git checkout 499674dec8e01774889806d098bf9a12731930ee
        # save the attached .config to linux build tree
        make W=1 W=1 ARCH=x86_64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   drivers/staging/rtl8192u/r819xU_cmdpkt.c: In function 'cmpk_message_handle_rx':
>> drivers/staging/rtl8192u/r819xU_cmdpkt.c:477:4: error: implicit declaration of function 'cmpk_handle_query_config_rx' [-Werror=implicit-function-declaration]
     477 |    cmpk_handle_query_config_rx(dev, pcmd_buff);
         |    ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/cmpk_handle_query_config_rx +477 drivers/staging/rtl8192u/r819xU_cmdpkt.c

8fc8598e61f6f3 Jerry Chuang      2009-11-03  409  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  410  /*-----------------------------------------------------------------------------
8fc8598e61f6f3 Jerry Chuang      2009-11-03  411   * Function:    cmpk_message_handle_rx()
8fc8598e61f6f3 Jerry Chuang      2009-11-03  412   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  413   * Overview:    In the function, we will capture different RX command packet
8fc8598e61f6f3 Jerry Chuang      2009-11-03  414   *		info. Every RX command packet element has different message
8fc8598e61f6f3 Jerry Chuang      2009-11-03  415   *		length and meaning in content. We only support three type of RX
8fc8598e61f6f3 Jerry Chuang      2009-11-03  416   *		command packet now. Please refer to document
8fc8598e61f6f3 Jerry Chuang      2009-11-03  417   *		ws-06-0063-rtl8190-command-packet-specification.
8fc8598e61f6f3 Jerry Chuang      2009-11-03  418   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  419   * Input:       NONE
8fc8598e61f6f3 Jerry Chuang      2009-11-03  420   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  421   * Output:      NONE
8fc8598e61f6f3 Jerry Chuang      2009-11-03  422   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  423   * Return:      NONE
8fc8598e61f6f3 Jerry Chuang      2009-11-03  424   *
8fc8598e61f6f3 Jerry Chuang      2009-11-03  425   * Revised History:
8fc8598e61f6f3 Jerry Chuang      2009-11-03  426   *  When		Who	Remark
8fc8598e61f6f3 Jerry Chuang      2009-11-03  427   *  05/06/2008		amy	Create Version 0 porting from windows code.
8fc8598e61f6f3 Jerry Chuang      2009-11-03  428   *
70cd55d6755ee8 Derek Robson      2017-02-16  429   *---------------------------------------------------------------------------
70cd55d6755ee8 Derek Robson      2017-02-16  430   */
a115ee4175c3eb Teodora Baluta    2013-10-16  431  u32 cmpk_message_handle_rx(struct net_device *dev,
8fc8598e61f6f3 Jerry Chuang      2009-11-03  432  			   struct ieee80211_rx_stats *pstats)
8fc8598e61f6f3 Jerry Chuang      2009-11-03  433  {
8fc8598e61f6f3 Jerry Chuang      2009-11-03  434  	int			total_length;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  435  	u8			cmd_length, exe_cnt = 0;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  436  	u8			element_id;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  437  	u8			*pcmd_buff;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  438  
dc109dc597d7f4 simran singhal    2017-03-04  439  	/* 0. Check inpt arguments. It is a command queue message or
70cd55d6755ee8 Derek Robson      2017-02-16  440  	 * pointer is null.
70cd55d6755ee8 Derek Robson      2017-02-16  441  	 */
d6628e8cbe2047 Michael Straube   2020-09-19  442  	if (!pstats)
8fc8598e61f6f3 Jerry Chuang      2009-11-03  443  		return 0;	/* This is not a command packet. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  444  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  445  	/* 1. Read received command packet message length from RFD. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  446  	total_length = pstats->Length;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  447  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  448  	/* 2. Read virtual address from RFD. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  449  	pcmd_buff = pstats->virtual_address;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  450  
589b3d06fd1597 Justin P. Mattock 2012-04-30  451  	/* 3. Read command packet element id and length. */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  452  	element_id = pcmd_buff[0];
8fc8598e61f6f3 Jerry Chuang      2009-11-03  453  
589b3d06fd1597 Justin P. Mattock 2012-04-30  454  	/* 4. Check every received command packet content according to different
70cd55d6755ee8 Derek Robson      2017-02-16  455  	 *    element type. Because FW may aggregate RX command packet to
70cd55d6755ee8 Derek Robson      2017-02-16  456  	 *    minimize transmit time between DRV and FW.
70cd55d6755ee8 Derek Robson      2017-02-16  457  	 */
6df9f669de3da5 Xenia Ragiadakou  2013-06-26  458  	/* Add a counter to prevent the lock in the loop from being held too
70cd55d6755ee8 Derek Robson      2017-02-16  459  	 * long
70cd55d6755ee8 Derek Robson      2017-02-16  460  	 */
05cdf47ac3374f Xenia Ragiadakou  2013-06-26  461  	while (total_length > 0 && exe_cnt++ < 100) {
6df9f669de3da5 Xenia Ragiadakou  2013-06-26  462  		/* We support aggregation of different cmd in the same packet */
8fc8598e61f6f3 Jerry Chuang      2009-11-03  463  		element_id = pcmd_buff[0];
8fc8598e61f6f3 Jerry Chuang      2009-11-03  464  
05cdf47ac3374f Xenia Ragiadakou  2013-06-26  465  		switch (element_id) {
8fc8598e61f6f3 Jerry Chuang      2009-11-03  466  		case RX_TX_FEEDBACK:
8fc8598e61f6f3 Jerry Chuang      2009-11-03  467  			cmpk_handle_tx_feedback(dev, pcmd_buff);
8fc8598e61f6f3 Jerry Chuang      2009-11-03  468  			cmd_length = CMPK_RX_TX_FB_SIZE;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  469  			break;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  470  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  471  		case RX_INTERRUPT_STATUS:
8fc8598e61f6f3 Jerry Chuang      2009-11-03  472  			cmpk_handle_interrupt_status(dev, pcmd_buff);
17a16b769466e2 John Whitmore     2018-07-29  473  			cmd_length = sizeof(struct cmd_pkt_interrupt_status);
8fc8598e61f6f3 Jerry Chuang      2009-11-03  474  			break;
8fc8598e61f6f3 Jerry Chuang      2009-11-03  475  
8fc8598e61f6f3 Jerry Chuang      2009-11-03  476  		case BOTH_QUERY_CONFIG:
8fc8598e61f6f3 Jerry Chuang      2009-11-03 @477  			cmpk_handle_query_config_rx(dev, pcmd_buff);

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 65051 bytes --]

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

end of thread, other threads:[~2021-04-19 18:57 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-11 18:48 [Outreachy kernel] [PATCH] staging: rtl8192u: Remove function Fabio M. De Francesco
2021-04-12  9:42 ` Greg KH
2021-04-12 10:12   ` Fabio M. De Francesco
2021-04-12 10:22     ` Greg KH
2021-04-12 10:42       ` Fabio M. De Francesco
2021-04-19 18:57 ` kernel test robot
2021-04-19 18:57   ` kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.