summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorAndres Salomon <dilinger@queued.net>2011-02-23 22:38:22 -0800
committerGrant Likely <grant.likely@secretlab.ca>2011-03-02 13:45:19 -0700
commita74ea43df1afc68f265c0ac2cb64031d855ae97b (patch)
tree7e3b00d2493bd19c408df10a55daf111375c9104 /arch
parent60cba5a57b8affe98ea9f2bac147be0fb253d5f4 (diff)
downloadkernel-common-a74ea43df1afc68f265c0ac2cb64031d855ae97b.tar.gz
kernel-common-a74ea43df1afc68f265c0ac2cb64031d855ae97b.tar.bz2
kernel-common-a74ea43df1afc68f265c0ac2cb64031d855ae97b.zip
of/promtree: allow DT device matching by fixing 'name' brokenness (v5)
Commit e2f2a93b, "of/promtree: add package-to-path support to pdt" changed dp->name from using the 'name' property to using package-to-path. This fixed /proc/device-tree creation by eliminating conflicts between names (the 'name' property provides names like 'battery', whereas package-to-path provides names like '/foo/bar/battery@0', which we stripped to 'battery@0'). However, it also breaks of_device_id table matching. The fix that we _really_ wanted was to keep dp->name based upon the name property ('battery'), but based dp->full_name upon package-to-path ('battery@0'). This patch does just that. This changes all users (except SPARC) of promtree to use the full result from package-to-path for full_name, rather than stripping the directory out. In practice, the strings end up being exactly the same; this change saves time, code, and memory. SPARC continues to use the existing build_path_component() code. v2: combine two patches and revert of_pdt_node_name to original version v3: use dp->phandle instead of passing around node v4: warn/bail out for non-sparc archs if pkg2path is not set v5: split of_pdt_build_full_name into sparc & non-sparc versions v6: Pass NULL to pkg2path before buf gets assigned. Drop check for pkg2path hook on each and every node. v7: Don't BUG() when unable to get the full_path; create a known-unique name instead. Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions