mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-26 02:25:00 -05:00
75ae04206a
HPUX has separate NDELAY & NONBLOCK values. In the past we wanted to be able to run HP-UX binaries natively on parisc Linux which is why we defined O_NONBLOCK to 000200004 to distinguish NDELAY & NONBLOCK bits. But with 2 bits set in this bitmask we often ran into compatibility issues with other Linux applications which often only test one bit (or even compare the values). To avoid such issues in the future, this patch changes O_NONBLOCK to become 000200000. That way old programs will still be functional, and for new programs we now have only one bit set. Update the comment about SOCK_NONBLOCK too. Signed-off-by: Helge Deller <deller@gmx.de>
12 lines
310 B
C
12 lines
310 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef _ASM_SOCKET_H
|
|
#define _ASM_SOCKET_H
|
|
|
|
#include <uapi/asm/socket.h>
|
|
|
|
/* O_NONBLOCK clashed with the bits used for socket types. Therefore we
|
|
* had to define SOCK_NONBLOCK to a different value here.
|
|
*/
|
|
#define SOCK_NONBLOCK 0x40000000
|
|
|
|
#endif /* _ASM_SOCKET_H */
|