From: Grant Likely Date: Wed, 21 May 2014 06:40:31 +0000 (+0900) Subject: of: Ensure unique names without sacrificing determinism X-Git-Tag: omap-for-v3.16/fixes-against-rc1~56^2~21^2~5^2~11 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=07e461cd7e73a84f0e3757932b93cc80976fd749;p=pandora-kernel.git of: Ensure unique names without sacrificing determinism The way the driver core is implemented, every device using the same bus type is required to have a unique name because a symlink to each device is created in the appropriate /sys/bus/*/devices directory, and two identical names causes a collision. The current code handles the requirement by using an globally incremented counter that is appended to the device name. It works, but it means any change to device registration will change the assigned numbers. Instead, if we build up the name by using information from the parent nodes, then it can be guaranteed to be unique without adding a random number to the end of it. Signed-off-by: Grant Likely Cc: Ezequiel Garcia Cc: Rob Herring --- Reading git-diff-tree failed