All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] DT labels for connector device mapping
@ 2015-12-10 21:21 ` Rob Herring
  0 siblings, 0 replies; 16+ messages in thread
From: Rob Herring @ 2015-12-10 21:21 UTC (permalink / raw)
  To: Bintian Wang, Andy Gross, arm-DgEjT+Ai2ygdnm+yROfE0A
  Cc: devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Grant Likely,
	Srinivas Kandagatla, Jorge Ramirez-Ortiz

Having a common connector interface across different platforms can be 
problematic for determining which SOC device is connected to which 
connector pins. The standard DT property "label" is intended to provide 
a human readable name for a device and can be used to provide this 
information. Then userspace can can read the label to determine the 
device mapping. For example:

for f in $(ls -d /sys/class/tty/tty*); do
  label=$(cat $f/device/of_node/label)
  if [ "$label" = "LS-UART1" ]; then
    # you've found UART1, so do something with it.
    # $f/dev is the major:minor for the /dev node
  fi
done

This series adds labels on hikey and dragonboard 410c devices for the 
low speed and high speed connectors. Not tested at all.

BTW, there are no platform maintainers listed for these files. Setting 
them should be enforced for the dts files as DT maintainers mainly 
review binding docs, not dts files.

Rob

Rob Herring (3):
  arm64: dts: apq8016-sbc: enable UART0 on LS connector
  arm64: dts: apq8016-sbc: add label properties for UART, I2C, and SPI
  arm64: dts: hikey: add label properties to UARTs

 arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts |  7 +++++++
 arch/arm64/boot/dts/qcom/apq8016-sbc.dtsi      | 14 ++++++++++++++
 2 files changed, 21 insertions(+)

-- 
2.5.0

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2015-12-22 19:25 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-10 21:21 [PATCH 0/3] DT labels for connector device mapping Rob Herring
2015-12-10 21:21 ` Rob Herring
     [not found] ` <1449782473-20880-1-git-send-email-robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2015-12-10 21:21   ` [PATCH 1/3] arm64: dts: apq8016-sbc: enable UART0 on LS connector Rob Herring
2015-12-10 21:21     ` Rob Herring
2015-12-10 21:21   ` [PATCH 2/3] arm64: dts: apq8016-sbc: add label properties for UART, I2C, and SPI Rob Herring
2015-12-10 21:21     ` Rob Herring
     [not found]     ` <1449782473-20880-3-git-send-email-robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2015-12-11 23:14       ` Kevin Hilman
2015-12-11 23:14         ` Kevin Hilman
2015-12-10 21:21   ` [PATCH 3/3] arm64: dts: hikey: add label properties to UARTs Rob Herring
2015-12-10 21:21     ` Rob Herring
2015-12-10 21:36   ` [PATCH 0/3] DT labels for connector device mapping Jorge Ramirez-Ortiz
2015-12-10 21:36     ` Jorge Ramirez-Ortiz
     [not found]     ` <5669F053.4080509-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2015-12-11  0:00       ` Rob Herring
2015-12-11  0:00         ` Rob Herring
2015-12-22 19:25   ` Olof Johansson
2015-12-22 19:25     ` Olof Johansson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.