struct regmap *regmap;
struct input_dev *input_dev;
struct clk *clk;
- void __iomem *base;
u32 n_rows;
u32 n_cols;
DECLARE_BITMAP(keymap_state, MTK_KPD_NUM_BITS);
static int mt6779_keypad_pdrv_probe(struct platform_device *pdev)
{
struct mt6779_keypad *keypad;
+ void __iomem *base;
int irq;
u32 debounce;
bool wakeup;
if (!keypad)
return -ENOMEM;
- keypad->base = devm_platform_ioremap_resource(pdev, 0);
- if (IS_ERR(keypad->base))
- return PTR_ERR(keypad->base);
+ base = devm_platform_ioremap_resource(pdev, 0);
+ if (IS_ERR(base))
+ return PTR_ERR(base);
- keypad->regmap = devm_regmap_init_mmio(&pdev->dev, keypad->base,
+ keypad->regmap = devm_regmap_init_mmio(&pdev->dev, base,
&mt6779_keypad_regmap_cfg);
if (IS_ERR(keypad->regmap)) {
dev_err(&pdev->dev,