diff options
author | Rob Herring <robh@kernel.org> | 2023-08-18 15:40:57 -0500 |
---|---|---|
committer | Rob Herring <robh@kernel.org> | 2023-08-21 09:23:55 -0500 |
commit | 914d9d831e6126a6e7a92e27fcfaa250671be42c (patch) | |
tree | 07c518abf9338f6aea334f7f6347c0371bd7a336 /drivers/net/ethernet/intel/igc/igc_base.c | |
parent | 0aeae3788e28f64ccb95405d4dc8cd80637ffaea (diff) |
of: dynamic: Refactor action prints to not use "%pOF" inside devtree_lock
While originally it was fine to format strings using "%pOF" while
holding devtree_lock, this now causes a deadlock. Lockdep reports:
of_get_parent from of_fwnode_get_parent+0x18/0x24
^^^^^^^^^^^^^
of_fwnode_get_parent from fwnode_count_parents+0xc/0x28
fwnode_count_parents from fwnode_full_name_string+0x18/0xac
fwnode_full_name_string from device_node_string+0x1a0/0x404
device_node_string from pointer+0x3c0/0x534
pointer from vsnprintf+0x248/0x36c
vsnprintf from vprintk_store+0x130/0x3b4
Fix this by moving the printing in __of_changeset_entry_apply() outside
the lock. As the only difference in the multiple prints is the action
name, use the existing "action_names" to refactor the prints into a
single print.
Fixes: a92eb7621b9fb2c2 ("lib/vsprintf: Make use of fwnode API to obtain node names and separators")
Cc: stable@vger.kernel.org
Reported-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/20230801-dt-changeset-fixes-v3-2-5f0410e007dd@kernel.org
Signed-off-by: Rob Herring <robh@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/intel/igc/igc_base.c')
0 files changed, 0 insertions, 0 deletions