Skip to contentSkip to conversation

rfkill: uapi: fix RFKILL_IOCTL_MAX_SIZE ioctl request definition

PATCH Superseded Gleb Fotengauer-Malinovskiy 4 participants 5 messages May 6, 2022 – May 7, 2022

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rfkill: uapi: fix RFKILL_IOCTL_MAX_SIZE ioctl request definition

Fixes 54f586a91532 ("rfkill: make new event layout opt-in")
---
 include/uapi/linux/rfkill.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/uapi/linux/rfkill.h +1 -1
index 283c5a7b3f2c..db6c8588c1d0 100644
@@ -184,7 +184,7 @@ struct rfkill_event_ext {
 #define RFKILL_IOC_NOINPUT	1
 #define RFKILL_IOCTL_NOINPUT	_IO(RFKILL_IOC_MAGIC, RFKILL_IOC_NOINPUT)
 #define RFKILL_IOC_MAX_SIZE	2
-#define RFKILL_IOCTL_MAX_SIZE	_IOW(RFKILL_IOC_MAGIC, RFKILL_IOC_EXT_SIZE, __u32)
+#define RFKILL_IOCTL_MAX_SIZE	_IOW(RFKILL_IOC_MAGIC, RFKILL_IOC_MAX_SIZE, __u32)
 
 /* and that's all userspace gets */
 
Signature · 1 line
glebfm
maintainer
#1 lore raw
Quoted 10 lines · Gleb Fotengauer-Malinovskiy
Fixes 54f586a91532 ("rfkill: make new event layout opt-in")
---
 include/uapi/linux/rfkill.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/uapi/linux/rfkill.h +0 -0
index 283c5a7b3f2c..db6c8588c1d0 100644

include/uapi/linux/rfkill.h struct rfkill_event_ext { · line 188

Quoted 6 lines
include/uapi/linux/rfkill.h +1 -1
@@ -184,7 +184,7 @@ struct rfkill_event_ext {
 #define RFKILL_IOC_NOINPUT	1
 #define RFKILL_IOCTL_NOINPUT	_IO(RFKILL_IOC_MAGIC, RFKILL_IOC_NOINPUT)
 #define RFKILL_IOC_MAX_SIZE	2
-#define RFKILL_IOCTL_MAX_SIZE	_IOW(RFKILL_IOC_MAGIC, RFKILL_IOC_EXT_SIZE, __u32)
+#define RFKILL_IOCTL_MAX_SIZE	_IOW(RFKILL_IOC_MAGIC, RFKILL_IOC_MAX_SIZE, __u32)
 

Oops. But I still need your Signed-off-by (see the documentation), and a commit message would be nice :)

johannes

#2 lore raw

PATCH v2 1/1 rfkill: uapi: fix RFKILL_IOCTL_MAX_SIZE ioctl request definition

In reply to Gleb Fotengauer-Malinovskiy
Fixes 54f586a91532 ("rfkill: make new event layout opt-in")
---
 include/uapi/linux/rfkill.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/uapi/linux/rfkill.h +1 -1
index 283c5a7b3f2c..db6c8588c1d0 100644
@@ -184,7 +184,7 @@ struct rfkill_event_ext {
 #define RFKILL_IOC_NOINPUT	1
 #define RFKILL_IOCTL_NOINPUT	_IO(RFKILL_IOC_MAGIC, RFKILL_IOC_NOINPUT)
 #define RFKILL_IOC_MAX_SIZE	2
-#define RFKILL_IOCTL_MAX_SIZE	_IOW(RFKILL_IOC_MAGIC, RFKILL_IOC_EXT_SIZE, __u32)
+#define RFKILL_IOCTL_MAX_SIZE	_IOW(RFKILL_IOC_MAGIC, RFKILL_IOC_MAX_SIZE, __u32)
 
 /* and that's all userspace gets */
 
Signature · 1 line
glebfm
maintainer
#3 lore raw
Quoted 4 lines · Gleb Fotengauer-Malinovskiy
Fixes 54f586a91532 ("rfkill: make new event layout opt-in")

---

No changelog text at all? I know I don't take patches like that, maybe other subsystem maintainers are more lax?

Please provide a changelog...

thanks,

greg k-h

#4 lore raw
Quoted 10 lines · Greg KH
Quoted 4 lines · Gleb Fotengauer-Malinovskiy
Fixes 54f586a91532 ("rfkill: make new event layout opt-in")

---

No changelog text at all? I know I don't take patches like that, maybe other subsystem maintainers are more lax?

Please provide a changelog...

The definition of RFKILL_IOCTL_MAX_SIZE introduced by commit 54f586a91532 is unusable since it is based on RFKILL_IOC_EXT_SIZE which has not been defined. Fix that by replacing the undefined constant with the constant which is intended to be used in this definition.

Signature · 1 line
ldv