aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/platform
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2013-10-23 15:14:52 -0400
committerMatthew Garrett <matthew.garrett@nebula.com>2013-11-20 18:51:03 -0500
commitb222cca6002c9396c0ac03b68756f8c565d73561 (patch)
tree9606fde2e51be15aff436c6fae5ac36e3b615b23 /drivers/platform
parenta825bc87b2694dbefe39590a3efe29c5da4d3dd3 (diff)
platform:x86: Remove OOM message after input_allocate_device
Emitting an OOM message isn't necessary after input_allocate_device as there's a generic OOM and a dump_stack already done. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Matthew Garrett <matthew.garrett@nebula.com>
Diffstat (limited to 'drivers/platform')
-rw-r--r--drivers/platform/x86/asus-laptop.c5
-rw-r--r--drivers/platform/x86/eeepc-laptop.c4
-rw-r--r--drivers/platform/x86/ideapad-laptop.c4
-rw-r--r--drivers/platform/x86/intel_mid_powerbtn.c4
-rw-r--r--drivers/platform/x86/panasonic-laptop.c5
-rw-r--r--drivers/platform/x86/thinkpad_acpi.c1
-rw-r--r--drivers/platform/x86/topstar-laptop.c4
-rw-r--r--drivers/platform/x86/toshiba_acpi.c4
8 files changed, 8 insertions, 23 deletions
diff --git a/drivers/platform/x86/asus-laptop.c b/drivers/platform/x86/asus-laptop.c
index 0e9c169b42f8..594323a926cf 100644
--- a/drivers/platform/x86/asus-laptop.c
+++ b/drivers/platform/x86/asus-laptop.c
@@ -1494,10 +1494,9 @@ static int asus_input_init(struct asus_laptop *asus)
1494 int error; 1494 int error;
1495 1495
1496 input = input_allocate_device(); 1496 input = input_allocate_device();
1497 if (!input) { 1497 if (!input)
1498 pr_warn("Unable to allocate input device\n");
1499 return -ENOMEM; 1498 return -ENOMEM;
1500 } 1499
1501 input->name = "Asus Laptop extra buttons"; 1500 input->name = "Asus Laptop extra buttons";
1502 input->phys = ASUS_LAPTOP_FILE "/input0"; 1501 input->phys = ASUS_LAPTOP_FILE "/input0";
1503 input->id.bustype = BUS_HOST; 1502 input->id.bustype = BUS_HOST;
diff --git a/drivers/platform/x86/eeepc-laptop.c b/drivers/platform/x86/eeepc-laptop.c
index aefcc32e5634..dec68e7a99c7 100644
--- a/drivers/platform/x86/eeepc-laptop.c
+++ b/drivers/platform/x86/eeepc-laptop.c
@@ -1203,10 +1203,8 @@ static int eeepc_input_init(struct eeepc_laptop *eeepc)
1203 int error; 1203 int error;
1204 1204
1205 input = input_allocate_device(); 1205 input = input_allocate_device();
1206 if (!input) { 1206 if (!input)
1207 pr_info("Unable to allocate input device\n");
1208 return -ENOMEM; 1207 return -ENOMEM;
1209 }
1210 1208
1211 input->name = "Asus EeePC extra buttons"; 1209 input->name = "Asus EeePC extra buttons";
1212 input->phys = EEEPC_LAPTOP_FILE "/input0"; 1210 input->phys = EEEPC_LAPTOP_FILE "/input0";
diff --git a/drivers/platform/x86/ideapad-laptop.c b/drivers/platform/x86/ideapad-laptop.c
index 6788acc22ab9..19ec95147f69 100644
--- a/drivers/platform/x86/ideapad-laptop.c
+++ b/drivers/platform/x86/ideapad-laptop.c
@@ -570,10 +570,8 @@ static int ideapad_input_init(struct ideapad_private *priv)
570 int error; 570 int error;
571 571
572 inputdev = input_allocate_device(); 572 inputdev = input_allocate_device();
573 if (!inputdev) { 573 if (!inputdev)
574 pr_info("Unable to allocate input device\n");
575 return -ENOMEM; 574 return -ENOMEM;
576 }
577 575
578 inputdev->name = "Ideapad extra buttons"; 576 inputdev->name = "Ideapad extra buttons";
579 inputdev->phys = "ideapad/input0"; 577 inputdev->phys = "ideapad/input0";
diff --git a/drivers/platform/x86/intel_mid_powerbtn.c b/drivers/platform/x86/intel_mid_powerbtn.c
index 6b18aba82cfa..8d6775266d66 100644
--- a/drivers/platform/x86/intel_mid_powerbtn.c
+++ b/drivers/platform/x86/intel_mid_powerbtn.c
@@ -66,10 +66,8 @@ static int mfld_pb_probe(struct platform_device *pdev)
66 return -EINVAL; 66 return -EINVAL;
67 67
68 input = input_allocate_device(); 68 input = input_allocate_device();
69 if (!input) { 69 if (!input)
70 dev_err(&pdev->dev, "Input device allocation error\n");
71 return -ENOMEM; 70 return -ENOMEM;
72 }
73 71
74 input->name = pdev->name; 72 input->name = pdev->name;
75 input->phys = "power-button/input0"; 73 input->phys = "power-button/input0";
diff --git a/drivers/platform/x86/panasonic-laptop.c b/drivers/platform/x86/panasonic-laptop.c
index 10d12b221601..3008fd20572e 100644
--- a/drivers/platform/x86/panasonic-laptop.c
+++ b/drivers/platform/x86/panasonic-laptop.c
@@ -490,11 +490,8 @@ static int acpi_pcc_init_input(struct pcc_acpi *pcc)
490 int error; 490 int error;
491 491
492 input_dev = input_allocate_device(); 492 input_dev = input_allocate_device();
493 if (!input_dev) { 493 if (!input_dev)
494 ACPI_DEBUG_PRINT((ACPI_DB_ERROR,
495 "Couldn't allocate input device for hotkey"));
496 return -ENOMEM; 494 return -ENOMEM;
497 }
498 495
499 input_dev->name = ACPI_PCC_DRIVER_NAME; 496 input_dev->name = ACPI_PCC_DRIVER_NAME;
500 input_dev->phys = ACPI_PCC_INPUT_PHYS; 497 input_dev->phys = ACPI_PCC_INPUT_PHYS;
diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c
index 05e046aa5e31..a5e99d749246 100644
--- a/drivers/platform/x86/thinkpad_acpi.c
+++ b/drivers/platform/x86/thinkpad_acpi.c
@@ -9163,7 +9163,6 @@ static int __init thinkpad_acpi_module_init(void)
9163 mutex_init(&tpacpi_inputdev_send_mutex); 9163 mutex_init(&tpacpi_inputdev_send_mutex);
9164 tpacpi_inputdev = input_allocate_device(); 9164 tpacpi_inputdev = input_allocate_device();
9165 if (!tpacpi_inputdev) { 9165 if (!tpacpi_inputdev) {
9166 pr_err("unable to allocate input device\n");
9167 thinkpad_acpi_module_exit(); 9166 thinkpad_acpi_module_exit();
9168 return -ENOMEM; 9167 return -ENOMEM;
9169 } else { 9168 } else {
diff --git a/drivers/platform/x86/topstar-laptop.c b/drivers/platform/x86/topstar-laptop.c
index 67897c8740ba..e597de05e6c2 100644
--- a/drivers/platform/x86/topstar-laptop.c
+++ b/drivers/platform/x86/topstar-laptop.c
@@ -97,10 +97,8 @@ static int acpi_topstar_init_hkey(struct topstar_hkey *hkey)
97 int error; 97 int error;
98 98
99 input = input_allocate_device(); 99 input = input_allocate_device();
100 if (!input) { 100 if (!input)
101 pr_err("Unable to allocate input device\n");
102 return -ENOMEM; 101 return -ENOMEM;
103 }
104 102
105 input->name = "Topstar Laptop extra buttons"; 103 input->name = "Topstar Laptop extra buttons";
106 input->phys = "topstar/input0"; 104 input->phys = "topstar/input0";
diff --git a/drivers/platform/x86/toshiba_acpi.c b/drivers/platform/x86/toshiba_acpi.c
index 0cfadb65f7c6..7fce391818d3 100644
--- a/drivers/platform/x86/toshiba_acpi.c
+++ b/drivers/platform/x86/toshiba_acpi.c
@@ -975,10 +975,8 @@ static int toshiba_acpi_setup_keyboard(struct toshiba_acpi_dev *dev)
975 u32 hci_result; 975 u32 hci_result;
976 976
977 dev->hotkey_dev = input_allocate_device(); 977 dev->hotkey_dev = input_allocate_device();
978 if (!dev->hotkey_dev) { 978 if (!dev->hotkey_dev)
979 pr_info("Unable to register input device\n");
980 return -ENOMEM; 979 return -ENOMEM;
981 }
982 980
983 dev->hotkey_dev->name = "Toshiba input device"; 981 dev->hotkey_dev->name = "Toshiba input device";
984 dev->hotkey_dev->phys = "toshiba_acpi/input0"; 982 dev->hotkey_dev->phys = "toshiba_acpi/input0";