Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 101984
b: refs/heads/master
c: 74523c9
h: refs/heads/master
v: v3
  • Loading branch information
Alok N Kataria authored and Andi Kleen committed Jul 16, 2008
1 parent 85851dc commit e32c642
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 20b937343e55c16e37b1a4ad2176760b4a11002c
refs/heads/master: 74523c901342a773ddd9f14c14539ec3d4197ecf
12 changes: 8 additions & 4 deletions trunk/drivers/acpi/scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/acpi.h>
#include <asm/signal.h>
#include <linux/signal.h>
#include <linux/kthread.h>

#include <acpi/acpi_drivers.h>
#include <acpi/acinterp.h> /* for acpi_ex_eisa_id_to_string() */
Expand Down Expand Up @@ -154,6 +155,7 @@ acpi_eject_store(struct device *d, struct device_attribute *attr,
acpi_status status;
acpi_object_type type = 0;
struct acpi_device *acpi_device = to_acpi_device(d);
struct task_struct *task;

if ((!count) || (buf[0] != '1')) {
return -EINVAL;
Expand All @@ -171,9 +173,11 @@ acpi_eject_store(struct device *d, struct device_attribute *attr,
}

/* remove the device in another thread to fix the deadlock issue */
ret = kernel_thread(acpi_bus_hot_remove_device,
acpi_device->handle, SIGCHLD);
err:
task = kthread_run(acpi_bus_hot_remove_device,
acpi_device->handle, "acpi_hot_remove_device");
if (IS_ERR(task))
ret = PTR_ERR(task);
err:
return ret;
}

Expand Down

0 comments on commit e32c642

Please sign in to comment.