Re: [PATCH v4] Input: sysrq - DT binding for key sequence

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jul 16, 2013 at 5:24 PM, Mathieu Poirier
<mathieu.poirier@xxxxxxxxxx> wrote:
>
>
>
> On 15 July 2013 20:43, Rob Herring <robherring2@xxxxxxxxx> wrote:
>>
>> On 07/15/2013 10:36 AM, mathieu.poirier@xxxxxxxxxx wrote:
>> > From: "Mathieu J. Poirier" <mathieu.poirier@xxxxxxxxxx>
>> >

[snip]

>> > +     prop = of_find_property(np, "keyset", NULL);
>> > +     if (!prop || !prop->value) {
>> > +             pr_err("Invalid input keyset");
>> > +             goto out;
>> > +     }
>> > +
>> > +     count = prop->length / sizeof(u32);
>> > +     val = prop->value;
>>
>> None of the existing helpers to retrieve property arrays doesn't work
>> here?
>
>
> The problem here is that we never know how long the sequence will be.  As
> such the 'of_property_read_uXY_array' functions won't work.  Or maybe you're
> referring to another set of helpers... If so, please clarify.

What about of_property_for_each_u32? Or we should make
of_property_read_uXY_array work with arrays that can be less than some
max size.

Rob
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux