On Thu, Mar 7, 2013 at 7:43 PM, Benson Leung <ble...@chromium.org> wrote:
> +static void mxt_input_button(struct mxt_data *data, struct mxt_message 
> *message)
> +{
> +       struct device *dev = &data->client->dev;
Oops. I missed a warning: unused variable 'dev' here.

> +       struct input_dev *input = data->input_dev;
> +       bool button;
> +       int i;
> +
> +       /* Active-low switch */
> +       for (i = 0; i < MXT_NUM_GPIO; i++) {
> +               if (data->pdata->key_map[i] == KEY_RESERVED)
> +                       continue;
> +               button = !(message->message[0] & MXT_GPIO0_MASK << i);
> +               input_report_key(input, data->pdata->key_map[i], button);
> +       }
> +}
> +




--
Benson Leung
Software Engineer, Chrom* OS
ble...@chromium.org
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to