[PATCH 10/11] driver: thinkpad_acpi: fix minor checkpatch warnings

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

 



This commit fixes the following checkpatch warnings:
    - Use #include <linux/uaccess.h> instead of <asm/uaccess.h>
    - __packed is preferred over __attribute__((packed))
    - static const char * array should probably be static const char *
      const

Signed-off-by: Konrad Zapalowicz <bergo.torino@xxxxxxxxx>
---
 drivers/platform/x86/thinkpad_acpi.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c
index 9456e3f..14da752 100644
--- a/drivers/platform/x86/thinkpad_acpi.c
+++ b/drivers/platform/x86/thinkpad_acpi.c
@@ -82,7 +82,7 @@
 #include <sound/core.h>
 #include <sound/control.h>
 #include <sound/initval.h>
-#include <asm/uaccess.h>
+#include <linux/uaccess.h>
 
 /* ThinkPad CMOS commands */
 #define TP_CMOS_VOLUME_DOWN	0
@@ -999,7 +999,7 @@ struct attribute_set {
 struct attribute_set_obj {
 	struct attribute_set s;
 	struct attribute *a;
-} __attribute__((packed));
+} __packed;
 
 static struct attribute_set *create_attr_set(unsigned int max_members,
 						const char *name)
@@ -1131,7 +1131,7 @@ enum tpacpi_rfk_id {
 	TPACPI_RFK_SW_MAX
 };
 
-static const char *tpacpi_rfkill_names[] = {
+static const char * const tpacpi_rfkill_names[] = {
 	[TPACPI_RFK_BLUETOOTH_SW_ID] = "bluetooth",
 	[TPACPI_RFK_WWAN_SW_ID] = "wwan",
 	[TPACPI_RFK_UWB_SW_ID] = "uwb",
@@ -2098,7 +2098,7 @@ static int hotkey_mask_get(void)
 	return 0;
 }
 
-void static hotkey_mask_warn_incomplete_mask(void)
+static void hotkey_mask_warn_incomplete_mask(void)
 {
 	/* log only what the user can fix... */
 	const u32 wantedmask = hotkey_driver_mask &
-- 
1.8.1.2

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




[Index of Archives]     [Linux Kernel Development]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux