diff options
author | Henrique de Moraes Holschuh <hmh@hmh.eng.br> | 2007-04-21 10:08:40 -0400 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2007-04-21 23:30:34 -0400 |
commit | d6fdd1e91a8a4cd852dc1d945165e3a69ac9e257 (patch) | |
tree | 207fd1e4aac402c03863f6eb253b07830f190c04 /drivers/misc/thinkpad_acpi.h | |
parent | b86c4722de62f336b82dff3c47ef59ba2a587ec1 (diff) |
ACPI: thinkpad-acpi: cleanup bluetooth and wan for sysfs conversion
Prepare bluetooth and wan driver code to be more easily hooked into sysfs
helpers, by separating the procfs logic from the device attribute handling.
These changes also remove the entries from procfs on notebooks without the
bluetooth/wan hardware installed.
Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/misc/thinkpad_acpi.h')
-rw-r--r-- | drivers/misc/thinkpad_acpi.h | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/drivers/misc/thinkpad_acpi.h b/drivers/misc/thinkpad_acpi.h index 1b4cd167ebd2..e06bad5c8fe4 100644 --- a/drivers/misc/thinkpad_acpi.h +++ b/drivers/misc/thinkpad_acpi.h | |||
@@ -241,8 +241,16 @@ static int beep_write(char *buf); | |||
241 | * Bluetooth subdriver | 241 | * Bluetooth subdriver |
242 | */ | 242 | */ |
243 | 243 | ||
244 | enum { | ||
245 | /* ACPI GBDC/SBDC bits */ | ||
246 | TP_ACPI_BLUETOOTH_HWPRESENT = 0x01, /* Bluetooth hw available */ | ||
247 | TP_ACPI_BLUETOOTH_RADIOSSW = 0x02, /* Bluetooth radio enabled */ | ||
248 | TP_ACPI_BLUETOOTH_UNK = 0x04, /* unknown function */ | ||
249 | }; | ||
250 | |||
244 | static int bluetooth_init(struct ibm_init_struct *iibm); | 251 | static int bluetooth_init(struct ibm_init_struct *iibm); |
245 | static int bluetooth_status(void); | 252 | static int bluetooth_get_radiosw(void); |
253 | static int bluetooth_set_radiosw(int radio_on); | ||
246 | static int bluetooth_read(char *p); | 254 | static int bluetooth_read(char *p); |
247 | static int bluetooth_write(char *buf); | 255 | static int bluetooth_write(char *buf); |
248 | 256 | ||
@@ -467,8 +475,16 @@ static int volume_write(char *buf); | |||
467 | * Wan subdriver | 475 | * Wan subdriver |
468 | */ | 476 | */ |
469 | 477 | ||
478 | enum { | ||
479 | /* ACPI GWAN/SWAN bits */ | ||
480 | TP_ACPI_WANCARD_HWPRESENT = 0x01, /* Wan hw available */ | ||
481 | TP_ACPI_WANCARD_RADIOSSW = 0x02, /* Wan radio enabled */ | ||
482 | TP_ACPI_WANCARD_UNK = 0x04, /* unknown function */ | ||
483 | }; | ||
484 | |||
470 | static int wan_init(struct ibm_init_struct *iibm); | 485 | static int wan_init(struct ibm_init_struct *iibm); |
471 | static int wan_status(void); | 486 | static int wan_get_radiosw(void); |
487 | static int wan_set_radiosw(int radio_on); | ||
472 | static int wan_read(char *p); | 488 | static int wan_read(char *p); |
473 | static int wan_write(char *buf); | 489 | static int wan_write(char *buf); |
474 | 490 | ||