diff options
| author | Martin Kaiser <martin@kaiser.cx> | 2022-12-30 19:06:29 +0100 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-01-17 19:31:21 +0100 |
| commit | 00df407396ddf0d027bb3380fe07ed67e3624b81 (patch) | |
| tree | 4f799baa7bde3e5393e345e6e0d7967476c91a0f | |
| parent | 55074f02b4ef4db8d0467afc9eb78a53ef838a36 (diff) | |
| download | linux-00df407396ddf0d027bb3380fe07ed67e3624b81.tar.gz linux-00df407396ddf0d027bb3380fe07ed67e3624b81.zip | |
staging: r8188eu: cmd_seq is write-only
The cmd_seq component of struct cmd_priv is set and incremented but never
read. It can be removed.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150
Link: https://lore.kernel.org/r/20221230180646.91008-4-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| -rw-r--r-- | drivers/staging/r8188eu/core/rtw_cmd.c | 4 | ||||
| -rw-r--r-- | drivers/staging/r8188eu/include/rtw_cmd.h | 1 |
2 files changed, 0 insertions, 5 deletions
diff --git a/drivers/staging/r8188eu/core/rtw_cmd.c b/drivers/staging/r8188eu/core/rtw_cmd.c index 19b2f73d481d..eb79435da355 100644 --- a/drivers/staging/r8188eu/core/rtw_cmd.c +++ b/drivers/staging/r8188eu/core/rtw_cmd.c @@ -65,8 +65,6 @@ int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv) /* allocate DMA-able/Non-Page memory for cmd_buf and rsp_buf */ - pcmdpriv->cmd_seq = 1; - pcmdpriv->cmd_allocated_buf = kzalloc(MAX_CMDSZ + CMDBUFF_ALIGN_SZ, GFP_KERNEL); @@ -233,8 +231,6 @@ _next: ret = cmd_hdl(pcmd->padapter, pcmdbuf); pcmd->res = ret; } - - pcmdpriv->cmd_seq++; } else { pcmd->res = H2C_PARAMETERS_ERROR; } diff --git a/drivers/staging/r8188eu/include/rtw_cmd.h b/drivers/staging/r8188eu/include/rtw_cmd.h index c330a4435b31..9df7d4bf441d 100644 --- a/drivers/staging/r8188eu/include/rtw_cmd.h +++ b/drivers/staging/r8188eu/include/rtw_cmd.h @@ -32,7 +32,6 @@ struct cmd_priv { struct completion start_cmd_thread; struct completion stop_cmd_thread; struct __queue cmd_queue; - u8 cmd_seq; u8 *cmd_buf; /* shall be non-paged, and 4 bytes aligned */ u8 *cmd_allocated_buf; u8 *rsp_buf; /* shall be non-paged, and 4 bytes aligned */ |
