From: Sriram R <srirrama@codeaurora.org>
To: dan.carpenter@oracle.com, mpubbise@codeaurora.org
Cc: linux-wireless@vger.kernel.org, ath11k@lists.infradead.org
Subject: Re: [bug report] ath11k: handle RX fragments
Date: Mon, 13 Apr 2020 18:48:25 +0530 [thread overview]
Message-ID: <304723517988acc2b595b0b4131546c5@codeaurora.org> (raw)
In-Reply-To: <BY5PR02MB6820A065D360B48F7251CADAF7DD0@BY5PR02MB6820.namprd02.prod.outlook.com>
Hi Dan,
> -----Original Message-----
> From: linux-wireless-owner@vger.kernel.org
> <linux-wireless-owner@vger.kernel.org> On Behalf Of Dan Carpenter
> Sent: Tuesday, April 7, 2020 7:11 PM
> To: mpubbise@codeaurora.org
> Cc: ath11k@lists.infradead.org; linux-wireless@vger.kernel.org
> Subject: [EXT] [bug report] ath11k: handle RX fragments
>
> Hello Manikanta Pubbisetty,
>
> The patch 243874c64c81: "ath11k: handle RX fragments" from Mar 16,
> 2020, leads to the following static checker warning:
>
> drivers/net/wireless/ath/ath11k/dp_rx.c:3365 ath11k_dp_rx_frag_h_mpdu()
> warn: missing error code here? 'ath11k_dp_rx_h_defrag()' failed. 'ret'
> = '0'
>
> drivers/net/wireless/ath/ath11k/dp_rx.c
> 3343
> HAL_WBM_REL_BM_ACT_PUT_IN_IDLE);
> 3344 }
> 3345
> 3346 if (!rx_tid->last_frag_no ||
> 3347 rx_tid->rx_frag_bitmap !=
> GENMASK(rx_tid->last_frag_no, 0)) {
> 3348 mod_timer(&rx_tid->frag_timer, jiffies +
> 3349
> ATH11K_DP_RX_FRAGMENT_TIMEOUT_MS);
> 3350 goto out_unlock;
> ^^^^^^^^^^^^^^^
>
> All these gotos should probably set error codes instead of returning
> success.
Thanks for pointing out. But, this function was written in this way on
purpose.
The error retval to caller and error goto's in this function perform
different cleanups and moving them to caller will only make the caller
function complex which is better to avoid.
Thanks,
Sriram.R
_______________________________________________
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k
WARNING: multiple messages have this Message-ID (diff)
From: Sriram R <srirrama@codeaurora.org>
To: dan.carpenter@oracle.com, mpubbise@codeaurora.org
Cc: ath11k@lists.infradead.org, linux-wireless@vger.kernel.org
Subject: Re: [bug report] ath11k: handle RX fragments
Date: Mon, 13 Apr 2020 18:48:25 +0530 [thread overview]
Message-ID: <304723517988acc2b595b0b4131546c5@codeaurora.org> (raw)
In-Reply-To: <BY5PR02MB6820A065D360B48F7251CADAF7DD0@BY5PR02MB6820.namprd02.prod.outlook.com>
Hi Dan,
> -----Original Message-----
> From: linux-wireless-owner@vger.kernel.org
> <linux-wireless-owner@vger.kernel.org> On Behalf Of Dan Carpenter
> Sent: Tuesday, April 7, 2020 7:11 PM
> To: mpubbise@codeaurora.org
> Cc: ath11k@lists.infradead.org; linux-wireless@vger.kernel.org
> Subject: [EXT] [bug report] ath11k: handle RX fragments
>
> Hello Manikanta Pubbisetty,
>
> The patch 243874c64c81: "ath11k: handle RX fragments" from Mar 16,
> 2020, leads to the following static checker warning:
>
> drivers/net/wireless/ath/ath11k/dp_rx.c:3365 ath11k_dp_rx_frag_h_mpdu()
> warn: missing error code here? 'ath11k_dp_rx_h_defrag()' failed. 'ret'
> = '0'
>
> drivers/net/wireless/ath/ath11k/dp_rx.c
> 3343
> HAL_WBM_REL_BM_ACT_PUT_IN_IDLE);
> 3344 }
> 3345
> 3346 if (!rx_tid->last_frag_no ||
> 3347 rx_tid->rx_frag_bitmap !=
> GENMASK(rx_tid->last_frag_no, 0)) {
> 3348 mod_timer(&rx_tid->frag_timer, jiffies +
> 3349
> ATH11K_DP_RX_FRAGMENT_TIMEOUT_MS);
> 3350 goto out_unlock;
> ^^^^^^^^^^^^^^^
>
> All these gotos should probably set error codes instead of returning
> success.
Thanks for pointing out. But, this function was written in this way on
purpose.
The error retval to caller and error goto's in this function perform
different cleanups and moving them to caller will only make the caller
function complex which is better to avoid.
Thanks,
Sriram.R
next prev parent reply other threads:[~2020-04-13 13:18 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-07 13:41 [bug report] ath11k: handle RX fragments Dan Carpenter
2020-04-07 13:41 ` Dan Carpenter
[not found] ` <BY5PR02MB6820A065D360B48F7251CADAF7DD0@BY5PR02MB6820.namprd02.prod.outlook.com>
2020-04-13 13:18 ` Sriram R [this message]
2020-04-13 13:18 ` Sriram R
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=304723517988acc2b595b0b4131546c5@codeaurora.org \
--to=srirrama@codeaurora.org \
--cc=ath11k@lists.infradead.org \
--cc=dan.carpenter@oracle.com \
--cc=linux-wireless@vger.kernel.org \
--cc=mpubbise@codeaurora.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 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.