[PATCH v3 5/7] dell-led: remove code related to mic mute LED
With dell_micmute_led_set() moved to drivers/platform/x86/dell-laptop.c, all remnants of the mic mute LED handling code can be removed from drivers/leds/dell-led.c, restoring it back to the state it was in before commit db6d8cc00773 ("dell-led: add mic mute led interface"). Signed-off-by: Michał KępieńTested-by: Alex Hung Reviewed-by: Pali Rohár --- drivers/leds/Kconfig| 1 - drivers/leds/dell-led.c | 25 +++-- 2 files changed, 7 insertions(+), 19 deletions(-) diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index 275f467956ee..8d1b4c9b3bda 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -467,7 +467,6 @@ config LEDS_DELL_NETBOOKS tristate "External LED on Dell Business Netbooks" depends on LEDS_CLASS depends on X86 && ACPI_WMI - depends on DELL_SMBIOS help This adds support for the Latitude 2100 and similar notebooks that have an external LED. diff --git a/drivers/leds/dell-led.c b/drivers/leds/dell-led.c index c9cc36a7c890..e5c57389efd6 100644 --- a/drivers/leds/dell-led.c +++ b/drivers/leds/dell-led.c @@ -15,15 +15,12 @@ #include #include #include -#include -#include "../platform/x86/dell-smbios.h" MODULE_AUTHOR("Louis Davis/Jim Dailey"); MODULE_DESCRIPTION("Dell LED Control Driver"); MODULE_LICENSE("GPL"); #define DELL_LED_BIOS_GUID "F6E4FE6E-909D-47cb-8BAB-C9F6F2F8D396" -#define DELL_APP_GUID "A80593CE-A997-11DA-B012-B622A1EF5492" MODULE_ALIAS("wmi:" DELL_LED_BIOS_GUID); /* Error Result Codes: */ @@ -184,29 +181,21 @@ static int __init dell_led_init(void) { int error = 0; - if (!wmi_has_guid(DELL_LED_BIOS_GUID) && !wmi_has_guid(DELL_APP_GUID)) + if (!wmi_has_guid(DELL_LED_BIOS_GUID)) return -ENODEV; - if (wmi_has_guid(DELL_LED_BIOS_GUID)) { - error = led_off(); - if (error != 0) - return -ENODEV; - - error = led_classdev_register(NULL, _led); - } + error = led_off(); + if (error != 0) + return -ENODEV; - return error; + return led_classdev_register(NULL, _led); } static void __exit dell_led_exit(void) { - int error = 0; + led_classdev_unregister(_led); - if (wmi_has_guid(DELL_LED_BIOS_GUID)) { - error = led_off(); - if (error == 0) - led_classdev_unregister(_led); - } + led_off(); } module_init(dell_led_init); -- 2.11.1
[PATCH v3 1/7] dell-led: remove GUID check from dell_micmute_led_set()
As dell_micmute_led_set() no longer uses the dell_wmi_perform_query() method, which was removed in commit 0c41a08e131d ("dell-led: use dell_smbios_send_request() for performing SMBIOS calls"), the DELL_APP_GUID check is redundant and thus can be safely removed. Signed-off-by: Michał KępieńTested-by: Alex Hung Reviewed-by: Pali Rohár --- drivers/leds/dell-led.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/leds/dell-led.c b/drivers/leds/dell-led.c index b3d6e9c15cf9..e8e8f67224c1 100644 --- a/drivers/leds/dell-led.c +++ b/drivers/leds/dell-led.c @@ -51,9 +51,6 @@ static int dell_micmute_led_set(int state) struct calling_interface_buffer *buffer; struct calling_interface_token *token; - if (!wmi_has_guid(DELL_APP_GUID)) - return -ENODEV; - if (state == 0) token = dell_smbios_find_token(GLOBAL_MIC_MUTE_DISABLE); else if (state == 1) -- 2.11.1
[PATCH v3 7/7] platform/x86: dell-wmi-led: fix coding style issues
Fix coding style issues in dell-wmi-led to make sure the module gets a clean start in the x86 platform driver subsystem. Signed-off-by: Michał Kępień--- drivers/platform/x86/dell-wmi-led.c | 66 +++-- 1 file changed, 26 insertions(+), 40 deletions(-) diff --git a/drivers/platform/x86/dell-wmi-led.c b/drivers/platform/x86/dell-wmi-led.c index d0232c7f1909..a0c7e99530ef 100644 --- a/drivers/platform/x86/dell-wmi-led.c +++ b/drivers/platform/x86/dell-wmi-led.c @@ -46,37 +46,29 @@ struct bios_args { unsigned char off_time; }; -static int dell_led_perform_fn(u8 length, - u8 result_code, - u8 device_id, - u8 command, - u8 on_time, - u8 off_time) +static int dell_led_perform_fn(u8 length, u8 result_code, u8 device_id, + u8 command, u8 on_time, u8 off_time) { - struct bios_args *bios_return; - u8 return_code; - union acpi_object *obj; struct acpi_buffer output = { ACPI_ALLOCATE_BUFFER, NULL }; + struct bios_args *bios_return; struct acpi_buffer input; + union acpi_object *obj; acpi_status status; + u8 return_code; - struct bios_args args; - args.length = length; - args.result_code = result_code; - args.device_id = device_id; - args.command = command; - args.on_time = on_time; - args.off_time = off_time; + struct bios_args args = { + .length = length, + .result_code = result_code, + .device_id = device_id, + .command = command, + .on_time = on_time, + .off_time = off_time + }; input.length = sizeof(struct bios_args); input.pointer = - status = wmi_evaluate_method(DELL_LED_BIOS_GUID, - 1, - 1, - , - ); - + status = wmi_evaluate_method(DELL_LED_BIOS_GUID, 1, 1, , ); if (ACPI_FAILURE(status)) return status; @@ -84,7 +76,7 @@ static int dell_led_perform_fn(u8 length, if (!obj) return -EINVAL; - else if (obj->type != ACPI_TYPE_BUFFER) { + if (obj->type != ACPI_TYPE_BUFFER) { kfree(obj); return -EINVAL; } @@ -117,8 +109,7 @@ static int led_off(void) 0); /* not used */ } -static int led_blink(unsigned char on_eighths, - unsigned char off_eighths) +static int led_blink(unsigned char on_eighths, unsigned char off_eighths) { return dell_led_perform_fn(5, /* Length of command */ INTERFACE_ERROR,/* Init to INTERFACE_ERROR */ @@ -129,7 +120,7 @@ static int led_blink(unsigned char on_eighths, } static void dell_led_set(struct led_classdev *led_cdev, - enum led_brightness value) +enum led_brightness value) { if (value == LED_OFF) led_off(); @@ -138,27 +129,22 @@ static void dell_led_set(struct led_classdev *led_cdev, } static int dell_led_blink(struct led_classdev *led_cdev, - unsigned long *delay_on, - unsigned long *delay_off) + unsigned long *delay_on, unsigned long *delay_off) { unsigned long on_eighths; unsigned long off_eighths; - /* The Dell LED delay is based on 125ms intervals. - Need to round up to next interval. */ + /* +* The Dell LED delay is based on 125ms intervals. +* Need to round up to next interval. +*/ - on_eighths = (*delay_on + 124) / 125; - if (0 == on_eighths) - on_eighths = 1; - if (on_eighths > 255) - on_eighths = 255; + on_eighths = DIV_ROUND_UP(*delay_on, 125); + on_eighths = clamp_t(unsigned long, on_eighths, 1, 255); *delay_on = on_eighths * 125; - off_eighths = (*delay_off + 124) / 125; - if (0 == off_eighths) - off_eighths = 1; - if (off_eighths > 255) - off_eighths = 255; + off_eighths = DIV_ROUND_UP(*delay_off, 125); + off_eighths = clamp_t(unsigned long, off_eighths, 1, 255); *delay_off = off_eighths * 125; led_blink(on_eighths, off_eighths); -- 2.11.1
[PATCH v3 5/7] dell-led: remove code related to mic mute LED
With dell_micmute_led_set() moved to drivers/platform/x86/dell-laptop.c, all remnants of the mic mute LED handling code can be removed from drivers/leds/dell-led.c, restoring it back to the state it was in before commit db6d8cc00773 ("dell-led: add mic mute led interface"). Signed-off-by: Michał Kępień Tested-by: Alex Hung Reviewed-by: Pali Rohár --- drivers/leds/Kconfig| 1 - drivers/leds/dell-led.c | 25 +++-- 2 files changed, 7 insertions(+), 19 deletions(-) diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index 275f467956ee..8d1b4c9b3bda 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -467,7 +467,6 @@ config LEDS_DELL_NETBOOKS tristate "External LED on Dell Business Netbooks" depends on LEDS_CLASS depends on X86 && ACPI_WMI - depends on DELL_SMBIOS help This adds support for the Latitude 2100 and similar notebooks that have an external LED. diff --git a/drivers/leds/dell-led.c b/drivers/leds/dell-led.c index c9cc36a7c890..e5c57389efd6 100644 --- a/drivers/leds/dell-led.c +++ b/drivers/leds/dell-led.c @@ -15,15 +15,12 @@ #include #include #include -#include -#include "../platform/x86/dell-smbios.h" MODULE_AUTHOR("Louis Davis/Jim Dailey"); MODULE_DESCRIPTION("Dell LED Control Driver"); MODULE_LICENSE("GPL"); #define DELL_LED_BIOS_GUID "F6E4FE6E-909D-47cb-8BAB-C9F6F2F8D396" -#define DELL_APP_GUID "A80593CE-A997-11DA-B012-B622A1EF5492" MODULE_ALIAS("wmi:" DELL_LED_BIOS_GUID); /* Error Result Codes: */ @@ -184,29 +181,21 @@ static int __init dell_led_init(void) { int error = 0; - if (!wmi_has_guid(DELL_LED_BIOS_GUID) && !wmi_has_guid(DELL_APP_GUID)) + if (!wmi_has_guid(DELL_LED_BIOS_GUID)) return -ENODEV; - if (wmi_has_guid(DELL_LED_BIOS_GUID)) { - error = led_off(); - if (error != 0) - return -ENODEV; - - error = led_classdev_register(NULL, _led); - } + error = led_off(); + if (error != 0) + return -ENODEV; - return error; + return led_classdev_register(NULL, _led); } static void __exit dell_led_exit(void) { - int error = 0; + led_classdev_unregister(_led); - if (wmi_has_guid(DELL_LED_BIOS_GUID)) { - error = led_off(); - if (error == 0) - led_classdev_unregister(_led); - } + led_off(); } module_init(dell_led_init); -- 2.11.1
[PATCH v3 1/7] dell-led: remove GUID check from dell_micmute_led_set()
As dell_micmute_led_set() no longer uses the dell_wmi_perform_query() method, which was removed in commit 0c41a08e131d ("dell-led: use dell_smbios_send_request() for performing SMBIOS calls"), the DELL_APP_GUID check is redundant and thus can be safely removed. Signed-off-by: Michał Kępień Tested-by: Alex Hung Reviewed-by: Pali Rohár --- drivers/leds/dell-led.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/leds/dell-led.c b/drivers/leds/dell-led.c index b3d6e9c15cf9..e8e8f67224c1 100644 --- a/drivers/leds/dell-led.c +++ b/drivers/leds/dell-led.c @@ -51,9 +51,6 @@ static int dell_micmute_led_set(int state) struct calling_interface_buffer *buffer; struct calling_interface_token *token; - if (!wmi_has_guid(DELL_APP_GUID)) - return -ENODEV; - if (state == 0) token = dell_smbios_find_token(GLOBAL_MIC_MUTE_DISABLE); else if (state == 1) -- 2.11.1
[PATCH v3 7/7] platform/x86: dell-wmi-led: fix coding style issues
Fix coding style issues in dell-wmi-led to make sure the module gets a clean start in the x86 platform driver subsystem. Signed-off-by: Michał Kępień --- drivers/platform/x86/dell-wmi-led.c | 66 +++-- 1 file changed, 26 insertions(+), 40 deletions(-) diff --git a/drivers/platform/x86/dell-wmi-led.c b/drivers/platform/x86/dell-wmi-led.c index d0232c7f1909..a0c7e99530ef 100644 --- a/drivers/platform/x86/dell-wmi-led.c +++ b/drivers/platform/x86/dell-wmi-led.c @@ -46,37 +46,29 @@ struct bios_args { unsigned char off_time; }; -static int dell_led_perform_fn(u8 length, - u8 result_code, - u8 device_id, - u8 command, - u8 on_time, - u8 off_time) +static int dell_led_perform_fn(u8 length, u8 result_code, u8 device_id, + u8 command, u8 on_time, u8 off_time) { - struct bios_args *bios_return; - u8 return_code; - union acpi_object *obj; struct acpi_buffer output = { ACPI_ALLOCATE_BUFFER, NULL }; + struct bios_args *bios_return; struct acpi_buffer input; + union acpi_object *obj; acpi_status status; + u8 return_code; - struct bios_args args; - args.length = length; - args.result_code = result_code; - args.device_id = device_id; - args.command = command; - args.on_time = on_time; - args.off_time = off_time; + struct bios_args args = { + .length = length, + .result_code = result_code, + .device_id = device_id, + .command = command, + .on_time = on_time, + .off_time = off_time + }; input.length = sizeof(struct bios_args); input.pointer = - status = wmi_evaluate_method(DELL_LED_BIOS_GUID, - 1, - 1, - , - ); - + status = wmi_evaluate_method(DELL_LED_BIOS_GUID, 1, 1, , ); if (ACPI_FAILURE(status)) return status; @@ -84,7 +76,7 @@ static int dell_led_perform_fn(u8 length, if (!obj) return -EINVAL; - else if (obj->type != ACPI_TYPE_BUFFER) { + if (obj->type != ACPI_TYPE_BUFFER) { kfree(obj); return -EINVAL; } @@ -117,8 +109,7 @@ static int led_off(void) 0); /* not used */ } -static int led_blink(unsigned char on_eighths, - unsigned char off_eighths) +static int led_blink(unsigned char on_eighths, unsigned char off_eighths) { return dell_led_perform_fn(5, /* Length of command */ INTERFACE_ERROR,/* Init to INTERFACE_ERROR */ @@ -129,7 +120,7 @@ static int led_blink(unsigned char on_eighths, } static void dell_led_set(struct led_classdev *led_cdev, - enum led_brightness value) +enum led_brightness value) { if (value == LED_OFF) led_off(); @@ -138,27 +129,22 @@ static void dell_led_set(struct led_classdev *led_cdev, } static int dell_led_blink(struct led_classdev *led_cdev, - unsigned long *delay_on, - unsigned long *delay_off) + unsigned long *delay_on, unsigned long *delay_off) { unsigned long on_eighths; unsigned long off_eighths; - /* The Dell LED delay is based on 125ms intervals. - Need to round up to next interval. */ + /* +* The Dell LED delay is based on 125ms intervals. +* Need to round up to next interval. +*/ - on_eighths = (*delay_on + 124) / 125; - if (0 == on_eighths) - on_eighths = 1; - if (on_eighths > 255) - on_eighths = 255; + on_eighths = DIV_ROUND_UP(*delay_on, 125); + on_eighths = clamp_t(unsigned long, on_eighths, 1, 255); *delay_on = on_eighths * 125; - off_eighths = (*delay_off + 124) / 125; - if (0 == off_eighths) - off_eighths = 1; - if (off_eighths > 255) - off_eighths = 255; + off_eighths = DIV_ROUND_UP(*delay_off, 125); + off_eighths = clamp_t(unsigned long, off_eighths, 1, 255); *delay_off = off_eighths * 125; led_blink(on_eighths, off_eighths); -- 2.11.1
[PATCH v3 6/7] dell-led: move driver to drivers/platform/x86/dell-wmi-led.c
The dell-led driver handles a specific WMI GUID present on some Dell laptops and as such it belongs in the x86 platform driver subsystem. Source code is moved along with the relevant Kconfig and Makefile entries, with some minor modifications: - Kconfig option is renamed from CONFIG_LEDS_DELL_NETBOOKS to CONFIG_DELL_WMI_LED, - the X86 Kconfig dependency is removed as the whole drivers/platform/x86 menu depends on it, so there is no need to duplicate it, - the name of the module's source file is removed from the header comment to avoid the need to update it in the future. Signed-off-by: Michał KępieńTested-by: Alex Hung Reviewed-by: Pali Rohár Acked-by: Pavel Machek Acked-by: Andy Shevchenko --- drivers/leds/Kconfig | 8 drivers/leds/Makefile| 1 - drivers/platform/x86/Kconfig | 8 drivers/platform/x86/Makefile| 1 + drivers/{leds/dell-led.c => platform/x86/dell-wmi-led.c} | 2 -- 5 files changed, 9 insertions(+), 11 deletions(-) rename drivers/{leds/dell-led.c => platform/x86/dell-wmi-led.c} (99%) diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index 8d1b4c9b3bda..6a88474b2970 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -463,14 +463,6 @@ config LEDS_ADP5520 To compile this driver as a module, choose M here: the module will be called leds-adp5520. -config LEDS_DELL_NETBOOKS - tristate "External LED on Dell Business Netbooks" - depends on LEDS_CLASS - depends on X86 && ACPI_WMI - help - This adds support for the Latitude 2100 and similar - notebooks that have an external LED. - config LEDS_MC13783 tristate "LED Support for MC13XXX PMIC" depends on LEDS_CLASS diff --git a/drivers/leds/Makefile b/drivers/leds/Makefile index 6b8273736478..558d24675454 100644 --- a/drivers/leds/Makefile +++ b/drivers/leds/Makefile @@ -52,7 +52,6 @@ obj-$(CONFIG_LEDS_REGULATOR) += leds-regulator.o obj-$(CONFIG_LEDS_INTEL_SS4200)+= leds-ss4200.o obj-$(CONFIG_LEDS_LT3593) += leds-lt3593.o obj-$(CONFIG_LEDS_ADP5520) += leds-adp5520.o -obj-$(CONFIG_LEDS_DELL_NETBOOKS) += dell-led.o obj-$(CONFIG_LEDS_MC13783) += leds-mc13783.o obj-$(CONFIG_LEDS_NS2) += leds-ns2.o obj-$(CONFIG_LEDS_NETXBIG) += leds-netxbig.o diff --git a/drivers/platform/x86/Kconfig b/drivers/platform/x86/Kconfig index 5fe8be089b8b..6683e2e9cfb7 100644 --- a/drivers/platform/x86/Kconfig +++ b/drivers/platform/x86/Kconfig @@ -143,6 +143,14 @@ config DELL_WMI_AIO To compile this driver as a module, choose M here: the module will be called dell-wmi-aio. +config DELL_WMI_LED + tristate "External LED on Dell Business Netbooks" + depends on LEDS_CLASS + depends on ACPI_WMI + help + This adds support for the Latitude 2100 and similar + notebooks that have an external LED. + config DELL_SMO8800 tristate "Dell Latitude freefall driver (ACPI SMO88XX)" depends on ACPI diff --git a/drivers/platform/x86/Makefile b/drivers/platform/x86/Makefile index d4111f0f8a78..e46114930877 100644 --- a/drivers/platform/x86/Makefile +++ b/drivers/platform/x86/Makefile @@ -15,6 +15,7 @@ obj-$(CONFIG_DELL_SMBIOS) += dell-smbios.o obj-$(CONFIG_DELL_LAPTOP) += dell-laptop.o obj-$(CONFIG_DELL_WMI) += dell-wmi.o obj-$(CONFIG_DELL_WMI_AIO) += dell-wmi-aio.o +obj-$(CONFIG_DELL_WMI_LED) += dell-wmi-led.o obj-$(CONFIG_DELL_SMO8800) += dell-smo8800.o obj-$(CONFIG_DELL_RBTN)+= dell-rbtn.o obj-$(CONFIG_ACER_WMI) += acer-wmi.o diff --git a/drivers/leds/dell-led.c b/drivers/platform/x86/dell-wmi-led.c similarity index 99% rename from drivers/leds/dell-led.c rename to drivers/platform/x86/dell-wmi-led.c index e5c57389efd6..d0232c7f1909 100644 --- a/drivers/leds/dell-led.c +++ b/drivers/platform/x86/dell-wmi-led.c @@ -1,6 +1,4 @@ /* - * dell_led.c - Dell LED Driver - * * Copyright (C) 2010 Dell Inc. * Louis Davis * Jim Dailey -- 2.11.1
[PATCH v3 6/7] dell-led: move driver to drivers/platform/x86/dell-wmi-led.c
The dell-led driver handles a specific WMI GUID present on some Dell laptops and as such it belongs in the x86 platform driver subsystem. Source code is moved along with the relevant Kconfig and Makefile entries, with some minor modifications: - Kconfig option is renamed from CONFIG_LEDS_DELL_NETBOOKS to CONFIG_DELL_WMI_LED, - the X86 Kconfig dependency is removed as the whole drivers/platform/x86 menu depends on it, so there is no need to duplicate it, - the name of the module's source file is removed from the header comment to avoid the need to update it in the future. Signed-off-by: Michał Kępień Tested-by: Alex Hung Reviewed-by: Pali Rohár Acked-by: Pavel Machek Acked-by: Andy Shevchenko --- drivers/leds/Kconfig | 8 drivers/leds/Makefile| 1 - drivers/platform/x86/Kconfig | 8 drivers/platform/x86/Makefile| 1 + drivers/{leds/dell-led.c => platform/x86/dell-wmi-led.c} | 2 -- 5 files changed, 9 insertions(+), 11 deletions(-) rename drivers/{leds/dell-led.c => platform/x86/dell-wmi-led.c} (99%) diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index 8d1b4c9b3bda..6a88474b2970 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -463,14 +463,6 @@ config LEDS_ADP5520 To compile this driver as a module, choose M here: the module will be called leds-adp5520. -config LEDS_DELL_NETBOOKS - tristate "External LED on Dell Business Netbooks" - depends on LEDS_CLASS - depends on X86 && ACPI_WMI - help - This adds support for the Latitude 2100 and similar - notebooks that have an external LED. - config LEDS_MC13783 tristate "LED Support for MC13XXX PMIC" depends on LEDS_CLASS diff --git a/drivers/leds/Makefile b/drivers/leds/Makefile index 6b8273736478..558d24675454 100644 --- a/drivers/leds/Makefile +++ b/drivers/leds/Makefile @@ -52,7 +52,6 @@ obj-$(CONFIG_LEDS_REGULATOR) += leds-regulator.o obj-$(CONFIG_LEDS_INTEL_SS4200)+= leds-ss4200.o obj-$(CONFIG_LEDS_LT3593) += leds-lt3593.o obj-$(CONFIG_LEDS_ADP5520) += leds-adp5520.o -obj-$(CONFIG_LEDS_DELL_NETBOOKS) += dell-led.o obj-$(CONFIG_LEDS_MC13783) += leds-mc13783.o obj-$(CONFIG_LEDS_NS2) += leds-ns2.o obj-$(CONFIG_LEDS_NETXBIG) += leds-netxbig.o diff --git a/drivers/platform/x86/Kconfig b/drivers/platform/x86/Kconfig index 5fe8be089b8b..6683e2e9cfb7 100644 --- a/drivers/platform/x86/Kconfig +++ b/drivers/platform/x86/Kconfig @@ -143,6 +143,14 @@ config DELL_WMI_AIO To compile this driver as a module, choose M here: the module will be called dell-wmi-aio. +config DELL_WMI_LED + tristate "External LED on Dell Business Netbooks" + depends on LEDS_CLASS + depends on ACPI_WMI + help + This adds support for the Latitude 2100 and similar + notebooks that have an external LED. + config DELL_SMO8800 tristate "Dell Latitude freefall driver (ACPI SMO88XX)" depends on ACPI diff --git a/drivers/platform/x86/Makefile b/drivers/platform/x86/Makefile index d4111f0f8a78..e46114930877 100644 --- a/drivers/platform/x86/Makefile +++ b/drivers/platform/x86/Makefile @@ -15,6 +15,7 @@ obj-$(CONFIG_DELL_SMBIOS) += dell-smbios.o obj-$(CONFIG_DELL_LAPTOP) += dell-laptop.o obj-$(CONFIG_DELL_WMI) += dell-wmi.o obj-$(CONFIG_DELL_WMI_AIO) += dell-wmi-aio.o +obj-$(CONFIG_DELL_WMI_LED) += dell-wmi-led.o obj-$(CONFIG_DELL_SMO8800) += dell-smo8800.o obj-$(CONFIG_DELL_RBTN)+= dell-rbtn.o obj-$(CONFIG_ACER_WMI) += acer-wmi.o diff --git a/drivers/leds/dell-led.c b/drivers/platform/x86/dell-wmi-led.c similarity index 99% rename from drivers/leds/dell-led.c rename to drivers/platform/x86/dell-wmi-led.c index e5c57389efd6..d0232c7f1909 100644 --- a/drivers/leds/dell-led.c +++ b/drivers/platform/x86/dell-wmi-led.c @@ -1,6 +1,4 @@ /* - * dell_led.c - Dell LED Driver - * * Copyright (C) 2010 Dell Inc. * Louis Davis * Jim Dailey -- 2.11.1
Re: [PATCH 13/35] drivers/char: Convert remaining use of pr_warning to pr_warn
On (Thu) 16 Feb 2017 [23:11:26], Joe Perches wrote: > To enable eventual removal of pr_warning > > This makes pr_warn use consistent for drivers/char > > Prior to this patch, there were 1 use of pr_warning and > 40 uses of pr_warn in drivers/char > > Signed-off-by: Joe PerchesReviewed-by: Amit Shah Thanks, Amit -- http://log.amitshah.net/
Re: [PATCH 13/35] drivers/char: Convert remaining use of pr_warning to pr_warn
On (Thu) 16 Feb 2017 [23:11:26], Joe Perches wrote: > To enable eventual removal of pr_warning > > This makes pr_warn use consistent for drivers/char > > Prior to this patch, there were 1 use of pr_warning and > 40 uses of pr_warn in drivers/char > > Signed-off-by: Joe Perches Reviewed-by: Amit Shah Thanks, Amit -- http://log.amitshah.net/
[PATCH] timers, sched_clock: Update timeout for clock wrap
The scheduler clock framework may not use the correct timeout for the clock wrap. This happens when a new clock driver calls sched_clock_register() after the kernel called sched_clock_postinit(). In this case the clock wrap timeout is too long thus sched_clock_poll() is called too late and the clock already wrapped. On my ARM system the scheduler was no longer scheduling any other task than the idle task because the sched_clock() wrapped. Signed-off-by: David Engraf--- kernel/time/sched_clock.c | 5 + 1 file changed, 5 insertions(+) diff --git a/kernel/time/sched_clock.c b/kernel/time/sched_clock.c index a26036d..382b159 100644 --- a/kernel/time/sched_clock.c +++ b/kernel/time/sched_clock.c @@ -205,6 +205,11 @@ sched_clock_register(u64 (*read)(void), int bits, unsigned long rate) update_clock_read_data(); + if (sched_clock_timer.function != NULL) { + /* update timeout for clock wrap */ + hrtimer_start(_clock_timer, cd.wrap_kt, HRTIMER_MODE_REL); + } + r = rate; if (r >= 400) { r /= 100; -- 2.9.3
[PATCH] timers, sched_clock: Update timeout for clock wrap
The scheduler clock framework may not use the correct timeout for the clock wrap. This happens when a new clock driver calls sched_clock_register() after the kernel called sched_clock_postinit(). In this case the clock wrap timeout is too long thus sched_clock_poll() is called too late and the clock already wrapped. On my ARM system the scheduler was no longer scheduling any other task than the idle task because the sched_clock() wrapped. Signed-off-by: David Engraf --- kernel/time/sched_clock.c | 5 + 1 file changed, 5 insertions(+) diff --git a/kernel/time/sched_clock.c b/kernel/time/sched_clock.c index a26036d..382b159 100644 --- a/kernel/time/sched_clock.c +++ b/kernel/time/sched_clock.c @@ -205,6 +205,11 @@ sched_clock_register(u64 (*read)(void), int bits, unsigned long rate) update_clock_read_data(); + if (sched_clock_timer.function != NULL) { + /* update timeout for clock wrap */ + hrtimer_start(_clock_timer, cd.wrap_kt, HRTIMER_MODE_REL); + } + r = rate; if (r >= 400) { r /= 100; -- 2.9.3
Re: [PATCH V2 0/6] PM / Domains: Implement domain performance states
On 17 February 2017 at 06:38, Viresh Kumarwrote: > On 09-02-17, 09:11, Viresh Kumar wrote: >> The first 5 patches update the PM domain and QoS frameworks to support >> that and the last one presents the front end interface to it. > > @Kevin and Ulf, > > Is there something wrong with this series? Its been 7 weeks since this > series is getting posted and I haven't received a single review from > you guys. We will get into the merge window very soon and then it > wouldn't be good for me to ask for reviews as everyone would be busy. > > This stuff and the rest of the development around it is getting > delayed unnecessarily. > > Please see if you guys can take some time out to get this reviewed. Apologize for the delay! I will have a look asap. Kind regards Uffe
Re: [PATCH V2 0/6] PM / Domains: Implement domain performance states
On 17 February 2017 at 06:38, Viresh Kumar wrote: > On 09-02-17, 09:11, Viresh Kumar wrote: >> The first 5 patches update the PM domain and QoS frameworks to support >> that and the last one presents the front end interface to it. > > @Kevin and Ulf, > > Is there something wrong with this series? Its been 7 weeks since this > series is getting posted and I haven't received a single review from > you guys. We will get into the merge window very soon and then it > wouldn't be good for me to ask for reviews as everyone would be busy. > > This stuff and the rest of the development around it is getting > delayed unnecessarily. > > Please see if you guys can take some time out to get this reviewed. Apologize for the delay! I will have a look asap. Kind regards Uffe
Re: [PATCH 09/35] x86: Convert remaining uses of pr_warning to pr_warn
On Thu, 16 Feb 2017 23:11:22 -0800 Joe Percheswrote: > To enable eventual removal of pr_warning > > This makes pr_warn use consistent for arch/x86 > > Prior to this patch, there were 46 uses of pr_warning and > 122 uses of pr_warn in arch/x86 > > Miscellanea: > > o Coalesce a few formats and realign arguments > o Convert a couple of multiple line printks to single line > > Signed-off-by: Joe Perches > --- > arch/x86/kernel/amd_gart_64.c | 12 +++-- > arch/x86/kernel/apic/apic.c| 46 > -- > arch/x86/kernel/apic/apic_noop.c | 2 +- > arch/x86/kernel/setup_percpu.c | 4 +-- > arch/x86/kernel/tboot.c| 15 ++- > arch/x86/kernel/tsc_sync.c | 8 +++--- > arch/x86/mm/kmmio.c| 8 +++--- > arch/x86/mm/mmio-mod.c | 5 ++-- > arch/x86/mm/numa.c | 12 - > arch/x86/mm/numa_emulation.c | 6 ++--- > arch/x86/mm/testmmiotrace.c| 5 ++-- > arch/x86/oprofile/op_x86_model.h | 6 ++--- > arch/x86/platform/olpc/olpc-xo15-sci.c | 2 +- > arch/x86/platform/sfi/sfi.c| 3 +-- > arch/x86/xen/debugfs.c | 2 +- > arch/x86/xen/setup.c | 2 +- > 16 files changed, 63 insertions(+), 75 deletions(-) > Hi, seems fine to me, even though I haven't been involved in the kernel side for years. For the hunks quoted below *only*: Reviewed-by: Pekka Paalanen > diff --git a/arch/x86/mm/kmmio.c b/arch/x86/mm/kmmio.c > index afc47f5c9531..ad70518cdcc7 100644 > --- a/arch/x86/mm/kmmio.c > +++ b/arch/x86/mm/kmmio.c > @@ -187,8 +187,8 @@ static int arm_kmmio_fault_page(struct kmmio_fault_page > *f) > int ret; > WARN_ONCE(f->armed, KERN_ERR pr_fmt("kmmio page already armed.\n")); > if (f->armed) { > - pr_warning("double-arm: addr 0x%08lx, ref %d, old %d\n", > -f->addr, f->count, !!f->old_presence); > + pr_warn("double-arm: addr 0x%08lx, ref %d, old %d\n", > + f->addr, f->count, !!f->old_presence); > } > ret = clear_page_presence(f, true); > WARN_ONCE(ret < 0, KERN_ERR pr_fmt("arming at 0x%08lx failed.\n"), > @@ -335,8 +335,8 @@ static int post_kmmio_handler(unsigned long condition, > struct pt_regs *regs) >* something external causing them (f.e. using a debugger while >* mmio tracing enabled), or erroneous behaviour >*/ > - pr_warning("unexpected debug trap on CPU %d.\n", > -smp_processor_id()); > + pr_warn("unexpected debug trap on CPU %d\n", > + smp_processor_id()); > goto out; > } > > diff --git a/arch/x86/mm/mmio-mod.c b/arch/x86/mm/mmio-mod.c > index bef36622e408..706ae44d1af7 100644 > --- a/arch/x86/mm/mmio-mod.c > +++ b/arch/x86/mm/mmio-mod.c > @@ -407,7 +407,7 @@ static void enter_uniprocessor(void) > } > out: > if (num_online_cpus() > 1) > - pr_warning("multiple CPUs still online, may miss events.\n"); > + pr_warn("multiple CPUs still online, may miss events\n"); > } > > static void leave_uniprocessor(void) > @@ -431,8 +431,7 @@ static void leave_uniprocessor(void) > static void enter_uniprocessor(void) > { > if (num_online_cpus() > 1) > - pr_warning("multiple CPUs are online, may miss events. " > -"Suggest booting with maxcpus=1 kernel argument.\n"); > + pr_warn("multiple CPUs are online, may miss events. Suggest > booting with maxcpus=1 kernel argument.\n"); > } > > static void leave_uniprocessor(void) > diff --git a/arch/x86/mm/testmmiotrace.c b/arch/x86/mm/testmmiotrace.c > index 38868adf07ea..4a55e453296d 100644 > --- a/arch/x86/mm/testmmiotrace.c > +++ b/arch/x86/mm/testmmiotrace.c > @@ -121,9 +121,8 @@ static int __init init(void) > return -ENXIO; > } > > - pr_warning("WARNING: mapping %lu kB @ 0x%08lx in PCI address space, " > -"and writing 16 kB of rubbish in there.\n", > -size >> 10, mmio_address); > + pr_warn("WARNING: mapping %lu kB @ 0x%08lx in PCI address space, and > writing 16 kB of rubbish in there\n", > + size >> 10, mmio_address); > do_test(size); > do_test_bulk_ioremapping(); > pr_info("All done.\n"); Thanks, pq pgpU81x3bT5nB.pgp Description: OpenPGP digital signature
Re: [PATCH 09/35] x86: Convert remaining uses of pr_warning to pr_warn
On Thu, 16 Feb 2017 23:11:22 -0800 Joe Perches wrote: > To enable eventual removal of pr_warning > > This makes pr_warn use consistent for arch/x86 > > Prior to this patch, there were 46 uses of pr_warning and > 122 uses of pr_warn in arch/x86 > > Miscellanea: > > o Coalesce a few formats and realign arguments > o Convert a couple of multiple line printks to single line > > Signed-off-by: Joe Perches > --- > arch/x86/kernel/amd_gart_64.c | 12 +++-- > arch/x86/kernel/apic/apic.c| 46 > -- > arch/x86/kernel/apic/apic_noop.c | 2 +- > arch/x86/kernel/setup_percpu.c | 4 +-- > arch/x86/kernel/tboot.c| 15 ++- > arch/x86/kernel/tsc_sync.c | 8 +++--- > arch/x86/mm/kmmio.c| 8 +++--- > arch/x86/mm/mmio-mod.c | 5 ++-- > arch/x86/mm/numa.c | 12 - > arch/x86/mm/numa_emulation.c | 6 ++--- > arch/x86/mm/testmmiotrace.c| 5 ++-- > arch/x86/oprofile/op_x86_model.h | 6 ++--- > arch/x86/platform/olpc/olpc-xo15-sci.c | 2 +- > arch/x86/platform/sfi/sfi.c| 3 +-- > arch/x86/xen/debugfs.c | 2 +- > arch/x86/xen/setup.c | 2 +- > 16 files changed, 63 insertions(+), 75 deletions(-) > Hi, seems fine to me, even though I haven't been involved in the kernel side for years. For the hunks quoted below *only*: Reviewed-by: Pekka Paalanen > diff --git a/arch/x86/mm/kmmio.c b/arch/x86/mm/kmmio.c > index afc47f5c9531..ad70518cdcc7 100644 > --- a/arch/x86/mm/kmmio.c > +++ b/arch/x86/mm/kmmio.c > @@ -187,8 +187,8 @@ static int arm_kmmio_fault_page(struct kmmio_fault_page > *f) > int ret; > WARN_ONCE(f->armed, KERN_ERR pr_fmt("kmmio page already armed.\n")); > if (f->armed) { > - pr_warning("double-arm: addr 0x%08lx, ref %d, old %d\n", > -f->addr, f->count, !!f->old_presence); > + pr_warn("double-arm: addr 0x%08lx, ref %d, old %d\n", > + f->addr, f->count, !!f->old_presence); > } > ret = clear_page_presence(f, true); > WARN_ONCE(ret < 0, KERN_ERR pr_fmt("arming at 0x%08lx failed.\n"), > @@ -335,8 +335,8 @@ static int post_kmmio_handler(unsigned long condition, > struct pt_regs *regs) >* something external causing them (f.e. using a debugger while >* mmio tracing enabled), or erroneous behaviour >*/ > - pr_warning("unexpected debug trap on CPU %d.\n", > -smp_processor_id()); > + pr_warn("unexpected debug trap on CPU %d\n", > + smp_processor_id()); > goto out; > } > > diff --git a/arch/x86/mm/mmio-mod.c b/arch/x86/mm/mmio-mod.c > index bef36622e408..706ae44d1af7 100644 > --- a/arch/x86/mm/mmio-mod.c > +++ b/arch/x86/mm/mmio-mod.c > @@ -407,7 +407,7 @@ static void enter_uniprocessor(void) > } > out: > if (num_online_cpus() > 1) > - pr_warning("multiple CPUs still online, may miss events.\n"); > + pr_warn("multiple CPUs still online, may miss events\n"); > } > > static void leave_uniprocessor(void) > @@ -431,8 +431,7 @@ static void leave_uniprocessor(void) > static void enter_uniprocessor(void) > { > if (num_online_cpus() > 1) > - pr_warning("multiple CPUs are online, may miss events. " > -"Suggest booting with maxcpus=1 kernel argument.\n"); > + pr_warn("multiple CPUs are online, may miss events. Suggest > booting with maxcpus=1 kernel argument.\n"); > } > > static void leave_uniprocessor(void) > diff --git a/arch/x86/mm/testmmiotrace.c b/arch/x86/mm/testmmiotrace.c > index 38868adf07ea..4a55e453296d 100644 > --- a/arch/x86/mm/testmmiotrace.c > +++ b/arch/x86/mm/testmmiotrace.c > @@ -121,9 +121,8 @@ static int __init init(void) > return -ENXIO; > } > > - pr_warning("WARNING: mapping %lu kB @ 0x%08lx in PCI address space, " > -"and writing 16 kB of rubbish in there.\n", > -size >> 10, mmio_address); > + pr_warn("WARNING: mapping %lu kB @ 0x%08lx in PCI address space, and > writing 16 kB of rubbish in there\n", > + size >> 10, mmio_address); > do_test(size); > do_test_bulk_ioremapping(); > pr_info("All done.\n"); Thanks, pq pgpU81x3bT5nB.pgp Description: OpenPGP digital signature
Re: [PATCH 27/35] drivers/platform: Convert remaining uses of pr_warning to pr_warn
On Fri, Feb 17, 2017 at 9:11 AM, Joe Percheswrote: > To enable eventual removal of pr_warning > > This makes pr_warn use consistent for drivers/platform > > Prior to this patch, there were 7 uses of pr_warning and > 108 uses of pr_warn in drivers/platform Acked-by: Andy Shevchenko > > Signed-off-by: Joe Perches > --- > drivers/platform/x86/asus-laptop.c| 2 +- > drivers/platform/x86/eeepc-laptop.c | 2 +- > drivers/platform/x86/intel_oaktrail.c | 10 +- > 3 files changed, 7 insertions(+), 7 deletions(-) > > diff --git a/drivers/platform/x86/asus-laptop.c > b/drivers/platform/x86/asus-laptop.c > index 28551f5a2e07..7f248f84f49a 100644 > --- a/drivers/platform/x86/asus-laptop.c > +++ b/drivers/platform/x86/asus-laptop.c > @@ -1163,7 +1163,7 @@ static void asus_als_switch(struct asus_laptop *asus, > int value) > ret = write_acpi_int(asus->handle, METHOD_ALS_CONTROL, value); > } > if (ret) > - pr_warning("Error setting light sensor switch\n"); > + pr_warn("Error setting light sensor switch\n"); > > asus->light_switch = value; > } > diff --git a/drivers/platform/x86/eeepc-laptop.c > b/drivers/platform/x86/eeepc-laptop.c > index 8cdf315f9730..09f93eb49230 100644 > --- a/drivers/platform/x86/eeepc-laptop.c > +++ b/drivers/platform/x86/eeepc-laptop.c > @@ -585,7 +585,7 @@ static void eeepc_rfkill_hotplug(struct eeepc_laptop > *eeepc, acpi_handle handle) > > port = acpi_get_pci_dev(handle); > if (!port) { > - pr_warning("Unable to find port\n"); > + pr_warn("Unable to find port\n"); > goto out_unlock; > } > > diff --git a/drivers/platform/x86/intel_oaktrail.c > b/drivers/platform/x86/intel_oaktrail.c > index 6aa33c4a809f..133b2f04643d 100644 > --- a/drivers/platform/x86/intel_oaktrail.c > +++ b/drivers/platform/x86/intel_oaktrail.c > @@ -257,7 +257,7 @@ static int oaktrail_backlight_init(void) > > if (IS_ERR(bd)) { > oaktrail_bl_device = NULL; > - pr_warning("Unable to register backlight device\n"); > + pr_warn("Unable to register backlight device\n"); > return PTR_ERR(bd); > } > > @@ -327,20 +327,20 @@ static int __init oaktrail_init(void) > > ret = platform_driver_register(_driver); > if (ret) { > - pr_warning("Unable to register platform driver\n"); > + pr_warn("Unable to register platform driver\n"); > goto err_driver_reg; > } > > oaktrail_device = platform_device_alloc(DRIVER_NAME, -1); > if (!oaktrail_device) { > - pr_warning("Unable to allocate platform device\n"); > + pr_warn("Unable to allocate platform device\n"); > ret = -ENOMEM; > goto err_device_alloc; > } > > ret = platform_device_add(oaktrail_device); > if (ret) { > - pr_warning("Unable to add platform device\n"); > + pr_warn("Unable to add platform device\n"); > goto err_device_add; > } > > @@ -352,7 +352,7 @@ static int __init oaktrail_init(void) > > ret = oaktrail_rfkill_init(); > if (ret) { > - pr_warning("Setup rfkill failed\n"); > + pr_warn("Setup rfkill failed\n"); > goto err_rfkill; > } > > -- > 2.10.0.rc2.1.g053435c > -- With Best Regards, Andy Shevchenko
Re: [PATCH 27/35] drivers/platform: Convert remaining uses of pr_warning to pr_warn
On Fri, Feb 17, 2017 at 9:11 AM, Joe Perches wrote: > To enable eventual removal of pr_warning > > This makes pr_warn use consistent for drivers/platform > > Prior to this patch, there were 7 uses of pr_warning and > 108 uses of pr_warn in drivers/platform Acked-by: Andy Shevchenko > > Signed-off-by: Joe Perches > --- > drivers/platform/x86/asus-laptop.c| 2 +- > drivers/platform/x86/eeepc-laptop.c | 2 +- > drivers/platform/x86/intel_oaktrail.c | 10 +- > 3 files changed, 7 insertions(+), 7 deletions(-) > > diff --git a/drivers/platform/x86/asus-laptop.c > b/drivers/platform/x86/asus-laptop.c > index 28551f5a2e07..7f248f84f49a 100644 > --- a/drivers/platform/x86/asus-laptop.c > +++ b/drivers/platform/x86/asus-laptop.c > @@ -1163,7 +1163,7 @@ static void asus_als_switch(struct asus_laptop *asus, > int value) > ret = write_acpi_int(asus->handle, METHOD_ALS_CONTROL, value); > } > if (ret) > - pr_warning("Error setting light sensor switch\n"); > + pr_warn("Error setting light sensor switch\n"); > > asus->light_switch = value; > } > diff --git a/drivers/platform/x86/eeepc-laptop.c > b/drivers/platform/x86/eeepc-laptop.c > index 8cdf315f9730..09f93eb49230 100644 > --- a/drivers/platform/x86/eeepc-laptop.c > +++ b/drivers/platform/x86/eeepc-laptop.c > @@ -585,7 +585,7 @@ static void eeepc_rfkill_hotplug(struct eeepc_laptop > *eeepc, acpi_handle handle) > > port = acpi_get_pci_dev(handle); > if (!port) { > - pr_warning("Unable to find port\n"); > + pr_warn("Unable to find port\n"); > goto out_unlock; > } > > diff --git a/drivers/platform/x86/intel_oaktrail.c > b/drivers/platform/x86/intel_oaktrail.c > index 6aa33c4a809f..133b2f04643d 100644 > --- a/drivers/platform/x86/intel_oaktrail.c > +++ b/drivers/platform/x86/intel_oaktrail.c > @@ -257,7 +257,7 @@ static int oaktrail_backlight_init(void) > > if (IS_ERR(bd)) { > oaktrail_bl_device = NULL; > - pr_warning("Unable to register backlight device\n"); > + pr_warn("Unable to register backlight device\n"); > return PTR_ERR(bd); > } > > @@ -327,20 +327,20 @@ static int __init oaktrail_init(void) > > ret = platform_driver_register(_driver); > if (ret) { > - pr_warning("Unable to register platform driver\n"); > + pr_warn("Unable to register platform driver\n"); > goto err_driver_reg; > } > > oaktrail_device = platform_device_alloc(DRIVER_NAME, -1); > if (!oaktrail_device) { > - pr_warning("Unable to allocate platform device\n"); > + pr_warn("Unable to allocate platform device\n"); > ret = -ENOMEM; > goto err_device_alloc; > } > > ret = platform_device_add(oaktrail_device); > if (ret) { > - pr_warning("Unable to add platform device\n"); > + pr_warn("Unable to add platform device\n"); > goto err_device_add; > } > > @@ -352,7 +352,7 @@ static int __init oaktrail_init(void) > > ret = oaktrail_rfkill_init(); > if (ret) { > - pr_warning("Setup rfkill failed\n"); > + pr_warn("Setup rfkill failed\n"); > goto err_rfkill; > } > > -- > 2.10.0.rc2.1.g053435c > -- With Best Regards, Andy Shevchenko
Re: [PATCH] platform/x86: ideapad-laptop: Add sysfs interface for touchpad state
On Fri, Feb 17, 2017 at 5:33 AM, Darren Hartwrote: > On Tue, Feb 14, 2017 at 07:46:12PM +0530, Ritesh Raj Sarraf wrote: >> Lenovo Yoga (many variants: Yoga, Yoga2 Pro, Yoga2 13, Yoga3 Pro, Yoga 3 >> 14 etc) has multiple modles that are a hybrid laptop, working in laptop >> mode as well as tablet mode. > That said, we need to make these systems usable, and as there appears not to > be > an accepted standard way of doing this, I don't object to the approach. > However, > you mentioned in the bug comments (#64) on 2/12: > > "I have attached the final patch that I had proposed, but for whatever > reasons, the maintainer isn't convinced that that interface is needed." > > This is the only version of this patch I have seen. This patch is actually a v2 that includes maintainers as I had asked and additional paragraph to explain why we need such interface. > Who objected to the patch? I was trying to understand why /dev/input/eventX can not be used for a such. > I would like to hear from Rafael and Dmitry, for their opinion on an ACPI or > INPUT > interface for indicating TABLET_MODE to userspace. Even if we accept this > patch > as is, we should be thinking about how to do this in a standard way. Good point! >> + >> + if (!count) >> + return 0; >> + if (sscanf(buf, "%i", ) != 1) >> + return -EINVAL; > > Please use kstrtoint, and no need to check for count as this function won't > get > called if it is 0. I guess Ritesh followed existing style in the code. -- With Best Regards, Andy Shevchenko
Re: [PATCH] platform/x86: ideapad-laptop: Add sysfs interface for touchpad state
On Fri, Feb 17, 2017 at 5:33 AM, Darren Hart wrote: > On Tue, Feb 14, 2017 at 07:46:12PM +0530, Ritesh Raj Sarraf wrote: >> Lenovo Yoga (many variants: Yoga, Yoga2 Pro, Yoga2 13, Yoga3 Pro, Yoga 3 >> 14 etc) has multiple modles that are a hybrid laptop, working in laptop >> mode as well as tablet mode. > That said, we need to make these systems usable, and as there appears not to > be > an accepted standard way of doing this, I don't object to the approach. > However, > you mentioned in the bug comments (#64) on 2/12: > > "I have attached the final patch that I had proposed, but for whatever > reasons, the maintainer isn't convinced that that interface is needed." > > This is the only version of this patch I have seen. This patch is actually a v2 that includes maintainers as I had asked and additional paragraph to explain why we need such interface. > Who objected to the patch? I was trying to understand why /dev/input/eventX can not be used for a such. > I would like to hear from Rafael and Dmitry, for their opinion on an ACPI or > INPUT > interface for indicating TABLET_MODE to userspace. Even if we accept this > patch > as is, we should be thinking about how to do this in a standard way. Good point! >> + >> + if (!count) >> + return 0; >> + if (sscanf(buf, "%i", ) != 1) >> + return -EINVAL; > > Please use kstrtoint, and no need to check for count as this function won't > get > called if it is 0. I guess Ritesh followed existing style in the code. -- With Best Regards, Andy Shevchenko
[GIT PULL] MMC fixes for v.4.10 rc9
Hi Linus, Here's one mmc fix intended for v4.10 rc9 (or final if no new rc). Based on v4.10-rc8. Details are as usual found in the signed tag. Please pull this in! Kind regards Ulf Hansson The following changes since commit 7089db84e356562f8ba737c29e472cc42d530dbc: Linux 4.10-rc8 (2017-02-12 13:03:20 -0800) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc.git tags/mmc-v4.10-rc8 for you to fetch changes up to 3d4ef329757cfd5e0b23cce97cdeca7e2df89c99: mmc: core: fix multi-bit bus width without high-speed mode (2017-02-14 08:50:10 +0100) MMC core: - Fix multi-bit bus width without high-speed mode for MMC Anssi Hannula (1): mmc: core: fix multi-bit bus width without high-speed mode drivers/mmc/core/mmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
[PATCH 0/2] x86/xen: cpuid() cleanup
Reduce special casing of xen_cpuid() and disable DCA feature for pv domains as it isn't supported under Xen. Juergen Gross (2): x86/xen: don't indicate DCA support in pv domains x86/xen: use capabilities instead of fake cpuid values arch/x86/xen/enlighten.c | 14 ++ 1 file changed, 6 insertions(+), 8 deletions(-) -- 2.10.2
[GIT PULL] MMC fixes for v.4.10 rc9
Hi Linus, Here's one mmc fix intended for v4.10 rc9 (or final if no new rc). Based on v4.10-rc8. Details are as usual found in the signed tag. Please pull this in! Kind regards Ulf Hansson The following changes since commit 7089db84e356562f8ba737c29e472cc42d530dbc: Linux 4.10-rc8 (2017-02-12 13:03:20 -0800) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc.git tags/mmc-v4.10-rc8 for you to fetch changes up to 3d4ef329757cfd5e0b23cce97cdeca7e2df89c99: mmc: core: fix multi-bit bus width without high-speed mode (2017-02-14 08:50:10 +0100) MMC core: - Fix multi-bit bus width without high-speed mode for MMC Anssi Hannula (1): mmc: core: fix multi-bit bus width without high-speed mode drivers/mmc/core/mmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
[PATCH 0/2] x86/xen: cpuid() cleanup
Reduce special casing of xen_cpuid() and disable DCA feature for pv domains as it isn't supported under Xen. Juergen Gross (2): x86/xen: don't indicate DCA support in pv domains x86/xen: use capabilities instead of fake cpuid values arch/x86/xen/enlighten.c | 14 ++ 1 file changed, 6 insertions(+), 8 deletions(-) -- 2.10.2
[PATCH 1/2] x86/xen: don't indicate DCA support in pv domains
Xen doesn't support DCA (direct cache access) for pv domains. Clear the corresponding capability indicator. Signed-off-by: Juergen Gross--- arch/x86/xen/enlighten.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 51ef952..83399ce 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c @@ -461,6 +461,9 @@ static void __init xen_init_cpuid_mask(void) cpuid_leaf1_ecx_mask &= ~xsave_mask; /* disable XSAVE & OSXSAVE */ if (xen_check_mwait()) cpuid_leaf1_ecx_set_mask = (1 << (X86_FEATURE_MWAIT % 32)); + + /* Disable DCA feature. */ + setup_clear_cpu_cap(X86_FEATURE_DCA); } static void xen_set_debugreg(int reg, unsigned long val) -- 2.10.2
[PATCH 1/2] x86/xen: don't indicate DCA support in pv domains
Xen doesn't support DCA (direct cache access) for pv domains. Clear the corresponding capability indicator. Signed-off-by: Juergen Gross --- arch/x86/xen/enlighten.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 51ef952..83399ce 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c @@ -461,6 +461,9 @@ static void __init xen_init_cpuid_mask(void) cpuid_leaf1_ecx_mask &= ~xsave_mask; /* disable XSAVE & OSXSAVE */ if (xen_check_mwait()) cpuid_leaf1_ecx_set_mask = (1 << (X86_FEATURE_MWAIT % 32)); + + /* Disable DCA feature. */ + setup_clear_cpu_cap(X86_FEATURE_DCA); } static void xen_set_debugreg(int reg, unsigned long val) -- 2.10.2
[PATCH 2/2] x86/xen: use capabilities instead of fake cpuid values
When running as pv domain xen_cpuid() is being used instead of native_cpuid(). In xen_cpuid() the aperf/mperf feature is indicated as not being present by special casing the related cpuid leaf. Instead of delivering fake cpuid values clear the cpu capability bit for aperf/mperf instead. Signed-off-by: Juergen Gross--- arch/x86/xen/enlighten.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 83399ce..0eebb75 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c @@ -301,9 +301,6 @@ xen_running_on_version_or_later(unsigned int major, unsigned int minor) return false; } -#define CPUID_THERM_POWER_LEAF 6 -#define APERFMPERF_PRESENT 0 - static __read_mostly unsigned int cpuid_leaf1_edx_mask = ~0; static __read_mostly unsigned int cpuid_leaf1_ecx_mask = ~0; @@ -337,11 +334,6 @@ static void xen_cpuid(unsigned int *ax, unsigned int *bx, *dx = cpuid_leaf5_edx_val; return; - case CPUID_THERM_POWER_LEAF: - /* Disabling APERFMPERF for kernel usage */ - maskecx = ~(1 << APERFMPERF_PRESENT); - break; - case 0xb: /* Suppress extended topology stuff */ maskebx = 0; @@ -462,6 +454,9 @@ static void __init xen_init_cpuid_mask(void) if (xen_check_mwait()) cpuid_leaf1_ecx_set_mask = (1 << (X86_FEATURE_MWAIT % 32)); + /* Disable APERFMPERF feature. */ + setup_clear_cpu_cap(X86_FEATURE_APERFMPERF); + /* Disable DCA feature. */ setup_clear_cpu_cap(X86_FEATURE_DCA); } -- 2.10.2
Re: [PATCH 4/5] sprd_serial: switch comptible string to sc-uart
On 四, 2月 16, 2017 at 02:31:38下午 +0100, Arnd Bergmann wrote: > On Tuesday, February 14, 2017 5:19:11 PM CET Chunyan Zhang wrote: > > static const struct of_device_id serial_ids[] = { > > - {.compatible = "sprd,sc9836-uart",}, > > + {.compatible = "sprd,sc-uart",}, > > {} > > We really need this to be specific, in case Spreadtrum ever > makes a slightly different UART that is not 100% compatible > with this one. Also, you can't remove the string you already have, > only add to it. > > Normally when you have a new chip that is compatible with one > we already have a driver for, we mark the device as compatible > with the old one and avoid having to change the driver, e.g. > > compatible = "sprd,sc9995-uart", "sprd,sc9836-uart"; > > This way, the driver could later be changed to handle anything > that is compatible with sc9995 differently from sc9836, but > by default it would match the original string. > Right, I've addressed this when I received the same comments from Rob Herring :) Thanks for your comments, Chunyan > Arnd
[PATCH 2/2] x86/xen: use capabilities instead of fake cpuid values
When running as pv domain xen_cpuid() is being used instead of native_cpuid(). In xen_cpuid() the aperf/mperf feature is indicated as not being present by special casing the related cpuid leaf. Instead of delivering fake cpuid values clear the cpu capability bit for aperf/mperf instead. Signed-off-by: Juergen Gross --- arch/x86/xen/enlighten.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 83399ce..0eebb75 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c @@ -301,9 +301,6 @@ xen_running_on_version_or_later(unsigned int major, unsigned int minor) return false; } -#define CPUID_THERM_POWER_LEAF 6 -#define APERFMPERF_PRESENT 0 - static __read_mostly unsigned int cpuid_leaf1_edx_mask = ~0; static __read_mostly unsigned int cpuid_leaf1_ecx_mask = ~0; @@ -337,11 +334,6 @@ static void xen_cpuid(unsigned int *ax, unsigned int *bx, *dx = cpuid_leaf5_edx_val; return; - case CPUID_THERM_POWER_LEAF: - /* Disabling APERFMPERF for kernel usage */ - maskecx = ~(1 << APERFMPERF_PRESENT); - break; - case 0xb: /* Suppress extended topology stuff */ maskebx = 0; @@ -462,6 +454,9 @@ static void __init xen_init_cpuid_mask(void) if (xen_check_mwait()) cpuid_leaf1_ecx_set_mask = (1 << (X86_FEATURE_MWAIT % 32)); + /* Disable APERFMPERF feature. */ + setup_clear_cpu_cap(X86_FEATURE_APERFMPERF); + /* Disable DCA feature. */ setup_clear_cpu_cap(X86_FEATURE_DCA); } -- 2.10.2
Re: [PATCH 4/5] sprd_serial: switch comptible string to sc-uart
On 四, 2月 16, 2017 at 02:31:38下午 +0100, Arnd Bergmann wrote: > On Tuesday, February 14, 2017 5:19:11 PM CET Chunyan Zhang wrote: > > static const struct of_device_id serial_ids[] = { > > - {.compatible = "sprd,sc9836-uart",}, > > + {.compatible = "sprd,sc-uart",}, > > {} > > We really need this to be specific, in case Spreadtrum ever > makes a slightly different UART that is not 100% compatible > with this one. Also, you can't remove the string you already have, > only add to it. > > Normally when you have a new chip that is compatible with one > we already have a driver for, we mark the device as compatible > with the old one and avoid having to change the driver, e.g. > > compatible = "sprd,sc9995-uart", "sprd,sc9836-uart"; > > This way, the driver could later be changed to handle anything > that is compatible with sc9995 differently from sc9836, but > by default it would match the original string. > Right, I've addressed this when I received the same comments from Rob Herring :) Thanks for your comments, Chunyan > Arnd
4.10-rc8: mce: [Hardware Error]: CPU 0: Machine Check: 0 Bank 6: ae0000000040110a
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Hello, WIth the 4.10-rc8 kernel, I keep getting the following (non-fatal) error on every boot. With previous kernels, the mcelog daemon used to register errors occasionally. But the errors messages weren't recurrent on every boot. Filing it here, in case it is not a hardware bug. On 4.10-rc8: Feb 16 22:23:58 learner kernel: CPU: Physical Processor ID: 0 Feb 16 22:23:58 learner kernel: CPU: Processor Core ID: 0 Feb 16 22:23:58 learner kernel: ENERGY_PERF_BIAS: Set to 'normal', was 'performance' Feb 16 22:23:58 learner kernel: ENERGY_PERF_BIAS: View and update with x86_energy_perf_policy(8) Feb 16 22:23:58 learner kernel: mce: CPU supports 7 MCE banks Feb 16 22:23:58 learner kernel: CPU0: Thermal monitoring enabled (TM1) Feb 16 22:23:58 learner kernel: process: using mwait in idle threads Feb 16 22:23:58 learner kernel: Last level iTLB entries: 4KB 1024, 2MB 1024, 4MB 1024 Feb 16 22:23:58 learner kernel: Last level dTLB entries: 4KB 1024, 2MB 1024, 4MB 1024, 1GB 4 Feb 16 22:23:58 learner kernel: Freeing SMP alternatives memory: 24K Feb 16 22:23:58 learner kernel: ftrace: allocating 25290 entries in 99 pages Feb 16 22:23:58 learner kernel: smpboot: Max logical packages: 4 Feb 16 22:23:58 learner kernel: ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1 Feb 16 22:23:58 learner kernel: TSC deadline timer enabled Feb 16 22:23:58 learner kernel: smpboot: CPU0: Intel(R) Core(TM) i7-4510U CPU @ 2.00GHz (family: 0x6, model: 0x45, stepping: 0x1) Feb 16 22:23:58 learner kernel: mce: [Hardware Error]: CPU 0: Machine Check: 0 Bank 6: ae40110a Feb 16 22:23:58 learner kernel: mce: [Hardware Error]: TSC 0 ADDR fef87300 MISC 78a086 Feb 16 22:23:58 learner kernel: mce: [Hardware Error]: PROCESSOR 0:40651 TIME 1487264016 SOCKET 0 APIC 0 microcode 1f Feb 16 22:23:58 learner kernel: Performance Events: PEBS fmt2+, Haswell events, 16-deep LBR, full-width counters, Intel PMU driver. Feb 16 22:23:58 learner kernel: ... version:3 Feb 16 22:23:58 learner kernel: ... bit width: 48 Feb 16 22:23:58 learner kernel: ... generic registers: 4 Feb 16 22:23:58 learner kernel: ... value mask: Feb 16 22:23:58 learner kernel: ... max period: 7fff Feb 16 22:23:58 learner kernel: ... fixed-purpose events: 3 Feb 16 22:23:58 learner kernel: ... event mask: 0007000f Feb 16 22:23:58 learner kernel: NMI watchdog: enabled on all CPUs, permanently consumes one hw-PMU counter. Feb 16 22:23:58 learner kernel: smp: Bringing up secondary CPUs ... Feb 16 22:23:58 learner kernel: x86: Booting SMP configuration: Feb 16 22:23:58 learner kernel: node #0, CPUs: #1 #2 #3 Feb 16 22:23:58 learner kernel: smp: Brought up 1 node, 4 CPUs Feb 16 22:23:58 learner kernel: smpboot: Total of 4 processors activated (20765.31 BogoMIPS) On kernels prior to 4.10, occasional log: [0.041496] mce: CPU supports 7 MCE banks [ 299.540930] mce: [Hardware Error]: Machine check events logged and mcelog: failed to prefill DIMM database from DMI data Hardware event. This is not a software error. MCE 0 CPU 0 BANK 5 MISC 38a086 ADDR fef81880 TIME 1432455005 Sun May 24 13:40:05 2015 MCG status: MCi status: Error overflow Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ee40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Hardware event. This is not a software error. MCE 1 CPU 0 BANK 6 MISC 78a086 ADDR fef81780 TIME 1432455005 Sun May 24 13:40:05 2015 MCG status: MCi status: Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ae40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Hardware event. This is not a software error. MCE 2 CPU 0 BANK 5 MISC 38a086 ADDR fef81880 TIME 1432455114 Sun May 24 13:41:54 2015 MCG status: MCi status: Error overflow Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ee40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Hardware event. This is not a software error. MCE 3 CPU 0 BANK 6 MISC 78a086 ADDR fef81780 TIME 1432455114 Sun May 24 13:41:54 2015 MCG status: MCi status: Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ae40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Full kernel log
4.10-rc8: mce: [Hardware Error]: CPU 0: Machine Check: 0 Bank 6: ae0000000040110a
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Hello, WIth the 4.10-rc8 kernel, I keep getting the following (non-fatal) error on every boot. With previous kernels, the mcelog daemon used to register errors occasionally. But the errors messages weren't recurrent on every boot. Filing it here, in case it is not a hardware bug. On 4.10-rc8: Feb 16 22:23:58 learner kernel: CPU: Physical Processor ID: 0 Feb 16 22:23:58 learner kernel: CPU: Processor Core ID: 0 Feb 16 22:23:58 learner kernel: ENERGY_PERF_BIAS: Set to 'normal', was 'performance' Feb 16 22:23:58 learner kernel: ENERGY_PERF_BIAS: View and update with x86_energy_perf_policy(8) Feb 16 22:23:58 learner kernel: mce: CPU supports 7 MCE banks Feb 16 22:23:58 learner kernel: CPU0: Thermal monitoring enabled (TM1) Feb 16 22:23:58 learner kernel: process: using mwait in idle threads Feb 16 22:23:58 learner kernel: Last level iTLB entries: 4KB 1024, 2MB 1024, 4MB 1024 Feb 16 22:23:58 learner kernel: Last level dTLB entries: 4KB 1024, 2MB 1024, 4MB 1024, 1GB 4 Feb 16 22:23:58 learner kernel: Freeing SMP alternatives memory: 24K Feb 16 22:23:58 learner kernel: ftrace: allocating 25290 entries in 99 pages Feb 16 22:23:58 learner kernel: smpboot: Max logical packages: 4 Feb 16 22:23:58 learner kernel: ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1 Feb 16 22:23:58 learner kernel: TSC deadline timer enabled Feb 16 22:23:58 learner kernel: smpboot: CPU0: Intel(R) Core(TM) i7-4510U CPU @ 2.00GHz (family: 0x6, model: 0x45, stepping: 0x1) Feb 16 22:23:58 learner kernel: mce: [Hardware Error]: CPU 0: Machine Check: 0 Bank 6: ae40110a Feb 16 22:23:58 learner kernel: mce: [Hardware Error]: TSC 0 ADDR fef87300 MISC 78a086 Feb 16 22:23:58 learner kernel: mce: [Hardware Error]: PROCESSOR 0:40651 TIME 1487264016 SOCKET 0 APIC 0 microcode 1f Feb 16 22:23:58 learner kernel: Performance Events: PEBS fmt2+, Haswell events, 16-deep LBR, full-width counters, Intel PMU driver. Feb 16 22:23:58 learner kernel: ... version:3 Feb 16 22:23:58 learner kernel: ... bit width: 48 Feb 16 22:23:58 learner kernel: ... generic registers: 4 Feb 16 22:23:58 learner kernel: ... value mask: Feb 16 22:23:58 learner kernel: ... max period: 7fff Feb 16 22:23:58 learner kernel: ... fixed-purpose events: 3 Feb 16 22:23:58 learner kernel: ... event mask: 0007000f Feb 16 22:23:58 learner kernel: NMI watchdog: enabled on all CPUs, permanently consumes one hw-PMU counter. Feb 16 22:23:58 learner kernel: smp: Bringing up secondary CPUs ... Feb 16 22:23:58 learner kernel: x86: Booting SMP configuration: Feb 16 22:23:58 learner kernel: node #0, CPUs: #1 #2 #3 Feb 16 22:23:58 learner kernel: smp: Brought up 1 node, 4 CPUs Feb 16 22:23:58 learner kernel: smpboot: Total of 4 processors activated (20765.31 BogoMIPS) On kernels prior to 4.10, occasional log: [0.041496] mce: CPU supports 7 MCE banks [ 299.540930] mce: [Hardware Error]: Machine check events logged and mcelog: failed to prefill DIMM database from DMI data Hardware event. This is not a software error. MCE 0 CPU 0 BANK 5 MISC 38a086 ADDR fef81880 TIME 1432455005 Sun May 24 13:40:05 2015 MCG status: MCi status: Error overflow Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ee40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Hardware event. This is not a software error. MCE 1 CPU 0 BANK 6 MISC 78a086 ADDR fef81780 TIME 1432455005 Sun May 24 13:40:05 2015 MCG status: MCi status: Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ae40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Hardware event. This is not a software error. MCE 2 CPU 0 BANK 5 MISC 38a086 ADDR fef81880 TIME 1432455114 Sun May 24 13:41:54 2015 MCG status: MCi status: Error overflow Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ee40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Hardware event. This is not a software error. MCE 3 CPU 0 BANK 6 MISC 78a086 ADDR fef81780 TIME 1432455114 Sun May 24 13:41:54 2015 MCG status: MCi status: Uncorrected error MCi_MISC register valid MCi_ADDR register valid Processor context corrupt MCA: corrected filtering (some unreported errors in same region) Generic CACHE Level-2 Generic Error STATUS ae40110a MCGSTATUS 0 MCGCAP c07 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 69 Full kernel log
Re: swap_cluster_info lockdep splat
Hi, Hugh, Hugh Dickinswrites: > On Thu, 16 Feb 2017, Tim Chen wrote: >> >> > I do not understand your zest for putting wrappers around every little >> > thing, making it all harder to follow than it need be. Here's the patch >> > I've been running with (but you have a leak somewhere, and I don't have >> > time to search out and fix it: please try sustained swapping and swapoff). >> > >> >> Hugh, trying to duplicate your test case. So you were doing swapping, >> then swap off, swap on the swap device and restart swapping? > > Repeated pair of make -j20 kernel builds in 700M RAM, 1.5G swap on SSD, > 8 cpus; one of the builds in tmpfs, other in ext4 on loop on tmpfs file; > sizes tuned for plenty of swapping but no OOMing (it's an ancient 2.6.24 > kernel I build, modern one needing a lot more space with a lot less in use). > > How much of that is relevant I don't know: hopefully none of it, it's > hard to get the tunings right from scratch. To answer your specific > question: yes, I'm not doing concurrent swapoffs in this test showing > the leak, just waiting for each of the pair of builds to complete, > then tearing down the trees, doing swapoff followed by swapon, and > starting a new pair of builds. > > Sometimes it's the swapoff that fails with ENOMEM, more often it's a > fork during build that fails with ENOMEM: after 6 or 7 hours of load > (but timings show it getting slower leading up to that). /proc/meminfo > did not give me an immediate clue, Slab didn't look surprising but > I may not have studied close enough. > > I quilt-bisected it as far as the mm-swap series, good before, bad > after, but didn't manage to narrow it down further because of hitting > a presumably different issue inside the series, where swapoff ENOMEMed > much sooner (after 25 mins one time, during first iteration the next). I found a memory leak in __read_swap_cache_async() introduced by mm-swap series, and confirmed it via testing. Could you verify whether it fixed your cases? Thanks a lot for reporting. Best Regards, Huang, Ying -> >From 4b96423796ab7435104eb2cb4dcf5d525b9e0800 Mon Sep 17 00:00:00 2001 From: Huang Ying Date: Fri, 17 Feb 2017 10:31:37 +0800 Subject: [PATCH] mm, swap: Fix memory leak in __read_swap_cache_async() The memory may be leaked in __read_swap_cache_async(). For the cases as below, CPU 0 CPU 1 - - find_get_page() == NULL __swp_swapcount() != 0 new_page = alloc_page_vma() radix_tree_maybe_preload() swap in swap slot swapcache_prepare() == -EEXIST cond_resched() reclaim the swap slot find_get_page() == NULL __swp_swapcount() == 0 return NULL <- new_page leaked here !!! The memory leak has been confirmed via checking the value of new_page when returning inside the loop in __read_swap_cache_async(). This is fixed via replacing return with break inside of loop in __read_swap_cache_async(), so that there is opportunity for the new_page to be checked and freed. Reported-by: Hugh Dickins Cc: Tim Chen Signed-off-by: "Huang, Ying" --- mm/swap_state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/swap_state.c b/mm/swap_state.c index 2126e9ba23b2..473b71e052a8 100644 --- a/mm/swap_state.c +++ b/mm/swap_state.c @@ -333,7 +333,7 @@ struct page *__read_swap_cache_async(swp_entry_t entry, gfp_t gfp_mask, * else swap_off will be aborted if we return NULL. */ if (!__swp_swapcount(entry) && swap_slot_cache_enabled) - return NULL; + break; /* * Get a new page to read into from swap. -- 2.11.0
Re: swap_cluster_info lockdep splat
Hi, Hugh, Hugh Dickins writes: > On Thu, 16 Feb 2017, Tim Chen wrote: >> >> > I do not understand your zest for putting wrappers around every little >> > thing, making it all harder to follow than it need be. Here's the patch >> > I've been running with (but you have a leak somewhere, and I don't have >> > time to search out and fix it: please try sustained swapping and swapoff). >> > >> >> Hugh, trying to duplicate your test case. So you were doing swapping, >> then swap off, swap on the swap device and restart swapping? > > Repeated pair of make -j20 kernel builds in 700M RAM, 1.5G swap on SSD, > 8 cpus; one of the builds in tmpfs, other in ext4 on loop on tmpfs file; > sizes tuned for plenty of swapping but no OOMing (it's an ancient 2.6.24 > kernel I build, modern one needing a lot more space with a lot less in use). > > How much of that is relevant I don't know: hopefully none of it, it's > hard to get the tunings right from scratch. To answer your specific > question: yes, I'm not doing concurrent swapoffs in this test showing > the leak, just waiting for each of the pair of builds to complete, > then tearing down the trees, doing swapoff followed by swapon, and > starting a new pair of builds. > > Sometimes it's the swapoff that fails with ENOMEM, more often it's a > fork during build that fails with ENOMEM: after 6 or 7 hours of load > (but timings show it getting slower leading up to that). /proc/meminfo > did not give me an immediate clue, Slab didn't look surprising but > I may not have studied close enough. > > I quilt-bisected it as far as the mm-swap series, good before, bad > after, but didn't manage to narrow it down further because of hitting > a presumably different issue inside the series, where swapoff ENOMEMed > much sooner (after 25 mins one time, during first iteration the next). I found a memory leak in __read_swap_cache_async() introduced by mm-swap series, and confirmed it via testing. Could you verify whether it fixed your cases? Thanks a lot for reporting. Best Regards, Huang, Ying -> >From 4b96423796ab7435104eb2cb4dcf5d525b9e0800 Mon Sep 17 00:00:00 2001 From: Huang Ying Date: Fri, 17 Feb 2017 10:31:37 +0800 Subject: [PATCH] mm, swap: Fix memory leak in __read_swap_cache_async() The memory may be leaked in __read_swap_cache_async(). For the cases as below, CPU 0 CPU 1 - - find_get_page() == NULL __swp_swapcount() != 0 new_page = alloc_page_vma() radix_tree_maybe_preload() swap in swap slot swapcache_prepare() == -EEXIST cond_resched() reclaim the swap slot find_get_page() == NULL __swp_swapcount() == 0 return NULL <- new_page leaked here !!! The memory leak has been confirmed via checking the value of new_page when returning inside the loop in __read_swap_cache_async(). This is fixed via replacing return with break inside of loop in __read_swap_cache_async(), so that there is opportunity for the new_page to be checked and freed. Reported-by: Hugh Dickins Cc: Tim Chen Signed-off-by: "Huang, Ying" --- mm/swap_state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/swap_state.c b/mm/swap_state.c index 2126e9ba23b2..473b71e052a8 100644 --- a/mm/swap_state.c +++ b/mm/swap_state.c @@ -333,7 +333,7 @@ struct page *__read_swap_cache_async(swp_entry_t entry, gfp_t gfp_mask, * else swap_off will be aborted if we return NULL. */ if (!__swp_swapcount(entry) && swap_slot_cache_enabled) - return NULL; + break; /* * Get a new page to read into from swap. -- 2.11.0
Re: [PATCH 1/5] arm64: dts: Add basic DT to support Spreadtrum's SP9860G
Hi Sudeep, On 二, 2月 14, 2017 at 04:44:53下午 +, Sudeep Holla wrote: > On Tue, Feb 14, 2017 at 9:19 AM, Chunyan Zhang >wrote: > > From: Orson Zhai > > > > SC9860G is a 8 cores of A53 SoC with 4G LTE support SoC from Spreadtrum. > > > > According to regular hierarchy of sprd dts, whale2.dtsi contains SoC > > peripherals IP nodes, sc9860.dtsi contains stuff related to ARM core stuff > > and sp9860g dts is for the board level. > > > > Signed-off-by: Orson Zhai > > Signed-off-by: Chunyan Zhang > > --- > > arch/arm64/boot/dts/sprd/Makefile | 3 +- > > arch/arm64/boot/dts/sprd/sc9860.dtsi | 534 > > ++ > > arch/arm64/boot/dts/sprd/sp9860g-1h10.dts | 58 > > arch/arm64/boot/dts/sprd/whale2.dtsi | 66 > > 4 files changed, 660 insertions(+), 1 deletion(-) > > create mode 100644 arch/arm64/boot/dts/sprd/sc9860.dtsi > > create mode 100644 arch/arm64/boot/dts/sprd/sp9860g-1h10.dts > > create mode 100644 arch/arm64/boot/dts/sprd/whale2.dtsi > > > > diff --git a/arch/arm64/boot/dts/sprd/Makefile > > b/arch/arm64/boot/dts/sprd/Makefile > > index b658c5e..f0535e6 100644 > > --- a/arch/arm64/boot/dts/sprd/Makefile > > +++ b/arch/arm64/boot/dts/sprd/Makefile > > @@ -1,4 +1,5 @@ > > -dtb-$(CONFIG_ARCH_SPRD) += sc9836-openphone.dtb > > +dtb-$(CONFIG_ARCH_SPRD) += sc9836-openphone.dtb \ > > + sp9860g-1h10.dtb > > > > always := $(dtb-y) > > subdir-y := $(dts-dirs) > > diff --git a/arch/arm64/boot/dts/sprd/sc9860.dtsi > > b/arch/arm64/boot/dts/sprd/sc9860.dtsi > > new file mode 100644 > > index 000..604a8c9 > > --- /dev/null > > +++ b/arch/arm64/boot/dts/sprd/sc9860.dtsi > > @@ -0,0 +1,534 @@ > > [...] > > > + idle-states{ > > + entry-method = "arm,psci"; > > + > > + CORE_PD: core_pd { > > + compatible = "arm,idle-state"; > > + entry-latency-us = <1000>; > > + exit-latency-us = <700>; > > + min-residency-us = <2500>; > > + local-timer-stop; > > + arm,psci-suspend-param = <0x00010002>; > > + }; > > + > > + CLUSTER_PD: cluster_pd { > > + compatible = "arm,idle-state"; > > + entry-latency-us = <1000>; > > + exit-latency-us = <1000>; > > + min-residency-us = <3000>; > > + local-timer-stop; > > + arm,psci-suspend-param = <0x01010003>; > > + }; > > + > > + DEEP_SLEEP: deep_sleep { > > + compatible = "arm,idle-state"; > > + wakeup-latency-us = <0x>; > > A value > 4294 seconds(i.e >1 hour) seems suspicious. > Are you working around the firmware issue with high latency value so > that it's never entered ? Why not remove advertising the state from DT. > Haved checked with related colleagues, this node 'deep_sleep' was not for working around any firmware issue, but was a trick utilization of idle subsystem, and that was definitely not elegant, the author indeed intendly didn't want CPU entered this state, I will remove this node therefore. > Can you get me the dump of: > grep "" /sys/devices/system/cpu/cpu*/cpuidle/state*/{time,usage} > FYI: https://www.irccloud.com/pastebin/XyEMLzfq/ Thanks, Chunyan > IIUC, you might have seen boot issue without this values and workaround > the issue with such high values ? If so please drop this state. > > > + entry-latency-us = <1500>; > > + exit-latency-us = <1500>; > > + min-residency-us = <0x>; > > + local-timer-stop; > > + arm,psci-suspend-param = <0x01010005>; > > + }; > > + }; > > > > -- > Regards, > Sudeep
Re: [PATCH 1/5] arm64: dts: Add basic DT to support Spreadtrum's SP9860G
Hi Sudeep, On 二, 2月 14, 2017 at 04:44:53下午 +, Sudeep Holla wrote: > On Tue, Feb 14, 2017 at 9:19 AM, Chunyan Zhang > wrote: > > From: Orson Zhai > > > > SC9860G is a 8 cores of A53 SoC with 4G LTE support SoC from Spreadtrum. > > > > According to regular hierarchy of sprd dts, whale2.dtsi contains SoC > > peripherals IP nodes, sc9860.dtsi contains stuff related to ARM core stuff > > and sp9860g dts is for the board level. > > > > Signed-off-by: Orson Zhai > > Signed-off-by: Chunyan Zhang > > --- > > arch/arm64/boot/dts/sprd/Makefile | 3 +- > > arch/arm64/boot/dts/sprd/sc9860.dtsi | 534 > > ++ > > arch/arm64/boot/dts/sprd/sp9860g-1h10.dts | 58 > > arch/arm64/boot/dts/sprd/whale2.dtsi | 66 > > 4 files changed, 660 insertions(+), 1 deletion(-) > > create mode 100644 arch/arm64/boot/dts/sprd/sc9860.dtsi > > create mode 100644 arch/arm64/boot/dts/sprd/sp9860g-1h10.dts > > create mode 100644 arch/arm64/boot/dts/sprd/whale2.dtsi > > > > diff --git a/arch/arm64/boot/dts/sprd/Makefile > > b/arch/arm64/boot/dts/sprd/Makefile > > index b658c5e..f0535e6 100644 > > --- a/arch/arm64/boot/dts/sprd/Makefile > > +++ b/arch/arm64/boot/dts/sprd/Makefile > > @@ -1,4 +1,5 @@ > > -dtb-$(CONFIG_ARCH_SPRD) += sc9836-openphone.dtb > > +dtb-$(CONFIG_ARCH_SPRD) += sc9836-openphone.dtb \ > > + sp9860g-1h10.dtb > > > > always := $(dtb-y) > > subdir-y := $(dts-dirs) > > diff --git a/arch/arm64/boot/dts/sprd/sc9860.dtsi > > b/arch/arm64/boot/dts/sprd/sc9860.dtsi > > new file mode 100644 > > index 000..604a8c9 > > --- /dev/null > > +++ b/arch/arm64/boot/dts/sprd/sc9860.dtsi > > @@ -0,0 +1,534 @@ > > [...] > > > + idle-states{ > > + entry-method = "arm,psci"; > > + > > + CORE_PD: core_pd { > > + compatible = "arm,idle-state"; > > + entry-latency-us = <1000>; > > + exit-latency-us = <700>; > > + min-residency-us = <2500>; > > + local-timer-stop; > > + arm,psci-suspend-param = <0x00010002>; > > + }; > > + > > + CLUSTER_PD: cluster_pd { > > + compatible = "arm,idle-state"; > > + entry-latency-us = <1000>; > > + exit-latency-us = <1000>; > > + min-residency-us = <3000>; > > + local-timer-stop; > > + arm,psci-suspend-param = <0x01010003>; > > + }; > > + > > + DEEP_SLEEP: deep_sleep { > > + compatible = "arm,idle-state"; > > + wakeup-latency-us = <0x>; > > A value > 4294 seconds(i.e >1 hour) seems suspicious. > Are you working around the firmware issue with high latency value so > that it's never entered ? Why not remove advertising the state from DT. > Haved checked with related colleagues, this node 'deep_sleep' was not for working around any firmware issue, but was a trick utilization of idle subsystem, and that was definitely not elegant, the author indeed intendly didn't want CPU entered this state, I will remove this node therefore. > Can you get me the dump of: > grep "" /sys/devices/system/cpu/cpu*/cpuidle/state*/{time,usage} > FYI: https://www.irccloud.com/pastebin/XyEMLzfq/ Thanks, Chunyan > IIUC, you might have seen boot issue without this values and workaround > the issue with such high values ? If so please drop this state. > > > + entry-latency-us = <1500>; > > + exit-latency-us = <1500>; > > + min-residency-us = <0x>; > > + local-timer-stop; > > + arm,psci-suspend-param = <0x01010005>; > > + }; > > + }; > > > > -- > Regards, > Sudeep
Re: [PATCH 5/5] tpm_tis_spi: Add small delay after last transfer
Am 17. Februar 2017 06:09:42 MEZ schrieb Christophe Ricard: >Are you sure it is not better to introduce this delay directly in the >rpi spi driver ? > >Other than that i don't see any issue with it. Yes - it would be perfect to fix the issue in the upstream rpi spi master driver. However this only happens sporadically in some strange cases (i.e. 300-500khz, single byte transfer after having more bytes in the same #cs frame) (unrelated to the tpm) We are still looking into it, why /where it happens and how to reproduce it reliably and then file a bug/fix it. For now however the priority is to make the tpm_tis_spi driver work reliably also on the rpi, and this is what this workaround does. We can simply remove it once the rpi spi master is fixed. Peter > > >On 16/02/2017 08:09, Peter Huewe wrote: >> Testing the implementation with a Raspberry Pi 2 showed that under >some >> circumstances its SPI master erroneously releases the CS line before >the >> transfer is complete, i.e. before the end of the last clock. In this >case >> the TPM ignores the transfer and misses for example the GO command. >The >> driver is unable to detect this communication problem and will wait >for a >> command response that is never going to arrive, timing out >eventually. >> >> As a workaround, the small delay ensures that the CS line is held >long >> enough, even with a faulty SPI master. Other SPI masters are not >affected, >> except for a negligible performance penalty. >> >> Cc: >> Fixes: 0edbfea537d1 ("tpm/tpm_tis_spi: Add support for spi phy") >> Signed-off-by: Alexander Steffen >> Signed-off-by: Peter Huewe >> --- >> drivers/char/tpm/tpm_tis_spi.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/drivers/char/tpm/tpm_tis_spi.c >b/drivers/char/tpm/tpm_tis_spi.c >> index b50c5b072df3..685c51bf5d7e 100644 >> --- a/drivers/char/tpm/tpm_tis_spi.c >> +++ b/drivers/char/tpm/tpm_tis_spi.c >> @@ -110,6 +110,7 @@ static int tpm_tis_spi_transfer(struct >tpm_tis_data *data, u32 addr, u8 len, >> >> spi_xfer.cs_change = 0; >> spi_xfer.len = transfer_len; >> +spi_xfer.delay_usecs = 5; >> >> if (direction) { >> spi_xfer.tx_buf = NULL; -- Sent from my mobile
Re: [PATCH 5/5] tpm_tis_spi: Add small delay after last transfer
Am 17. Februar 2017 06:09:42 MEZ schrieb Christophe Ricard : >Are you sure it is not better to introduce this delay directly in the >rpi spi driver ? > >Other than that i don't see any issue with it. Yes - it would be perfect to fix the issue in the upstream rpi spi master driver. However this only happens sporadically in some strange cases (i.e. 300-500khz, single byte transfer after having more bytes in the same #cs frame) (unrelated to the tpm) We are still looking into it, why /where it happens and how to reproduce it reliably and then file a bug/fix it. For now however the priority is to make the tpm_tis_spi driver work reliably also on the rpi, and this is what this workaround does. We can simply remove it once the rpi spi master is fixed. Peter > > >On 16/02/2017 08:09, Peter Huewe wrote: >> Testing the implementation with a Raspberry Pi 2 showed that under >some >> circumstances its SPI master erroneously releases the CS line before >the >> transfer is complete, i.e. before the end of the last clock. In this >case >> the TPM ignores the transfer and misses for example the GO command. >The >> driver is unable to detect this communication problem and will wait >for a >> command response that is never going to arrive, timing out >eventually. >> >> As a workaround, the small delay ensures that the CS line is held >long >> enough, even with a faulty SPI master. Other SPI masters are not >affected, >> except for a negligible performance penalty. >> >> Cc: >> Fixes: 0edbfea537d1 ("tpm/tpm_tis_spi: Add support for spi phy") >> Signed-off-by: Alexander Steffen >> Signed-off-by: Peter Huewe >> --- >> drivers/char/tpm/tpm_tis_spi.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/drivers/char/tpm/tpm_tis_spi.c >b/drivers/char/tpm/tpm_tis_spi.c >> index b50c5b072df3..685c51bf5d7e 100644 >> --- a/drivers/char/tpm/tpm_tis_spi.c >> +++ b/drivers/char/tpm/tpm_tis_spi.c >> @@ -110,6 +110,7 @@ static int tpm_tis_spi_transfer(struct >tpm_tis_data *data, u32 addr, u8 len, >> >> spi_xfer.cs_change = 0; >> spi_xfer.len = transfer_len; >> +spi_xfer.delay_usecs = 5; >> >> if (direction) { >> spi_xfer.tx_buf = NULL; -- Sent from my mobile
[PATCH 04/35] arch/blackfin: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/blackfin Prior to this patch, there were 11 uses of pr_warning and 0 uses of pr_warn in arch/blackfin Signed-off-by: Joe Perches--- arch/blackfin/kernel/nmi.c | 2 +- arch/blackfin/kernel/ptrace.c | 2 +- arch/blackfin/mach-bf533/boards/stamp.c | 2 +- arch/blackfin/mach-bf537/boards/cm_bf537e.c | 2 +- arch/blackfin/mach-bf537/boards/cm_bf537u.c | 2 +- arch/blackfin/mach-bf537/boards/stamp.c | 2 +- arch/blackfin/mach-bf537/boards/tcm_bf537.c | 2 +- arch/blackfin/mach-bf561/boards/cm_bf561.c | 2 +- arch/blackfin/mach-bf561/boards/ezkit.c | 2 +- arch/blackfin/mm/isram-driver.c | 4 ++-- 10 files changed, 11 insertions(+), 11 deletions(-) diff --git a/arch/blackfin/kernel/nmi.c b/arch/blackfin/kernel/nmi.c index 9919d29287dc..bc837dc38998 100644 --- a/arch/blackfin/kernel/nmi.c +++ b/arch/blackfin/kernel/nmi.c @@ -126,7 +126,7 @@ static inline int nmi_wdt_set_timeout(unsigned long t) max_t = -1 / sclk; cnt = t * sclk; if (t > max_t) { - pr_warning("NMI: timeout value is too large\n"); + pr_warn("NMI: timeout value is too large\n"); return -EINVAL; } diff --git a/arch/blackfin/kernel/ptrace.c b/arch/blackfin/kernel/ptrace.c index 360d99645163..28dbbaf79896 100644 --- a/arch/blackfin/kernel/ptrace.c +++ b/arch/blackfin/kernel/ptrace.c @@ -98,7 +98,7 @@ put_reg(struct task_struct *task, unsigned long regno, unsigned long data) break; case PT_SYSCFG: /* don't let userspace screw with this */ if ((data & ~1) != 0x6) - pr_warning("ptrace: ignore syscfg write of %#lx\n", data); + pr_warn("ptrace: ignore syscfg write of %#lx\n", data); break; /* regs->syscfg = data; break; */ default: if (regno < sizeof(*regs)) { diff --git a/arch/blackfin/mach-bf533/boards/stamp.c b/arch/blackfin/mach-bf533/boards/stamp.c index 23eada79439c..365fed0c7685 100644 --- a/arch/blackfin/mach-bf533/boards/stamp.c +++ b/arch/blackfin/mach-bf533/boards/stamp.c @@ -869,7 +869,7 @@ static int __init stamp_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); spi_register_board_info(bfin_spi_board_info, ARRAY_SIZE(bfin_spi_board_info)); return 0; diff --git a/arch/blackfin/mach-bf537/boards/cm_bf537e.c b/arch/blackfin/mach-bf537/boards/cm_bf537e.c index 1e1014df5e9e..8c5250da0577 100644 --- a/arch/blackfin/mach-bf537/boards/cm_bf537e.c +++ b/arch/blackfin/mach-bf537/boards/cm_bf537e.c @@ -904,7 +904,7 @@ static int __init cm_bf537e_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf537/boards/cm_bf537u.c b/arch/blackfin/mach-bf537/boards/cm_bf537u.c index d056db9e5592..5cb4808a3304 100644 --- a/arch/blackfin/mach-bf537/boards/cm_bf537u.c +++ b/arch/blackfin/mach-bf537/boards/cm_bf537u.c @@ -761,7 +761,7 @@ static int __init cm_bf537u_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf537/boards/stamp.c b/arch/blackfin/mach-bf537/boards/stamp.c index eaec7b4832a2..f9168094427b 100644 --- a/arch/blackfin/mach-bf537/boards/stamp.c +++ b/arch/blackfin/mach-bf537/boards/stamp.c @@ -2964,7 +2964,7 @@ static int __init stamp_init(void) spi_register_board_info(bfin_spi_board_info, ARRAY_SIZE(bfin_spi_board_info)); if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf537/boards/tcm_bf537.c b/arch/blackfin/mach-bf537/boards/tcm_bf537.c index ed309c9a62b6..de4a4d705527 100644 --- a/arch/blackfin/mach-bf537/boards/tcm_bf537.c +++ b/arch/blackfin/mach-bf537/boards/tcm_bf537.c @@ -751,7 +751,7 @@ static int __init tcm_bf537_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf561/boards/cm_bf561.c b/arch/blackfin/mach-bf561/boards/cm_bf561.c index 10c57771822d..f95ca2026cc4 100644 --- a/arch/blackfin/mach-bf561/boards/cm_bf561.c
[PATCH 01/35] alpha: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/alpha Prior to this patch, there were 2 uses of pr_warning and 0 uses of pr_warn in arch/alpha Signed-off-by: Joe Perches--- arch/alpha/kernel/perf_event.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/alpha/kernel/perf_event.c b/arch/alpha/kernel/perf_event.c index 5c218aa3f3df..06c118ab640b 100644 --- a/arch/alpha/kernel/perf_event.c +++ b/arch/alpha/kernel/perf_event.c @@ -828,7 +828,7 @@ static void alpha_perf_event_irq_handler(unsigned long la_ptr, if (unlikely(la_ptr >= alpha_pmu->num_pmcs)) { /* This should never occur! */ irq_err_count++; - pr_warning("PMI: silly index %ld\n", la_ptr); + pr_warn("PMI: silly index %ld\n", la_ptr); wrperfmon(PERFMON_CMD_ENABLE, cpuc->idx_mask); return; } @@ -851,7 +851,7 @@ static void alpha_perf_event_irq_handler(unsigned long la_ptr, if (unlikely(!event)) { /* This should never occur! */ irq_err_count++; - pr_warning("PMI: No event at index %d!\n", idx); + pr_warn("PMI: No event at index %d!\n", idx); wrperfmon(PERFMON_CMD_ENABLE, cpuc->idx_mask); return; } -- 2.10.0.rc2.1.g053435c
[PATCH 00/35] treewide trivial patches converting pr_warning to pr_warn
There are ~4300 uses of pr_warn and ~250 uses of the older pr_warning in the kernel source tree. Make the use of pr_warn consistent across all kernel files. This excludes all files in tools/ as there is a separate define pr_warning for that directory tree and pr_warn is not used in tools/. Done with 'sed s/\bpr_warning\b/pr_warn/' and some emacsing. Miscellanea: o Coalesce formats and realign arguments Some files not compiled - no cross-compilers Joe Perches (35): alpha: Convert remaining uses of pr_warning to pr_warn ARM: ep93xx: Convert remaining uses of pr_warning to pr_warn arm64: Convert remaining uses of pr_warning to pr_warn arch/blackfin: Convert remaining uses of pr_warning to pr_warn ia64: Convert remaining use of pr_warning to pr_warn powerpc: Convert remaining uses of pr_warning to pr_warn sh: Convert remaining uses of pr_warning to pr_warn sparc: Convert remaining use of pr_warning to pr_warn x86: Convert remaining uses of pr_warning to pr_warn drivers/acpi: Convert remaining uses of pr_warning to pr_warn block/drbd: Convert remaining uses of pr_warning to pr_warn gdrom: Convert remaining uses of pr_warning to pr_warn drivers/char: Convert remaining use of pr_warning to pr_warn clocksource: Convert remaining use of pr_warning to pr_warn drivers/crypto: Convert remaining uses of pr_warning to pr_warn fmc: Convert remaining use of pr_warning to pr_warn drivers/gpu: Convert remaining uses of pr_warning to pr_warn drivers/ide: Convert remaining uses of pr_warning to pr_warn drivers/input: Convert remaining uses of pr_warning to pr_warn drivers/isdn: Convert remaining uses of pr_warning to pr_warn drivers/macintosh: Convert remaining uses of pr_warning to pr_warn drivers/media: Convert remaining use of pr_warning to pr_warn drivers/mfd: Convert remaining uses of pr_warning to pr_warn drivers/mtd: Convert remaining uses of pr_warning to pr_warn drivers/of: Convert remaining uses of pr_warning to pr_warn drivers/oprofile: Convert remaining uses of pr_warning to pr_warn drivers/platform: Convert remaining uses of pr_warning to pr_warn drivers/rapidio: Convert remaining use of pr_warning to pr_warn drivers/scsi: Convert remaining use of pr_warning to pr_warn drivers/sh: Convert remaining use of pr_warning to pr_warn drivers/tty: Convert remaining uses of pr_warning to pr_warn drivers/video: Convert remaining uses of pr_warning to pr_warn kernel/trace: Convert remaining uses of pr_warning to pr_warn lib: Convert remaining uses of pr_warning to pr_warn sound/soc: Convert remaining uses of pr_warning to pr_warn arch/alpha/kernel/perf_event.c | 4 +- arch/arm/mach-ep93xx/core.c| 4 +- arch/arm64/include/asm/syscall.h | 8 ++-- arch/arm64/kernel/hw_breakpoint.c | 8 ++-- arch/arm64/kernel/smp.c| 4 +- arch/blackfin/kernel/nmi.c | 2 +- arch/blackfin/kernel/ptrace.c | 2 +- arch/blackfin/mach-bf533/boards/stamp.c| 2 +- arch/blackfin/mach-bf537/boards/cm_bf537e.c| 2 +- arch/blackfin/mach-bf537/boards/cm_bf537u.c| 2 +- arch/blackfin/mach-bf537/boards/stamp.c| 2 +- arch/blackfin/mach-bf537/boards/tcm_bf537.c| 2 +- arch/blackfin/mach-bf561/boards/cm_bf561.c | 2 +- arch/blackfin/mach-bf561/boards/ezkit.c| 2 +- arch/blackfin/mm/isram-driver.c| 4 +- arch/ia64/kernel/setup.c | 6 +-- arch/powerpc/kernel/pci-common.c | 4 +- arch/powerpc/mm/init_64.c | 5 +-- arch/powerpc/mm/mem.c | 3 +- arch/powerpc/platforms/512x/mpc512x_shared.c | 4 +- arch/powerpc/platforms/85xx/socrates_fpga_pic.c| 7 ++-- arch/powerpc/platforms/86xx/mpc86xx_hpcn.c | 2 +- arch/powerpc/platforms/pasemi/dma_lib.c| 4 +- arch/powerpc/platforms/powernv/opal.c | 8 ++-- arch/powerpc/platforms/powernv/pci-ioda.c | 10 ++--- arch/powerpc/platforms/ps3/device-init.c | 14 +++ arch/powerpc/platforms/ps3/mm.c| 4 +- arch/powerpc/platforms/ps3/os-area.c | 2 +- arch/powerpc/platforms/pseries/iommu.c | 8 ++-- arch/powerpc/platforms/pseries/setup.c | 4 +- arch/powerpc/sysdev/fsl_pci.c | 9 ++--- arch/powerpc/sysdev/mpic.c | 10 ++--- arch/powerpc/sysdev/xics/icp-native.c | 10 ++--- arch/powerpc/sysdev/xics/ics-opal.c| 4 +- arch/powerpc/sysdev/xics/ics-rtas.c| 4 +- arch/powerpc/sysdev/xics/xics-common.c | 8 ++-- arch/sh/boards/mach-sdk7786/nmi.c | 2 +- arch/sh/drivers/pci/fixups-sdk7786.c | 2 +- arch/sh/kernel/io_trapped.c
[PATCH 04/35] arch/blackfin: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/blackfin Prior to this patch, there were 11 uses of pr_warning and 0 uses of pr_warn in arch/blackfin Signed-off-by: Joe Perches --- arch/blackfin/kernel/nmi.c | 2 +- arch/blackfin/kernel/ptrace.c | 2 +- arch/blackfin/mach-bf533/boards/stamp.c | 2 +- arch/blackfin/mach-bf537/boards/cm_bf537e.c | 2 +- arch/blackfin/mach-bf537/boards/cm_bf537u.c | 2 +- arch/blackfin/mach-bf537/boards/stamp.c | 2 +- arch/blackfin/mach-bf537/boards/tcm_bf537.c | 2 +- arch/blackfin/mach-bf561/boards/cm_bf561.c | 2 +- arch/blackfin/mach-bf561/boards/ezkit.c | 2 +- arch/blackfin/mm/isram-driver.c | 4 ++-- 10 files changed, 11 insertions(+), 11 deletions(-) diff --git a/arch/blackfin/kernel/nmi.c b/arch/blackfin/kernel/nmi.c index 9919d29287dc..bc837dc38998 100644 --- a/arch/blackfin/kernel/nmi.c +++ b/arch/blackfin/kernel/nmi.c @@ -126,7 +126,7 @@ static inline int nmi_wdt_set_timeout(unsigned long t) max_t = -1 / sclk; cnt = t * sclk; if (t > max_t) { - pr_warning("NMI: timeout value is too large\n"); + pr_warn("NMI: timeout value is too large\n"); return -EINVAL; } diff --git a/arch/blackfin/kernel/ptrace.c b/arch/blackfin/kernel/ptrace.c index 360d99645163..28dbbaf79896 100644 --- a/arch/blackfin/kernel/ptrace.c +++ b/arch/blackfin/kernel/ptrace.c @@ -98,7 +98,7 @@ put_reg(struct task_struct *task, unsigned long regno, unsigned long data) break; case PT_SYSCFG: /* don't let userspace screw with this */ if ((data & ~1) != 0x6) - pr_warning("ptrace: ignore syscfg write of %#lx\n", data); + pr_warn("ptrace: ignore syscfg write of %#lx\n", data); break; /* regs->syscfg = data; break; */ default: if (regno < sizeof(*regs)) { diff --git a/arch/blackfin/mach-bf533/boards/stamp.c b/arch/blackfin/mach-bf533/boards/stamp.c index 23eada79439c..365fed0c7685 100644 --- a/arch/blackfin/mach-bf533/boards/stamp.c +++ b/arch/blackfin/mach-bf533/boards/stamp.c @@ -869,7 +869,7 @@ static int __init stamp_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); spi_register_board_info(bfin_spi_board_info, ARRAY_SIZE(bfin_spi_board_info)); return 0; diff --git a/arch/blackfin/mach-bf537/boards/cm_bf537e.c b/arch/blackfin/mach-bf537/boards/cm_bf537e.c index 1e1014df5e9e..8c5250da0577 100644 --- a/arch/blackfin/mach-bf537/boards/cm_bf537e.c +++ b/arch/blackfin/mach-bf537/boards/cm_bf537e.c @@ -904,7 +904,7 @@ static int __init cm_bf537e_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf537/boards/cm_bf537u.c b/arch/blackfin/mach-bf537/boards/cm_bf537u.c index d056db9e5592..5cb4808a3304 100644 --- a/arch/blackfin/mach-bf537/boards/cm_bf537u.c +++ b/arch/blackfin/mach-bf537/boards/cm_bf537u.c @@ -761,7 +761,7 @@ static int __init cm_bf537u_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf537/boards/stamp.c b/arch/blackfin/mach-bf537/boards/stamp.c index eaec7b4832a2..f9168094427b 100644 --- a/arch/blackfin/mach-bf537/boards/stamp.c +++ b/arch/blackfin/mach-bf537/boards/stamp.c @@ -2964,7 +2964,7 @@ static int __init stamp_init(void) spi_register_board_info(bfin_spi_board_info, ARRAY_SIZE(bfin_spi_board_info)); if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf537/boards/tcm_bf537.c b/arch/blackfin/mach-bf537/boards/tcm_bf537.c index ed309c9a62b6..de4a4d705527 100644 --- a/arch/blackfin/mach-bf537/boards/tcm_bf537.c +++ b/arch/blackfin/mach-bf537/boards/tcm_bf537.c @@ -751,7 +751,7 @@ static int __init tcm_bf537_init(void) #endif if (net2272_init()) - pr_warning("unable to configure net2272; it probably won't work\n"); + pr_warn("unable to configure net2272; it probably won't work\n"); return 0; } diff --git a/arch/blackfin/mach-bf561/boards/cm_bf561.c b/arch/blackfin/mach-bf561/boards/cm_bf561.c index 10c57771822d..f95ca2026cc4 100644 --- a/arch/blackfin/mach-bf561/boards/cm_bf561.c +++
[PATCH 01/35] alpha: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/alpha Prior to this patch, there were 2 uses of pr_warning and 0 uses of pr_warn in arch/alpha Signed-off-by: Joe Perches --- arch/alpha/kernel/perf_event.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/alpha/kernel/perf_event.c b/arch/alpha/kernel/perf_event.c index 5c218aa3f3df..06c118ab640b 100644 --- a/arch/alpha/kernel/perf_event.c +++ b/arch/alpha/kernel/perf_event.c @@ -828,7 +828,7 @@ static void alpha_perf_event_irq_handler(unsigned long la_ptr, if (unlikely(la_ptr >= alpha_pmu->num_pmcs)) { /* This should never occur! */ irq_err_count++; - pr_warning("PMI: silly index %ld\n", la_ptr); + pr_warn("PMI: silly index %ld\n", la_ptr); wrperfmon(PERFMON_CMD_ENABLE, cpuc->idx_mask); return; } @@ -851,7 +851,7 @@ static void alpha_perf_event_irq_handler(unsigned long la_ptr, if (unlikely(!event)) { /* This should never occur! */ irq_err_count++; - pr_warning("PMI: No event at index %d!\n", idx); + pr_warn("PMI: No event at index %d!\n", idx); wrperfmon(PERFMON_CMD_ENABLE, cpuc->idx_mask); return; } -- 2.10.0.rc2.1.g053435c
[PATCH 00/35] treewide trivial patches converting pr_warning to pr_warn
There are ~4300 uses of pr_warn and ~250 uses of the older pr_warning in the kernel source tree. Make the use of pr_warn consistent across all kernel files. This excludes all files in tools/ as there is a separate define pr_warning for that directory tree and pr_warn is not used in tools/. Done with 'sed s/\bpr_warning\b/pr_warn/' and some emacsing. Miscellanea: o Coalesce formats and realign arguments Some files not compiled - no cross-compilers Joe Perches (35): alpha: Convert remaining uses of pr_warning to pr_warn ARM: ep93xx: Convert remaining uses of pr_warning to pr_warn arm64: Convert remaining uses of pr_warning to pr_warn arch/blackfin: Convert remaining uses of pr_warning to pr_warn ia64: Convert remaining use of pr_warning to pr_warn powerpc: Convert remaining uses of pr_warning to pr_warn sh: Convert remaining uses of pr_warning to pr_warn sparc: Convert remaining use of pr_warning to pr_warn x86: Convert remaining uses of pr_warning to pr_warn drivers/acpi: Convert remaining uses of pr_warning to pr_warn block/drbd: Convert remaining uses of pr_warning to pr_warn gdrom: Convert remaining uses of pr_warning to pr_warn drivers/char: Convert remaining use of pr_warning to pr_warn clocksource: Convert remaining use of pr_warning to pr_warn drivers/crypto: Convert remaining uses of pr_warning to pr_warn fmc: Convert remaining use of pr_warning to pr_warn drivers/gpu: Convert remaining uses of pr_warning to pr_warn drivers/ide: Convert remaining uses of pr_warning to pr_warn drivers/input: Convert remaining uses of pr_warning to pr_warn drivers/isdn: Convert remaining uses of pr_warning to pr_warn drivers/macintosh: Convert remaining uses of pr_warning to pr_warn drivers/media: Convert remaining use of pr_warning to pr_warn drivers/mfd: Convert remaining uses of pr_warning to pr_warn drivers/mtd: Convert remaining uses of pr_warning to pr_warn drivers/of: Convert remaining uses of pr_warning to pr_warn drivers/oprofile: Convert remaining uses of pr_warning to pr_warn drivers/platform: Convert remaining uses of pr_warning to pr_warn drivers/rapidio: Convert remaining use of pr_warning to pr_warn drivers/scsi: Convert remaining use of pr_warning to pr_warn drivers/sh: Convert remaining use of pr_warning to pr_warn drivers/tty: Convert remaining uses of pr_warning to pr_warn drivers/video: Convert remaining uses of pr_warning to pr_warn kernel/trace: Convert remaining uses of pr_warning to pr_warn lib: Convert remaining uses of pr_warning to pr_warn sound/soc: Convert remaining uses of pr_warning to pr_warn arch/alpha/kernel/perf_event.c | 4 +- arch/arm/mach-ep93xx/core.c| 4 +- arch/arm64/include/asm/syscall.h | 8 ++-- arch/arm64/kernel/hw_breakpoint.c | 8 ++-- arch/arm64/kernel/smp.c| 4 +- arch/blackfin/kernel/nmi.c | 2 +- arch/blackfin/kernel/ptrace.c | 2 +- arch/blackfin/mach-bf533/boards/stamp.c| 2 +- arch/blackfin/mach-bf537/boards/cm_bf537e.c| 2 +- arch/blackfin/mach-bf537/boards/cm_bf537u.c| 2 +- arch/blackfin/mach-bf537/boards/stamp.c| 2 +- arch/blackfin/mach-bf537/boards/tcm_bf537.c| 2 +- arch/blackfin/mach-bf561/boards/cm_bf561.c | 2 +- arch/blackfin/mach-bf561/boards/ezkit.c| 2 +- arch/blackfin/mm/isram-driver.c| 4 +- arch/ia64/kernel/setup.c | 6 +-- arch/powerpc/kernel/pci-common.c | 4 +- arch/powerpc/mm/init_64.c | 5 +-- arch/powerpc/mm/mem.c | 3 +- arch/powerpc/platforms/512x/mpc512x_shared.c | 4 +- arch/powerpc/platforms/85xx/socrates_fpga_pic.c| 7 ++-- arch/powerpc/platforms/86xx/mpc86xx_hpcn.c | 2 +- arch/powerpc/platforms/pasemi/dma_lib.c| 4 +- arch/powerpc/platforms/powernv/opal.c | 8 ++-- arch/powerpc/platforms/powernv/pci-ioda.c | 10 ++--- arch/powerpc/platforms/ps3/device-init.c | 14 +++ arch/powerpc/platforms/ps3/mm.c| 4 +- arch/powerpc/platforms/ps3/os-area.c | 2 +- arch/powerpc/platforms/pseries/iommu.c | 8 ++-- arch/powerpc/platforms/pseries/setup.c | 4 +- arch/powerpc/sysdev/fsl_pci.c | 9 ++--- arch/powerpc/sysdev/mpic.c | 10 ++--- arch/powerpc/sysdev/xics/icp-native.c | 10 ++--- arch/powerpc/sysdev/xics/ics-opal.c| 4 +- arch/powerpc/sysdev/xics/ics-rtas.c| 4 +- arch/powerpc/sysdev/xics/xics-common.c | 8 ++-- arch/sh/boards/mach-sdk7786/nmi.c | 2 +- arch/sh/drivers/pci/fixups-sdk7786.c | 2 +- arch/sh/kernel/io_trapped.c
Re: [PATCH 4/5] tpm_tis_spi: Remove limitation of transfers to MAX_SPI_FRAMESIZE bytes
Am 17. Februar 2017 06:11:53 MEZ schrieb Christophe Ricard: >I am not sure i understand here, are you considering there could be >burstcount > 64 with "TCG" TPM ? > With the current upstream version, any command larger with a response of more than 64 byte is broken, since the splitting loop went missing during the merge. At least with our tpms that's the case. (I think we are signalling a higher burstcount value than 64, which is allowed) >Or is this because of TIS vs PTP differences ? > >To be honest, this is a little behind me now :-) > > >On 16/02/2017 08:08, Peter Huewe wrote: >> Limiting transfers to MAX_SPI_FRAMESIZE was not expected by the upper >> layers, as tpm_tis has no such limitation. Add a loop to hide that >> limitation. >> >> Cc: >> Fixes: 0edbfea537d1 ("tpm/tpm_tis_spi: Add support for spi phy") >> Signed-off-by: Alexander Steffen >> Signed-off-by: Peter Huewe >> --- >> drivers/char/tpm/tpm_tis_spi.c | 108 >++--- >> 1 file changed, 57 insertions(+), 51 deletions(-) >> >> diff --git a/drivers/char/tpm/tpm_tis_spi.c >b/drivers/char/tpm/tpm_tis_spi.c >> index 16938e2253d2..b50c5b072df3 100644 >> --- a/drivers/char/tpm/tpm_tis_spi.c >> +++ b/drivers/char/tpm/tpm_tis_spi.c >> @@ -61,68 +61,74 @@ static int tpm_tis_spi_transfer(struct >tpm_tis_data *data, u32 addr, u8 len, >> { >> struct tpm_tis_spi_phy *phy = to_tpm_tis_spi_phy(data); >> int ret; >> -struct spi_message m; >> -struct spi_transfer spi_xfer = { >> -.tx_buf = phy->tx_buf, >> -.rx_buf = phy->rx_buf, >> -.len = 4, >> -.cs_change = 1, >> -}; >> - >> -if (len > MAX_SPI_FRAMESIZE) >> -return -ENOMEM; >> >> -phy->tx_buf[0] = direction | (len - 1); >> -phy->tx_buf[1] = 0xd4; >> -phy->tx_buf[2] = addr >> 8; >> -phy->tx_buf[3] = addr; >> +spi_bus_lock(phy->spi_device->master); >> >> -spi_message_init(); >> -spi_message_add_tail(_xfer, ); >> +while (len) { >> +struct spi_message m; >> +struct spi_transfer spi_xfer = { >> +.tx_buf = phy->tx_buf, >> +.rx_buf = phy->rx_buf, >> +.len = 4, >> +.cs_change = 1, >> +}; >> +u8 transfer_len = min_t(u16, len, MAX_SPI_FRAMESIZE); >> + >> +phy->tx_buf[0] = direction | (transfer_len - 1); >> +phy->tx_buf[1] = 0xd4; >> +phy->tx_buf[2] = addr >> 8; >> +phy->tx_buf[3] = addr; >> + >> +spi_message_init(); >> +spi_message_add_tail(_xfer, ); >> +ret = spi_sync_locked(phy->spi_device, ); >> +if (ret < 0) >> +goto exit; >> >> -spi_bus_lock(phy->spi_device->master); >> -ret = spi_sync_locked(phy->spi_device, ); >> -if (ret < 0) >> -goto exit; >> - >> -if ((phy->rx_buf[3] & 0x01) == 0) { >> -// handle SPI wait states >> -int i; >> - >> -phy->tx_buf[0] = 0; >> - >> -for (i = 0; i < TPM_RETRY; i++) { >> -spi_xfer.len = 1; >> -spi_message_init(); >> -spi_message_add_tail(_xfer, ); >> -ret = spi_sync_locked(phy->spi_device, ); >> -if (ret < 0) >> +if ((phy->rx_buf[3] & 0x01) == 0) { >> +// handle SPI wait states >> +int i; >> + >> +phy->tx_buf[0] = 0; >> + >> +for (i = 0; i < TPM_RETRY; i++) { >> +spi_xfer.len = 1; >> +spi_message_init(); >> +spi_message_add_tail(_xfer, ); >> +ret = spi_sync_locked(phy->spi_device, ); >> +if (ret < 0) >> +goto exit; >> +if (phy->rx_buf[0] & 0x01) >> +break; >> +} >> + >> +if (i == TPM_RETRY) { >> +ret = -ETIMEDOUT; >> goto exit; >> -if (phy->rx_buf[0] & 0x01) >> -break; >> +} >> } >> >> -if (i == TPM_RETRY) { >> -ret = -ETIMEDOUT; >> -goto exit; >> +spi_xfer.cs_change = 0; >> +spi_xfer.len = transfer_len; >> + >> +if (direction) { >> +spi_xfer.tx_buf = NULL; >> +spi_xfer.rx_buf = buffer; >> +} else { >> +spi_xfer.tx_buf = buffer; >> +spi_xfer.rx_buf = NULL; >> } >> -} >> >> -
Re: [PATCH 4/5] tpm_tis_spi: Remove limitation of transfers to MAX_SPI_FRAMESIZE bytes
Am 17. Februar 2017 06:11:53 MEZ schrieb Christophe Ricard : >I am not sure i understand here, are you considering there could be >burstcount > 64 with "TCG" TPM ? > With the current upstream version, any command larger with a response of more than 64 byte is broken, since the splitting loop went missing during the merge. At least with our tpms that's the case. (I think we are signalling a higher burstcount value than 64, which is allowed) >Or is this because of TIS vs PTP differences ? > >To be honest, this is a little behind me now :-) > > >On 16/02/2017 08:08, Peter Huewe wrote: >> Limiting transfers to MAX_SPI_FRAMESIZE was not expected by the upper >> layers, as tpm_tis has no such limitation. Add a loop to hide that >> limitation. >> >> Cc: >> Fixes: 0edbfea537d1 ("tpm/tpm_tis_spi: Add support for spi phy") >> Signed-off-by: Alexander Steffen >> Signed-off-by: Peter Huewe >> --- >> drivers/char/tpm/tpm_tis_spi.c | 108 >++--- >> 1 file changed, 57 insertions(+), 51 deletions(-) >> >> diff --git a/drivers/char/tpm/tpm_tis_spi.c >b/drivers/char/tpm/tpm_tis_spi.c >> index 16938e2253d2..b50c5b072df3 100644 >> --- a/drivers/char/tpm/tpm_tis_spi.c >> +++ b/drivers/char/tpm/tpm_tis_spi.c >> @@ -61,68 +61,74 @@ static int tpm_tis_spi_transfer(struct >tpm_tis_data *data, u32 addr, u8 len, >> { >> struct tpm_tis_spi_phy *phy = to_tpm_tis_spi_phy(data); >> int ret; >> -struct spi_message m; >> -struct spi_transfer spi_xfer = { >> -.tx_buf = phy->tx_buf, >> -.rx_buf = phy->rx_buf, >> -.len = 4, >> -.cs_change = 1, >> -}; >> - >> -if (len > MAX_SPI_FRAMESIZE) >> -return -ENOMEM; >> >> -phy->tx_buf[0] = direction | (len - 1); >> -phy->tx_buf[1] = 0xd4; >> -phy->tx_buf[2] = addr >> 8; >> -phy->tx_buf[3] = addr; >> +spi_bus_lock(phy->spi_device->master); >> >> -spi_message_init(); >> -spi_message_add_tail(_xfer, ); >> +while (len) { >> +struct spi_message m; >> +struct spi_transfer spi_xfer = { >> +.tx_buf = phy->tx_buf, >> +.rx_buf = phy->rx_buf, >> +.len = 4, >> +.cs_change = 1, >> +}; >> +u8 transfer_len = min_t(u16, len, MAX_SPI_FRAMESIZE); >> + >> +phy->tx_buf[0] = direction | (transfer_len - 1); >> +phy->tx_buf[1] = 0xd4; >> +phy->tx_buf[2] = addr >> 8; >> +phy->tx_buf[3] = addr; >> + >> +spi_message_init(); >> +spi_message_add_tail(_xfer, ); >> +ret = spi_sync_locked(phy->spi_device, ); >> +if (ret < 0) >> +goto exit; >> >> -spi_bus_lock(phy->spi_device->master); >> -ret = spi_sync_locked(phy->spi_device, ); >> -if (ret < 0) >> -goto exit; >> - >> -if ((phy->rx_buf[3] & 0x01) == 0) { >> -// handle SPI wait states >> -int i; >> - >> -phy->tx_buf[0] = 0; >> - >> -for (i = 0; i < TPM_RETRY; i++) { >> -spi_xfer.len = 1; >> -spi_message_init(); >> -spi_message_add_tail(_xfer, ); >> -ret = spi_sync_locked(phy->spi_device, ); >> -if (ret < 0) >> +if ((phy->rx_buf[3] & 0x01) == 0) { >> +// handle SPI wait states >> +int i; >> + >> +phy->tx_buf[0] = 0; >> + >> +for (i = 0; i < TPM_RETRY; i++) { >> +spi_xfer.len = 1; >> +spi_message_init(); >> +spi_message_add_tail(_xfer, ); >> +ret = spi_sync_locked(phy->spi_device, ); >> +if (ret < 0) >> +goto exit; >> +if (phy->rx_buf[0] & 0x01) >> +break; >> +} >> + >> +if (i == TPM_RETRY) { >> +ret = -ETIMEDOUT; >> goto exit; >> -if (phy->rx_buf[0] & 0x01) >> -break; >> +} >> } >> >> -if (i == TPM_RETRY) { >> -ret = -ETIMEDOUT; >> -goto exit; >> +spi_xfer.cs_change = 0; >> +spi_xfer.len = transfer_len; >> + >> +if (direction) { >> +spi_xfer.tx_buf = NULL; >> +spi_xfer.rx_buf = buffer; >> +} else { >> +spi_xfer.tx_buf = buffer; >> +spi_xfer.rx_buf = NULL; >> } >> -} >> >> -spi_xfer.cs_change = 0; >> -spi_xfer.len = len; >> +spi_message_init(); >> +
[PATCH 06/35] powerpc: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/powerpc Prior to this patch, there were 36 uses of pr_warning and 217 uses of pr_warn in arch/powerpc Signed-off-by: Joe Perches--- arch/powerpc/kernel/pci-common.c| 4 ++-- arch/powerpc/mm/init_64.c | 5 ++--- arch/powerpc/mm/mem.c | 3 +-- arch/powerpc/platforms/512x/mpc512x_shared.c| 4 ++-- arch/powerpc/platforms/85xx/socrates_fpga_pic.c | 7 +++ arch/powerpc/platforms/86xx/mpc86xx_hpcn.c | 2 +- arch/powerpc/platforms/pasemi/dma_lib.c | 4 ++-- arch/powerpc/platforms/powernv/opal.c | 8 arch/powerpc/platforms/powernv/pci-ioda.c | 10 +- arch/powerpc/platforms/ps3/device-init.c| 14 +++--- arch/powerpc/platforms/ps3/mm.c | 4 ++-- arch/powerpc/platforms/ps3/os-area.c| 2 +- arch/powerpc/platforms/pseries/iommu.c | 8 +++- arch/powerpc/platforms/pseries/setup.c | 4 ++-- arch/powerpc/sysdev/fsl_pci.c | 9 +++-- arch/powerpc/sysdev/mpic.c | 10 -- arch/powerpc/sysdev/xics/icp-native.c | 10 -- arch/powerpc/sysdev/xics/ics-opal.c | 4 ++-- arch/powerpc/sysdev/xics/ics-rtas.c | 4 ++-- arch/powerpc/sysdev/xics/xics-common.c | 8 20 files changed, 56 insertions(+), 68 deletions(-) diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c index 74bec5498972..338f7f7dbfb2 100644 --- a/arch/powerpc/kernel/pci-common.c +++ b/arch/powerpc/kernel/pci-common.c @@ -1267,8 +1267,8 @@ static void pcibios_allocate_bus_resources(struct pci_bus *bus) i + PCI_BRIDGE_RESOURCES) == 0) continue; } - pr_warning("PCI: Cannot allocate resource region " - "%d of PCI bridge %d, will remap\n", i, bus->number); + pr_warn("PCI: Cannot allocate resource region %d of PCI bridge %d, will remap\n", + i, bus->number); clear_resource: /* The resource might be figured out when doing * reassignment based on the resources required diff --git a/arch/powerpc/mm/init_64.c b/arch/powerpc/mm/init_64.c index 6aa3b76aa0d6..55221447e995 100644 --- a/arch/powerpc/mm/init_64.c +++ b/arch/powerpc/mm/init_64.c @@ -192,9 +192,8 @@ int __meminit vmemmap_populate(unsigned long start, unsigned long end, int node) rc = vmemmap_create_mapping(start, page_size, __pa(p)); if (rc < 0) { - pr_warning( - "vmemmap_populate: Unable to create vmemmap mapping: %d\n", - rc); + pr_warn("%s: Unable to create vmemmap mapping: %d\n", + __func__, rc); return -EFAULT; } } diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c index 9ee536ec0739..7dbb48bd4593 100644 --- a/arch/powerpc/mm/mem.c +++ b/arch/powerpc/mm/mem.c @@ -141,8 +141,7 @@ int arch_add_memory(int nid, u64 start, u64 size, bool for_device) start = (unsigned long)__va(start); rc = create_section_mapping(start, start + size); if (rc) { - pr_warning( - "Unable to create mapping for hot added memory 0x%llx..0x%llx: %d\n", + pr_warn("Unable to create mapping for hot added memory 0x%llx..0x%llx: %d\n", start, start + size, rc); return -EFAULT; } diff --git a/arch/powerpc/platforms/512x/mpc512x_shared.c b/arch/powerpc/platforms/512x/mpc512x_shared.c index 6b4f4cb7009a..1592b7ce9635 100644 --- a/arch/powerpc/platforms/512x/mpc512x_shared.c +++ b/arch/powerpc/platforms/512x/mpc512x_shared.c @@ -387,8 +387,8 @@ static unsigned int __init get_fifo_size(struct device_node *np, if (fp) return *fp; - pr_warning("no %s property in %s node, defaulting to %d\n", - prop_name, np->full_name, DEFAULT_FIFO_SIZE); + pr_warn("no %s property in %s node, defaulting to %d\n", + prop_name, np->full_name, DEFAULT_FIFO_SIZE); return DEFAULT_FIFO_SIZE; } diff --git a/arch/powerpc/platforms/85xx/socrates_fpga_pic.c b/arch/powerpc/platforms/85xx/socrates_fpga_pic.c index 82f8490b5aa7..38d4ba9f37b5 100644 --- a/arch/powerpc/platforms/85xx/socrates_fpga_pic.c +++ b/arch/powerpc/platforms/85xx/socrates_fpga_pic.c @@ -252,8 +252,7 @@ static int socrates_fpga_pic_host_xlate(struct irq_domain *h, /* type is configurable */ if (intspec[1] != IRQ_TYPE_LEVEL_LOW && intspec[1] != IRQ_TYPE_LEVEL_HIGH) { -
[PATCH 06/35] powerpc: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/powerpc Prior to this patch, there were 36 uses of pr_warning and 217 uses of pr_warn in arch/powerpc Signed-off-by: Joe Perches --- arch/powerpc/kernel/pci-common.c| 4 ++-- arch/powerpc/mm/init_64.c | 5 ++--- arch/powerpc/mm/mem.c | 3 +-- arch/powerpc/platforms/512x/mpc512x_shared.c| 4 ++-- arch/powerpc/platforms/85xx/socrates_fpga_pic.c | 7 +++ arch/powerpc/platforms/86xx/mpc86xx_hpcn.c | 2 +- arch/powerpc/platforms/pasemi/dma_lib.c | 4 ++-- arch/powerpc/platforms/powernv/opal.c | 8 arch/powerpc/platforms/powernv/pci-ioda.c | 10 +- arch/powerpc/platforms/ps3/device-init.c| 14 +++--- arch/powerpc/platforms/ps3/mm.c | 4 ++-- arch/powerpc/platforms/ps3/os-area.c| 2 +- arch/powerpc/platforms/pseries/iommu.c | 8 +++- arch/powerpc/platforms/pseries/setup.c | 4 ++-- arch/powerpc/sysdev/fsl_pci.c | 9 +++-- arch/powerpc/sysdev/mpic.c | 10 -- arch/powerpc/sysdev/xics/icp-native.c | 10 -- arch/powerpc/sysdev/xics/ics-opal.c | 4 ++-- arch/powerpc/sysdev/xics/ics-rtas.c | 4 ++-- arch/powerpc/sysdev/xics/xics-common.c | 8 20 files changed, 56 insertions(+), 68 deletions(-) diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c index 74bec5498972..338f7f7dbfb2 100644 --- a/arch/powerpc/kernel/pci-common.c +++ b/arch/powerpc/kernel/pci-common.c @@ -1267,8 +1267,8 @@ static void pcibios_allocate_bus_resources(struct pci_bus *bus) i + PCI_BRIDGE_RESOURCES) == 0) continue; } - pr_warning("PCI: Cannot allocate resource region " - "%d of PCI bridge %d, will remap\n", i, bus->number); + pr_warn("PCI: Cannot allocate resource region %d of PCI bridge %d, will remap\n", + i, bus->number); clear_resource: /* The resource might be figured out when doing * reassignment based on the resources required diff --git a/arch/powerpc/mm/init_64.c b/arch/powerpc/mm/init_64.c index 6aa3b76aa0d6..55221447e995 100644 --- a/arch/powerpc/mm/init_64.c +++ b/arch/powerpc/mm/init_64.c @@ -192,9 +192,8 @@ int __meminit vmemmap_populate(unsigned long start, unsigned long end, int node) rc = vmemmap_create_mapping(start, page_size, __pa(p)); if (rc < 0) { - pr_warning( - "vmemmap_populate: Unable to create vmemmap mapping: %d\n", - rc); + pr_warn("%s: Unable to create vmemmap mapping: %d\n", + __func__, rc); return -EFAULT; } } diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c index 9ee536ec0739..7dbb48bd4593 100644 --- a/arch/powerpc/mm/mem.c +++ b/arch/powerpc/mm/mem.c @@ -141,8 +141,7 @@ int arch_add_memory(int nid, u64 start, u64 size, bool for_device) start = (unsigned long)__va(start); rc = create_section_mapping(start, start + size); if (rc) { - pr_warning( - "Unable to create mapping for hot added memory 0x%llx..0x%llx: %d\n", + pr_warn("Unable to create mapping for hot added memory 0x%llx..0x%llx: %d\n", start, start + size, rc); return -EFAULT; } diff --git a/arch/powerpc/platforms/512x/mpc512x_shared.c b/arch/powerpc/platforms/512x/mpc512x_shared.c index 6b4f4cb7009a..1592b7ce9635 100644 --- a/arch/powerpc/platforms/512x/mpc512x_shared.c +++ b/arch/powerpc/platforms/512x/mpc512x_shared.c @@ -387,8 +387,8 @@ static unsigned int __init get_fifo_size(struct device_node *np, if (fp) return *fp; - pr_warning("no %s property in %s node, defaulting to %d\n", - prop_name, np->full_name, DEFAULT_FIFO_SIZE); + pr_warn("no %s property in %s node, defaulting to %d\n", + prop_name, np->full_name, DEFAULT_FIFO_SIZE); return DEFAULT_FIFO_SIZE; } diff --git a/arch/powerpc/platforms/85xx/socrates_fpga_pic.c b/arch/powerpc/platforms/85xx/socrates_fpga_pic.c index 82f8490b5aa7..38d4ba9f37b5 100644 --- a/arch/powerpc/platforms/85xx/socrates_fpga_pic.c +++ b/arch/powerpc/platforms/85xx/socrates_fpga_pic.c @@ -252,8 +252,7 @@ static int socrates_fpga_pic_host_xlate(struct irq_domain *h, /* type is configurable */ if (intspec[1] != IRQ_TYPE_LEVEL_LOW && intspec[1] != IRQ_TYPE_LEVEL_HIGH) { - pr_warning("FPGA PIC:
[PATCH 08/35] sparc: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/sparc Prior to this patch, there was 1 use of pr_warning and 8 uses of pr_warn in arch/sparc Signed-off-by: Joe Perches--- arch/sparc/kernel/smp_64.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/sparc/kernel/smp_64.c b/arch/sparc/kernel/smp_64.c index dcb12d9002e9..ca0f8faa79a9 100644 --- a/arch/sparc/kernel/smp_64.c +++ b/arch/sparc/kernel/smp_64.c @@ -1564,9 +1564,8 @@ void __init setup_per_cpu_areas(void) pcpu_alloc_bootmem, pcpu_free_bootmem); if (rc) - pr_warning("PERCPU: %s allocator failed (%d), " - "falling back to page size\n", - pcpu_fc_names[pcpu_chosen_fc], rc); + pr_warn("PERCPU: %s allocator failed (%d), falling back to page size\n", + pcpu_fc_names[pcpu_chosen_fc], rc); } if (rc < 0) rc = pcpu_page_first_chunk(PERCPU_MODULE_RESERVE, -- 2.10.0.rc2.1.g053435c
[PATCH 08/35] sparc: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/sparc Prior to this patch, there was 1 use of pr_warning and 8 uses of pr_warn in arch/sparc Signed-off-by: Joe Perches --- arch/sparc/kernel/smp_64.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/sparc/kernel/smp_64.c b/arch/sparc/kernel/smp_64.c index dcb12d9002e9..ca0f8faa79a9 100644 --- a/arch/sparc/kernel/smp_64.c +++ b/arch/sparc/kernel/smp_64.c @@ -1564,9 +1564,8 @@ void __init setup_per_cpu_areas(void) pcpu_alloc_bootmem, pcpu_free_bootmem); if (rc) - pr_warning("PERCPU: %s allocator failed (%d), " - "falling back to page size\n", - pcpu_fc_names[pcpu_chosen_fc], rc); + pr_warn("PERCPU: %s allocator failed (%d), falling back to page size\n", + pcpu_fc_names[pcpu_chosen_fc], rc); } if (rc < 0) rc = pcpu_page_first_chunk(PERCPU_MODULE_RESERVE, -- 2.10.0.rc2.1.g053435c
[PATCH 11/35] block/drbd: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/block Prior to this patch, there were 2 uses of pr_warning and 26 uses of pr_warn in drivers/block Signed-off-by: Joe Perches--- drivers/block/drbd/drbd_nl.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/block/drbd/drbd_nl.c b/drivers/block/drbd/drbd_nl.c index 908c704e20aa..4a237b4418bb 100644 --- a/drivers/block/drbd/drbd_nl.c +++ b/drivers/block/drbd/drbd_nl.c @@ -251,19 +251,18 @@ static int drbd_adm_prepare(struct drbd_config_context *adm_ctx, /* some more paranoia, if the request was over-determined */ if (adm_ctx->device && adm_ctx->resource && adm_ctx->device->resource != adm_ctx->resource) { - pr_warning("request: minor=%u, resource=%s; but that minor belongs to resource %s\n", - adm_ctx->minor, adm_ctx->resource->name, - adm_ctx->device->resource->name); + pr_warn("request: minor=%u, resource=%s; but that minor belongs to resource %s\n", + adm_ctx->minor, adm_ctx->resource->name, + adm_ctx->device->resource->name); drbd_msg_put_info(adm_ctx->reply_skb, "minor exists in different resource"); return ERR_INVALID_REQUEST; } if (adm_ctx->device && adm_ctx->volume != VOLUME_UNSPECIFIED && adm_ctx->volume != adm_ctx->device->vnr) { - pr_warning("request: minor=%u, volume=%u; but that minor is volume %u in %s\n", - adm_ctx->minor, adm_ctx->volume, - adm_ctx->device->vnr, - adm_ctx->device->resource->name); + pr_warn("request: minor=%u, volume=%u; but that minor is volume %u in %s\n", + adm_ctx->minor, adm_ctx->volume, + adm_ctx->device->vnr, adm_ctx->device->resource->name); drbd_msg_put_info(adm_ctx->reply_skb, "minor exists as different volume"); return ERR_INVALID_REQUEST; } -- 2.10.0.rc2.1.g053435c
[PATCH 15/35] drivers/crypto: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/crypto Prior to this patch, there were 3 uses of pr_warning and 12 uses of pr_warn in drivers/crypto Signed-off-by: Joe Perches--- drivers/crypto/n2_core.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/crypto/n2_core.c b/drivers/crypto/n2_core.c index c5aac25a5738..82ab91adfee7 100644 --- a/drivers/crypto/n2_core.c +++ b/drivers/crypto/n2_core.c @@ -365,8 +365,8 @@ static int n2_hash_cra_init(struct crypto_tfm *tfm) fallback_tfm = crypto_alloc_ahash(fallback_driver_name, 0, CRYPTO_ALG_NEED_FALLBACK); if (IS_ERR(fallback_tfm)) { - pr_warning("Fallback driver '%s' could not be loaded!\n", - fallback_driver_name); + pr_warn("Fallback driver '%s' could not be loaded!\n", + fallback_driver_name); err = PTR_ERR(fallback_tfm); goto out; } @@ -402,16 +402,16 @@ static int n2_hmac_cra_init(struct crypto_tfm *tfm) fallback_tfm = crypto_alloc_ahash(fallback_driver_name, 0, CRYPTO_ALG_NEED_FALLBACK); if (IS_ERR(fallback_tfm)) { - pr_warning("Fallback driver '%s' could not be loaded!\n", - fallback_driver_name); + pr_warn("Fallback driver '%s' could not be loaded!\n", + fallback_driver_name); err = PTR_ERR(fallback_tfm); goto out; } child_shash = crypto_alloc_shash(n2alg->child_alg, 0, 0); if (IS_ERR(child_shash)) { - pr_warning("Child shash '%s' could not be loaded!\n", - n2alg->child_alg); + pr_warn("Child shash '%s' could not be loaded!\n", + n2alg->child_alg); err = PTR_ERR(child_shash); goto out_free_fallback; } -- 2.10.0.rc2.1.g053435c
[PATCH 11/35] block/drbd: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/block Prior to this patch, there were 2 uses of pr_warning and 26 uses of pr_warn in drivers/block Signed-off-by: Joe Perches --- drivers/block/drbd/drbd_nl.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/block/drbd/drbd_nl.c b/drivers/block/drbd/drbd_nl.c index 908c704e20aa..4a237b4418bb 100644 --- a/drivers/block/drbd/drbd_nl.c +++ b/drivers/block/drbd/drbd_nl.c @@ -251,19 +251,18 @@ static int drbd_adm_prepare(struct drbd_config_context *adm_ctx, /* some more paranoia, if the request was over-determined */ if (adm_ctx->device && adm_ctx->resource && adm_ctx->device->resource != adm_ctx->resource) { - pr_warning("request: minor=%u, resource=%s; but that minor belongs to resource %s\n", - adm_ctx->minor, adm_ctx->resource->name, - adm_ctx->device->resource->name); + pr_warn("request: minor=%u, resource=%s; but that minor belongs to resource %s\n", + adm_ctx->minor, adm_ctx->resource->name, + adm_ctx->device->resource->name); drbd_msg_put_info(adm_ctx->reply_skb, "minor exists in different resource"); return ERR_INVALID_REQUEST; } if (adm_ctx->device && adm_ctx->volume != VOLUME_UNSPECIFIED && adm_ctx->volume != adm_ctx->device->vnr) { - pr_warning("request: minor=%u, volume=%u; but that minor is volume %u in %s\n", - adm_ctx->minor, adm_ctx->volume, - adm_ctx->device->vnr, - adm_ctx->device->resource->name); + pr_warn("request: minor=%u, volume=%u; but that minor is volume %u in %s\n", + adm_ctx->minor, adm_ctx->volume, + adm_ctx->device->vnr, adm_ctx->device->resource->name); drbd_msg_put_info(adm_ctx->reply_skb, "minor exists as different volume"); return ERR_INVALID_REQUEST; } -- 2.10.0.rc2.1.g053435c
[PATCH 15/35] drivers/crypto: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/crypto Prior to this patch, there were 3 uses of pr_warning and 12 uses of pr_warn in drivers/crypto Signed-off-by: Joe Perches --- drivers/crypto/n2_core.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/crypto/n2_core.c b/drivers/crypto/n2_core.c index c5aac25a5738..82ab91adfee7 100644 --- a/drivers/crypto/n2_core.c +++ b/drivers/crypto/n2_core.c @@ -365,8 +365,8 @@ static int n2_hash_cra_init(struct crypto_tfm *tfm) fallback_tfm = crypto_alloc_ahash(fallback_driver_name, 0, CRYPTO_ALG_NEED_FALLBACK); if (IS_ERR(fallback_tfm)) { - pr_warning("Fallback driver '%s' could not be loaded!\n", - fallback_driver_name); + pr_warn("Fallback driver '%s' could not be loaded!\n", + fallback_driver_name); err = PTR_ERR(fallback_tfm); goto out; } @@ -402,16 +402,16 @@ static int n2_hmac_cra_init(struct crypto_tfm *tfm) fallback_tfm = crypto_alloc_ahash(fallback_driver_name, 0, CRYPTO_ALG_NEED_FALLBACK); if (IS_ERR(fallback_tfm)) { - pr_warning("Fallback driver '%s' could not be loaded!\n", - fallback_driver_name); + pr_warn("Fallback driver '%s' could not be loaded!\n", + fallback_driver_name); err = PTR_ERR(fallback_tfm); goto out; } child_shash = crypto_alloc_shash(n2alg->child_alg, 0, 0); if (IS_ERR(child_shash)) { - pr_warning("Child shash '%s' could not be loaded!\n", - n2alg->child_alg); + pr_warn("Child shash '%s' could not be loaded!\n", + n2alg->child_alg); err = PTR_ERR(child_shash); goto out_free_fallback; } -- 2.10.0.rc2.1.g053435c
[PATCH 10/35] drivers/acpi: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/acpi Prior to this patch, there were 20 uses of pr_warning and 45 uses of pr_warn in drivers/acpi Signed-off-by: Joe Perches--- drivers/acpi/apei/apei-base.c | 32 drivers/acpi/apei/einj.c | 4 ++-- drivers/acpi/apei/erst-dbg.c | 4 ++-- drivers/acpi/apei/ghes.c | 30 ++ drivers/acpi/apei/hest.c | 10 +- drivers/acpi/resource.c | 4 ++-- 6 files changed, 41 insertions(+), 43 deletions(-) diff --git a/drivers/acpi/apei/apei-base.c b/drivers/acpi/apei/apei-base.c index da370e1d31f4..63b7830c2498 100644 --- a/drivers/acpi/apei/apei-base.c +++ b/drivers/acpi/apei/apei-base.c @@ -178,9 +178,9 @@ int __apei_exec_run(struct apei_exec_context *ctx, u8 action, if (ip == ctx->ip) { if (entry->instruction >= ctx->instructions || !ctx->ins_table[entry->instruction].run) { - pr_warning(FW_WARN APEI_PFX + pr_warn(FW_WARN APEI_PFX "Invalid action table, unknown instruction type: %d\n", - entry->instruction); + entry->instruction); return -EINVAL; } run = ctx->ins_table[entry->instruction].run; @@ -219,9 +219,9 @@ static int apei_exec_for_each_entry(struct apei_exec_context *ctx, if (end) *end = i; if (ins >= ctx->instructions || !ins_table[ins].run) { - pr_warning(FW_WARN APEI_PFX + pr_warn(FW_WARN APEI_PFX "Invalid action table, unknown instruction type: %d\n", - ins); + ins); return -EINVAL; } rc = func(ctx, entry, data); @@ -587,18 +587,18 @@ static int apei_check_gar(struct acpi_generic_address *reg, u64 *paddr, space_id = reg->space_id; *paddr = get_unaligned(>address); if (!*paddr) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid physical address in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } if (access_size_code < 1 || access_size_code > 4) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid access size code in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } *access_bit_width = 1UL << (access_size_code + 2); @@ -612,19 +612,19 @@ static int apei_check_gar(struct acpi_generic_address *reg, u64 *paddr, *access_bit_width = 64; if ((bit_width + bit_offset) > *access_bit_width) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid bit width + offset in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } if (space_id != ACPI_ADR_SPACE_SYSTEM_MEMORY && space_id != ACPI_ADR_SPACE_SYSTEM_IO) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid address space type in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } diff --git a/drivers/acpi/apei/einj.c b/drivers/acpi/apei/einj.c index ec50c32ea3da..730a594483f4 100644 --- a/drivers/acpi/apei/einj.c +++ b/drivers/acpi/apei/einj.c @@ -180,7 +180,7 @@ static int einj_get_available_error_type(u32 *type) static int einj_timedout(u64 *t) { if ((s64)*t < SPIN_UNIT) { - pr_warning(FW_WARN "Firmware does not respond in time\n"); + pr_warn(FW_WARN "Firmware does not respond in time\n"); return 1; } *t -= SPIN_UNIT; @@ -320,7 +320,7 @@ static
[PATCH 18/35] drivers/ide: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/ide Prior to this patch, there were 2 uses of pr_warning and 0 uses of pr_warn in drivers/ide Signed-off-by: Joe Perches--- drivers/ide/tx4938ide.c | 2 +- drivers/ide/tx4939ide.c | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/ide/tx4938ide.c b/drivers/ide/tx4938ide.c index 40a3f55b08dd..962eb92501b5 100644 --- a/drivers/ide/tx4938ide.c +++ b/drivers/ide/tx4938ide.c @@ -46,7 +46,7 @@ static void tx4938ide_tune_ebusc(unsigned int ebus_ch, while ((shwt * 4 + wt + (wt ? 2 : 3)) * cycle < t->cycle) shwt++; if (shwt > 7) { - pr_warning("tx4938ide: SHWT violation (%d)\n", shwt); + pr_warn("tx4938ide: SHWT violation (%d)\n", shwt); shwt = 7; } pr_debug("tx4938ide: ebus %d, bus cycle %dns, WT %d, SHWT %d\n", diff --git a/drivers/ide/tx4939ide.c b/drivers/ide/tx4939ide.c index 67d4a7d4acc8..7fa4ff6fc099 100644 --- a/drivers/ide/tx4939ide.c +++ b/drivers/ide/tx4939ide.c @@ -364,9 +364,8 @@ static int tx4939ide_dma_test_irq(ide_drive_t *drive) case TX4939IDE_INT_HOST | TX4939IDE_INT_XFEREND: dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); if (!(dma_stat & ATA_DMA_INTR)) - pr_warning("%s: weird interrupt status. " - "DMA_Stat %#02x int_ctl %#04x\n", - hwif->name, dma_stat, ctl); + pr_warn("%s: weird interrupt status. DMA_Stat %#02x int_ctl %#04x\n", + hwif->name, dma_stat, ctl); found = 1; break; } -- 2.10.0.rc2.1.g053435c
[PATCH 10/35] drivers/acpi: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/acpi Prior to this patch, there were 20 uses of pr_warning and 45 uses of pr_warn in drivers/acpi Signed-off-by: Joe Perches --- drivers/acpi/apei/apei-base.c | 32 drivers/acpi/apei/einj.c | 4 ++-- drivers/acpi/apei/erst-dbg.c | 4 ++-- drivers/acpi/apei/ghes.c | 30 ++ drivers/acpi/apei/hest.c | 10 +- drivers/acpi/resource.c | 4 ++-- 6 files changed, 41 insertions(+), 43 deletions(-) diff --git a/drivers/acpi/apei/apei-base.c b/drivers/acpi/apei/apei-base.c index da370e1d31f4..63b7830c2498 100644 --- a/drivers/acpi/apei/apei-base.c +++ b/drivers/acpi/apei/apei-base.c @@ -178,9 +178,9 @@ int __apei_exec_run(struct apei_exec_context *ctx, u8 action, if (ip == ctx->ip) { if (entry->instruction >= ctx->instructions || !ctx->ins_table[entry->instruction].run) { - pr_warning(FW_WARN APEI_PFX + pr_warn(FW_WARN APEI_PFX "Invalid action table, unknown instruction type: %d\n", - entry->instruction); + entry->instruction); return -EINVAL; } run = ctx->ins_table[entry->instruction].run; @@ -219,9 +219,9 @@ static int apei_exec_for_each_entry(struct apei_exec_context *ctx, if (end) *end = i; if (ins >= ctx->instructions || !ins_table[ins].run) { - pr_warning(FW_WARN APEI_PFX + pr_warn(FW_WARN APEI_PFX "Invalid action table, unknown instruction type: %d\n", - ins); + ins); return -EINVAL; } rc = func(ctx, entry, data); @@ -587,18 +587,18 @@ static int apei_check_gar(struct acpi_generic_address *reg, u64 *paddr, space_id = reg->space_id; *paddr = get_unaligned(>address); if (!*paddr) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid physical address in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } if (access_size_code < 1 || access_size_code > 4) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid access size code in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } *access_bit_width = 1UL << (access_size_code + 2); @@ -612,19 +612,19 @@ static int apei_check_gar(struct acpi_generic_address *reg, u64 *paddr, *access_bit_width = 64; if ((bit_width + bit_offset) > *access_bit_width) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid bit width + offset in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } if (space_id != ACPI_ADR_SPACE_SYSTEM_MEMORY && space_id != ACPI_ADR_SPACE_SYSTEM_IO) { - pr_warning(FW_BUG APEI_PFX + pr_warn(FW_BUG APEI_PFX "Invalid address space type in GAR [0x%llx/%u/%u/%u/%u]\n", - *paddr, bit_width, bit_offset, access_size_code, - space_id); + *paddr, bit_width, bit_offset, access_size_code, + space_id); return -EINVAL; } diff --git a/drivers/acpi/apei/einj.c b/drivers/acpi/apei/einj.c index ec50c32ea3da..730a594483f4 100644 --- a/drivers/acpi/apei/einj.c +++ b/drivers/acpi/apei/einj.c @@ -180,7 +180,7 @@ static int einj_get_available_error_type(u32 *type) static int einj_timedout(u64 *t) { if ((s64)*t < SPIN_UNIT) { - pr_warning(FW_WARN "Firmware does not respond in time\n"); + pr_warn(FW_WARN "Firmware does not respond in time\n"); return 1; } *t -= SPIN_UNIT; @@ -320,7 +320,7 @@ static int
[PATCH 18/35] drivers/ide: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/ide Prior to this patch, there were 2 uses of pr_warning and 0 uses of pr_warn in drivers/ide Signed-off-by: Joe Perches --- drivers/ide/tx4938ide.c | 2 +- drivers/ide/tx4939ide.c | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/ide/tx4938ide.c b/drivers/ide/tx4938ide.c index 40a3f55b08dd..962eb92501b5 100644 --- a/drivers/ide/tx4938ide.c +++ b/drivers/ide/tx4938ide.c @@ -46,7 +46,7 @@ static void tx4938ide_tune_ebusc(unsigned int ebus_ch, while ((shwt * 4 + wt + (wt ? 2 : 3)) * cycle < t->cycle) shwt++; if (shwt > 7) { - pr_warning("tx4938ide: SHWT violation (%d)\n", shwt); + pr_warn("tx4938ide: SHWT violation (%d)\n", shwt); shwt = 7; } pr_debug("tx4938ide: ebus %d, bus cycle %dns, WT %d, SHWT %d\n", diff --git a/drivers/ide/tx4939ide.c b/drivers/ide/tx4939ide.c index 67d4a7d4acc8..7fa4ff6fc099 100644 --- a/drivers/ide/tx4939ide.c +++ b/drivers/ide/tx4939ide.c @@ -364,9 +364,8 @@ static int tx4939ide_dma_test_irq(ide_drive_t *drive) case TX4939IDE_INT_HOST | TX4939IDE_INT_XFEREND: dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); if (!(dma_stat & ATA_DMA_INTR)) - pr_warning("%s: weird interrupt status. " - "DMA_Stat %#02x int_ctl %#04x\n", - hwif->name, dma_stat, ctl); + pr_warn("%s: weird interrupt status. DMA_Stat %#02x int_ctl %#04x\n", + hwif->name, dma_stat, ctl); found = 1; break; } -- 2.10.0.rc2.1.g053435c
[PATCH 14/35] clocksource: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/clocksource Prior to this patch, there was 1 use of pr_warning and 34 uses of pr_warn in drivers/clocksource Signed-off-by: Joe Perches--- drivers/clocksource/samsung_pwm_timer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/clocksource/samsung_pwm_timer.c b/drivers/clocksource/samsung_pwm_timer.c index 0093ece661fe..fa4c6ddc7d95 100644 --- a/drivers/clocksource/samsung_pwm_timer.c +++ b/drivers/clocksource/samsung_pwm_timer.c @@ -433,8 +433,8 @@ static int __init samsung_pwm_alloc(struct device_node *np, of_property_for_each_u32(np, "samsung,pwm-outputs", prop, cur, val) { if (val >= SAMSUNG_PWM_NUM) { - pr_warning("%s: invalid channel index in samsung,pwm-outputs property\n", - __func__); + pr_warn("%s: invalid channel index in samsung,pwm-outputs property\n", + __func__); continue; } pwm.variant.output_mask |= 1 << val; -- 2.10.0.rc2.1.g053435c
[PATCH 09/35] x86: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/x86 Prior to this patch, there were 46 uses of pr_warning and 122 uses of pr_warn in arch/x86 Miscellanea: o Coalesce a few formats and realign arguments o Convert a couple of multiple line printks to single line Signed-off-by: Joe Perches--- arch/x86/kernel/amd_gart_64.c | 12 +++-- arch/x86/kernel/apic/apic.c| 46 -- arch/x86/kernel/apic/apic_noop.c | 2 +- arch/x86/kernel/setup_percpu.c | 4 +-- arch/x86/kernel/tboot.c| 15 ++- arch/x86/kernel/tsc_sync.c | 8 +++--- arch/x86/mm/kmmio.c| 8 +++--- arch/x86/mm/mmio-mod.c | 5 ++-- arch/x86/mm/numa.c | 12 - arch/x86/mm/numa_emulation.c | 6 ++--- arch/x86/mm/testmmiotrace.c| 5 ++-- arch/x86/oprofile/op_x86_model.h | 6 ++--- arch/x86/platform/olpc/olpc-xo15-sci.c | 2 +- arch/x86/platform/sfi/sfi.c| 3 +-- arch/x86/xen/debugfs.c | 2 +- arch/x86/xen/setup.c | 2 +- 16 files changed, 63 insertions(+), 75 deletions(-) diff --git a/arch/x86/kernel/amd_gart_64.c b/arch/x86/kernel/amd_gart_64.c index 63ff468a7986..6bb37027cd70 100644 --- a/arch/x86/kernel/amd_gart_64.c +++ b/arch/x86/kernel/amd_gart_64.c @@ -535,10 +535,8 @@ static __init unsigned long check_iommu_size(unsigned long aper, u64 aper_size) iommu_size -= round_up(a, PMD_PAGE_SIZE) - a; if (iommu_size < 64*1024*1024) { - pr_warning( - "PCI-DMA: Warning: Small IOMMU %luMB." - " Consider increasing the AGP aperture in BIOS\n", - iommu_size >> 20); + pr_warn("PCI-DMA: Warning: Small IOMMU %luMB. Consider increasing the AGP aperture in BIOS\n", + iommu_size >> 20); } return iommu_size; @@ -690,8 +688,7 @@ static __init int init_amd_gatt(struct agp_kern_info *info) nommu: /* Should not happen anymore */ - pr_warning("PCI-DMA: More than 4GB of RAM and no IOMMU\n" - "falling back to iommu=soft.\n"); + pr_warn("PCI-DMA: More than 4GB of RAM and no IOMMU - falling back to iommu=soft\n"); return -1; } @@ -756,8 +753,7 @@ int __init gart_iommu_init(void) !gart_iommu_aperture || (no_agp && init_amd_gatt() < 0)) { if (max_pfn > MAX_DMA32_PFN) { - pr_warning("More than 4GB of memory but GART IOMMU not available.\n"); - pr_warning("falling back to iommu=soft.\n"); + pr_warn("More than 4GB of memory but GART IOMMU not available - falling back to iommu=soft\n"); } return 0; } diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c index 4261b3282ad9..37e9129da8b3 100644 --- a/arch/x86/kernel/apic/apic.c +++ b/arch/x86/kernel/apic/apic.c @@ -685,8 +685,8 @@ calibrate_by_pmtimer(long deltapm, long *delta, long *deltatsc) res = (((u64)deltapm) * mult) >> 22; do_div(res, 100); - pr_warning("APIC calibration not consistent " - "with PM-Timer: %ldms instead of 100ms\n",(long)res); + pr_warn("APIC calibration not consistent with PM-Timer: %ldms instead of 100ms\n", + (long)res); /* Correct the lapic counter value */ res = (((u64)(*delta)) * pm_100ms); @@ -805,7 +805,7 @@ static int __init calibrate_APIC_clock(void) */ if (lapic_timer_frequency < (100 / HZ)) { local_irq_enable(); - pr_warning("APIC frequency too slow, disabling apic timer\n"); + pr_warn("APIC frequency too slow, disabling apic timer\n"); return -1; } @@ -848,8 +848,8 @@ static int __init calibrate_APIC_clock(void) local_irq_enable(); if (levt->features & CLOCK_EVT_FEAT_DUMMY) { - pr_warning("APIC timer disabled due to verification failure\n"); - return -1; + pr_warn("APIC timer disabled due to verification failure\n"); + return -1; } return 0; @@ -923,7 +923,7 @@ static void local_apic_timer_interrupt(void) * spurious. */ if (!evt->event_handler) { - pr_warning("Spurious LAPIC timer interrupt on cpu %d\n", cpu); + pr_warn("Spurious LAPIC timer interrupt on cpu %d\n", cpu); /* Switch it off */ lapic_timer_shutdown(evt); return; @@ -1503,11 +1503,11 @@ static int __init setup_nox2apic(char *str) int apicid = native_apic_msr_read(APIC_ID); if (apicid >= 255) { - pr_warning("Apicid: %08x, cannot enforce
[PATCH 14/35] clocksource: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/clocksource Prior to this patch, there was 1 use of pr_warning and 34 uses of pr_warn in drivers/clocksource Signed-off-by: Joe Perches --- drivers/clocksource/samsung_pwm_timer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/clocksource/samsung_pwm_timer.c b/drivers/clocksource/samsung_pwm_timer.c index 0093ece661fe..fa4c6ddc7d95 100644 --- a/drivers/clocksource/samsung_pwm_timer.c +++ b/drivers/clocksource/samsung_pwm_timer.c @@ -433,8 +433,8 @@ static int __init samsung_pwm_alloc(struct device_node *np, of_property_for_each_u32(np, "samsung,pwm-outputs", prop, cur, val) { if (val >= SAMSUNG_PWM_NUM) { - pr_warning("%s: invalid channel index in samsung,pwm-outputs property\n", - __func__); + pr_warn("%s: invalid channel index in samsung,pwm-outputs property\n", + __func__); continue; } pwm.variant.output_mask |= 1 << val; -- 2.10.0.rc2.1.g053435c
[PATCH 09/35] x86: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for arch/x86 Prior to this patch, there were 46 uses of pr_warning and 122 uses of pr_warn in arch/x86 Miscellanea: o Coalesce a few formats and realign arguments o Convert a couple of multiple line printks to single line Signed-off-by: Joe Perches --- arch/x86/kernel/amd_gart_64.c | 12 +++-- arch/x86/kernel/apic/apic.c| 46 -- arch/x86/kernel/apic/apic_noop.c | 2 +- arch/x86/kernel/setup_percpu.c | 4 +-- arch/x86/kernel/tboot.c| 15 ++- arch/x86/kernel/tsc_sync.c | 8 +++--- arch/x86/mm/kmmio.c| 8 +++--- arch/x86/mm/mmio-mod.c | 5 ++-- arch/x86/mm/numa.c | 12 - arch/x86/mm/numa_emulation.c | 6 ++--- arch/x86/mm/testmmiotrace.c| 5 ++-- arch/x86/oprofile/op_x86_model.h | 6 ++--- arch/x86/platform/olpc/olpc-xo15-sci.c | 2 +- arch/x86/platform/sfi/sfi.c| 3 +-- arch/x86/xen/debugfs.c | 2 +- arch/x86/xen/setup.c | 2 +- 16 files changed, 63 insertions(+), 75 deletions(-) diff --git a/arch/x86/kernel/amd_gart_64.c b/arch/x86/kernel/amd_gart_64.c index 63ff468a7986..6bb37027cd70 100644 --- a/arch/x86/kernel/amd_gart_64.c +++ b/arch/x86/kernel/amd_gart_64.c @@ -535,10 +535,8 @@ static __init unsigned long check_iommu_size(unsigned long aper, u64 aper_size) iommu_size -= round_up(a, PMD_PAGE_SIZE) - a; if (iommu_size < 64*1024*1024) { - pr_warning( - "PCI-DMA: Warning: Small IOMMU %luMB." - " Consider increasing the AGP aperture in BIOS\n", - iommu_size >> 20); + pr_warn("PCI-DMA: Warning: Small IOMMU %luMB. Consider increasing the AGP aperture in BIOS\n", + iommu_size >> 20); } return iommu_size; @@ -690,8 +688,7 @@ static __init int init_amd_gatt(struct agp_kern_info *info) nommu: /* Should not happen anymore */ - pr_warning("PCI-DMA: More than 4GB of RAM and no IOMMU\n" - "falling back to iommu=soft.\n"); + pr_warn("PCI-DMA: More than 4GB of RAM and no IOMMU - falling back to iommu=soft\n"); return -1; } @@ -756,8 +753,7 @@ int __init gart_iommu_init(void) !gart_iommu_aperture || (no_agp && init_amd_gatt() < 0)) { if (max_pfn > MAX_DMA32_PFN) { - pr_warning("More than 4GB of memory but GART IOMMU not available.\n"); - pr_warning("falling back to iommu=soft.\n"); + pr_warn("More than 4GB of memory but GART IOMMU not available - falling back to iommu=soft\n"); } return 0; } diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c index 4261b3282ad9..37e9129da8b3 100644 --- a/arch/x86/kernel/apic/apic.c +++ b/arch/x86/kernel/apic/apic.c @@ -685,8 +685,8 @@ calibrate_by_pmtimer(long deltapm, long *delta, long *deltatsc) res = (((u64)deltapm) * mult) >> 22; do_div(res, 100); - pr_warning("APIC calibration not consistent " - "with PM-Timer: %ldms instead of 100ms\n",(long)res); + pr_warn("APIC calibration not consistent with PM-Timer: %ldms instead of 100ms\n", + (long)res); /* Correct the lapic counter value */ res = (((u64)(*delta)) * pm_100ms); @@ -805,7 +805,7 @@ static int __init calibrate_APIC_clock(void) */ if (lapic_timer_frequency < (100 / HZ)) { local_irq_enable(); - pr_warning("APIC frequency too slow, disabling apic timer\n"); + pr_warn("APIC frequency too slow, disabling apic timer\n"); return -1; } @@ -848,8 +848,8 @@ static int __init calibrate_APIC_clock(void) local_irq_enable(); if (levt->features & CLOCK_EVT_FEAT_DUMMY) { - pr_warning("APIC timer disabled due to verification failure\n"); - return -1; + pr_warn("APIC timer disabled due to verification failure\n"); + return -1; } return 0; @@ -923,7 +923,7 @@ static void local_apic_timer_interrupt(void) * spurious. */ if (!evt->event_handler) { - pr_warning("Spurious LAPIC timer interrupt on cpu %d\n", cpu); + pr_warn("Spurious LAPIC timer interrupt on cpu %d\n", cpu); /* Switch it off */ lapic_timer_shutdown(evt); return; @@ -1503,11 +1503,11 @@ static int __init setup_nox2apic(char *str) int apicid = native_apic_msr_read(APIC_ID); if (apicid >= 255) { - pr_warning("Apicid: %08x, cannot enforce nox2apic\n", -
[PATCH 19/35] drivers/input: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/input Prior to this patch, there were 8 uses of pr_warning and 17 uses of pr_warn in drivers/input Signed-off-by: Joe Perches--- drivers/input/gameport/gameport.c | 4 ++-- drivers/input/joystick/gamecon.c | 3 ++- drivers/input/misc/apanel.c | 3 ++- drivers/input/misc/xen-kbdfront.c | 8 drivers/input/serio/serio.c | 8 5 files changed, 14 insertions(+), 12 deletions(-) diff --git a/drivers/input/gameport/gameport.c b/drivers/input/gameport/gameport.c index 4a2a9e370be7..092cc4188b57 100644 --- a/drivers/input/gameport/gameport.c +++ b/drivers/input/gameport/gameport.c @@ -385,8 +385,8 @@ static int gameport_queue_event(void *object, struct module *owner, } if (!try_module_get(owner)) { - pr_warning("Can't get module reference, dropping event %d\n", - event_type); + pr_warn("Can't get module reference, dropping event %d\n", + event_type); kfree(event); retval = -EINVAL; goto out; diff --git a/drivers/input/joystick/gamecon.c b/drivers/input/joystick/gamecon.c index eae14d512353..c43f087a496d 100644 --- a/drivers/input/joystick/gamecon.c +++ b/drivers/input/joystick/gamecon.c @@ -870,7 +870,8 @@ static int gc_setup_pad(struct gc *gc, int idx, int pad_type) err = gc_n64_init_ff(input_dev, idx); if (err) { - pr_warning("Failed to initiate rumble for N64 device %d\n", idx); + pr_warn("Failed to initiate rumble for N64 device %d\n", + idx); goto err_free_dev; } diff --git a/drivers/input/misc/apanel.c b/drivers/input/misc/apanel.c index 53630afab606..aad1df04c854 100644 --- a/drivers/input/misc/apanel.c +++ b/drivers/input/misc/apanel.c @@ -314,7 +314,8 @@ static int __init apanel_init(void) if (devno >= APANEL_DEV_MAX) pr_notice(APANEL ": unknown device %u found\n", devno); else if (device_chip[devno] != CHIP_NONE) - pr_warning(APANEL ": duplicate entry for devno %u\n", devno); + pr_warn(APANEL ": duplicate entry for devno %u\n", + devno); else if (method != 1 && method != 2 && method != 4) { pr_notice(APANEL ": unknown method %u for devno %u\n", diff --git a/drivers/input/misc/xen-kbdfront.c b/drivers/input/misc/xen-kbdfront.c index 3900875dec10..1fd911d4fadf 100644 --- a/drivers/input/misc/xen-kbdfront.c +++ b/drivers/input/misc/xen-kbdfront.c @@ -84,8 +84,8 @@ static irqreturn_t input_handler(int rq, void *dev_id) input_report_key(dev, event->key.keycode, event->key.pressed); else - pr_warning("unhandled keycode 0x%x\n", - event->key.keycode); + pr_warn("unhandled keycode 0x%x\n", + event->key.keycode); break; case XENKBD_TYPE_POS: input_report_abs(dev, ABS_X, event->pos.abs_x); @@ -133,7 +133,7 @@ static int xenkbd_probe(struct xenbus_device *dev, ret = xenbus_write(XBT_NIL, dev->nodename, "request-abs-pointer", "1"); if (ret) { - pr_warning("xenkbd: can't request abs-pointer"); + pr_warn("xenkbd: can't request abs-pointer\n"); abs = 0; } } @@ -327,7 +327,7 @@ static void xenkbd_backend_changed(struct xenbus_device *dev, ret = xenbus_write(XBT_NIL, info->xbdev->nodename, "request-abs-pointer", "1"); if (ret) - pr_warning("xenkbd: can't request abs-pointer"); + pr_warn("xenkbd: can't request abs-pointer\n"); } xenbus_switch_state(dev, XenbusStateConnected); diff --git a/drivers/input/serio/serio.c b/drivers/input/serio/serio.c index 1ca7f551e2da..048ae748c4d1 100644 --- a/drivers/input/serio/serio.c +++ b/drivers/input/serio/serio.c @@ -285,8 +285,8 @@ static int serio_queue_event(void *object, struct module *owner, } if (!try_module_get(owner)) { - pr_warning("Can't get module reference, dropping event %d\n", - event_type); + pr_warn("Can't get module reference, dropping event %d\n", + event_type); kfree(event); retval = -EINVAL;
[PATCH 19/35] drivers/input: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/input Prior to this patch, there were 8 uses of pr_warning and 17 uses of pr_warn in drivers/input Signed-off-by: Joe Perches --- drivers/input/gameport/gameport.c | 4 ++-- drivers/input/joystick/gamecon.c | 3 ++- drivers/input/misc/apanel.c | 3 ++- drivers/input/misc/xen-kbdfront.c | 8 drivers/input/serio/serio.c | 8 5 files changed, 14 insertions(+), 12 deletions(-) diff --git a/drivers/input/gameport/gameport.c b/drivers/input/gameport/gameport.c index 4a2a9e370be7..092cc4188b57 100644 --- a/drivers/input/gameport/gameport.c +++ b/drivers/input/gameport/gameport.c @@ -385,8 +385,8 @@ static int gameport_queue_event(void *object, struct module *owner, } if (!try_module_get(owner)) { - pr_warning("Can't get module reference, dropping event %d\n", - event_type); + pr_warn("Can't get module reference, dropping event %d\n", + event_type); kfree(event); retval = -EINVAL; goto out; diff --git a/drivers/input/joystick/gamecon.c b/drivers/input/joystick/gamecon.c index eae14d512353..c43f087a496d 100644 --- a/drivers/input/joystick/gamecon.c +++ b/drivers/input/joystick/gamecon.c @@ -870,7 +870,8 @@ static int gc_setup_pad(struct gc *gc, int idx, int pad_type) err = gc_n64_init_ff(input_dev, idx); if (err) { - pr_warning("Failed to initiate rumble for N64 device %d\n", idx); + pr_warn("Failed to initiate rumble for N64 device %d\n", + idx); goto err_free_dev; } diff --git a/drivers/input/misc/apanel.c b/drivers/input/misc/apanel.c index 53630afab606..aad1df04c854 100644 --- a/drivers/input/misc/apanel.c +++ b/drivers/input/misc/apanel.c @@ -314,7 +314,8 @@ static int __init apanel_init(void) if (devno >= APANEL_DEV_MAX) pr_notice(APANEL ": unknown device %u found\n", devno); else if (device_chip[devno] != CHIP_NONE) - pr_warning(APANEL ": duplicate entry for devno %u\n", devno); + pr_warn(APANEL ": duplicate entry for devno %u\n", + devno); else if (method != 1 && method != 2 && method != 4) { pr_notice(APANEL ": unknown method %u for devno %u\n", diff --git a/drivers/input/misc/xen-kbdfront.c b/drivers/input/misc/xen-kbdfront.c index 3900875dec10..1fd911d4fadf 100644 --- a/drivers/input/misc/xen-kbdfront.c +++ b/drivers/input/misc/xen-kbdfront.c @@ -84,8 +84,8 @@ static irqreturn_t input_handler(int rq, void *dev_id) input_report_key(dev, event->key.keycode, event->key.pressed); else - pr_warning("unhandled keycode 0x%x\n", - event->key.keycode); + pr_warn("unhandled keycode 0x%x\n", + event->key.keycode); break; case XENKBD_TYPE_POS: input_report_abs(dev, ABS_X, event->pos.abs_x); @@ -133,7 +133,7 @@ static int xenkbd_probe(struct xenbus_device *dev, ret = xenbus_write(XBT_NIL, dev->nodename, "request-abs-pointer", "1"); if (ret) { - pr_warning("xenkbd: can't request abs-pointer"); + pr_warn("xenkbd: can't request abs-pointer\n"); abs = 0; } } @@ -327,7 +327,7 @@ static void xenkbd_backend_changed(struct xenbus_device *dev, ret = xenbus_write(XBT_NIL, info->xbdev->nodename, "request-abs-pointer", "1"); if (ret) - pr_warning("xenkbd: can't request abs-pointer"); + pr_warn("xenkbd: can't request abs-pointer\n"); } xenbus_switch_state(dev, XenbusStateConnected); diff --git a/drivers/input/serio/serio.c b/drivers/input/serio/serio.c index 1ca7f551e2da..048ae748c4d1 100644 --- a/drivers/input/serio/serio.c +++ b/drivers/input/serio/serio.c @@ -285,8 +285,8 @@ static int serio_queue_event(void *object, struct module *owner, } if (!try_module_get(owner)) { - pr_warning("Can't get module reference, dropping event %d\n", - event_type); + pr_warn("Can't get module reference, dropping event %d\n", + event_type); kfree(event); retval = -EINVAL; goto out;
[PATCH 12/35] gdrom: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/cdrom Prior to this patch, there were 2 uses of pr_warning and 0 uses of pr_warn in drivers/cdrom Signed-off-by: Joe Perches--- drivers/cdrom/gdrom.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/cdrom/gdrom.c b/drivers/cdrom/gdrom.c index 1372763a948f..19a644bec07d 100644 --- a/drivers/cdrom/gdrom.c +++ b/drivers/cdrom/gdrom.c @@ -773,7 +773,7 @@ static int probe_gdrom(struct platform_device *devptr) int err; /* Start the device */ if (gdrom_execute_diagnostic() != 1) { - pr_warning("ATA Probe for GDROM failed\n"); + pr_warn("ATA Probe for GDROM failed\n"); return -ENODEV; } /* Print out firmware ID */ @@ -838,7 +838,7 @@ static int probe_gdrom(struct platform_device *devptr) probe_fail_no_mem: unregister_blkdev(gdrom_major, GDROM_DEV_NAME); gdrom_major = 0; - pr_warning("Probe failed - error is 0x%X\n", err); + pr_warn("Probe failed - error is 0x%X\n", err); return err; } -- 2.10.0.rc2.1.g053435c
[PATCH 16/35] fmc: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/fmc Prior to this patch, there was 1 use of pr_warning and 0 uses of pr_warn in drivers/fmc Signed-off-by: Joe Perches--- drivers/fmc/fmc-fakedev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/fmc/fmc-fakedev.c b/drivers/fmc/fmc-fakedev.c index 941d0930969a..fc9ca763dd57 100644 --- a/drivers/fmc/fmc-fakedev.c +++ b/drivers/fmc/fmc-fakedev.c @@ -147,7 +147,7 @@ static void ff_work_fn(struct work_struct *work) ff = ff_dev_create(); if (IS_ERR(ff)) { - pr_warning("%s: can't re-create FMC devices\n", __func__); + pr_warn("%s: can't re-create FMC devices\n", __func__); return; } ret = fmc_device_register_n(ff->fmc, ff_nr_dev); -- 2.10.0.rc2.1.g053435c
[PATCH 16/35] fmc: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/fmc Prior to this patch, there was 1 use of pr_warning and 0 uses of pr_warn in drivers/fmc Signed-off-by: Joe Perches --- drivers/fmc/fmc-fakedev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/fmc/fmc-fakedev.c b/drivers/fmc/fmc-fakedev.c index 941d0930969a..fc9ca763dd57 100644 --- a/drivers/fmc/fmc-fakedev.c +++ b/drivers/fmc/fmc-fakedev.c @@ -147,7 +147,7 @@ static void ff_work_fn(struct work_struct *work) ff = ff_dev_create(); if (IS_ERR(ff)) { - pr_warning("%s: can't re-create FMC devices\n", __func__); + pr_warn("%s: can't re-create FMC devices\n", __func__); return; } ret = fmc_device_register_n(ff->fmc, ff_nr_dev); -- 2.10.0.rc2.1.g053435c
[PATCH 12/35] gdrom: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/cdrom Prior to this patch, there were 2 uses of pr_warning and 0 uses of pr_warn in drivers/cdrom Signed-off-by: Joe Perches --- drivers/cdrom/gdrom.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/cdrom/gdrom.c b/drivers/cdrom/gdrom.c index 1372763a948f..19a644bec07d 100644 --- a/drivers/cdrom/gdrom.c +++ b/drivers/cdrom/gdrom.c @@ -773,7 +773,7 @@ static int probe_gdrom(struct platform_device *devptr) int err; /* Start the device */ if (gdrom_execute_diagnostic() != 1) { - pr_warning("ATA Probe for GDROM failed\n"); + pr_warn("ATA Probe for GDROM failed\n"); return -ENODEV; } /* Print out firmware ID */ @@ -838,7 +838,7 @@ static int probe_gdrom(struct platform_device *devptr) probe_fail_no_mem: unregister_blkdev(gdrom_major, GDROM_DEV_NAME); gdrom_major = 0; - pr_warning("Probe failed - error is 0x%X\n", err); + pr_warn("Probe failed - error is 0x%X\n", err); return err; } -- 2.10.0.rc2.1.g053435c
Re: [PATCH 3/5] tpm_tis_spi: Check correct byte for wait state indicator
Am 17. Februar 2017 06:09:30 MEZ schrieb Christophe Ricard: >That's is correct, this is a mistake on my side and never saw it :-(. > >I guess it was possibly leading to "waste" at least 1 wait state on >some >TPMs. Unfortunately the 1 for indicating end of waitstates does only appear once so it actually rendered the driver non-functional - atleast with our tpms. > >Wouldn't it be better to merge that with #1 and update the comment >consequently? Yes, that's what I wanted to express in the cover letter, logically it makes sense to squash #1 and #3 - but reviewing it merged with #1 is quite hard since it "obfuscates" the problem - since too much stuff moves around. That's why I decided to split it - for easier review. Peter > > >On 16/02/2017 08:08, Peter Huewe wrote: >> Wait states are signaled in the last byte received from the TPM in >> response to the header, not the first byte. Check rx_buf[3] instead >of >> rx_buf[0]. >> >> Cc: >> Fixes: 0edbfea537d1 ("tpm/tpm_tis_spi: Add support for spi phy") >> Signed-off-by: Alexander Steffen >> Signed-off-by: Peter Huewe >> --- >> drivers/char/tpm/tpm_tis_spi.c | 40 >+--- >> 1 file changed, 21 insertions(+), 19 deletions(-) >> >> diff --git a/drivers/char/tpm/tpm_tis_spi.c >b/drivers/char/tpm/tpm_tis_spi.c >> index d782b9974c14..16938e2253d2 100644 >> --- a/drivers/char/tpm/tpm_tis_spi.c >> +++ b/drivers/char/tpm/tpm_tis_spi.c >> @@ -60,7 +60,7 @@ static int tpm_tis_spi_transfer(struct tpm_tis_data >*data, u32 addr, u8 len, >> u8 *buffer, u8 direction) >> { >> struct tpm_tis_spi_phy *phy = to_tpm_tis_spi_phy(data); >> -int ret, i; >> +int ret; >> struct spi_message m; >> struct spi_transfer spi_xfer = { >> .tx_buf = phy->tx_buf, >> @@ -85,25 +85,27 @@ static int tpm_tis_spi_transfer(struct >tpm_tis_data *data, u32 addr, u8 len, >> if (ret < 0) >> goto exit; >> >> -phy->tx_buf[0] = 0; >> - >> -/* According to TCG PTP specification, if there is no TPM present >at >> - * all, then the design has a weak pull-up on MISO. If a TPM is not >> - * present, a pull-up on MISO means that the SB controller sees a >1, >> - * and will latch in 0xFF on the read. >> - */ >> -for (i = 0; (phy->rx_buf[0] & 0x01) == 0 && i < TPM_RETRY; i++) { >> -spi_xfer.len = 1; >> -spi_message_init(); >> -spi_message_add_tail(_xfer, ); >> -ret = spi_sync_locked(phy->spi_device, ); >> -if (ret < 0) >> +if ((phy->rx_buf[3] & 0x01) == 0) { >> +// handle SPI wait states >> +int i; >> + >> +phy->tx_buf[0] = 0; >> + >> +for (i = 0; i < TPM_RETRY; i++) { >> +spi_xfer.len = 1; >> +spi_message_init(); >> +spi_message_add_tail(_xfer, ); >> +ret = spi_sync_locked(phy->spi_device, ); >> +if (ret < 0) >> +goto exit; >> +if (phy->rx_buf[0] & 0x01) >> +break; >> +} >> + >> +if (i == TPM_RETRY) { >> +ret = -ETIMEDOUT; >> goto exit; >> -} >> - >> -if (i == TPM_RETRY) { >> -ret = -ETIMEDOUT; >> -goto exit; >> +} >> } >> >> spi_xfer.cs_change = 0; -- Sent from my mobile
Re: [PATCH 3/5] tpm_tis_spi: Check correct byte for wait state indicator
Am 17. Februar 2017 06:09:30 MEZ schrieb Christophe Ricard : >That's is correct, this is a mistake on my side and never saw it :-(. > >I guess it was possibly leading to "waste" at least 1 wait state on >some >TPMs. Unfortunately the 1 for indicating end of waitstates does only appear once so it actually rendered the driver non-functional - atleast with our tpms. > >Wouldn't it be better to merge that with #1 and update the comment >consequently? Yes, that's what I wanted to express in the cover letter, logically it makes sense to squash #1 and #3 - but reviewing it merged with #1 is quite hard since it "obfuscates" the problem - since too much stuff moves around. That's why I decided to split it - for easier review. Peter > > >On 16/02/2017 08:08, Peter Huewe wrote: >> Wait states are signaled in the last byte received from the TPM in >> response to the header, not the first byte. Check rx_buf[3] instead >of >> rx_buf[0]. >> >> Cc: >> Fixes: 0edbfea537d1 ("tpm/tpm_tis_spi: Add support for spi phy") >> Signed-off-by: Alexander Steffen >> Signed-off-by: Peter Huewe >> --- >> drivers/char/tpm/tpm_tis_spi.c | 40 >+--- >> 1 file changed, 21 insertions(+), 19 deletions(-) >> >> diff --git a/drivers/char/tpm/tpm_tis_spi.c >b/drivers/char/tpm/tpm_tis_spi.c >> index d782b9974c14..16938e2253d2 100644 >> --- a/drivers/char/tpm/tpm_tis_spi.c >> +++ b/drivers/char/tpm/tpm_tis_spi.c >> @@ -60,7 +60,7 @@ static int tpm_tis_spi_transfer(struct tpm_tis_data >*data, u32 addr, u8 len, >> u8 *buffer, u8 direction) >> { >> struct tpm_tis_spi_phy *phy = to_tpm_tis_spi_phy(data); >> -int ret, i; >> +int ret; >> struct spi_message m; >> struct spi_transfer spi_xfer = { >> .tx_buf = phy->tx_buf, >> @@ -85,25 +85,27 @@ static int tpm_tis_spi_transfer(struct >tpm_tis_data *data, u32 addr, u8 len, >> if (ret < 0) >> goto exit; >> >> -phy->tx_buf[0] = 0; >> - >> -/* According to TCG PTP specification, if there is no TPM present >at >> - * all, then the design has a weak pull-up on MISO. If a TPM is not >> - * present, a pull-up on MISO means that the SB controller sees a >1, >> - * and will latch in 0xFF on the read. >> - */ >> -for (i = 0; (phy->rx_buf[0] & 0x01) == 0 && i < TPM_RETRY; i++) { >> -spi_xfer.len = 1; >> -spi_message_init(); >> -spi_message_add_tail(_xfer, ); >> -ret = spi_sync_locked(phy->spi_device, ); >> -if (ret < 0) >> +if ((phy->rx_buf[3] & 0x01) == 0) { >> +// handle SPI wait states >> +int i; >> + >> +phy->tx_buf[0] = 0; >> + >> +for (i = 0; i < TPM_RETRY; i++) { >> +spi_xfer.len = 1; >> +spi_message_init(); >> +spi_message_add_tail(_xfer, ); >> +ret = spi_sync_locked(phy->spi_device, ); >> +if (ret < 0) >> +goto exit; >> +if (phy->rx_buf[0] & 0x01) >> +break; >> +} >> + >> +if (i == TPM_RETRY) { >> +ret = -ETIMEDOUT; >> goto exit; >> -} >> - >> -if (i == TPM_RETRY) { >> -ret = -ETIMEDOUT; >> -goto exit; >> +} >> } >> >> spi_xfer.cs_change = 0; -- Sent from my mobile
[PATCH 22/35] drivers/media: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/media Prior to this patch, there was 1 use of pr_warning and 310 uses of pr_warn in drivers/media Signed-off-by: Joe Perches--- drivers/media/platform/sh_vou.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/platform/sh_vou.c b/drivers/media/platform/sh_vou.c index ef2a519bcd4c..992d61a8b961 100644 --- a/drivers/media/platform/sh_vou.c +++ b/drivers/media/platform/sh_vou.c @@ -813,8 +813,8 @@ static u32 sh_vou_ntsc_mode(enum sh_vou_bus_fmt bus_fmt) { switch (bus_fmt) { default: - pr_warning("%s(): Invalid bus-format code %d, using default 8-bit\n", - __func__, bus_fmt); + pr_warn("%s(): Invalid bus-format code %d, using default 8-bit\n", + __func__, bus_fmt); case SH_VOU_BUS_8BIT: return 1; case SH_VOU_BUS_16BIT: -- 2.10.0.rc2.1.g053435c
[PATCH 25/35] drivers/of: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/of Prior to this patch, there were 5 uses of pr_warning and 19 uses of pr_warn in drivers/of Signed-off-by: Joe Perches--- drivers/of/fdt.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c index e5ce4b59e162..b9b1dc75e05d 100644 --- a/drivers/of/fdt.c +++ b/drivers/of/fdt.c @@ -514,8 +514,8 @@ static void *__unflatten_device_tree(const void *blob, /* Second pass, do actual unflattening */ unflatten_dt_nodes(blob, mem, dad, mynodes); if (be32_to_cpup(mem + size) != 0xdeadbeef) - pr_warning("End of tree marker overwritten: %08x\n", - be32_to_cpup(mem + size)); + pr_warn("End of tree marker overwritten: %08x\n", + be32_to_cpup(mem + size)); if (detached && mynodes) { of_node_set_flag(*mynodes, OF_DETACHED); @@ -1133,25 +1133,25 @@ void __init __weak early_init_dt_add_memory_arch(u64 base, u64 size) size &= PAGE_MASK; if (base > MAX_MEMBLOCK_ADDR) { - pr_warning("Ignoring memory block 0x%llx - 0x%llx\n", - base, base + size); + pr_warn("Ignoring memory block 0x%llx - 0x%llx\n", + base, base + size); return; } if (base + size - 1 > MAX_MEMBLOCK_ADDR) { - pr_warning("Ignoring memory range 0x%llx - 0x%llx\n", - ((u64)MAX_MEMBLOCK_ADDR) + 1, base + size); + pr_warn("Ignoring memory range 0x%llx - 0x%llx\n", + ((u64)MAX_MEMBLOCK_ADDR) + 1, base + size); size = MAX_MEMBLOCK_ADDR - base + 1; } if (base + size < phys_offset) { - pr_warning("Ignoring memory block 0x%llx - 0x%llx\n", - base, base + size); + pr_warn("Ignoring memory block 0x%llx - 0x%llx\n", + base, base + size); return; } if (base < phys_offset) { - pr_warning("Ignoring memory range 0x%llx - 0x%llx\n", - base, phys_offset); + pr_warn("Ignoring memory range 0x%llx - 0x%llx\n", + base, phys_offset); size -= phys_offset - base; base = phys_offset; } -- 2.10.0.rc2.1.g053435c
[PATCH 22/35] drivers/media: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/media Prior to this patch, there was 1 use of pr_warning and 310 uses of pr_warn in drivers/media Signed-off-by: Joe Perches --- drivers/media/platform/sh_vou.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/platform/sh_vou.c b/drivers/media/platform/sh_vou.c index ef2a519bcd4c..992d61a8b961 100644 --- a/drivers/media/platform/sh_vou.c +++ b/drivers/media/platform/sh_vou.c @@ -813,8 +813,8 @@ static u32 sh_vou_ntsc_mode(enum sh_vou_bus_fmt bus_fmt) { switch (bus_fmt) { default: - pr_warning("%s(): Invalid bus-format code %d, using default 8-bit\n", - __func__, bus_fmt); + pr_warn("%s(): Invalid bus-format code %d, using default 8-bit\n", + __func__, bus_fmt); case SH_VOU_BUS_8BIT: return 1; case SH_VOU_BUS_16BIT: -- 2.10.0.rc2.1.g053435c
[PATCH 25/35] drivers/of: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/of Prior to this patch, there were 5 uses of pr_warning and 19 uses of pr_warn in drivers/of Signed-off-by: Joe Perches --- drivers/of/fdt.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c index e5ce4b59e162..b9b1dc75e05d 100644 --- a/drivers/of/fdt.c +++ b/drivers/of/fdt.c @@ -514,8 +514,8 @@ static void *__unflatten_device_tree(const void *blob, /* Second pass, do actual unflattening */ unflatten_dt_nodes(blob, mem, dad, mynodes); if (be32_to_cpup(mem + size) != 0xdeadbeef) - pr_warning("End of tree marker overwritten: %08x\n", - be32_to_cpup(mem + size)); + pr_warn("End of tree marker overwritten: %08x\n", + be32_to_cpup(mem + size)); if (detached && mynodes) { of_node_set_flag(*mynodes, OF_DETACHED); @@ -1133,25 +1133,25 @@ void __init __weak early_init_dt_add_memory_arch(u64 base, u64 size) size &= PAGE_MASK; if (base > MAX_MEMBLOCK_ADDR) { - pr_warning("Ignoring memory block 0x%llx - 0x%llx\n", - base, base + size); + pr_warn("Ignoring memory block 0x%llx - 0x%llx\n", + base, base + size); return; } if (base + size - 1 > MAX_MEMBLOCK_ADDR) { - pr_warning("Ignoring memory range 0x%llx - 0x%llx\n", - ((u64)MAX_MEMBLOCK_ADDR) + 1, base + size); + pr_warn("Ignoring memory range 0x%llx - 0x%llx\n", + ((u64)MAX_MEMBLOCK_ADDR) + 1, base + size); size = MAX_MEMBLOCK_ADDR - base + 1; } if (base + size < phys_offset) { - pr_warning("Ignoring memory block 0x%llx - 0x%llx\n", - base, base + size); + pr_warn("Ignoring memory block 0x%llx - 0x%llx\n", + base, base + size); return; } if (base < phys_offset) { - pr_warning("Ignoring memory range 0x%llx - 0x%llx\n", - base, phys_offset); + pr_warn("Ignoring memory range 0x%llx - 0x%llx\n", + base, phys_offset); size -= phys_offset - base; base = phys_offset; } -- 2.10.0.rc2.1.g053435c
[PATCH 17/35] drivers/gpu: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/gpu Prior to this patch, there were 15 uses of pr_warning and 20 uses of pr_warn in drivers/gpu Signed-off-by: Joe Perches--- drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 2 +- drivers/gpu/drm/amd/powerplay/inc/pp_debug.h | 2 +- drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c | 4 ++-- drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c | 14 +++--- drivers/gpu/drm/amd/powerplay/smumgr/polaris10_smc.c | 4 ++-- drivers/gpu/drm/amd/powerplay/smumgr/tonga_smc.c | 4 ++-- 6 files changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c index b1de9e8ccdbc..83266408634e 100644 --- a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c @@ -1535,7 +1535,7 @@ static int smu7_get_evv_voltages(struct pp_hwmgr *hwmgr) if (vddc >= 2000 || vddc == 0) return -EINVAL; } else { - pr_warning("failed to retrieving EVV voltage!\n"); + pr_warn("failed to retrieving EVV voltage!\n"); continue; } diff --git a/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h b/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h index 072880130cfb..f3f9ebb631a5 100644 --- a/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h +++ b/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h @@ -37,7 +37,7 @@ #define PP_ASSERT_WITH_CODE(cond, msg, code) \ do {\ if (!(cond)) { \ - pr_warning("%s\n", msg);\ + pr_warn("%s\n", msg); \ code; \ } \ } while (0) diff --git a/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c b/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c index 0f7a77b7312e..5450f5ef8e89 100644 --- a/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c +++ b/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c @@ -2131,7 +2131,7 @@ uint32_t fiji_get_offsetof(uint32_t type, uint32_t member) return offsetof(SMU73_Discrete_DpmTable, LowSclkInterruptThreshold); } } - pr_warning("can't get the offset of type %x member %x\n", type, member); + pr_warn("can't get the offset of type %x member %x\n", type, member); return 0; } @@ -2156,7 +2156,7 @@ uint32_t fiji_get_mac_definition(uint32_t value) return SMU73_MAX_LEVELS_MVDD; } - pr_warning("can't get the mac of %x\n", value); + pr_warn("can't get the mac of %x\n", value); return 0; } diff --git a/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c b/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c index ad82161df831..51adf04ab4b3 100644 --- a/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c +++ b/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c @@ -122,7 +122,7 @@ static void iceland_initialize_power_tune_defaults(struct pp_hwmgr *hwmgr) break; default: smu_data->power_tune_defaults = _iceland; - pr_warning("Unknown V.I. Device ID.\n"); + pr_warn("Unknown V.I. Device ID.\n"); break; } return; @@ -378,7 +378,7 @@ static int iceland_get_std_voltage_value_sidd(struct pp_hwmgr *hwmgr, return -EINVAL); if (NULL == hwmgr->dyn_state.cac_leakage_table) { - pr_warning("CAC Leakage Table does not exist, using vddc.\n"); + pr_warn("CAC Leakage Table does not exist, using vddc.\n"); return 0; } @@ -394,7 +394,7 @@ static int iceland_get_std_voltage_value_sidd(struct pp_hwmgr *hwmgr, *lo = hwmgr->dyn_state.cac_leakage_table->entries[v_index].Vddc * VOLTAGE_SCALE; *hi = (uint16_t)(hwmgr->dyn_state.cac_leakage_table->entries[v_index].Leakage * VOLTAGE_SCALE); } else { - pr_warning("Index from SCLK/VDDC Dependency Table exceeds the CAC Leakage Table index, using maximum index from CAC table.\n"); + pr_warn("Index from SCLK/VDDC Dependency Table exceeds the CAC Leakage Table index, using maximum index from CAC table.\n"); *lo = hwmgr->dyn_state.cac_leakage_table->entries[hwmgr->dyn_state.cac_leakage_table->count - 1].Vddc * VOLTAGE_SCALE; *hi =
[PATCH 17/35] drivers/gpu: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/gpu Prior to this patch, there were 15 uses of pr_warning and 20 uses of pr_warn in drivers/gpu Signed-off-by: Joe Perches --- drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 2 +- drivers/gpu/drm/amd/powerplay/inc/pp_debug.h | 2 +- drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c | 4 ++-- drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c | 14 +++--- drivers/gpu/drm/amd/powerplay/smumgr/polaris10_smc.c | 4 ++-- drivers/gpu/drm/amd/powerplay/smumgr/tonga_smc.c | 4 ++-- 6 files changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c index b1de9e8ccdbc..83266408634e 100644 --- a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c @@ -1535,7 +1535,7 @@ static int smu7_get_evv_voltages(struct pp_hwmgr *hwmgr) if (vddc >= 2000 || vddc == 0) return -EINVAL; } else { - pr_warning("failed to retrieving EVV voltage!\n"); + pr_warn("failed to retrieving EVV voltage!\n"); continue; } diff --git a/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h b/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h index 072880130cfb..f3f9ebb631a5 100644 --- a/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h +++ b/drivers/gpu/drm/amd/powerplay/inc/pp_debug.h @@ -37,7 +37,7 @@ #define PP_ASSERT_WITH_CODE(cond, msg, code) \ do {\ if (!(cond)) { \ - pr_warning("%s\n", msg);\ + pr_warn("%s\n", msg); \ code; \ } \ } while (0) diff --git a/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c b/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c index 0f7a77b7312e..5450f5ef8e89 100644 --- a/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c +++ b/drivers/gpu/drm/amd/powerplay/smumgr/fiji_smc.c @@ -2131,7 +2131,7 @@ uint32_t fiji_get_offsetof(uint32_t type, uint32_t member) return offsetof(SMU73_Discrete_DpmTable, LowSclkInterruptThreshold); } } - pr_warning("can't get the offset of type %x member %x\n", type, member); + pr_warn("can't get the offset of type %x member %x\n", type, member); return 0; } @@ -2156,7 +2156,7 @@ uint32_t fiji_get_mac_definition(uint32_t value) return SMU73_MAX_LEVELS_MVDD; } - pr_warning("can't get the mac of %x\n", value); + pr_warn("can't get the mac of %x\n", value); return 0; } diff --git a/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c b/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c index ad82161df831..51adf04ab4b3 100644 --- a/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c +++ b/drivers/gpu/drm/amd/powerplay/smumgr/iceland_smc.c @@ -122,7 +122,7 @@ static void iceland_initialize_power_tune_defaults(struct pp_hwmgr *hwmgr) break; default: smu_data->power_tune_defaults = _iceland; - pr_warning("Unknown V.I. Device ID.\n"); + pr_warn("Unknown V.I. Device ID.\n"); break; } return; @@ -378,7 +378,7 @@ static int iceland_get_std_voltage_value_sidd(struct pp_hwmgr *hwmgr, return -EINVAL); if (NULL == hwmgr->dyn_state.cac_leakage_table) { - pr_warning("CAC Leakage Table does not exist, using vddc.\n"); + pr_warn("CAC Leakage Table does not exist, using vddc.\n"); return 0; } @@ -394,7 +394,7 @@ static int iceland_get_std_voltage_value_sidd(struct pp_hwmgr *hwmgr, *lo = hwmgr->dyn_state.cac_leakage_table->entries[v_index].Vddc * VOLTAGE_SCALE; *hi = (uint16_t)(hwmgr->dyn_state.cac_leakage_table->entries[v_index].Leakage * VOLTAGE_SCALE); } else { - pr_warning("Index from SCLK/VDDC Dependency Table exceeds the CAC Leakage Table index, using maximum index from CAC table.\n"); + pr_warn("Index from SCLK/VDDC Dependency Table exceeds the CAC Leakage Table index, using maximum index from CAC table.\n"); *lo = hwmgr->dyn_state.cac_leakage_table->entries[hwmgr->dyn_state.cac_leakage_table->count - 1].Vddc * VOLTAGE_SCALE; *hi = (uint16_t)(hwmgr->dyn_state.cac_leakage_table->entries[hwmgr->dyn_state.cac_leakage_table->count - 1].Leakage
[PATCH 23/35] drivers/mfd: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/mfd Prior to this patch, there were 4 uses of pr_warning and 9 uses of pr_warn in drivers/mfd Signed-off-by: Joe Perches--- drivers/mfd/db8500-prcmu.c | 2 +- drivers/mfd/sta2x11-mfd.c | 4 ++-- drivers/mfd/twl4030-power.c | 7 ++- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/drivers/mfd/db8500-prcmu.c b/drivers/mfd/db8500-prcmu.c index ca38a6a14110..5c739ac752e8 100644 --- a/drivers/mfd/db8500-prcmu.c +++ b/drivers/mfd/db8500-prcmu.c @@ -2377,7 +2377,7 @@ static void ack_dbb_wakeup(void) static inline void print_unknown_header_warning(u8 n, u8 header) { - pr_warning("prcmu: Unknown message header (%d) in mailbox %d.\n", + pr_warn("prcmu: Unknown message header (%d) in mailbox %d\n", header, n); } diff --git a/drivers/mfd/sta2x11-mfd.c b/drivers/mfd/sta2x11-mfd.c index 9292202039ee..3aeafa228baf 100644 --- a/drivers/mfd/sta2x11-mfd.c +++ b/drivers/mfd/sta2x11-mfd.c @@ -60,8 +60,8 @@ static struct sta2x11_mfd *sta2x11_mfd_find(struct pci_dev *pdev) struct sta2x11_mfd *mfd; if (!pdev && !list_empty(_mfd_list)) { - pr_warning("%s: Unspecified device, " - "using first instance\n", __func__); + pr_warn("%s: Unspecified device, using first instance\n", + __func__); return list_entry(sta2x11_mfd_list.next, struct sta2x11_mfd, list); } diff --git a/drivers/mfd/twl4030-power.c b/drivers/mfd/twl4030-power.c index 1beb722f6080..8be023ba8e3e 100644 --- a/drivers/mfd/twl4030-power.c +++ b/drivers/mfd/twl4030-power.c @@ -502,9 +502,7 @@ static int load_twl4030_script(const struct twl4030_power_data *pdata, } if (tscript->flags & TWL4030_SLEEP_SCRIPT) { if (!order) - pr_warning("TWL4030: Bad order of scripts (sleep "\ - "script before wakeup) Leads to boot"\ - "failure on some boards\n"); + pr_warn("TWL4030: Bad order of scripts (sleep script before wakeup) Leads to boot failure on some boards\n"); err = twl4030_config_sleep_sequence(address); } out: @@ -929,8 +927,7 @@ static int twl4030_power_probe(struct platform_device *pdev) err = twl_i2c_read_u8(TWL_MODULE_PM_MASTER, , TWL4030_PM_MASTER_CFG_P123_TRANSITION); if (err) { - pr_warning("TWL4030 Unable to read registers\n"); - + pr_warn("TWL4030 Unable to read registers\n"); } else if (!(val & SEQ_OFFSYNC)) { val |= SEQ_OFFSYNC; err = twl_i2c_write_u8(TWL_MODULE_PM_MASTER, val, -- 2.10.0.rc2.1.g053435c
[PATCH 23/35] drivers/mfd: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/mfd Prior to this patch, there were 4 uses of pr_warning and 9 uses of pr_warn in drivers/mfd Signed-off-by: Joe Perches --- drivers/mfd/db8500-prcmu.c | 2 +- drivers/mfd/sta2x11-mfd.c | 4 ++-- drivers/mfd/twl4030-power.c | 7 ++- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/drivers/mfd/db8500-prcmu.c b/drivers/mfd/db8500-prcmu.c index ca38a6a14110..5c739ac752e8 100644 --- a/drivers/mfd/db8500-prcmu.c +++ b/drivers/mfd/db8500-prcmu.c @@ -2377,7 +2377,7 @@ static void ack_dbb_wakeup(void) static inline void print_unknown_header_warning(u8 n, u8 header) { - pr_warning("prcmu: Unknown message header (%d) in mailbox %d.\n", + pr_warn("prcmu: Unknown message header (%d) in mailbox %d\n", header, n); } diff --git a/drivers/mfd/sta2x11-mfd.c b/drivers/mfd/sta2x11-mfd.c index 9292202039ee..3aeafa228baf 100644 --- a/drivers/mfd/sta2x11-mfd.c +++ b/drivers/mfd/sta2x11-mfd.c @@ -60,8 +60,8 @@ static struct sta2x11_mfd *sta2x11_mfd_find(struct pci_dev *pdev) struct sta2x11_mfd *mfd; if (!pdev && !list_empty(_mfd_list)) { - pr_warning("%s: Unspecified device, " - "using first instance\n", __func__); + pr_warn("%s: Unspecified device, using first instance\n", + __func__); return list_entry(sta2x11_mfd_list.next, struct sta2x11_mfd, list); } diff --git a/drivers/mfd/twl4030-power.c b/drivers/mfd/twl4030-power.c index 1beb722f6080..8be023ba8e3e 100644 --- a/drivers/mfd/twl4030-power.c +++ b/drivers/mfd/twl4030-power.c @@ -502,9 +502,7 @@ static int load_twl4030_script(const struct twl4030_power_data *pdata, } if (tscript->flags & TWL4030_SLEEP_SCRIPT) { if (!order) - pr_warning("TWL4030: Bad order of scripts (sleep "\ - "script before wakeup) Leads to boot"\ - "failure on some boards\n"); + pr_warn("TWL4030: Bad order of scripts (sleep script before wakeup) Leads to boot failure on some boards\n"); err = twl4030_config_sleep_sequence(address); } out: @@ -929,8 +927,7 @@ static int twl4030_power_probe(struct platform_device *pdev) err = twl_i2c_read_u8(TWL_MODULE_PM_MASTER, , TWL4030_PM_MASTER_CFG_P123_TRANSITION); if (err) { - pr_warning("TWL4030 Unable to read registers\n"); - + pr_warn("TWL4030 Unable to read registers\n"); } else if (!(val & SEQ_OFFSYNC)) { val |= SEQ_OFFSYNC; err = twl_i2c_write_u8(TWL_MODULE_PM_MASTER, val, -- 2.10.0.rc2.1.g053435c
[PATCH 33/35] kernel/trace: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for kernel/trace Prior to this patch, there were 2 uses of pr_warning and 79 uses of pr_warn in kernel/trace Signed-off-by: Joe Perches--- kernel/trace/trace_benchmark.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/trace/trace_benchmark.c b/kernel/trace/trace_benchmark.c index e49fbe901cfc..483e8b3fcb27 100644 --- a/kernel/trace/trace_benchmark.c +++ b/kernel/trace/trace_benchmark.c @@ -169,14 +169,14 @@ static int benchmark_event_kthread(void *arg) int trace_benchmark_reg(void) { if (!ok_to_run) { - pr_warning("trace benchmark cannot be started via kernel command line\n"); + pr_warn("trace benchmark cannot be started via kernel command line\n"); return -EBUSY; } bm_event_thread = kthread_run(benchmark_event_kthread, NULL, "event_benchmark"); if (IS_ERR(bm_event_thread)) { - pr_warning("trace benchmark failed to create kernel thread\n"); + pr_warn("trace benchmark failed to create kernel thread\n"); return PTR_ERR(bm_event_thread); } -- 2.10.0.rc2.1.g053435c
[PATCH 33/35] kernel/trace: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for kernel/trace Prior to this patch, there were 2 uses of pr_warning and 79 uses of pr_warn in kernel/trace Signed-off-by: Joe Perches --- kernel/trace/trace_benchmark.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/trace/trace_benchmark.c b/kernel/trace/trace_benchmark.c index e49fbe901cfc..483e8b3fcb27 100644 --- a/kernel/trace/trace_benchmark.c +++ b/kernel/trace/trace_benchmark.c @@ -169,14 +169,14 @@ static int benchmark_event_kthread(void *arg) int trace_benchmark_reg(void) { if (!ok_to_run) { - pr_warning("trace benchmark cannot be started via kernel command line\n"); + pr_warn("trace benchmark cannot be started via kernel command line\n"); return -EBUSY; } bm_event_thread = kthread_run(benchmark_event_kthread, NULL, "event_benchmark"); if (IS_ERR(bm_event_thread)) { - pr_warning("trace benchmark failed to create kernel thread\n"); + pr_warn("trace benchmark failed to create kernel thread\n"); return PTR_ERR(bm_event_thread); } -- 2.10.0.rc2.1.g053435c
[PATCH 30/35] drivers/sh: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/sh Prior to this patch, there was 1 use of pr_warning and 0 uses of pr_warn in drivers/sh Signed-off-by: Joe Perches--- drivers/sh/intc/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/sh/intc/core.c b/drivers/sh/intc/core.c index 8e72bcbd3d6d..2258597f354a 100644 --- a/drivers/sh/intc/core.c +++ b/drivers/sh/intc/core.c @@ -100,8 +100,8 @@ static void __init intc_register_irq(struct intc_desc *desc, primary = 1; if (!data[0] && !data[1]) - pr_warning("missing unique irq mask for irq %d (vect 0x%04x)\n", - irq, irq2evt(irq)); + pr_warn("missing unique irq mask for irq %d (vect 0x%04x)\n", + irq, irq2evt(irq)); data[0] = data[0] ? data[0] : intc_get_mask_handle(desc, d, enum_id, 1); data[1] = data[1] ? data[1] : intc_get_prio_handle(desc, d, enum_id, 1); -- 2.10.0.rc2.1.g053435c
Re: [PATCH 00/10] fujitsu-laptop: renames and cleanups
> On Fri, Feb 17, 2017 at 01:38:04PM +1030, Jonathan Woithe wrote: > > On Thu, Feb 16, 2017 at 06:57:08PM -0800, Darren Hart wrote: > > > On Fri, Feb 10, 2017 at 02:42:00AM +0200, Andy Shevchenko wrote: > > > > On Fri, Feb 10, 2017 at 2:16 AM, Jonathan Woithe> > > > wrote: > > > > > On Wed, Feb 08, 2017 at 02:46:23PM +0100, Micha?? K??pie?? wrote: > > > > > > > > > In summary, I see no issues with this patch series which provides a > > > > > much > > > > > needed clean up of the code and naming conventions within the > > > > > fujitsu-laptop > > > > > driver. I'm happy for this series (patches 1-10/10) to be applied. > > > > > > > > > > Signed-off-by: Jonathan Woithe > > > > > > > > I have noticed people start using SoB for the code they are > > > > maintaining w/o sending any pull requests. > > > > It is okay, but there is, as Wolfram pointed, a downside for patchwork > > > > users. Patchwork is tracking tags (A/R/T) which by a glance allows to > > > > see what patches are acked/reviewed/tested. > > > > > > Signed-off-by tracks the path the code takes from author to mainline. If > > > you are > > > not the author or committing it to a tree followed by a pull-request, the > > > correct tag is "Reviewed-by". > > > > Yes, of course - I clearly had a brain fade back there. Having said that, > > in the past I've used "Acked-by" intead of "Reviewed-by". > > :-) > > > Do you want me to continue to use Acked-by, or should I switch to > > Reviewed-by? > > These tags do have different meanings, and have come up at Kernel Summit the > last couple of years. My interpretation of those discussions is: > > Acked-by: I have no objection to this patch, but I didn't really give it a > thorough review. I trust your judgement. e.g. minor change to your driver to > support a subsystem API change. These are of very little value. > > Reviewed-by: I have carefully reviewed this patch and would like it to be > applied. This should usually come with some sort of commentary describing the > level of review or an area you focused on. This is what we would like to see > from all of our driver maintainers. These are high value. > > Linus *really* dislikes one line acked by's, and only *slightly* more so than > one line reviewed by's. :-) This is really useful information and I think it does not deserve to be forgotten in a mailing list archive. If this is indeed the status quo, Documentation/process/submitting-patches.rst could use some love. Here is what it currently says: > Acked-by: is often used by the maintainer of the affected code when that > maintainer neither contributed to nor forwarded the patch. My short experience with the x86 platform driver subsystem is consistent with that. The informal rule I inferred from mailing list discussions is that Acked-by: means the maintainer has reviewed the patch and sees no objections to it being applied. Granted, Documentation/process/submitting-patches.rst also states that: > Acked-by: does not necessarily indicate acknowledgement of the entire patch. > For example, if a patch affects multiple subsystems and has an Acked-by: from > one subsystem maintainer then this usually indicates acknowledgement of just > the part which affects that maintainer's code. Judgement should be used here. > When in doubt people should refer to the original discussion in the mailing > list archives. And indeed, that is also true, especially for patch series affecting multiple subsystems. However, while the meaning of Reviewed-by: is described very thoroughly in that same document, I cannot recall a single case of a patch series affecting a single driver that would get a Reviewed-by: _from the maintainer_. Let alone a Reviewed-by: with a description of review depth. Perhaps I have read too little threads (or the wrong ones) :) With time, I have also grown to believe that one of the differences between Acked-by: and Reviewed-by: is that anyone interested can offer their Reviewed-by: while Acked-by: is reserved for driver maintainers. Perhaps this is all material for a "falsehoods kernel developers believe about commit tags"-type article ;) -- Best regards, Michał Kępień
[PATCH 30/35] drivers/sh: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/sh Prior to this patch, there was 1 use of pr_warning and 0 uses of pr_warn in drivers/sh Signed-off-by: Joe Perches --- drivers/sh/intc/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/sh/intc/core.c b/drivers/sh/intc/core.c index 8e72bcbd3d6d..2258597f354a 100644 --- a/drivers/sh/intc/core.c +++ b/drivers/sh/intc/core.c @@ -100,8 +100,8 @@ static void __init intc_register_irq(struct intc_desc *desc, primary = 1; if (!data[0] && !data[1]) - pr_warning("missing unique irq mask for irq %d (vect 0x%04x)\n", - irq, irq2evt(irq)); + pr_warn("missing unique irq mask for irq %d (vect 0x%04x)\n", + irq, irq2evt(irq)); data[0] = data[0] ? data[0] : intc_get_mask_handle(desc, d, enum_id, 1); data[1] = data[1] ? data[1] : intc_get_prio_handle(desc, d, enum_id, 1); -- 2.10.0.rc2.1.g053435c
Re: [PATCH 00/10] fujitsu-laptop: renames and cleanups
> On Fri, Feb 17, 2017 at 01:38:04PM +1030, Jonathan Woithe wrote: > > On Thu, Feb 16, 2017 at 06:57:08PM -0800, Darren Hart wrote: > > > On Fri, Feb 10, 2017 at 02:42:00AM +0200, Andy Shevchenko wrote: > > > > On Fri, Feb 10, 2017 at 2:16 AM, Jonathan Woithe > > > > wrote: > > > > > On Wed, Feb 08, 2017 at 02:46:23PM +0100, Micha?? K??pie?? wrote: > > > > > > > > > In summary, I see no issues with this patch series which provides a > > > > > much > > > > > needed clean up of the code and naming conventions within the > > > > > fujitsu-laptop > > > > > driver. I'm happy for this series (patches 1-10/10) to be applied. > > > > > > > > > > Signed-off-by: Jonathan Woithe > > > > > > > > I have noticed people start using SoB for the code they are > > > > maintaining w/o sending any pull requests. > > > > It is okay, but there is, as Wolfram pointed, a downside for patchwork > > > > users. Patchwork is tracking tags (A/R/T) which by a glance allows to > > > > see what patches are acked/reviewed/tested. > > > > > > Signed-off-by tracks the path the code takes from author to mainline. If > > > you are > > > not the author or committing it to a tree followed by a pull-request, the > > > correct tag is "Reviewed-by". > > > > Yes, of course - I clearly had a brain fade back there. Having said that, > > in the past I've used "Acked-by" intead of "Reviewed-by". > > :-) > > > Do you want me to continue to use Acked-by, or should I switch to > > Reviewed-by? > > These tags do have different meanings, and have come up at Kernel Summit the > last couple of years. My interpretation of those discussions is: > > Acked-by: I have no objection to this patch, but I didn't really give it a > thorough review. I trust your judgement. e.g. minor change to your driver to > support a subsystem API change. These are of very little value. > > Reviewed-by: I have carefully reviewed this patch and would like it to be > applied. This should usually come with some sort of commentary describing the > level of review or an area you focused on. This is what we would like to see > from all of our driver maintainers. These are high value. > > Linus *really* dislikes one line acked by's, and only *slightly* more so than > one line reviewed by's. :-) This is really useful information and I think it does not deserve to be forgotten in a mailing list archive. If this is indeed the status quo, Documentation/process/submitting-patches.rst could use some love. Here is what it currently says: > Acked-by: is often used by the maintainer of the affected code when that > maintainer neither contributed to nor forwarded the patch. My short experience with the x86 platform driver subsystem is consistent with that. The informal rule I inferred from mailing list discussions is that Acked-by: means the maintainer has reviewed the patch and sees no objections to it being applied. Granted, Documentation/process/submitting-patches.rst also states that: > Acked-by: does not necessarily indicate acknowledgement of the entire patch. > For example, if a patch affects multiple subsystems and has an Acked-by: from > one subsystem maintainer then this usually indicates acknowledgement of just > the part which affects that maintainer's code. Judgement should be used here. > When in doubt people should refer to the original discussion in the mailing > list archives. And indeed, that is also true, especially for patch series affecting multiple subsystems. However, while the meaning of Reviewed-by: is described very thoroughly in that same document, I cannot recall a single case of a patch series affecting a single driver that would get a Reviewed-by: _from the maintainer_. Let alone a Reviewed-by: with a description of review depth. Perhaps I have read too little threads (or the wrong ones) :) With time, I have also grown to believe that one of the differences between Acked-by: and Reviewed-by: is that anyone interested can offer their Reviewed-by: while Acked-by: is reserved for driver maintainers. Perhaps this is all material for a "falsehoods kernel developers believe about commit tags"-type article ;) -- Best regards, Michał Kępień
[PATCH 24/35] drivers/mtd: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/mtd Prior to this patch, there were 7 uses of pr_warning and 31 uses of pr_warn in drivers/mtd Signed-off-by: Joe Perches--- drivers/mtd/chips/cfi_cmdset_0002.c | 12 drivers/mtd/nand/cmx270_nand.c | 4 ++-- drivers/mtd/ofpart.c| 4 ++-- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/drivers/mtd/chips/cfi_cmdset_0002.c b/drivers/mtd/chips/cfi_cmdset_0002.c index 9dca881bb378..56aa6b75213d 100644 --- a/drivers/mtd/chips/cfi_cmdset_0002.c +++ b/drivers/mtd/chips/cfi_cmdset_0002.c @@ -323,7 +323,8 @@ static void fixup_sst38vf640x_sectorsize(struct mtd_info *mtd) * it should report a size of 8KBytes (0x0020*256). */ cfi->cfiq->EraseRegionInfo[0] = 0x002003ff; - pr_warning("%s: Bad 38VF640x CFI data; adjusting sector size from 64 to 8KiB\n", mtd->name); + pr_warn("%s: Bad 38VF640x CFI data; adjusting sector size from 64 to 8KiB\n", + mtd->name); } static void fixup_s29gl064n_sectors(struct mtd_info *mtd) @@ -333,7 +334,8 @@ static void fixup_s29gl064n_sectors(struct mtd_info *mtd) if ((cfi->cfiq->EraseRegionInfo[0] & 0x) == 0x003f) { cfi->cfiq->EraseRegionInfo[0] |= 0x0040; - pr_warning("%s: Bad S29GL064N CFI data; adjust from 64 to 128 sectors\n", mtd->name); + pr_warn("%s: Bad S29GL064N CFI data; adjust from 64 to 128 sectors\n", + mtd->name); } } @@ -344,7 +346,8 @@ static void fixup_s29gl032n_sectors(struct mtd_info *mtd) if ((cfi->cfiq->EraseRegionInfo[1] & 0x) == 0x007e) { cfi->cfiq->EraseRegionInfo[1] &= ~0x0040; - pr_warning("%s: Bad S29GL032N CFI data; adjust from 127 to 63 sectors\n", mtd->name); + pr_warn("%s: Bad S29GL032N CFI data; adjust from 127 to 63 sectors\n", + mtd->name); } } @@ -358,7 +361,8 @@ static void fixup_s29ns512p_sectors(struct mtd_info *mtd) * which is not permitted by CFI. */ cfi->cfiq->EraseRegionInfo[0] = 0x020001ff; - pr_warning("%s: Bad S29NS512P CFI data; adjust to 512 sectors\n", mtd->name); + pr_warn("%s: Bad S29NS512P CFI data; adjust to 512 sectors\n", + mtd->name); } /* Used to fix CFI-Tables of chips without Extended Query Tables */ diff --git a/drivers/mtd/nand/cmx270_nand.c b/drivers/mtd/nand/cmx270_nand.c index 226ac0bcafc6..949b9400dcb7 100644 --- a/drivers/mtd/nand/cmx270_nand.c +++ b/drivers/mtd/nand/cmx270_nand.c @@ -145,7 +145,7 @@ static int __init cmx270_init(void) ret = gpio_request(GPIO_NAND_CS, "NAND CS"); if (ret) { - pr_warning("CM-X270: failed to request NAND CS gpio\n"); + pr_warn("CM-X270: failed to request NAND CS gpio\n"); return ret; } @@ -153,7 +153,7 @@ static int __init cmx270_init(void) ret = gpio_request(GPIO_NAND_RB, "NAND R/B"); if (ret) { - pr_warning("CM-X270: failed to request NAND R/B gpio\n"); + pr_warn("CM-X270: failed to request NAND R/B gpio\n"); goto err_gpio_request; } diff --git a/drivers/mtd/ofpart.c b/drivers/mtd/ofpart.c index 464470122493..2861c7079d7b 100644 --- a/drivers/mtd/ofpart.c +++ b/drivers/mtd/ofpart.c @@ -166,8 +166,8 @@ static int parse_ofoldpart_partitions(struct mtd_info *master, if (!part) return 0; /* No partitions found */ - pr_warning("Device tree uses obsolete partition map binding: %s\n", - dp->full_name); + pr_warn("Device tree uses obsolete partition map binding: %s\n", + dp->full_name); nr_parts = plen / sizeof(part[0]); -- 2.10.0.rc2.1.g053435c
[PATCH 28/35] drivers/rapidio: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/rapidio Prior to this patch, there was 1 use of pr_warning and 2 uses of pr_warn in drivers/rapidio Signed-off-by: Joe Perches--- drivers/rapidio/rio-sysfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/rapidio/rio-sysfs.c b/drivers/rapidio/rio-sysfs.c index eda41563d06d..945c4b1d9717 100644 --- a/drivers/rapidio/rio-sysfs.c +++ b/drivers/rapidio/rio-sysfs.c @@ -278,8 +278,8 @@ int rio_create_sysfs_dev_files(struct rio_dev *rdev) } if (err) - pr_warning("RIO: Failed to create attribute file(s) for %s\n", - rio_name(rdev)); + pr_warn("RIO: Failed to create attribute file(s) for %s\n", + rio_name(rdev)); return err; } -- 2.10.0.rc2.1.g053435c
[PATCH 24/35] drivers/mtd: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/mtd Prior to this patch, there were 7 uses of pr_warning and 31 uses of pr_warn in drivers/mtd Signed-off-by: Joe Perches --- drivers/mtd/chips/cfi_cmdset_0002.c | 12 drivers/mtd/nand/cmx270_nand.c | 4 ++-- drivers/mtd/ofpart.c| 4 ++-- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/drivers/mtd/chips/cfi_cmdset_0002.c b/drivers/mtd/chips/cfi_cmdset_0002.c index 9dca881bb378..56aa6b75213d 100644 --- a/drivers/mtd/chips/cfi_cmdset_0002.c +++ b/drivers/mtd/chips/cfi_cmdset_0002.c @@ -323,7 +323,8 @@ static void fixup_sst38vf640x_sectorsize(struct mtd_info *mtd) * it should report a size of 8KBytes (0x0020*256). */ cfi->cfiq->EraseRegionInfo[0] = 0x002003ff; - pr_warning("%s: Bad 38VF640x CFI data; adjusting sector size from 64 to 8KiB\n", mtd->name); + pr_warn("%s: Bad 38VF640x CFI data; adjusting sector size from 64 to 8KiB\n", + mtd->name); } static void fixup_s29gl064n_sectors(struct mtd_info *mtd) @@ -333,7 +334,8 @@ static void fixup_s29gl064n_sectors(struct mtd_info *mtd) if ((cfi->cfiq->EraseRegionInfo[0] & 0x) == 0x003f) { cfi->cfiq->EraseRegionInfo[0] |= 0x0040; - pr_warning("%s: Bad S29GL064N CFI data; adjust from 64 to 128 sectors\n", mtd->name); + pr_warn("%s: Bad S29GL064N CFI data; adjust from 64 to 128 sectors\n", + mtd->name); } } @@ -344,7 +346,8 @@ static void fixup_s29gl032n_sectors(struct mtd_info *mtd) if ((cfi->cfiq->EraseRegionInfo[1] & 0x) == 0x007e) { cfi->cfiq->EraseRegionInfo[1] &= ~0x0040; - pr_warning("%s: Bad S29GL032N CFI data; adjust from 127 to 63 sectors\n", mtd->name); + pr_warn("%s: Bad S29GL032N CFI data; adjust from 127 to 63 sectors\n", + mtd->name); } } @@ -358,7 +361,8 @@ static void fixup_s29ns512p_sectors(struct mtd_info *mtd) * which is not permitted by CFI. */ cfi->cfiq->EraseRegionInfo[0] = 0x020001ff; - pr_warning("%s: Bad S29NS512P CFI data; adjust to 512 sectors\n", mtd->name); + pr_warn("%s: Bad S29NS512P CFI data; adjust to 512 sectors\n", + mtd->name); } /* Used to fix CFI-Tables of chips without Extended Query Tables */ diff --git a/drivers/mtd/nand/cmx270_nand.c b/drivers/mtd/nand/cmx270_nand.c index 226ac0bcafc6..949b9400dcb7 100644 --- a/drivers/mtd/nand/cmx270_nand.c +++ b/drivers/mtd/nand/cmx270_nand.c @@ -145,7 +145,7 @@ static int __init cmx270_init(void) ret = gpio_request(GPIO_NAND_CS, "NAND CS"); if (ret) { - pr_warning("CM-X270: failed to request NAND CS gpio\n"); + pr_warn("CM-X270: failed to request NAND CS gpio\n"); return ret; } @@ -153,7 +153,7 @@ static int __init cmx270_init(void) ret = gpio_request(GPIO_NAND_RB, "NAND R/B"); if (ret) { - pr_warning("CM-X270: failed to request NAND R/B gpio\n"); + pr_warn("CM-X270: failed to request NAND R/B gpio\n"); goto err_gpio_request; } diff --git a/drivers/mtd/ofpart.c b/drivers/mtd/ofpart.c index 464470122493..2861c7079d7b 100644 --- a/drivers/mtd/ofpart.c +++ b/drivers/mtd/ofpart.c @@ -166,8 +166,8 @@ static int parse_ofoldpart_partitions(struct mtd_info *master, if (!part) return 0; /* No partitions found */ - pr_warning("Device tree uses obsolete partition map binding: %s\n", - dp->full_name); + pr_warn("Device tree uses obsolete partition map binding: %s\n", + dp->full_name); nr_parts = plen / sizeof(part[0]); -- 2.10.0.rc2.1.g053435c
[PATCH 28/35] drivers/rapidio: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/rapidio Prior to this patch, there was 1 use of pr_warning and 2 uses of pr_warn in drivers/rapidio Signed-off-by: Joe Perches --- drivers/rapidio/rio-sysfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/rapidio/rio-sysfs.c b/drivers/rapidio/rio-sysfs.c index eda41563d06d..945c4b1d9717 100644 --- a/drivers/rapidio/rio-sysfs.c +++ b/drivers/rapidio/rio-sysfs.c @@ -278,8 +278,8 @@ int rio_create_sysfs_dev_files(struct rio_dev *rdev) } if (err) - pr_warning("RIO: Failed to create attribute file(s) for %s\n", - rio_name(rdev)); + pr_warn("RIO: Failed to create attribute file(s) for %s\n", + rio_name(rdev)); return err; } -- 2.10.0.rc2.1.g053435c
[PATCH 34/35] lib: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for lib Prior to this patch, there were 2 uses of pr_warning and 59 uses of pr_warn in lib Signed-off-by: Joe Perches--- lib/cpu_rmap.c | 2 +- lib/dma-debug.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/cpu_rmap.c b/lib/cpu_rmap.c index f610b2a10b3e..fa9778e57eab 100644 --- a/lib/cpu_rmap.c +++ b/lib/cpu_rmap.c @@ -258,7 +258,7 @@ irq_cpu_rmap_notify(struct irq_affinity_notify *notify, const cpumask_t *mask) rc = cpu_rmap_update(glue->rmap, glue->index, mask); if (rc) - pr_warning("irq_cpu_rmap_notify: update failed: %d\n", rc); + pr_warn("irq_cpu_rmap_notify: update failed: %d\n", rc); } /** diff --git a/lib/dma-debug.c b/lib/dma-debug.c index 60c57ec936db..bccb92a85268 100644 --- a/lib/dma-debug.c +++ b/lib/dma-debug.c @@ -176,7 +176,7 @@ static inline void dump_entry_trace(struct dma_debug_entry *entry) { #ifdef CONFIG_STACKTRACE if (entry) { - pr_warning("Mapped at:\n"); + pr_warn("Mapped at:\n"); print_stack_trace(>stacktrace, 0); } #endif -- 2.10.0.rc2.1.g053435c
[PATCH 27/35] drivers/platform: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/platform Prior to this patch, there were 7 uses of pr_warning and 108 uses of pr_warn in drivers/platform Signed-off-by: Joe Perches--- drivers/platform/x86/asus-laptop.c| 2 +- drivers/platform/x86/eeepc-laptop.c | 2 +- drivers/platform/x86/intel_oaktrail.c | 10 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/platform/x86/asus-laptop.c b/drivers/platform/x86/asus-laptop.c index 28551f5a2e07..7f248f84f49a 100644 --- a/drivers/platform/x86/asus-laptop.c +++ b/drivers/platform/x86/asus-laptop.c @@ -1163,7 +1163,7 @@ static void asus_als_switch(struct asus_laptop *asus, int value) ret = write_acpi_int(asus->handle, METHOD_ALS_CONTROL, value); } if (ret) - pr_warning("Error setting light sensor switch\n"); + pr_warn("Error setting light sensor switch\n"); asus->light_switch = value; } diff --git a/drivers/platform/x86/eeepc-laptop.c b/drivers/platform/x86/eeepc-laptop.c index 8cdf315f9730..09f93eb49230 100644 --- a/drivers/platform/x86/eeepc-laptop.c +++ b/drivers/platform/x86/eeepc-laptop.c @@ -585,7 +585,7 @@ static void eeepc_rfkill_hotplug(struct eeepc_laptop *eeepc, acpi_handle handle) port = acpi_get_pci_dev(handle); if (!port) { - pr_warning("Unable to find port\n"); + pr_warn("Unable to find port\n"); goto out_unlock; } diff --git a/drivers/platform/x86/intel_oaktrail.c b/drivers/platform/x86/intel_oaktrail.c index 6aa33c4a809f..133b2f04643d 100644 --- a/drivers/platform/x86/intel_oaktrail.c +++ b/drivers/platform/x86/intel_oaktrail.c @@ -257,7 +257,7 @@ static int oaktrail_backlight_init(void) if (IS_ERR(bd)) { oaktrail_bl_device = NULL; - pr_warning("Unable to register backlight device\n"); + pr_warn("Unable to register backlight device\n"); return PTR_ERR(bd); } @@ -327,20 +327,20 @@ static int __init oaktrail_init(void) ret = platform_driver_register(_driver); if (ret) { - pr_warning("Unable to register platform driver\n"); + pr_warn("Unable to register platform driver\n"); goto err_driver_reg; } oaktrail_device = platform_device_alloc(DRIVER_NAME, -1); if (!oaktrail_device) { - pr_warning("Unable to allocate platform device\n"); + pr_warn("Unable to allocate platform device\n"); ret = -ENOMEM; goto err_device_alloc; } ret = platform_device_add(oaktrail_device); if (ret) { - pr_warning("Unable to add platform device\n"); + pr_warn("Unable to add platform device\n"); goto err_device_add; } @@ -352,7 +352,7 @@ static int __init oaktrail_init(void) ret = oaktrail_rfkill_init(); if (ret) { - pr_warning("Setup rfkill failed\n"); + pr_warn("Setup rfkill failed\n"); goto err_rfkill; } -- 2.10.0.rc2.1.g053435c
[PATCH 31/35] drivers/tty: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/tty Prior to this patch, there were 2 uses of pr_warning and 23 uses of pr_warn in drivers/tty Signed-off-by: Joe Perches--- drivers/tty/hvc/hvcs.c | 2 +- drivers/tty/tty_io.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/tty/hvc/hvcs.c b/drivers/tty/hvc/hvcs.c index 7823d6d998cf..99bb875178d7 100644 --- a/drivers/tty/hvc/hvcs.c +++ b/drivers/tty/hvc/hvcs.c @@ -1575,7 +1575,7 @@ static int __init hvcs_module_init(void) */ rc = driver_create_file(&(hvcs_vio_driver.driver), _attr_rescan); if (rc) - pr_warning("HVCS: Failed to create rescan file (err %d)\n", rc); + pr_warn("HVCS: Failed to create rescan file (err %d)\n", rc); return 0; } diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c index a1fd3f7d487a..e9ba3d06d8e1 100644 --- a/drivers/tty/tty_io.c +++ b/drivers/tty/tty_io.c @@ -2842,8 +2842,8 @@ static void tty_warn_deprecated_flags(struct serial_struct __user *ss) flags &= ASYNC_DEPRECATED; if (flags && __ratelimit(_flags)) - pr_warning("%s: '%s' is using deprecated serial flags (with no effect): %.8x\n", - __func__, get_task_comm(comm, current), flags); + pr_warn("%s: '%s' is using deprecated serial flags (with no effect): %.8x\n", + __func__, get_task_comm(comm, current), flags); } /* -- 2.10.0.rc2.1.g053435c
[PATCH 35/35] sound/soc: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for sound/soc Prior to this patch, there were 5 uses of pr_warning and 10 uses of pr_warn in sound/soc Signed-off-by: Joe Perches--- sound/soc/fsl/imx-audmux.c | 6 +++--- sound/soc/samsung/s3c-i2s-v2.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sound/soc/fsl/imx-audmux.c b/sound/soc/fsl/imx-audmux.c index fc57da341d61..41e877d2b400 100644 --- a/sound/soc/fsl/imx-audmux.c +++ b/sound/soc/fsl/imx-audmux.c @@ -152,7 +152,7 @@ static void audmux_debugfs_init(void) audmux_debugfs_root = debugfs_create_dir("audmux", NULL); if (!audmux_debugfs_root) { - pr_warning("Failed to create AUDMUX debugfs root\n"); + pr_warn("Failed to create AUDMUX debugfs root\n"); return; } @@ -160,8 +160,8 @@ static void audmux_debugfs_init(void) snprintf(buf, sizeof(buf), "ssi%lu", i); if (!debugfs_create_file(buf, 0444, audmux_debugfs_root, (void *)i, _debugfs_fops)) - pr_warning("Failed to create AUDMUX port %lu debugfs file\n", - i); + pr_warn("Failed to create AUDMUX port %lu debugfs file\n", + i); } } diff --git a/sound/soc/samsung/s3c-i2s-v2.c b/sound/soc/samsung/s3c-i2s-v2.c index 644f186fd35c..7423e4257a1b 100644 --- a/sound/soc/samsung/s3c-i2s-v2.c +++ b/sound/soc/samsung/s3c-i2s-v2.c @@ -669,13 +669,13 @@ static int s3c2412_i2s_suspend(struct snd_soc_dai *dai) iismod = readl(i2s->regs + S3C2412_IISMOD); if (iismod & S3C2412_IISCON_RXDMA_ACTIVE) - pr_warning("%s: RXDMA active?\n", __func__); + pr_warn("%s: RXDMA active?\n", __func__); if (iismod & S3C2412_IISCON_TXDMA_ACTIVE) - pr_warning("%s: TXDMA active?\n", __func__); + pr_warn("%s: TXDMA active?\n", __func__); if (iismod & S3C2412_IISCON_IIS_ACTIVE) - pr_warning("%s: IIS active\n", __func__); + pr_warn("%s: IIS active\n", __func__); } return 0; -- 2.10.0.rc2.1.g053435c
[PATCH 34/35] lib: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for lib Prior to this patch, there were 2 uses of pr_warning and 59 uses of pr_warn in lib Signed-off-by: Joe Perches --- lib/cpu_rmap.c | 2 +- lib/dma-debug.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/cpu_rmap.c b/lib/cpu_rmap.c index f610b2a10b3e..fa9778e57eab 100644 --- a/lib/cpu_rmap.c +++ b/lib/cpu_rmap.c @@ -258,7 +258,7 @@ irq_cpu_rmap_notify(struct irq_affinity_notify *notify, const cpumask_t *mask) rc = cpu_rmap_update(glue->rmap, glue->index, mask); if (rc) - pr_warning("irq_cpu_rmap_notify: update failed: %d\n", rc); + pr_warn("irq_cpu_rmap_notify: update failed: %d\n", rc); } /** diff --git a/lib/dma-debug.c b/lib/dma-debug.c index 60c57ec936db..bccb92a85268 100644 --- a/lib/dma-debug.c +++ b/lib/dma-debug.c @@ -176,7 +176,7 @@ static inline void dump_entry_trace(struct dma_debug_entry *entry) { #ifdef CONFIG_STACKTRACE if (entry) { - pr_warning("Mapped at:\n"); + pr_warn("Mapped at:\n"); print_stack_trace(>stacktrace, 0); } #endif -- 2.10.0.rc2.1.g053435c
[PATCH 27/35] drivers/platform: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/platform Prior to this patch, there were 7 uses of pr_warning and 108 uses of pr_warn in drivers/platform Signed-off-by: Joe Perches --- drivers/platform/x86/asus-laptop.c| 2 +- drivers/platform/x86/eeepc-laptop.c | 2 +- drivers/platform/x86/intel_oaktrail.c | 10 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/platform/x86/asus-laptop.c b/drivers/platform/x86/asus-laptop.c index 28551f5a2e07..7f248f84f49a 100644 --- a/drivers/platform/x86/asus-laptop.c +++ b/drivers/platform/x86/asus-laptop.c @@ -1163,7 +1163,7 @@ static void asus_als_switch(struct asus_laptop *asus, int value) ret = write_acpi_int(asus->handle, METHOD_ALS_CONTROL, value); } if (ret) - pr_warning("Error setting light sensor switch\n"); + pr_warn("Error setting light sensor switch\n"); asus->light_switch = value; } diff --git a/drivers/platform/x86/eeepc-laptop.c b/drivers/platform/x86/eeepc-laptop.c index 8cdf315f9730..09f93eb49230 100644 --- a/drivers/platform/x86/eeepc-laptop.c +++ b/drivers/platform/x86/eeepc-laptop.c @@ -585,7 +585,7 @@ static void eeepc_rfkill_hotplug(struct eeepc_laptop *eeepc, acpi_handle handle) port = acpi_get_pci_dev(handle); if (!port) { - pr_warning("Unable to find port\n"); + pr_warn("Unable to find port\n"); goto out_unlock; } diff --git a/drivers/platform/x86/intel_oaktrail.c b/drivers/platform/x86/intel_oaktrail.c index 6aa33c4a809f..133b2f04643d 100644 --- a/drivers/platform/x86/intel_oaktrail.c +++ b/drivers/platform/x86/intel_oaktrail.c @@ -257,7 +257,7 @@ static int oaktrail_backlight_init(void) if (IS_ERR(bd)) { oaktrail_bl_device = NULL; - pr_warning("Unable to register backlight device\n"); + pr_warn("Unable to register backlight device\n"); return PTR_ERR(bd); } @@ -327,20 +327,20 @@ static int __init oaktrail_init(void) ret = platform_driver_register(_driver); if (ret) { - pr_warning("Unable to register platform driver\n"); + pr_warn("Unable to register platform driver\n"); goto err_driver_reg; } oaktrail_device = platform_device_alloc(DRIVER_NAME, -1); if (!oaktrail_device) { - pr_warning("Unable to allocate platform device\n"); + pr_warn("Unable to allocate platform device\n"); ret = -ENOMEM; goto err_device_alloc; } ret = platform_device_add(oaktrail_device); if (ret) { - pr_warning("Unable to add platform device\n"); + pr_warn("Unable to add platform device\n"); goto err_device_add; } @@ -352,7 +352,7 @@ static int __init oaktrail_init(void) ret = oaktrail_rfkill_init(); if (ret) { - pr_warning("Setup rfkill failed\n"); + pr_warn("Setup rfkill failed\n"); goto err_rfkill; } -- 2.10.0.rc2.1.g053435c
[PATCH 31/35] drivers/tty: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/tty Prior to this patch, there were 2 uses of pr_warning and 23 uses of pr_warn in drivers/tty Signed-off-by: Joe Perches --- drivers/tty/hvc/hvcs.c | 2 +- drivers/tty/tty_io.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/tty/hvc/hvcs.c b/drivers/tty/hvc/hvcs.c index 7823d6d998cf..99bb875178d7 100644 --- a/drivers/tty/hvc/hvcs.c +++ b/drivers/tty/hvc/hvcs.c @@ -1575,7 +1575,7 @@ static int __init hvcs_module_init(void) */ rc = driver_create_file(&(hvcs_vio_driver.driver), _attr_rescan); if (rc) - pr_warning("HVCS: Failed to create rescan file (err %d)\n", rc); + pr_warn("HVCS: Failed to create rescan file (err %d)\n", rc); return 0; } diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c index a1fd3f7d487a..e9ba3d06d8e1 100644 --- a/drivers/tty/tty_io.c +++ b/drivers/tty/tty_io.c @@ -2842,8 +2842,8 @@ static void tty_warn_deprecated_flags(struct serial_struct __user *ss) flags &= ASYNC_DEPRECATED; if (flags && __ratelimit(_flags)) - pr_warning("%s: '%s' is using deprecated serial flags (with no effect): %.8x\n", - __func__, get_task_comm(comm, current), flags); + pr_warn("%s: '%s' is using deprecated serial flags (with no effect): %.8x\n", + __func__, get_task_comm(comm, current), flags); } /* -- 2.10.0.rc2.1.g053435c
[PATCH 35/35] sound/soc: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for sound/soc Prior to this patch, there were 5 uses of pr_warning and 10 uses of pr_warn in sound/soc Signed-off-by: Joe Perches --- sound/soc/fsl/imx-audmux.c | 6 +++--- sound/soc/samsung/s3c-i2s-v2.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sound/soc/fsl/imx-audmux.c b/sound/soc/fsl/imx-audmux.c index fc57da341d61..41e877d2b400 100644 --- a/sound/soc/fsl/imx-audmux.c +++ b/sound/soc/fsl/imx-audmux.c @@ -152,7 +152,7 @@ static void audmux_debugfs_init(void) audmux_debugfs_root = debugfs_create_dir("audmux", NULL); if (!audmux_debugfs_root) { - pr_warning("Failed to create AUDMUX debugfs root\n"); + pr_warn("Failed to create AUDMUX debugfs root\n"); return; } @@ -160,8 +160,8 @@ static void audmux_debugfs_init(void) snprintf(buf, sizeof(buf), "ssi%lu", i); if (!debugfs_create_file(buf, 0444, audmux_debugfs_root, (void *)i, _debugfs_fops)) - pr_warning("Failed to create AUDMUX port %lu debugfs file\n", - i); + pr_warn("Failed to create AUDMUX port %lu debugfs file\n", + i); } } diff --git a/sound/soc/samsung/s3c-i2s-v2.c b/sound/soc/samsung/s3c-i2s-v2.c index 644f186fd35c..7423e4257a1b 100644 --- a/sound/soc/samsung/s3c-i2s-v2.c +++ b/sound/soc/samsung/s3c-i2s-v2.c @@ -669,13 +669,13 @@ static int s3c2412_i2s_suspend(struct snd_soc_dai *dai) iismod = readl(i2s->regs + S3C2412_IISMOD); if (iismod & S3C2412_IISCON_RXDMA_ACTIVE) - pr_warning("%s: RXDMA active?\n", __func__); + pr_warn("%s: RXDMA active?\n", __func__); if (iismod & S3C2412_IISCON_TXDMA_ACTIVE) - pr_warning("%s: TXDMA active?\n", __func__); + pr_warn("%s: TXDMA active?\n", __func__); if (iismod & S3C2412_IISCON_IIS_ACTIVE) - pr_warning("%s: IIS active\n", __func__); + pr_warn("%s: IIS active\n", __func__); } return 0; -- 2.10.0.rc2.1.g053435c
[PATCH 29/35] drivers/scsi: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/scsi Prior to this patch, there was 1 use of pr_warning and 96 uses of pr_warn in drivers/scsi Signed-off-by: Joe Perches--- drivers/scsi/a3000.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/a3000.c b/drivers/scsi/a3000.c index e6375b4de79e..2be0f577abbf 100644 --- a/drivers/scsi/a3000.c +++ b/drivers/scsi/a3000.c @@ -38,7 +38,7 @@ static irqreturn_t a3000_intr(int irq, void *data) spin_unlock_irqrestore(instance->host_lock, flags); return IRQ_HANDLED; } - pr_warning("Non-serviced A3000 SCSI-interrupt? ISTR = %02x\n", status); + pr_warn("Non-serviced A3000 SCSI-interrupt? ISTR = %02x\n", status); return IRQ_NONE; } -- 2.10.0.rc2.1.g053435c
[PATCH 32/35] drivers/video: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/video Prior to this patch, there were 6 uses of pr_warning and 25 uses of pr_warn in drivers/video Signed-off-by: Joe Perches--- drivers/video/fbdev/aty/radeon_base.c | 4 ++-- drivers/video/fbdev/core/fbmon.c | 4 ++-- drivers/video/fbdev/pxafb.c | 7 +++ 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/drivers/video/fbdev/aty/radeon_base.c b/drivers/video/fbdev/aty/radeon_base.c index 218339a4edaa..6b4c7872b375 100644 --- a/drivers/video/fbdev/aty/radeon_base.c +++ b/drivers/video/fbdev/aty/radeon_base.c @@ -2453,8 +2453,8 @@ static int radeonfb_pci_register(struct pci_dev *pdev, err |= sysfs_create_bin_file(>pdev->dev.kobj, _attr); if (err) - pr_warning("%s() Creating sysfs files failed, continuing\n", - __func__); + pr_warn("%s() Creating sysfs files failed, continuing\n", + __func__); /* save current mode regs before we switch into the new one * so we can restore this upon __exit diff --git a/drivers/video/fbdev/core/fbmon.c b/drivers/video/fbdev/core/fbmon.c index 62c0cf79674f..687ebb053438 100644 --- a/drivers/video/fbdev/core/fbmon.c +++ b/drivers/video/fbdev/core/fbmon.c @@ -1073,9 +1073,9 @@ void fb_edid_add_monspecs(unsigned char *edid, struct fb_monspecs *specs) for (i = specs->modedb_len + num; i < specs->modedb_len + num + svd_n; i++) { int idx = svd[i - specs->modedb_len - num]; if (!idx || idx >= ARRAY_SIZE(cea_modes)) { - pr_warning("Reserved SVD code %d\n", idx); + pr_warn("Reserved SVD code %d\n", idx); } else if (!cea_modes[idx].xres) { - pr_warning("Unimplemented SVD code %d\n", idx); + pr_warn("Unimplemented SVD code %d\n", idx); } else { memcpy([i], cea_modes + idx, sizeof(m[i])); pr_debug("Adding SVD #%d: %ux%u@%u\n", idx, diff --git a/drivers/video/fbdev/pxafb.c b/drivers/video/fbdev/pxafb.c index ef73f14d7ba0..b21a89b03fb4 100644 --- a/drivers/video/fbdev/pxafb.c +++ b/drivers/video/fbdev/pxafb.c @@ -645,7 +645,7 @@ static void overlay1fb_disable(struct pxafb_layer *ofb) lcd_writel(ofb->fbi, FBR1, ofb->fbi->fdadr[DMA_OV1] | 0x3); if (wait_for_completion_timeout(>branch_done, 1 * HZ) == 0) - pr_warning("%s: timeout disabling overlay1\n", __func__); + pr_warn("%s: timeout disabling overlay1\n", __func__); lcd_writel(ofb->fbi, LCCR5, lccr5); } @@ -710,7 +710,7 @@ static void overlay2fb_disable(struct pxafb_layer *ofb) lcd_writel(ofb->fbi, FBR4, ofb->fbi->fdadr[DMA_OV2_Cr] | 0x3); if (wait_for_completion_timeout(>branch_done, 1 * HZ) == 0) - pr_warning("%s: timeout disabling overlay2\n", __func__); + pr_warn("%s: timeout disabling overlay2\n", __func__); } static struct pxafb_layer_ops ofb_ops[] = { @@ -1187,8 +1187,7 @@ int pxafb_smart_flush(struct fb_info *info) lcd_writel(fbi, LCCR0, fbi->reg_lccr0 | LCCR0_ENB); if (wait_for_completion_timeout(>command_done, HZ/2) == 0) { - pr_warning("%s: timeout waiting for command done\n", - __func__); + pr_warn("%s: timeout waiting for command done\n", __func__); ret = -ETIMEDOUT; } -- 2.10.0.rc2.1.g053435c
[PATCH 26/35] drivers/oprofile: Convert remaining uses of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/oprofile Prior to this patch, there were 2 uses of pr_warning and 0 uses of pr_warn in drivers/oprofile Signed-off-by: Joe Perches--- drivers/oprofile/oprofile_perf.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/oprofile/oprofile_perf.c b/drivers/oprofile/oprofile_perf.c index d5b2732b1b81..6718440ab8da 100644 --- a/drivers/oprofile/oprofile_perf.c +++ b/drivers/oprofile/oprofile_perf.c @@ -45,8 +45,8 @@ static void op_overflow_handler(struct perf_event *event, if (id != num_counters) oprofile_add_sample(regs, id); else - pr_warning("oprofile: ignoring spurious overflow " - "on cpu %u\n", cpu); + pr_warn("oprofile: ignoring spurious overflow on cpu %u\n", + cpu); } /* @@ -87,8 +87,8 @@ static int op_create_counter(int cpu, int event) if (pevent->state != PERF_EVENT_STATE_ACTIVE) { perf_event_release_kernel(pevent); - pr_warning("oprofile: failed to enable event %d " - "on CPU %d\n", event, cpu); + pr_warn("oprofile: failed to enable event %d on CPU %d\n", + event, cpu); return -EBUSY; } -- 2.10.0.rc2.1.g053435c
[PATCH 29/35] drivers/scsi: Convert remaining use of pr_warning to pr_warn
To enable eventual removal of pr_warning This makes pr_warn use consistent for drivers/scsi Prior to this patch, there was 1 use of pr_warning and 96 uses of pr_warn in drivers/scsi Signed-off-by: Joe Perches --- drivers/scsi/a3000.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/a3000.c b/drivers/scsi/a3000.c index e6375b4de79e..2be0f577abbf 100644 --- a/drivers/scsi/a3000.c +++ b/drivers/scsi/a3000.c @@ -38,7 +38,7 @@ static irqreturn_t a3000_intr(int irq, void *data) spin_unlock_irqrestore(instance->host_lock, flags); return IRQ_HANDLED; } - pr_warning("Non-serviced A3000 SCSI-interrupt? ISTR = %02x\n", status); + pr_warn("Non-serviced A3000 SCSI-interrupt? ISTR = %02x\n", status); return IRQ_NONE; } -- 2.10.0.rc2.1.g053435c