[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <14d72e0b-3ec3-4d73-b2fa-e7f7b30f9a32@intel.com>
Date: Fri, 28 Jun 2024 14:15:07 +0200
From: Przemek Kitszel <przemyslaw.kitszel@...el.com>
To: Edward Cree <ecree.xilinx@...il.com>, <edward.cree@....com>
CC: <linux-net-drivers@....com>, <netdev@...r.kernel.org>,
<habetsm.xilinx@...il.com>, <sudheer.mogilappagari@...el.com>,
<jdamato@...tly.com>, <mw@...ihalf.com>, <linux@...linux.org.uk>,
<sgoutham@...vell.com>, <gakula@...vell.com>, <sbhatta@...vell.com>,
<hkelam@...vell.com>, <saeedm@...dia.com>, <leon@...nel.org>,
<jacob.e.keller@...el.com>, <andrew@...n.ch>, <ahmed.zaki@...el.com>,
<davem@...emloft.net>, <kuba@...nel.org>, <edumazet@...gle.com>,
<pabeni@...hat.com>
Subject: Re: [PATCH v6 net-next 3/9] net: ethtool: record custom RSS contexts
in the XArray
On 6/27/24 16:24, Edward Cree wrote:
> On 26/06/2024 10:05, Przemek Kitszel wrote:
>> On 6/25/24 15:39, Edward Cree wrote:
>>> On 20/06/2024 07:32, Przemek Kitszel wrote:
>>>> why no error code set?
>>>
>>> Because at this point the driver *has* created the context, it's
>>> in the hardware. If we wanted to return failure we'd have to
>>> call the driver again to delete it, and that would still leave
>>> an ugly case where that call fails.
>>
>> driver is creating both HW context and ID at the same time, after
>> you call it from ethtool, eh :(
>>
>> then my only concern is why do we want to keep old context instead of
>> update? (my only and last concern for this series by now)
>> say dumb driver always says "ctx=1" because it does not now better,
>> but wants to update the context
>
> Tbh I'm not sure there's a clear case either way, if driver is
> screwing up we don't know why or how. The old context could
> still be present too for all we know. So my preference is to
> say "we don't know what happened, let's just not touch the
> xarray at all".
> In any case the WARN_ON should hopefully quickly catch any
> drivers that are hitting this, and going forward new drivers
> using this API shouldn't get added.
>
> If you still feel strongly this should be changed, please
> elaborate further on the reasoning.
Thanks, it makes sense as currently in the code, works for me!
I'll review v8
Powered by blists - more mailing lists