[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20090919233044.8361a912.akpm@linux-foundation.org>
Date: Sat, 19 Sep 2009 23:30:44 -0700
From: Andrew Morton <akpm@...ux-foundation.org>
To: Mike Frysinger <vapier@...too.org>
Cc: linux-input@...r.kernel.org,
Dmitry Torokhov <dmitry.torokhov@...il.com>,
linux-kernel@...r.kernel.org,
uclinux-dist-devel@...ckfin.uclinux.org,
Michael Hennerich <michael.hennerich@...log.com>,
Bryan Wu <cooloney@...nel.org>
Subject: Re: [PATCH] input/keyboard: new driver for ADP5520 MFD PMICs
On Thu, 17 Sep 2009 14:24:10 -0400 Mike Frysinger <vapier@...too.org> wrote:
> ...
> +struct adp5520_keys {
> + struct input_dev *input;
> + struct notifier_block notifier;
> + struct device *master;
> + unsigned short keycode[ADP5520_KEYMAPSIZE];
Where is ADP5520_KEYMAPSIZE defined?
I can find a single instance in the tree:
./arch/blackfin/mach-bf537/boards/stamp.c:static const unsigned short adp5520_keymap[ADP5520_KEYMAPSIZE] = {
is it runtime-generated or something?
> +};
> +
> +static void adp5520_keys_report_event(struct adp5520_keys *dev,
> + unsigned short keymask, int value)
> +{
> + int i;
> +
> + for (i = 0; i < ADP5520_MAXKEYS; i++)
Where is ADP5520_MAXKEYS defined?
> + if (keymask & (1 << i))
> + input_report_key(dev->input, dev->keycode[i], value);
It seems odd that keycode is dimensioned with ADP5520_KEYMAPSIZE but
here we iterate up to ADP5520_MAXKEYS.
> +
> + input_sync(dev->input);
> +}
> +
> ...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists