Powerpc specific selftests (specifically powerpc/primitives) included in linux-next
tree fails to build with following error
gcc -std=gnu99 -O2 -Wall -Werror -DGIT_VERSION='"next-20240229-0-gf303a3e2bcfb-dirty"' -I/home/sachin/linux-next/tools/testing/selftests/powerpc/include -I/home/sachin/linux-next/tools/testing/selftests/powerpc/primitives load_unaligned_zeropad.c ../harness.c -o /home/sachin/linux-next/tools/testing/selftests/powerpc/primitives/load_unaligned_zeropad
In file included from load_unaligned_zeropad.c:26:
word-at-a-time.h:7:10: fatal error: linux/bitops.h: No such file or directory
7 | #include <linux/bitops.h>
| ^~~~~~~~~~~~~~~~
compilation terminated.
The header file in question was last changed by following commit
commit 66a5c40f60f5d88ad8d47ba6a4ba05892853fa1f
kernel.h: removed REPEAT_BYTE from kernel.h
Thanks
— Sachin
Hi,
when running the dev_addr_lists unit test with lock debugging enabled,
I always get the following lockdep warning.
[ 7.031327] ====================================
[ 7.031393] WARNING: kunit_try_catch/1886 still has locks held!
[ 7.031478] 6.8.0-rc6-00053-g0fec7343edb5-dirty #1 Tainted: G W N
[ 7.031728] ------------------------------------
[ 7.031816] 1 lock held by kunit_try_catch/1886:
[ 7.031896] #0: ffffffff8ed35008 (rtnl_mutex){+.+.}-{3:3}, at: dev_addr_test_init+0x6a/0x100
Instrumentation shows that dev_addr_test_exit() is called, but only
after the warning fires.
Is this a problem with kunit tests or a problem with this specific test ?
Thanks,
Guenter
CC testing
On Wed, Feb 28, 2024 at 8:59 AM Guenter Roeck <linux(a)roeck-us.net> wrote:
> On 2/27/24 23:25, Christophe Leroy wrote:
> [ ... ]
> >>
> >> This test case is supposed to be as true to the "general case" as
> >> possible, so I have aligned the data along 14 + NET_IP_ALIGN. On ARM
> >> this will be a 16-byte boundary since NET_IP_ALIGN is 2. A driver that
> >> does not follow this may not be appropriately tested by this test case,
> >> but anyone is welcome to submit additional test cases that address this
> >> additional alignment concern.
> >
> > But then this test case is becoming less and less true to the "general
> > case" with this patch, whereas your initial implementation was almost
> > perfect as it was covering most cases, a lot more than what we get with
> > that patch applied.
> >
> NP with me if that is where people want to go. I'll simply disable checksum
> tests on all architectures which don't support unaligned accesses (so far
> it looks like that is only arm with thumb instructions, and possibly nios2).
> I personally find that less desirable and would have preferred a second
> configurable set of tests for unaligned accesses, but I have no problem
> with it.
IMHO the tests should validate the expected functionality. If a test
fails, either functionality is missing or behaves wrong, or the test
is wrong.
What is the point of writing tests for a core functionality like network
checksumming that do not match the expected functionality?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert(a)linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds