Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mfd: kempld-core: Correct a variety of checkpatch warnings

WARNING: line over 80 characters
+module_param_string(force_device_id, force_device_id, sizeof(force_device_id), 0);

WARNING: msleep < 20ms can sleep for up to 20ms; see Documentation/timers/timers-howto.txt
+ msleep(1);

WARNING: __initdata should be placed after kempld_dmi_table[]
+static struct dmi_system_id __initdata kempld_dmi_table[] = {

WARNING: line over 80 characters
+ for (id = kempld_dmi_table; id->matches[0].slot != DMI_NONE; id++)

total: 0 errors, 4 warnings, 771 lines checked

This is part of an effort to clean-up the MFD subsystem.

Signed-off-by: Lee Jones <lee.jones@linaro.org>

Lee Jones 9ef4e935 9336fe91

+6 -4
+6 -4
drivers/mfd/kempld-core.c
··· 24 24 25 25 #define MAX_ID_LEN 4 26 26 static char force_device_id[MAX_ID_LEN + 1] = ""; 27 - module_param_string(force_device_id, force_device_id, sizeof(force_device_id), 0); 27 + module_param_string(force_device_id, force_device_id, 28 + sizeof(force_device_id), 0); 28 29 MODULE_PARM_DESC(force_device_id, "Override detected product"); 29 30 30 31 /* ··· 37 36 { 38 37 /* The mutex bit will read 1 until access has been granted */ 39 38 while (ioread8(pld->io_index) & KEMPLD_MUTEX_KEY) 40 - msleep(1); 39 + usleep_range(1000, 3000); 41 40 } 42 41 43 42 static void kempld_release_hardware_mutex(struct kempld_device_data *pld) ··· 500 499 .remove = kempld_remove, 501 500 }; 502 501 503 - static struct dmi_system_id __initdata kempld_dmi_table[] = { 502 + static struct dmi_system_id kempld_dmi_table[] __initdata = { 504 503 { 505 504 .ident = "BHL6", 506 505 .matches = { ··· 737 736 int ret; 738 737 739 738 if (force_device_id[0]) { 740 - for (id = kempld_dmi_table; id->matches[0].slot != DMI_NONE; id++) 739 + for (id = kempld_dmi_table; 740 + id->matches[0].slot != DMI_NONE; id++) 741 741 if (strstr(id->ident, force_device_id)) 742 742 if (id->callback && id->callback(id)) 743 743 break;