[PATCH 7/7] rfkill: provide RFKILL_TYPE_FM if undefined

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Ruediger Meier <ruediger.meier@xxxxxxxxxxx>

As discussed last year it's nice to be compatible to 2.6.32
https://www.spinics.net/lists/util-linux-ng/msg13963.html

BTW also re-define NUM_RFKILL_TYPES if needed, although we are
not really using it.

Signed-off-by: Ruediger Meier <ruediger.meier@xxxxxxxxxxx>
---
 sys-utils/rfkill.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/sys-utils/rfkill.c b/sys-utils/rfkill.c
index 75804ad41..031fe436f 100644
--- a/sys-utils/rfkill.c
+++ b/sys-utils/rfkill.c
@@ -45,7 +45,12 @@
  * year 2009 (2.6.33) or older.
  */
 #ifndef RFKILL_TYPE_NFC
+# ifndef RFKILL_TYPE_FM
+#  define RFKILL_TYPE_FM	RFKILL_TYPE_GPS + 1
+# endif
 # define RFKILL_TYPE_NFC	RFKILL_TYPE_FM + 1
+# undef NUM_RFKILL_TYPES
+# define NUM_RFKILL_TYPES	RFKILL_TYPE_NFC + 1
 #endif
 
 struct rfkill_type_str {
-- 
2.13.6

--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux