20 #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
22 #include <linux/kernel.h>
23 #include <linux/module.h>
25 #include <linux/types.h>
34 static int toshiba_bt_rfkill_add(
struct acpi_device *
device);
35 static int toshiba_bt_rfkill_remove(
struct acpi_device *
device,
int type);
36 static void toshiba_bt_rfkill_notify(
struct acpi_device *
device,
u32 event);
44 #ifdef CONFIG_PM_SLEEP
45 static int toshiba_bt_resume(
struct device *
dev);
49 static struct acpi_driver toshiba_bt_rfkill_driver = {
54 .add = toshiba_bt_rfkill_add,
55 .remove = toshiba_bt_rfkill_remove,
56 .notify = toshiba_bt_rfkill_notify,
59 .drv.pm = &toshiba_bt_pm,
79 pr_info(
"Re-enabling Toshiba Bluetooth\n");
85 pr_warn(
"Failed to re-enable Toshiba Bluetooth\n");
90 static void toshiba_bt_rfkill_notify(
struct acpi_device *
device,
u32 event)
92 toshiba_bluetooth_enable(device->handle);
95 #ifdef CONFIG_PM_SLEEP
96 static int toshiba_bt_resume(
struct device *
dev)
98 return toshiba_bluetooth_enable(to_acpi_device(dev)->handle);
102 static int toshiba_bt_rfkill_add(
struct acpi_device *
device)
117 pr_info(
"Detected Toshiba ACPI Bluetooth device - "
118 "installing RFKill handler\n");
119 result = toshiba_bluetooth_enable(device->handle);
125 static int toshiba_bt_rfkill_remove(
struct acpi_device *device,
int type)