Julia Lawall
04c5c4c47c
drm/imx: imx-ldb: add missing of_node_puts
...
[ Upstream commit aa3312012f ]
The device node iterators perform an of_node_get on each
iteration, so a jump out of the loop requires an of_node_put.
Move the initialization channel->child = child; down to just
before the call to imx_ldb_register so that intervening failures
don't need to clear it. Add a label at the end of the function to
do all the of_node_puts.
The semantic patch that finds part of this problem is as follows
(http://coccinelle.lip6.fr ):
// <smpl>
@@
expression root,e;
local idexpression child;
iterator name for_each_child_of_node;
@@
for_each_child_of_node(root, child) {
... when != of_node_put(child)
when != e = child
(
return child;
|
* return ...;
)
...
}
// </smpl>
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr >
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de >
Signed-off-by: Sasha Levin <sashal@kernel.org >
2019-03-23 20:09:41 +01:00
..
2019-03-13 14:02:38 -07:00
2018-07-13 18:40:27 +02:00
2018-09-21 10:55:00 +01:00
2018-07-30 11:53:06 +01:00
2018-12-21 14:15:23 +01:00
2018-07-04 10:27:12 +10:00
2018-07-13 18:40:27 +02:00
2019-02-20 10:25:41 +01:00
2018-07-13 18:40:27 +02:00
2018-11-21 09:19:25 +01:00
2018-11-27 16:13:04 +01:00
2018-07-13 18:40:27 +02:00
2018-08-23 18:48:43 -07:00
2018-11-21 09:19:10 +01:00
2018-10-04 10:32:14 +10:00
2018-07-03 15:00:42 +02:00
2019-02-27 10:09:01 +01:00
2019-03-23 20:09:41 +01:00
2018-11-13 11:08:54 -08:00
2019-02-27 10:08:55 +01:00
2018-07-13 18:40:27 +02:00
2019-03-05 17:58:51 +01:00
2019-02-20 10:25:43 +01:00
2018-11-21 09:19:10 +01:00
2018-08-14 13:42:37 -04:00
2018-09-10 16:01:22 -04:00
2018-07-13 18:40:27 +02:00
2019-03-13 14:02:35 -07:00
2018-11-21 09:19:11 +01:00
2019-02-12 19:47:00 +01:00
2018-07-04 14:27:01 +02:00
2018-08-09 11:57:39 -05:00
2018-06-22 12:58:08 +10:00
2018-07-13 18:40:27 +02:00
2018-07-13 18:40:27 +02:00
2018-07-13 10:11:02 +02:00
2019-03-13 14:02:36 -07:00
2018-08-15 17:39:07 -07:00
2018-07-20 10:46:49 +10:00
2018-07-12 12:10:07 -05:00
2018-12-21 14:15:15 +01:00
2019-01-09 17:38:42 +01:00
2019-02-12 19:47:04 +01:00
2019-02-12 19:46:59 +01:00
2019-02-12 19:46:56 +01:00
2018-07-13 18:40:27 +02:00
2019-02-20 10:25:49 +01:00
2019-02-15 08:10:12 +01:00
2018-06-22 12:58:08 +10:00
2018-07-13 18:40:27 +02:00
2019-03-19 13:12:42 +01:00
2018-10-18 14:23:13 -04:00
2018-12-08 12:59:07 +01:00
2019-02-12 19:46:56 +01:00
2018-10-02 13:03:34 +02:00
2018-07-16 13:18:09 -04:00
2018-07-16 10:01:19 -04:00
2018-07-13 18:40:27 +02:00
2018-10-05 15:55:17 +03:00
2018-07-06 14:57:03 +02:00
2018-09-17 19:24:37 -04:00
2018-07-28 15:50:40 -03:00
2018-07-16 11:47:53 -04:00
2018-11-21 09:19:26 +01:00
2018-07-16 11:47:53 -04:00
2018-06-28 13:29:07 +10:00
2018-11-27 16:12:59 +01:00
2018-10-02 13:03:34 +02:00
2019-01-22 21:40:38 +01:00
2018-07-10 14:51:37 +02:00
2018-07-18 16:56:45 +01:00
2018-07-02 18:45:55 +03:00
2018-06-20 14:43:13 +02:00
2018-07-13 16:14:04 +01:00
2018-06-29 15:28:47 -05:00
2018-12-13 09:16:21 +01:00
2018-12-29 13:37:59 +01:00
2019-02-20 10:25:49 +01:00
2018-07-25 07:51:05 -04:00
2018-06-20 15:30:20 +01:00
2018-07-13 18:40:27 +02:00
2019-02-15 08:10:12 +01:00
2018-07-03 09:46:05 +02:00
2018-07-13 18:40:28 +02:00
2018-11-21 09:19:26 +01:00
2018-09-27 11:00:42 -04:00
2018-07-05 16:40:00 -05:00
2018-07-03 09:30:19 +02:00
2018-07-13 17:58:19 +03:00
2018-06-20 15:59:34 +02:00
2018-07-30 08:49:41 -04:00
2018-07-13 18:40:27 +02:00
2018-07-02 11:05:21 -05:00
2018-07-13 18:40:27 +02:00
2018-09-26 10:39:14 -04:00
2018-12-13 09:16:21 +01:00
2018-06-29 15:28:47 -05:00
2018-07-16 16:35:27 +01:00
2019-01-16 22:04:35 +01:00
2018-07-13 17:58:19 +03:00