aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Hung <alex.hung@canonical.com>2016-06-28 23:41:15 -0400
committerDarren Hart <dvhart@linux.intel.com>2016-06-29 01:18:35 -0400
commit1d6de071cb0c321279373634d81eb8e176d887c4 (patch)
tree90cd86fbc550f26106b09d22bdee95cececa898e
parent9ee27487127461b5cf71670b708ed5b2b8da568c (diff)
intel-hid: Remove duplicated acpi_remove_notify_handler
The second call to acpi_remove_notify_handler does not result in panic or generate error messages, but it is unnecessary and the function returns with an error. Remove the duplicate call. Correct two improperly indented lines. Signed-off-by: Alex Hung <alex.hung@canonical.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
-rw-r--r--drivers/platform/x86/intel-hid.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/platform/x86/intel-hid.c b/drivers/platform/x86/intel-hid.c
index a818db6aa08f..ed5874217ee7 100644
--- a/drivers/platform/x86/intel-hid.c
+++ b/drivers/platform/x86/intel-hid.c
@@ -122,8 +122,8 @@ static int intel_hid_input_setup(struct platform_device *device)
122 return 0; 122 return 0;
123 123
124err_free_device: 124err_free_device:
125 input_free_device(priv->input_dev); 125 input_free_device(priv->input_dev);
126 return ret; 126 return ret;
127} 127}
128 128
129static void intel_hid_input_destroy(struct platform_device *device) 129static void intel_hid_input_destroy(struct platform_device *device)
@@ -224,7 +224,6 @@ static int intel_hid_remove(struct platform_device *device)
224 acpi_remove_notify_handler(handle, ACPI_DEVICE_NOTIFY, notify_handler); 224 acpi_remove_notify_handler(handle, ACPI_DEVICE_NOTIFY, notify_handler);
225 intel_hid_input_destroy(device); 225 intel_hid_input_destroy(device);
226 intel_hid_set_enable(&device->dev, 0); 226 intel_hid_set_enable(&device->dev, 0);
227 acpi_remove_notify_handler(handle, ACPI_DEVICE_NOTIFY, notify_handler);
228 227
229 /* 228 /*
230 * Even if we failed to shut off the event stream, we can still 229 * Even if we failed to shut off the event stream, we can still