From: Ivan Vecera <ivecera@redhat.com>
To: Petr Oros <poros@redhat.com>, netdev@vger.kernel.org
Cc: Sathya Perla <sathya.perla@broadcom.com>,
Ajit Khaparde <ajit.khaparde@broadcom.com>,
Sriharsha Basavapatna <sriharsha.basavapatna@broadcom.com>,
Somnath Kotur <somnath.kotur@broadcom.com>,
"David S. Miller" <davem@davemloft.net>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net] be2net: Fix memory leak in be_cmd_get_profile_config()
Date: Wed, 5 Sep 2018 14:45:07 +0200 [thread overview]
Message-ID: <4d28cb4d-a4e1-520d-27ee-ade1d4fb4fe4@redhat.com> (raw)
In-Reply-To: <20180905123746.7399-1-poros@redhat.com>
On 5.9.2018 14:37, Petr Oros wrote:
> DMA allocated memory is lost in be_cmd_get_profile_config() when we
> call it with non-NULL port_res parameter.
>
> Signed-off-by: Petr Oros <poros@redhat.com>
> ---
> drivers/net/ethernet/emulex/benet/be_cmds.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/emulex/benet/be_cmds.c b/drivers/net/ethernet/emulex/benet/be_cmds.c
> index ff92ab1daeb8..1e9d882c04ef 100644
> --- a/drivers/net/ethernet/emulex/benet/be_cmds.c
> +++ b/drivers/net/ethernet/emulex/benet/be_cmds.c
> @@ -4500,7 +4500,7 @@ int be_cmd_get_profile_config(struct be_adapter *adapter,
> port_res->max_vfs += le16_to_cpu(pcie->num_vfs);
> }
> }
> - return status;
> + goto err;
> }
>
> pcie = be_get_pcie_desc(resp->func_param, desc_count,
>
Good catch, Petr.
Reviewed-by: Ivan Vecera <ivecera@redhat.com>
next prev parent reply other threads:[~2018-09-05 12:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-05 12:37 Petr Oros
2018-09-05 12:45 ` Ivan Vecera [this message]
2018-09-05 15:08 ` David Miller
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=4d28cb4d-a4e1-520d-27ee-ade1d4fb4fe4@redhat.com \
--to=ivecera@redhat.com \
--cc=ajit.khaparde@broadcom.com \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=poros@redhat.com \
--cc=sathya.perla@broadcom.com \
--cc=somnath.kotur@broadcom.com \
--cc=sriharsha.basavapatna@broadcom.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
all inboxes | Powered by JetHome®