How to name multiple LEDs of the same type and color

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

 



Hi,

I wonder what would be the correct way to deal with a set of LEDs with the same color/function combination, e.g.

	leds {
		compatible = "gpio-leds";

		link1 {
			function = LED_FUNCTION_RSSI;
			color = <LED_COLOR_ID_GREEN>;
			gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
		};

		link2 {
			function = LED_FUNCTION_RSSI;
			color = <LED_COLOR_ID_GREEN>;
			gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
		};

		link3 {
			function = LED_FUNCTION_RSSI;
			color = <LED_COLOR_ID_GREEN>;
			gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
		};
	};

or

	leds {
		compatible = "gpio-leds";

		lan1 {
			function = LED_FUNCTION_LAN;
			color = <LED_COLOR_ID_GREEN>;
			gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
		};
		lan2 {
			function = LED_FUNCTION_LAN;
			color = <LED_COLOR_ID_GREEN>;
			gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
		};
		lan3 {
			function = LED_FUNCTION_LAN;
			color = <LED_COLOR_ID_GREEN>;
			gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
		};
	};

These nodes will automatically create names like green:lan, green:lan_1, etc.

Is there a way to force a certain numbering scheme, e.g.
green:lan1, green:lan2, etc.
?

(For the RSSI leds, we currently even have stuff like ...:green:rssilow, ...:green:rssimedium, etc. in the label now)

How does this match into the color/function concept?

Thanks for some pointers ...

Best

Adrian

Attachment: openpgp-digital-signature.asc
Description: PGP signature


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux