Johan Hovold
f3e3c50c36
of: add helper to lookup compatible child node
...
[ Upstream commit 36156f9241 ]
Add of_get_compatible_child() helper that can be used to lookup
compatible child nodes.
Several drivers currently use of_find_compatible_node() to lookup child
nodes while failing to notice that the of_find_ functions search the
entire tree depth-first (from a given start node) and therefore can
match unrelated nodes. The fact that these functions also drop a
reference to the node they start searching from (e.g. the parent node)
is typically also overlooked, something which can lead to use-after-free
bugs.
Signed-off-by: Johan Hovold <johan@kernel.org >
Signed-off-by: Rob Herring <robh@kernel.org >
Signed-off-by: Sasha Levin <sashal@kernel.org >
2018-12-01 09:46:35 +01:00
..
2018-12-01 09:46:34 +01:00
2018-11-21 09:27:42 +01:00
2018-08-24 13:27:00 +02:00
2018-07-03 11:21:30 +02:00
2018-04-13 19:50:17 +02:00
2018-04-13 19:50:10 +02:00
2018-08-06 16:24:36 +02:00
2018-05-02 07:53:42 -07:00
2018-11-27 16:08:01 +01:00
2018-10-13 09:11:35 +02:00
2018-10-10 08:52:09 +02:00
2018-05-30 07:49:13 +02:00
2018-04-08 11:51:57 +02:00
2018-04-24 09:32:12 +02:00
2018-04-24 09:32:12 +02:00
2018-07-03 11:21:35 +02:00
2018-11-10 07:41:37 -08:00
2018-07-22 14:25:51 +02:00
2018-07-22 14:25:51 +02:00
2018-07-03 11:21:28 +02:00
2018-08-15 17:42:09 +02:00
2018-11-10 07:41:43 -08:00
2018-04-08 11:51:57 +02:00
2018-05-30 07:48:52 +02:00
2018-02-25 11:03:46 +01:00
2018-08-06 16:24:36 +02:00
2018-05-26 08:49:00 +02:00
2018-05-26 08:48:56 +02:00
2018-02-25 11:03:53 +01:00
2018-06-16 09:54:26 +02:00
2018-04-24 09:32:07 +02:00
2018-11-21 09:27:44 +01:00
2018-10-20 09:52:38 +02:00
2018-11-21 09:27:42 +01:00
2018-04-29 07:50:05 +02:00
2018-02-25 11:03:54 +01:00
2018-09-09 20:04:35 +02:00
2018-09-09 20:04:36 +02:00
2018-04-08 11:51:57 +02:00
2018-02-22 15:45:01 +01:00
2018-11-27 16:07:57 +01:00
2018-07-17 11:31:43 +02:00
2018-04-08 11:51:59 +02:00
2018-09-19 22:49:00 +02:00
2018-11-21 09:27:44 +01:00
2018-11-27 16:07:58 +01:00
2018-02-25 11:03:48 +01:00
2018-10-20 09:52:36 +02:00
2018-07-25 10:18:27 +02:00
2018-12-01 09:46:35 +01:00
2018-03-22 09:23:22 +01:00
2018-03-24 10:58:40 +01:00
2018-11-10 07:41:35 -08:00
2018-08-09 12:19:28 +02:00
2018-09-19 22:49:00 +02:00
2018-07-25 10:18:27 +02:00
2018-05-26 08:48:54 +02:00
2018-10-13 09:11:34 +02:00
2018-10-10 08:52:08 +02:00
2018-02-25 11:03:36 +01:00
2018-05-30 07:48:55 +02:00
2018-08-15 17:42:10 +02:00
2018-09-05 09:18:40 +02:00
2018-11-21 09:27:36 +01:00
2018-10-13 09:11:34 +02:00
2018-08-15 17:42:05 +02:00
2018-05-26 08:49:00 +02:00
2018-05-02 07:53:40 -07:00
2018-11-27 16:08:02 +01:00
2018-05-02 07:53:40 -07:00
2018-09-19 22:49:00 +02:00
2018-09-19 22:49:00 +02:00
2018-03-18 11:17:48 +01:00