git: aa21554a8b03 - stable/13 - ioccom: define ioctl cmd value that can never be valid

Konstantin Belousov kib at FreeBSD.org
Fri May 7 00:43:40 UTC 2021


The branch stable/13 has been updated by kib:

URL: https://cgit.FreeBSD.org/src/commit/?id=aa21554a8b03196c4208a2a33527020f29073a00

commit aa21554a8b03196c4208a2a33527020f29073a00
Author:     Konstantin Belousov <kib at FreeBSD.org>
AuthorDate: 2021-04-22 19:40:08 +0000
Commit:     Konstantin Belousov <kib at FreeBSD.org>
CommitDate: 2021-05-07 00:36:00 +0000

    ioccom: define ioctl cmd value that can never be valid
    
    (cherry picked from commit 619fe095861274576a2cb45628076968051b1585)
---
 sys/sys/ioccom.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/sys/sys/ioccom.h b/sys/sys/ioccom.h
index 0329ac358491..13faba046719 100644
--- a/sys/sys/ioccom.h
+++ b/sys/sys/ioccom.h
@@ -79,6 +79,9 @@
 #define	IOCPARM_IVAL(x)	((int)(intptr_t)(void *)*(caddr_t *)(void *)(x))
 #endif
 
+#define	_IOC_INVALID	(_IOC_VOID|_IOC_INOUT)	/* Never valid cmd value,
+						   use as filler */
+
 #else
 
 #include <sys/cdefs.h>


More information about the dev-commits-src-all mailing list