aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-06-30 17:42:51 -0400
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-07-14 19:33:10 -0400
commitd460acebd7959cc91e7edc594d90adb9b72a0b05 (patch)
tree74701e2151eb83d1cef064e590aa0027fa5cf7e0
parentecd046da57d3327367b930478234e58f01bc9f0f (diff)
ACPI / dock: Drop the hp_lock mutex from struct dock_station
The only existing user of the hp_lock mutex in struct dock_station, hotplug_dock_devices(), is always called under acpi_scan_lock and cannot race with another instance of itself, so drop the mutex which is not necessary. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
-rw-r--r--drivers/acpi/dock.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/acpi/dock.c b/drivers/acpi/dock.c
index 810d1d720b1f..c10761533d6f 100644
--- a/drivers/acpi/dock.c
+++ b/drivers/acpi/dock.c
@@ -63,7 +63,6 @@ struct dock_station {
63 acpi_handle handle; 63 acpi_handle handle;
64 unsigned long last_dock_time; 64 unsigned long last_dock_time;
65 u32 flags; 65 u32 flags;
66 struct mutex hp_lock;
67 struct list_head dependent_devices; 66 struct list_head dependent_devices;
68 67
69 struct list_head sibling; 68 struct list_head sibling;
@@ -351,8 +350,6 @@ static void hotplug_dock_devices(struct dock_station *ds, u32 event)
351{ 350{
352 struct dock_dependent_device *dd; 351 struct dock_dependent_device *dd;
353 352
354 mutex_lock(&ds->hp_lock);
355
356 /* 353 /*
357 * First call driver specific hotplug functions 354 * First call driver specific hotplug functions
358 */ 355 */
@@ -371,7 +368,6 @@ static void hotplug_dock_devices(struct dock_station *ds, u32 event)
371 else 368 else
372 dock_create_acpi_device(dd->handle); 369 dock_create_acpi_device(dd->handle);
373 } 370 }
374 mutex_unlock(&ds->hp_lock);
375} 371}
376 372
377static void dock_event(struct dock_station *ds, u32 event, int num) 373static void dock_event(struct dock_station *ds, u32 event, int num)
@@ -893,7 +889,6 @@ static int __init dock_add(acpi_handle handle)
893 dock_station->dock_device = dd; 889 dock_station->dock_device = dd;
894 dock_station->last_dock_time = jiffies - HZ; 890 dock_station->last_dock_time = jiffies - HZ;
895 891
896 mutex_init(&dock_station->hp_lock);
897 INIT_LIST_HEAD(&dock_station->sibling); 892 INIT_LIST_HEAD(&dock_station->sibling);
898 INIT_LIST_HEAD(&dock_station->dependent_devices); 893 INIT_LIST_HEAD(&dock_station->dependent_devices);
899 894