[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20230320215229.53b7dfa7@kernel.org>
Date: Mon, 20 Mar 2023 21:52:29 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Nick Child <nnac123@...ux.ibm.com>
Cc: netdev@...r.kernel.org
Subject: Re: [PATCH net 1/2] net: Catch invalid index in XPS mapping
On Fri, 17 Mar 2023 13:19:40 -0500 Nick Child wrote:
> + if (index >= dev->num_tx_queues)
> + return -EINVAL;
WARN_ON_ONCE()? On a quick grep virtio does not check return value
for example. Others may assume this never fails and not print any
warning, and users will have "fun time" figuring out why their machine
fell of the network / where is the probe error coming from..
Also seems like net-next material? Why do we consider this a fix?
It's defensive / debug check, ain't no bug to assume callers are sane..
Powered by blists - more mailing lists