Pārlūkot izejas kodu

HID: roccat: declare meaning of pack pragma usage in driver headers

Using pack pragma to prevent padding bytes in binary data structures
used for hardware communication. Explanation of these pragmas was requested.

Signed-off-by: Stefan Achatz <erazor_de@users.sourceforge.net>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Stefan Achatz 15 gadi atpakaļ
vecāks
revīzija
bd3a2b9663
2 mainītis faili ar 6 papildinājumiem un 0 dzēšanām
  1. 3 0
      drivers/hid/hid-roccat-kone.h
  2. 3 0
      drivers/hid/hid-roccat-pyra.h

+ 3 - 0
drivers/hid/hid-roccat-kone.h

@@ -14,6 +14,9 @@
 
 #include <linux/types.h>
 
+/*
+ * Binary data structures used for hardware communication must have no padding.
+ */
 #pragma pack(push)
 #pragma pack(1)
 

+ 3 - 0
drivers/hid/hid-roccat-pyra.h

@@ -14,6 +14,9 @@
 
 #include <linux/types.h>
 
+/*
+ * Binary data structures used for hardware communication must have no padding.
+ */
 #pragma pack(push)
 #pragma pack(1)