freebsd-dev/sys
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
..
amd64 pmap: optimize MADV_WILLNEED on existing superpages 2022-09-30 12:14:05 -05:00
arm Teach the GICv3 driver to translate memory ranges 2022-09-23 15:28:45 +01:00
arm64 pmap: optimize MADV_WILLNEED on existing superpages 2022-09-30 12:14:05 -05:00
bsm
cam cam: Provide compatibility for CAMGETPASSTHRU for periph drivers 2022-09-29 13:14:57 -04:00
cddl opensolaris: Delete unused sources 2022-09-29 08:34:29 -04:00
compat Alter the prototype of qsort_r(3) to match POSIX, which adopted the 2022-09-30 15:26:30 -07:00
conf arm64: coresight: fix the build without FDT 2022-09-29 14:33:33 -05:00
contrib zlib crc32: Add prototypes for recently-added static functions. 2022-09-28 14:00:27 -07:00
crypto Fix the IV length in the armv8 AES GCM code 2022-09-06 13:11:04 +01:00
ddb Adjust db_flush_line() definition to avoid clang 15 warning 2022-07-19 20:37:15 +02:00
dev Alter the prototype of qsort_r(3) to match POSIX, which adopted the 2022-09-30 15:26:30 -07:00
dts
fs nfsclient: access v_mount only after the vnode is locked 2022-09-27 23:00:51 +03:00
gdb ddb: use _FLAGS command macros where appropriate 2022-07-05 11:56:55 -03:00
geom Adjust g_waitidle() visibility and definition 2022-08-02 21:11:10 +03:00
gnu
i386 kmem_malloc/free: Use void * instead of vm_offset_t for kernel pointers. 2022-09-22 15:09:19 -07:00
isa Adjust function definition in isa's pnp.c to avoid clang 15 warning 2022-07-27 21:13:59 +02:00
kern unix/dgram: don't leak file descriptors when socket write failed 2022-09-30 13:43:08 -07:00
kgssapi
libkern Alter the prototype of qsort_r(3) to match POSIX, which adopted the 2022-09-30 15:26:30 -07:00
modules qat: Fix build with GCC. 2022-09-29 15:07:02 -07:00
net if_vxlan(4): Check the size of data available in mbuf before using them 2022-09-30 09:56:15 +02:00
net80211 net80211: move IEEE80211_F_WME check to vap for consistency 2022-09-29 12:54:23 +00:00
netgraph Alter the prototype of qsort_r(3) to match POSIX, which adopted the 2022-09-30 15:26:30 -07:00
netinet Tcp progress timeout 2022-09-27 13:38:20 -04:00
netinet6 netinet6: factor interface addition code to the dedicated function 2022-09-27 13:23:34 +00:00
netipsec protosw: refactor protosw and domain static declaration and load 2022-08-17 11:50:32 -07:00
netpfil ipfilter: Cast uintmax_t values to size_t when adding to a pointer. 2022-09-28 13:58:34 -07:00
netsmb
nfs
nfsclient
nfsserver
nlm
ofed ibcore: The use of IN_LOOPBACK() now requires a valid VNET context. 2022-09-23 13:42:03 +02:00
opencrypto opencrypto: mark INVARIANTS variables as __diagused 2022-08-10 15:35:29 -04:00
powerpc kmem_malloc/free: Use void * instead of vm_offset_t for kernel pointers. 2022-09-22 15:09:19 -07:00
riscv riscv: Handle invalid L2 entries in pmap_extract() 2022-09-29 13:11:26 -04:00
rpc nfsd: Allow multiple instances of rpc.tlsservd 2022-08-22 13:54:24 -07:00
security vfs: introduce V_PCATCH to stop abusing PCATCH 2022-09-17 15:41:37 +00:00
sys Alter the prototype of qsort_r(3) to match POSIX, which adopted the 2022-09-30 15:26:30 -07:00
teken
tests
tools sound(4): Fix order of parameters for custom equalizer band pass filter. 2022-08-22 10:04:26 +02:00
ufs Fix an incorrectly placed parenthesis. 2022-09-29 01:45:41 -07:00
vm kmem_malloc/free: Use void * instead of vm_offset_t for kernel pointers. 2022-09-22 15:09:19 -07:00
x86 kmem_malloc/free: Use void * instead of vm_offset_t for kernel pointers. 2022-09-22 15:09:19 -07:00
xdr
xen
Makefile