]> git.baikalelectronics.ru Git - kernel.git/commit
of: Fix cpu node iterator to not ignore disabled cpu nodes
authorRob Herring <robh@kernel.org>
Wed, 31 Oct 2018 14:28:06 +0000 (09:28 -0500)
committerRob Herring <robh@kernel.org>
Thu, 1 Nov 2018 21:16:54 +0000 (16:16 -0500)
commit9cd6ebb02f91da9a720470cd9b72e53b2e05871c
tree7cc7e9fb98472b595e7e3ab7b0de3fbcfc428af5
parent7a0b378a04463279ea950a4761c5495e9e4260e6
of: Fix cpu node iterator to not ignore disabled cpu nodes

In most cases, nodes with 'status = "disabled";' are treated as if the
node is not present though it is a common bug to forget to check that.
However, cpu nodes are different in that "disabled" simply means offline
and the OS can bring the CPU core online. Commit 769cff0a78d0 ("of: Add
cpu node iterator for_each_of_cpu_node()") followed the common behavior
of ignoring disabled cpu nodes. This breaks some powerpc systems (at
least NXP P50XX/e5500). Fix this by dropping the status check.

Fixes: cb75c0b43c51 ("of: use for_each_of_cpu_node iterator")
Fixes: 769cff0a78d0 ("of: Add cpu node iterator for_each_of_cpu_node()")
Reported-by: Christian Zigotzky <chzigotzky@xenosoft.de>
Tested-by: Michael Ellerman <mpe@ellerman.id.au>
Cc: Frank Rowand <frowand.list@gmail.com>
Signed-off-by: Rob Herring <robh@kernel.org>
drivers/of/base.c