From: "Boyer, Andrew" <Andrew.Boyer@amd.com>
To: John McNamara <john.mcnamara@intel.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: rte_bitmap_free() Re: DPDK Coverity issue 426433
Date: Thu, 20 Jun 2024 13:45:39 +0000 [thread overview]
Message-ID: <6A08397F-8D6E-4631-B63E-4CAE319F1463@amd.com> (raw)
In-Reply-To: <20240620111828.576992-1-john.mcnamara@intel.com>
Hello John,
While Coverity is correct that this is a useless call, that's an internal implementation detail of rte_bitmap_free() - not really something the caller should know about.
Can we annotate rte_bitmap_free() in some way to eliminate these? This is not the first PMD that's had this issue reported against it.
Thanks,
Andrew
> On Jun 20, 2024, at 7:18 AM, John McNamara <john.mcnamara@intel.com> wrote:
>
> Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
>
>
> Hi Andrew,
>
> This is an automated email in relation to a new Coverity static code analysis
> issue in DPDK. Details of the issue are below.
>
> The email has been sent to you because you have been identified as the author
> or maintainer of the code where the defect appears.
>
> There are several possible scenarios:
>
> * The defect identified isn't a real issue: In this case you can edit the
> defect online and change the defect "Classification" to "False Positive" or
> "Intentional" and change the "Action" to "Ignore". You should also update
> the "Severity", add yourself as the "Owner" and add a comment note.
>
> * The defect is a real issue: In this case you should submit a patch to fix
> the issues. The patch should include the following information in addition
> to the usual comments and signoff:
>
> Coverity issue: 426433
> Fixes: 6bc7f2cf6687 ("crypto/ionic: support sessions")
>
> In Coverity you should update the Classification, Severity, Action (to "Fix
> required" or "Fix Submitted"), Owner and a Comment if necessary.
>
> * The defect wasn't introduced by you. The line where the defect occurs may
> not be the source of the defect. If this is the case then let the actual
> author of the defect know by forwarding this email with a note or reply to
> the sender of this automated email: <john.mcnamara@intel.com>
>
> You can review the defects online at:
>
> http://scan.coverity.com/projects/dpdk-data-plane-development-kit
>
> If you aren't registered for the DPDK Coverity you can do so here:
>
> http://scan.coverity.com/users/sign_up
>
> Git commit data and Coverity defect information below.
>
> Commit data
> ===========
>
> Commit: crypto/ionic: support sessions
> Id: 6bc7f2cf6687126e265d848bcb83743a68f96ad6
> Author: Andrew Boyer
> Email: andrew.boyer@amd.com
> Date: Fri Jun 7 14:27:37 2024 -0700
>
> Defect information
> ==================
>
> /drivers/crypto/ionic/ionic_crypto_main.c: 816 in iocpt_free_objs()
> *** CID 426433: Incorrect expression (USELESS_CALL)
> 810 for (i = 0; i < dev->crypto_dev->data->nb_queue_pairs; i++) {
> 811 iocpt_cryptoq_free(queue_pairs[i]);
> 812 queue_pairs[i] = NULL;
> 813 }
> 814
> 815 if (dev->sess_bm != NULL) {
>>>> CID 426433: Incorrect expression (USELESS_CALL)
>>>> Calling "rte_bitmap_free(dev->sess_bm)" is only useful for its return value, which is ignored.
> 816 rte_bitmap_free(dev->sess_bm);
> 817 rte_free(dev->sess_bm);
> 818 dev->sess_bm = NULL;
> 819 }
> 820
> 821 if (dev->adminq != NULL) {
>
next parent reply other threads:[~2024-06-20 13:45 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20240620111828.576992-1-john.mcnamara@intel.com>
2024-06-20 13:45 ` Boyer, Andrew [this message]
2024-06-20 17:14 ` Stephen Hemminger
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=6A08397F-8D6E-4631-B63E-4CAE319F1463@amd.com \
--to=andrew.boyer@amd.com \
--cc=dev@dpdk.org \
--cc=john.mcnamara@intel.com \
/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;
as well as URLs for NNTP newsgroup(s).