-static void button_hotplug_event(struct gpio_keys_button_data *data,
- unsigned int type, int value)
-{
- struct bh_priv *priv = &data->bh;
- unsigned long seen = jiffies;
- int btn;
-
- pr_debug(PFX "event type=%u, code=%u, value=%d\n", type, data->b->code, value);
-
- if ((type != EV_KEY) && (type != EV_SW))
- return;
-
- btn = button_get_index(data->b->code);
- if (btn < 0)
- return;
-
- if (priv->seen == 0)
- priv->seen = seen;
-
- button_hotplug_create_event(button_map[btn].name, type,
- (seen - priv->seen) / HZ, value);
- priv->seen = seen;
-}
-
-struct gpio_keys_button_dev {
- int polled;
- struct delayed_work work;
-
- struct device *dev;
- struct gpio_keys_platform_data *pdata;
- struct gpio_keys_button_data data[0];
-};
-