Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kernel-selftest: ptp: testptp is broken in latest kernel version #878

Open
cshilwant opened this issue Oct 6, 2024 · 1 comment
Open

Comments

@cshilwant
Copy link
Contributor

cshilwant commented Oct 6, 2024

The latest kernels could not build ptp correctly via openembedded.
For reference, with 6.12-rc1 I observe the following,

| make: Entering directory '/mnt/chirag-sdk/yocto-build_am62lxx-evm/build/arago-tmp-default-glibc/work/am62lxx_evm-oe-linux/kernel-selftest/1.0/kernel-selftest-1.0/tools/testing/selftests/rtc' inux/kernel-selftest/1.0/kernel-selftest-1.0/tools/testing/selftests/ptp/testptp | testptp.c: In function 'main': | testptp.c:613:31: error: 'PTP_MASK_CLEAR_ALL' undeclared (first use in this function) | 613 | if (ioctl(fd, PTP_MASK_CLEAR_ALL)) { | | ^~~~~~~~~~~~~~~~~~ | testptp.c:613:31: note: each undeclared identifier is reported only once for each function it appears in | testptp.c:615:38: error: 'PTP_MASK_EN_SINGLE' undeclared (first use in this function) | 615 | } else if (ioctl(fd, PTP_MASK_EN_SINGLE, (unsigned int *)&channel)) { | | ^~~~~~~~~~~~~~~~~~ | make: *** [../lib.mk:222: /mnt/chirag-sdk/yocto-build_am62lxx-evm/build/arago-tmp-default-glibc/work/am62lxx_evm-oe-linux/kernel-selftest/1.0/kernel-selftest-1.0/tools/testing/selftests/ptp/testptp] Error 1

I see both the identifiers are actually defined under https://github.com/torvalds/linux/blob/v6.12-rc1/include/uapi/linux/ptp_clock.h#L246

It appears there’s a procedural problem with the kernel builds since issues like this aren’t being detected during their standard testing.

This change was specifically introduced in v6.7 - torvalds/linux@c5a445b

So, I believe testptp is broken in meta-openembedded since then.

@kraj Any inputs for what should be the way going forward as ptp is a part of default testlist - https://github.com/openembedded/meta-openembedded/blob/master/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb#L53 ?

@kraj
Copy link
Contributor

kraj commented Oct 7, 2024

@cshilwant we can disable but I think it would be rather good to fix the upstream problem. You are right about breakages in selftest and perhaps lack of CI for selftest combination

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants