[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHS8izOUx=_HqS8foFoyv7H2d7zz6+jchG2r7w+LL9fq8CJvLQ@mail.gmail.com>
Date: Thu, 31 Oct 2024 10:20:14 -0700
From: Mina Almasry <almasrymina@...gle.com>
To: Stanislav Fomichev <stfomichev@...il.com>
Cc: Stanislav Fomichev <sdf@...ichev.me>, netdev@...r.kernel.org, davem@...emloft.net,
edumazet@...gle.com, kuba@...nel.org, pabeni@...hat.com,
linux-kernel@...r.kernel.org, linux-kselftest@...r.kernel.org,
andrew+netdev@...n.ch, shuah@...nel.org, horms@...nel.org, willemb@...gle.com,
petrm@...dia.com
Subject: Re: [PATCH net-next v6 00/12] selftests: ncdevmem: Add ncdevmem to ksft
On Thu, Oct 31, 2024 at 9:45 AM Mina Almasry <almasrymina@...gle.com> wrote:
>
...
>
> Sorry, 2 issues testing this series:
>
...
>
> 2. Validation is now broken:
>
Validation is re-fixed with this diff:
diff --git a/tools/testing/selftests/drivers/net/hw/ncdevmem.c
b/tools/testing/selftests/drivers/net/hw/ncdevmem.c
index 692c189bb5cc..494ae66d8abf 100644
--- a/tools/testing/selftests/drivers/net/hw/ncdevmem.c
+++ b/tools/testing/selftests/drivers/net/hw/ncdevmem.c
@@ -568,8 +568,7 @@ int do_server(struct memory_buffer *mem)
if (do_validation)
validate_buffer(
- ((unsigned char *)tmp_mem) +
- dmabuf_cmsg->frag_offset,
+ ((unsigned char *)tmp_mem),
dmabuf_cmsg->frag_size);
else
print_nonzero_bytes(tmp_mem,
dmabuf_cmsg->frag_size);
Since memcpy_from_device copies to the beginning of tmp_mem, then the
beginning tmp_mem should be passed to the validation.
--
Thanks,
Mina
Powered by blists - more mailing lists