public inbox for kernel-janitors@vger.kernel.org
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] Staging: rtl8723bs: remove some dead code
Date: Tue, 05 Feb 2019 08:43:39 +0000	[thread overview]
Message-ID: <eaf3aba2-7eae-fe08-1889-d3b9b13c48c4@redhat.com> (raw)
In-Reply-To: <20190204182343.GA8823@kadam>

Hi,

On 04-02-19 19:24, Dan Carpenter wrote:
> "psecnetwork" is the address of &psecuritypriv->sec_bss.  Since
> ->sec_bss isn't the first member of the struct that means that
> "psecnetwork" can't be NULL.
> 
> We can just remove this dead code.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

Thanks, LGTM:

Reviewed-by: Hans de Goede <hdegoede@redhat.com>

Regards,

Hans



> ---
>   drivers/staging/rtl8723bs/core/rtw_cmd.c | 8 --------
>   1 file changed, 8 deletions(-)
> 
> diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl8723bs/core/rtw_cmd.c
> index ea2c187e56bd..91520ca3bbad 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_cmd.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c
> @@ -835,14 +835,6 @@ u8 rtw_joinbss_cmd(struct adapter  *padapter, struct wlan_network *pnetwork)
>   	}
>   
>   	psecnetwork = (struct wlan_bssid_ex *)&psecuritypriv->sec_bss;
> -	if (psecnetwork = NULL) {
> -		kfree(pcmd);
> -		res = _FAIL;
> -
> -		RT_TRACE(_module_rtl871x_cmd_c_, _drv_err_, ("rtw_joinbss_cmd :psecnetwork = NULL!!!\n"));
> -
> -		goto exit;
> -	}
>   
>   	memset(psecnetwork, 0, t_len);
>   
> 

      reply	other threads:[~2019-02-05  8:43 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-04 18:24 [PATCH] Staging: rtl8723bs: remove some dead code Dan Carpenter
2019-02-05  8:43 ` Hans de Goede [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=eaf3aba2-7eae-fe08-1889-d3b9b13c48c4@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=kernel-janitors@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox