Page MenuHomeFreeBSD

linuxkpi: `list_sort()`'s callback now takes list arguments
ClosedPublic

Authored by dumbbell on Jan 16 2023, 7:45 PM.
Tags
None
Referenced Files
Unknown Object (File)
May 8 2024, 7:01 AM
Unknown Object (File)
Jan 15 2024, 12:17 AM
Unknown Object (File)
Dec 27 2023, 4:25 AM
Unknown Object (File)
Dec 23 2023, 12:01 PM
Unknown Object (File)
Dec 21 2023, 2:22 AM
Unknown Object (File)
Nov 26 2023, 4:24 AM
Unknown Object (File)
Nov 14 2023, 4:28 PM
Unknown Object (File)
Nov 10 2023, 2:55 PM

Details

Summary

This change breaks the API of list_sort() and thus the compilation of existing drivers. Does anyone have a suggestion on how to handle this change beside a bump of FreeBSD_version?

This is part of the update of the DRM drivers to Linux 5.13.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Did the API changed in Linux at some point ?
We used to have LINUXKPI_VERSION at some point, maybe we can use this again if this is a change in Linux API.

Support old and new list_sort() API.

manu requested changes to this revision.Jan 28 2023, 8:52 AM
manu added inline comments.
sys/compat/linuxkpi/common/src/linux_compat.c
39 ↗(On Diff #115768)

No sure that we should define it here now.
Let's start by supporting both version, we can define LINUXKPI_VERSION in drm-kmod starting from the 5.13 branch.
And when old consumer (drm-kmod 5.10-lts branch) are deprecated we can remove the check.

This revision now requires changes to proceed.Jan 28 2023, 8:52 AM
sys/compat/linuxkpi/common/src/linux_compat.c
39 ↗(On Diff #115768)

Ok, I will modify the patch to define the new header (if LINUXKPI_VERSION >= 51300), but leave linux_compat.c unmodified (it will deconstify the arguments as today).

Leave linux_compat.c unmodify (to use the old header). The KBI doesn't change anyway.

This revision is now accepted and ready to land.Jan 31 2023, 7:15 AM