On Mon, Jul 16, 2018 at 2:44 PM Morten Hein Tiljeset <morten.tiljeset@xxxxxxxxx> wrote: > Signed-off-by: Morten Hein Tiljeset <morten.tiljeset@xxxxxxxxx> > Reviewed-by: Sean Nyekjaer <sean.nyekjaer@xxxxxxxxx> Patch applied! No more feedback, so obvioisly apply time. > + bitmap_zero(bits, chip->ngpio); > + for (i = 0; i < nbytes; i++) { > + j = i / sizeof(unsigned long); > + bits[j] |= ((unsigned long) gpio->buffer[i]) > + << (8 * (i % sizeof(unsigned long))); > + } That's some clever code. We should probably think about making that a library way of getting multiple. Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html