From: Lance Richardson <lrichard@redhat.com>
To: Sudarsana Reddy Kalluru <sudarsana.kalluru@cavium.com>
Cc: davem@davemloft.net, netdev@vger.kernel.org,
Yuval Mintz <Yuval.Mintz@cavium.com>
Subject: Re: [PATCH net 3/4] qed: Fix possible system hang in the dcbnl-getdcbx() path.
Date: Wed, 19 Apr 2017 09:56:36 -0400 (EDT) [thread overview]
Message-ID: <1873138594.16006381.1492610196115.JavaMail.zimbra@redhat.com> (raw)
In-Reply-To: <20170419101955.26444-4-sudarsana.kalluru@cavium.com>
> From: "Sudarsana Reddy Kalluru" <sudarsana.kalluru@cavium.com>
> To: davem@davemloft.net
> Cc: netdev@vger.kernel.org, "Yuval Mintz" <Yuval.Mintz@cavium.com>
> Sent: Wednesday, 19 April, 2017 6:19:54 AM
> Subject: [PATCH net 3/4] qed: Fix possible system hang in the dcbnl-getdcbx() path.
>
> qed_dcbnl_get_dcbx() API uses kmalloc in GFT_KERNEL mode. The API gets
> invoked in the interrupt context by qed_dcbnl_getdcbx callback. Need
> to invoke this kmalloc in atomic mode.
>
> Signed-off-by: Sudarsana Reddy Kalluru <Sudarsana.Kalluru@cavium.com>
> Signed-off-by: Yuval Mintz <Yuval.Mintz@cavium.com>
> ---
> drivers/net/ethernet/qlogic/qed/qed_dcbx.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/qlogic/qed/qed_dcbx.c
> b/drivers/net/ethernet/qlogic/qed/qed_dcbx.c
> index ff058a3..8f0783a 100644
> --- a/drivers/net/ethernet/qlogic/qed/qed_dcbx.c
> +++ b/drivers/net/ethernet/qlogic/qed/qed_dcbx.c
> @@ -1264,7 +1264,7 @@ static struct qed_dcbx_get *qed_dcbnl_get_dcbx(struct
> qed_hwfn *hwfn,
> {
> struct qed_dcbx_get *dcbx_info;
>
> - dcbx_info = kzalloc(sizeof(*dcbx_info), GFP_KERNEL);
> + dcbx_info = kmalloc(sizeof(*dcbx_info), GFP_ATOMIC);
You are changing a kzalloc to kmalloc, was that intentional?
> if (!dcbx_info)
> return NULL;
>
> --
> 1.8.3.1
>
>
next prev parent reply other threads:[~2017-04-19 13:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-19 10:19 [PATCH net 0/4] qed: Dcbx bug fixes Sudarsana Reddy Kalluru
2017-04-19 10:19 ` [PATCH net 1/4] qed: Fix possible error in populating max_tc field Sudarsana Reddy Kalluru
2017-04-19 10:19 ` [PATCH net 2/4] qed: Fix sending an invalid PFC error mask to MFW Sudarsana Reddy Kalluru
2017-04-19 10:19 ` [PATCH net 3/4] qed: Fix possible system hang in the dcbnl-getdcbx() path Sudarsana Reddy Kalluru
2017-04-19 13:56 ` Lance Richardson [this message]
2017-04-19 14:14 ` Mintz, Yuval
2017-04-19 10:19 ` [PATCH net 4/4] qed: Fix issue in populating the PFC config paramters Sudarsana Reddy Kalluru
2017-04-20 20:29 ` [PATCH net 0/4] qed: Dcbx bug fixes 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=1873138594.16006381.1492610196115.JavaMail.zimbra@redhat.com \
--to=lrichard@redhat.com \
--cc=Yuval.Mintz@cavium.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=sudarsana.kalluru@cavium.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).