base-files: leds: do reverse lookup in get_dt_led()
In order to match the "label"-less DT properties we have to get
creative. In theory the dt-node should have everything (i.e.:
color, function and function-enumerator) to make the device-name
in /sys/class/leds. But thanks to color being a binary value
and not a "string", we would have to maintain a lookup table that
keeps in sync with the dt-binding.
It's much easier to use the "uevent" property of every led-class
device and do reverse lookup with it by comparing the OF_FULLNAME
with the alias pathname.
(This works with gpio-leds ... let's see where it breaks)
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>