Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 185079
b: refs/heads/master
c: 7f0cf71
h: refs/heads/master
i:
  185077: 3a1e2a4
  185075: 5cc9e8d
  185071: fbb6368
v: v3
  • Loading branch information
Henrique de Moraes Holschuh committed Feb 26, 2010
1 parent e97d81c commit c0f1b4b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 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: b589ea4c44170d3f7a845684e2d1b3b9571663af
refs/heads/master: 7f0cf712a74fcc3ad21f0bde95bd32c2f2cc3888
13 changes: 10 additions & 3 deletions trunk/drivers/platform/x86/thinkpad_acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -2082,6 +2082,7 @@ static struct attribute_set *hotkey_dev_attributes;

static void tpacpi_driver_event(const unsigned int hkey_event);
static void hotkey_driver_event(const unsigned int scancode);
static void hotkey_poll_setup(const bool may_warn);

/* HKEY.MHKG() return bits */
#define TP_HOTKEY_TABLET_MASK (1 << 3)
Expand Down Expand Up @@ -2264,6 +2265,8 @@ static int tpacpi_hotkey_driver_mask_set(const u32 mask)

rc = hotkey_mask_set((hotkey_acpi_mask | hotkey_driver_mask) &
~hotkey_source_mask);
hotkey_poll_setup(true);

mutex_unlock(&hotkey_mutex);

return rc;
Expand Down Expand Up @@ -2548,7 +2551,7 @@ static void hotkey_poll_stop_sync(void)
}

/* call with hotkey_mutex held */
static void hotkey_poll_setup(bool may_warn)
static void hotkey_poll_setup(const bool may_warn)
{
const u32 poll_driver_mask = hotkey_driver_mask & hotkey_source_mask;
const u32 poll_user_mask = hotkey_user_mask & hotkey_source_mask;
Expand Down Expand Up @@ -2579,7 +2582,7 @@ static void hotkey_poll_setup(bool may_warn)
}
}

static void hotkey_poll_setup_safe(bool may_warn)
static void hotkey_poll_setup_safe(const bool may_warn)
{
mutex_lock(&hotkey_mutex);
hotkey_poll_setup(may_warn);
Expand All @@ -2597,7 +2600,11 @@ static void hotkey_poll_set_freq(unsigned int freq)

#else /* CONFIG_THINKPAD_ACPI_HOTKEY_POLL */

static void hotkey_poll_setup_safe(bool __unused)
static void hotkey_poll_setup(const bool __unused)
{
}

static void hotkey_poll_setup_safe(const bool __unused)
{
}

Expand Down

0 comments on commit c0f1b4b

Please sign in to comment.