Skip to content

Commit 2655d14

Browse files
committed
fixup! WIP: mfd: Add support for Flipper One's MCU
1 parent 2074e6c commit 2655d14

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

drivers/mfd/flipper-one-mcu.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ static const struct resource fo_input_irqs[] = {
101101
DEFINE_RES_IRQ_NAMED(FOMCU_INT_INPUT_BTN, "flipper-one-input-btn"),
102102
DEFINE_RES_IRQ_NAMED(FOMCU_INT_INPUT_TOUCH, "flipper-one-input-touch"),
103103
DEFINE_RES_IRQ_NAMED(FOMCU_INT_INPUT_HEADSET, "flipper-one-input-headset"),
104+
DEFINE_RES_IRQ_NAMED(FOMCU_INT_INPUT_SWBTN, "flipper-one-input-swbtn"),
104105
};
105106

106107
static const struct resource fo_ucsi_irqs[] = {

include/linux/mfd/flipper-one-mcu.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ enum fomcu_interrupts {
1515
FOMCU_INT_INPUT_BTN,
1616
FOMCU_INT_INPUT_TOUCH,
1717
FOMCU_INT_INPUT_HEADSET,
18+
FOMCU_INT_INPUT_SWBTN,
1819
FOMCU_INT_UCSI_EVENT,
1920
};
2021

@@ -47,6 +48,7 @@ enum fomcu_cpu_states {
4748
#define FOMCU_INTSTS_INPUT_BTN BIT(0)
4849
#define FOMCU_INTSTS_INPUT_TOUCH BIT(1)
4950
#define FOMCU_INTSTS_INPUT_HEADSET BIT(2)
51+
#define FOMCU_INTSTS_INPUT_SWBTN BIT(3)
5052

5153
#define FOMCU_REG_INTSTS_UCSI 0x0102
5254
#define FOMCU_INTOFF_UCSI 0x2
@@ -60,6 +62,7 @@ enum fomcu_cpu_states {
6062
#define FOMCU_REG_INPUT_TOUCH_Y 0x0204
6163
#define FOMCU_REG_INPUT_TOUCH_Z 0x0206
6264
#define FOMCU_REG_INPUT_HEADSET 0x0208
65+
#define FOMCU_REG_INPUT_SWBTNS 0x020a
6366

6467
#define FOMCU_REG_LEDS_BR_LINK 0x0300
6568
#define FOMCU_REG_LEDS_BR_POWER 0x0302

0 commit comments

Comments
 (0)