From: Jakub Kicinski <kuba@kernel.org>
To: Rand Deeb <rand.sec96@gmail.com>
Cc: "David S . Miller" <davem@davemloft.net>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
deeb.rand@confident.ru, lvc-project@linuxtesting.org,
voskresenski.stanislav@confident.ru
Subject: Re: [PATCH] dl2k: Fix potential NULL pointer dereference in receive_packet()
Date: Wed, 14 Feb 2024 17:02:03 -0800 [thread overview]
Message-ID: <20240214170203.5bf20e2d@kernel.org> (raw)
In-Reply-To: <20240213200900.41722-1-rand.sec96@gmail.com>
On Tue, 13 Feb 2024 23:09:00 +0300 Rand Deeb wrote:
> + if (skb == NULL) {
if (!skb) is more common
> + np->rx_ring[entry].fraginfo = 0;
> + printk (KERN_INFO
> + "%s: receive_packet: "
> + "Unable to re-allocate Rx skbuff.#%d\n",
> + dev->name, entry);
no prints on allocation failure, please, there logs will include OOM
splats already. A counter as suggested by Jake would be better.
--
pw-bot: cr
next prev parent reply other threads:[~2024-02-15 1:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-13 20:09 [PATCH] dl2k: Fix potential NULL pointer dereference in receive_packet() Rand Deeb
2024-02-14 21:56 ` Jacob Keller
2024-02-15 1:02 ` Jakub Kicinski [this message]
2024-02-15 23:32 ` Rand Deeb
2024-02-16 0:18 ` Jakub Kicinski
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=20240214170203.5bf20e2d@kernel.org \
--to=kuba@kernel.org \
--cc=davem@davemloft.net \
--cc=deeb.rand@confident.ru \
--cc=linux-kernel@vger.kernel.org \
--cc=lvc-project@linuxtesting.org \
--cc=netdev@vger.kernel.org \
--cc=rand.sec96@gmail.com \
--cc=voskresenski.stanislav@confident.ru \
/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.