From: Pavel Skripkin <paskripkin@gmail.com>
To: Jaehee Park <jhpark1013@gmail.com>, Larry.Finger@lwfinger.net
Cc: phil@philpotter.co.uk, gregkh@linuxfoundation.org,
linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org,
outreachy@lists.linux.dev
Subject: Re: [PATCH v3 1/7] staging: r8188eu: remove unused member free_bss_buf
Date: Tue, 19 Apr 2022 22:27:05 +0300 [thread overview]
Message-ID: <32587233-0ff6-ed0f-b873-cd4f797005a9@gmail.com> (raw)
In-Reply-To: <3c5a510938ac395a13bb09c0de1868cce8ca3dd8.1650392020.git.jhpark1013@gmail.com>
Hi Jaehee,
On 4/19/22 21:19, Jaehee Park wrote:
> The free_bss_buf member of pmlmepriv is unused. Remove all related
> lines.
>
> Suggested-by: Pavel Skripkin <paskripkin@gmail.com>
> Signed-off-by: Jaehee Park <jhpark1013@gmail.com>
> ---
[code snip]
> @@ -55,16 +54,6 @@ static int _rtw_init_mlme_priv(struct adapter *padapter)
>
> memset(&pmlmepriv->assoc_ssid, 0, sizeof(struct ndis_802_11_ssid));
>
> - pbuf = vzalloc(MAX_BSS_CNT * (sizeof(struct wlan_network)));
> -
> - if (!pbuf) {
> - res = _FAIL;
> - goto exit;
> - }
> - pmlmepriv->free_bss_buf = pbuf;
> -
> - pnetwork = (struct wlan_network *)pbuf;
> -
> for (i = 0; i < MAX_BSS_CNT; i++) {
> INIT_LIST_HEAD(&pnetwork->list);
>
And now kernel will just boom here :)
I am sorry for not noticing that from the beginning, that's my fault.
This pointer is used in very weird way, so let's come back to initial
patch: just remove 'if' before vfree().
Refactoring that place is the separate task
I am again sorry for wrong suggestion,
With regards,
Pavel Skripkin
next prev parent reply other threads:[~2022-04-19 19:27 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-19 18:19 [PATCH v3 0/7] staging: r8188eu: fix warnings reported by checkpatch Jaehee Park
2022-04-19 18:19 ` [PATCH v3 1/7] staging: r8188eu: remove unused member free_bss_buf Jaehee Park
2022-04-19 19:27 ` Pavel Skripkin [this message]
2022-04-20 11:55 ` Dan Carpenter
2022-04-20 14:48 ` Jaehee Park
2022-04-20 17:39 ` Dan Carpenter
2022-04-22 16:13 ` Dan Carpenter
2022-04-20 16:33 ` Greg KH
2022-04-19 18:19 ` [PATCH v3 2/7] staging: r8188eu: remove spaces before tabs Jaehee Park
2022-04-19 18:19 ` [PATCH v3 3/7] staging: r8188eu: remove 'added by' author comments Jaehee Park
2022-04-19 18:19 ` [PATCH v3 4/7] staging: r8188eu: place constants on the right side of tests Jaehee Park
2022-04-19 18:19 ` [PATCH v3 5/7] staging: r8188eu: replace spaces with tabs Jaehee Park
2022-04-19 18:19 ` [PATCH v3 6/7] staging: r8188eu: correct typo in comments Jaehee Park
2022-04-19 18:19 ` [PATCH v3 7/7] staging: r8188eu: remove unused else condition Jaehee Park
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=32587233-0ff6-ed0f-b873-cd4f797005a9@gmail.com \
--to=paskripkin@gmail.com \
--cc=Larry.Finger@lwfinger.net \
--cc=gregkh@linuxfoundation.org \
--cc=jhpark1013@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=outreachy@lists.linux.dev \
--cc=phil@philpotter.co.uk \
/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
Powered by JetHome