ALSA: bump uapi version numbers
authorArnd Bergmann <arnd@arndb.de>
Wed, 13 Nov 2019 16:49:14 +0000 (17:49 +0100)
committerArnd Bergmann <arnd@arndb.de>
Fri, 13 Dec 2019 10:25:58 +0000 (11:25 +0100)
commit1cfaef9617033f38eba9cc725809ed32bcdb3dc5
treea8669f0fec3dab3ff2ffaae1a6b884ef3ed97790
parent80fe7430c7085951d1246d83f638cc17e6c0be36
ALSA: bump uapi version numbers

Change SNDRV_PCM_VERSION, SNDRV_RAWMIDI_VERSION and SNDRV_TIMER_VERSION
to indicate the addition of the time64 version of the mmap interface and
these ioctl commands:

SNDRV_PCM_IOCTL_SYNC
SNDRV_RAWMIDI_IOCTL_STATUS
SNDRV_PCM_IOCTL_STATUS
SNDRV_PCM_IOCTL_STATUS_EXT
SNDRV_TIMER_IOCTL_TREAD
SNDRV_TIMER_IOCTL_STATUS

32-bit applications built with 64-bit time_t require both the headers
and the running kernel to support at least the new API version. When
built with earlier kernel headers, some of these may not work
correctly, so applications are encouraged to fail compilation like

 #if SNDRV_PCM_VERSION < SNDRV_PROTOCOL_VERSION(2, 0, 15)
 extern int __fail_build_for_time_64[sizeof(long) - sizeof(time_t)];
 #endif

or provide their own updated copy of the header file.
At runtime, the interface is unchanged for 32-bit time_t, but new
kernels are required to work with user compiled with 64-bit time_t.

A runtime check can be used to detect old kernel versions and
warn about those.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
include/uapi/sound/asound.h