Re: [PATCH] led/led-class: Handle LEDs with the same name

From: Ricardo Ribalda Delgado
Date: Tue Feb 17 2015 - 18:47:45 EST


Hi

On Wed, Feb 18, 2015 at 12:35 AM, Bryan Wu <cooloney@xxxxxxxxx> wrote:

> So why not use name "red0" and name another one "red1"? since you have
> multiple different red leds here any way.

I cannot control how many cameras the user will decide to attach to
the system, and if two similar cameras are attached to pciA and pciB,
they would try to load the same dt.

So I would have to parse the device tree on-line, finding the leds,
renaming them... and that code would be duplicated for every driver
doing similar work. Not only that, I would have to avoid collisions
to my "cameras", also to other devices that may have decided to use
similar naming.

I think the proposed solution is more simple, and solves the issue of
duplicated led names around the whole system. Also, if there is no
duplicated names it follows the old behaviours.

Thanks!

>
> -Bryan
>> --
>> Ricardo Ribalda



--
Ricardo Ribalda
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/