opnsense-src/sys/compat/linuxkpi/common/src
Ed Schouten af3c78886f Alter the prototype of qsort_r(3) to match POSIX, which adopted the
glibc-based interface.

Unfortunately, the glibc maintainers, despite knowing the existence
of the FreeBSD qsort_r(3) interface in 2004 and refused to add the
same interface to glibc based on grounds of the lack of standardization
and portability concerns, has decided it was a good idea to introduce
their own qsort_r(3) interface in 2007 as a GNU extension with a
slightly different and incompatible interface.

With the adoption of their interface as POSIX standard, let's switch
to the same prototype, there is no need to remain incompatible.

C++ and C applications written for the historical FreeBSD interface
get source level compatibility when building in C++ mode, or when
building with a C compiler with C11 generics support, provided that
the caller passes a fifth parameter of qsort_r() that exactly matches
the historical FreeBSD comparator function pointer type and does not
redefine the historical qsort_r(3) prototype in their source code.

Symbol versioning is used to keep old binaries working.

MFC:			never
Relnotes:		yes
Reviewed by:		cem, imp, hps, pauamma
Differential revision:	https://reviews.freebsd.org/D17083
2022-09-30 15:26:30 -07:00
..
linux_80211.c LinuxKPI: 80211 / iwlwifi: improve queue management 2022-09-05 21:03:03 +00:00
linux_80211.h LinuxKPI: 80211: scanning code updates 2022-09-03 23:40:51 +00:00
linux_80211_macops.c LinuxKPI, dev: 80211 update mac80211 KPI 2022-09-07 23:38:54 +00:00
linux_acpi.c LinuxKPI: Implement ACPI bits required by drm-kmod in base system 2020-11-09 13:20:14 +00:00
linux_compat.c Alter the prototype of qsort_r(3) to match POSIX, which adopted the 2022-09-30 15:26:30 -07:00
linux_current.c linuxkpi: use SI_SUB_EVENTHANDLER + 1, like other consumers 2022-09-17 23:52:23 +00:00
linux_devres.c LinuxKPI: implement devres() framework parts and two examples 2021-01-28 16:32:43 +00:00
linux_dmi.c LinuxKPI: Fix dmi_matches() function 2022-06-06 10:31:34 +02:00
linux_domain.c Implement basic support for allocating memory from a specific numa node 2021-03-09 21:01:47 +01:00
linux_firmware.c LinuxKPI: firmware: add request_partial_firmware_into_buf() 2022-09-07 23:33:45 +00:00
linux_fpu.c LinuxKPI: Make FPU sections thread-safe and use the NOCTX flag. 2021-07-31 15:36:48 +02:00
linux_hrtimer.c compat: clean up empty lines in .c and .h files 2020-09-01 21:24:33 +00:00
linux_i2c.c linuxkpi: i2c: Fix 7bit/8bit addressing 2022-08-19 14:39:16 +02:00
linux_i2cbb.c linuxkpi: unbreak linux_i2cbb 2022-08-24 16:23:37 +03:00
linux_idr.c compat: clean up empty lines in .c and .h files 2020-09-01 21:24:33 +00:00
linux_interrupt.c LinuxKPI: Hide some internal symbols in linux_interrupt.c 2021-09-29 23:26:14 +03:00
linux_kmod.c LinuxKPI: add module dependency on firmware(9) 2021-01-30 17:50:26 +00:00
linux_kthread.c LinuxKPI: Implement kthread_worker related functions 2022-05-17 15:10:20 +03:00
linux_lock.c linuxkpi: Add down_read_killable() 2022-09-20 19:39:32 +02:00
linux_netdev.c LinuxKPI: netdev: expose napi state 2022-09-07 23:35:41 +00:00
linux_page.c kmem_malloc/free: Use void * instead of vm_offset_t for kernel pointers. 2022-09-22 15:09:19 -07:00
linux_pci.c kmem_malloc/free: Use void * instead of vm_offset_t for kernel pointers. 2022-09-22 15:09:19 -07:00
linux_radix.c compat: clean up empty lines in .c and .h files 2020-09-01 21:24:33 +00:00
linux_rcu.c LinuxKPI: Do not wait for a grace period in rcu_barrier() 2021-07-05 03:19:50 +03:00
linux_schedule.c Revert "LinuxKPI: Allow wake_up to be executed within a critical section" 2022-01-27 01:27:01 +03:00
linux_seq_file.c linuxkpi: Resolve duplicate global symbol name to fix LINT kernel build. 2022-09-20 22:37:15 +02:00
linux_shmemfs.c vm_object: Modify various drivers to allocate OBJT_SWAP objects 2022-07-12 09:10:15 -04:00
linux_shrinker.c LinuxKPI: Convert lkpi-shrinker lock to sx. 2022-05-17 15:10:20 +03:00
linux_simple_attr.c linuxkpi: drm-kmod debugfs support 2022-09-20 19:41:10 +02:00
linux_skbuff.c LinuxKPI: skbuff: sort list header and add new (dummy) functions 2022-07-29 15:21:48 +00:00
linux_slab.c linuxkpi: Handle a NULL cache pointer in kmem_cache_destroy() 2021-10-06 14:49:39 -04:00
linux_tasklet.c Make sure all tasklets are drained before unloading the LinuxKPI. 2021-05-21 11:21:32 +02:00
linux_usb.c LinuxKPI: move pm_message_t from kernel.h to pm.h 2022-06-10 14:05:12 +00:00
linux_work.c linux(4): Fix a typo in a source code comment 2022-06-04 11:27:19 +02:00
linux_xarray.c linuxkpi xarray: Correct expression in assertion. 2022-02-11 13:59:27 -08:00
lkpi_iic_if.m linuxkpi: Rework detach function 2022-05-25 09:57:10 +02:00