From b2ea73e3bb96e18261d370bf076791b9f79ad52a Mon Sep 17 00:00:00 2001 From: Zbigniew Bodek Date: Wed, 20 Jan 2016 13:35:06 +0000 Subject: [PATCH] Do not require strict compatibility on simplebus Strict compatibility requirement is a root of problems when simplebus' node has two compatibility strings (i.e. on Armada38x). Removing this requirement should not interfere with other platforms. fdt_is_compatible_strict() and fdt_find_compatible() calls were changed in fdt_common.c and mv_common.c. Reviewed by: ian, imp Obtained from: Semihalf Sponsored by: Stormshield Submitted by: Bartosz Szczepanek Differential revision: https://reviews.freebsd.org/D4602 --- sys/arm/mv/mv_common.c | 2 +- sys/dev/fdt/fdt_common.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/arm/mv/mv_common.c b/sys/arm/mv/mv_common.c index 6b234a4e08c..bc0ed4d9715 100644 --- a/sys/arm/mv/mv_common.c +++ b/sys/arm/mv/mv_common.c @@ -2064,7 +2064,7 @@ fdt_win_setup(void) */ child = OF_peer(child); if ((child == 0) && (node == OF_finddevice("/"))) { - node = fdt_find_compatible(node, "simple-bus", 1); + node = fdt_find_compatible(node, "simple-bus", 0); if (node == 0) return (ENXIO); child = OF_child(node); diff --git a/sys/dev/fdt/fdt_common.c b/sys/dev/fdt/fdt_common.c index f00519e5646..c7d33976bf3 100644 --- a/sys/dev/fdt/fdt_common.c +++ b/sys/dev/fdt/fdt_common.c @@ -212,7 +212,7 @@ fdt_immr_addr(vm_offset_t immr_va) * Try to access the SOC node directly i.e. through /aliases/. */ if ((node = OF_finddevice("soc")) != 0) - if (fdt_is_compatible_strict(node, "simple-bus")) + if (fdt_is_compatible(node, "simple-bus")) goto moveon; /* * Find the node the long way. @@ -220,7 +220,7 @@ fdt_immr_addr(vm_offset_t immr_va) if ((node = OF_finddevice("/")) == 0) return (ENXIO); - if ((node = fdt_find_compatible(node, "simple-bus", 1)) == 0) + if ((node = fdt_find_compatible(node, "simple-bus", 0)) == 0) return (ENXIO); moveon: