Skip to content

Commit c83571b

Browse files
marcanjannau
authored andcommitted
Input: macsmc-hid: Support the power button on desktops
Signed-off-by: Hector Martin <marcan@marcan.st>
1 parent 4020c77 commit c83571b

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

drivers/input/misc/macsmc-hid.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ struct macsmc_hid {
2424
#define SMC_EV_BTN 0x7201
2525
#define SMC_EV_LID 0x7203
2626

27-
#define BTN_POWER 0x06
27+
#define BTN_POWER 0x01
28+
#define BTN_TOUCHID 0x06
2829
#define BTN_POWER_HELD1 0xfe
2930
#define BTN_POWER_HELD2 0x00
3031

@@ -39,6 +40,7 @@ static int macsmc_hid_event(struct notifier_block *nb, unsigned long event, void
3940
case SMC_EV_BTN:
4041
switch (d1) {
4142
case BTN_POWER:
43+
case BTN_TOUCHID:
4244
if (smchid->wakeup_mode) {
4345
if (d2) {
4446
dev_info(smchid->dev, "Button wakeup\n");

0 commit comments

Comments
 (0)