[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <8f54ae13-7943-4e45-9881-a01108a1b58f@amd.com>
Date: Mon, 23 Jun 2025 08:44:39 -0700
From: Brett Creeley <bcreeley@....com>
To: Simon Horman <horms@...nel.org>
Cc: Thomas Fourier <fourier.thomas@...il.com>,
Shannon Nelson <shannon.nelson@....com>,
Brett Creeley <brett.creeley@....com>, Andrew Lunn <andrew+netdev@...n.ch>,
"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Alexei Starovoitov <ast@...nel.org>, Daniel Borkmann <daniel@...earbox.net>,
Jesper Dangaard Brouer <hawk@...nel.org>,
John Fastabend <john.fastabend@...il.com>,
Stanislav Fomichev <sdf@...ichev.me>,
Vladimir Oltean <vladimir.oltean@....com>,
Caleb Sander Mateos <csander@...estorage.com>,
Taehee Yoo <ap420073@...il.com>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, bpf@...r.kernel.org
Subject: Re: [PATCH net v3] ethernet: ionic: Fix DMA mapping tests
On 6/20/2025 3:51 AM, Simon Horman wrote:
> Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
>
>
> On Thu, Jun 19, 2025 at 03:28:06PM -0700, Brett Creeley wrote:
>>
>>
>> On 6/19/2025 2:45 AM, Thomas Fourier wrote:
>>> Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
>>>
>>>
>>> Change error values of `ionic_tx_map_single()` and `ionic_tx_map_frag()`
>>> from 0 to `DMA_MAPPING_ERROR` to prevent collision with 0 as a valid
>>> address.
>>>
>>> This also fixes the use of `dma_mapping_error()` to test against 0 in
>>> `ionic_xdp_post_frame()`
>>>
>>> Fixes: 0f3154e6bcb3 ("ionic: Add Tx and Rx handling")
>>
>> I'm not sure the Fixes commit above should be in the list. Functionally it's
>> correct, except there being multiple calls to dma_mapping_error() on the
>> same dma_addr.
>>
>> Other than the minor nit above the commit looks good. Thanks again for
>> fixing this.
>>
>> Reviewed-by: Brett Creeley <brett.creeley@....com>
>
> Hi Brett and Thomas,
>
> Maybe I misunderstand things, if so I apologise.
>
> If this patch fixes a bug - e.g. the may observe a system crash -
> then it should be targeted at net and have a Fixes tag. Where the
> Fixes tag generally cites the first commit in which the user may
> experience the bug.
>
> If, on the other hand, this does not fix a bug then the patch
> should be targeted at net-next and should not have a Fixes tag.
>
> In that case, commits may be cited using following form in
> the commit message (before the Signed-off-by and other tags).
> And, unlike tags, it may be line wrapped.
>
> commit 0f3154e6bcb3 ("ionic: Add Tx and Rx handling")
>
> E.g.: This was introduce by commit 0f3154e6bcb3 ("ionic: Add Tx and Rx
> handling").
>
> I hope this helps. If not, sorry for the noise.
Simon,
I suspect you are right and this probably shouldn't be categorized as a
bug fix since the change only addresses a corner case that would happen
if the DMA mapping API(s) return 0 as a valid adddress, which wouldn't
cause a crash with/without this patch.
Thanks for the feedback.
Brett
>
> ...
Powered by blists - more mailing lists