Commit 3d6955b
drm/etnaviv: fix ref count leak via pm_runtime_get_sync
[ Upstream commit c5d5a32 ]
in etnaviv_gpu_submit, etnaviv_gpu_recover_hang, etnaviv_gpu_debugfs,
and etnaviv_gpu_init the call to pm_runtime_get_sync increments the
counter even in case of failure, leading to incorrect ref count.
In case of failure, decrement the ref count before returning.
Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>1 parent 6569387 commit 3d6955b
1 file changed
Lines changed: 10 additions & 4 deletions
File tree
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
694 | 694 | | |
695 | 695 | | |
696 | 696 | | |
697 | | - | |
| 697 | + | |
698 | 698 | | |
699 | 699 | | |
700 | 700 | | |
| |||
808 | 808 | | |
809 | 809 | | |
810 | 810 | | |
| 811 | + | |
811 | 812 | | |
812 | 813 | | |
813 | 814 | | |
| |||
848 | 849 | | |
849 | 850 | | |
850 | 851 | | |
851 | | - | |
| 852 | + | |
852 | 853 | | |
853 | 854 | | |
854 | 855 | | |
| |||
971 | 972 | | |
972 | 973 | | |
973 | 974 | | |
| 975 | + | |
974 | 976 | | |
975 | 977 | | |
976 | 978 | | |
| |||
985 | 987 | | |
986 | 988 | | |
987 | 989 | | |
988 | | - | |
| 990 | + | |
989 | 991 | | |
990 | 992 | | |
991 | 993 | | |
| |||
1005 | 1007 | | |
1006 | 1008 | | |
1007 | 1009 | | |
| 1010 | + | |
1008 | 1011 | | |
1009 | 1012 | | |
1010 | 1013 | | |
| |||
1278 | 1281 | | |
1279 | 1282 | | |
1280 | 1283 | | |
1281 | | - | |
| 1284 | + | |
| 1285 | + | |
1282 | 1286 | | |
| 1287 | + | |
1283 | 1288 | | |
1284 | 1289 | | |
1285 | 1290 | | |
| |||
1296 | 1301 | | |
1297 | 1302 | | |
1298 | 1303 | | |
| 1304 | + | |
1299 | 1305 | | |
1300 | 1306 | | |
1301 | 1307 | | |
| |||
0 commit comments