Skip to content

Commit

Permalink
powerpc/pseries/mobility: Add pr_debug() for device tree changes
Browse files Browse the repository at this point in the history
When investigating issues with partition migration or resource
reassignments it is helpful to have a log of which nodes and
properties in the device tree have changed. Use pr_debug() so it's
easy to enable these at runtime with the dynamic debug facility.

Signed-off-by: Nathan Lynch <nathanl@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20190627053044.9238-3-nathanl@linux.ibm.com
  • Loading branch information
Nathan Lynch authored and Michael Ellerman committed Jul 30, 2020
1 parent 494a66f commit 5d8b1f9
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions arch/powerpc/platforms/pseries/mobility.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ static int delete_dt_node(__be32 phandle)
if (!dn)
return -ENOENT;

pr_debug("removing node %pOFfp\n", dn);

dlpar_detach_node(dn);
of_node_put(dn);
return 0;
Expand Down Expand Up @@ -125,6 +127,7 @@ static int update_dt_property(struct device_node *dn, struct property **prop,
}

if (!more) {
pr_debug("updating node %pOF property %s\n", dn, name);
of_update_property(dn, new_prop);
*prop = NULL;
}
Expand Down Expand Up @@ -243,6 +246,8 @@ static int add_dt_node(__be32 parent_phandle, __be32 drc_index)
if (rc)
dlpar_free_cc_nodes(dn);

pr_debug("added node %pOFfp\n", dn);

of_node_put(parent_dn);
return rc;
}
Expand Down

0 comments on commit 5d8b1f9

Please sign in to comment.