Commit c69f271
drm/radeon: Avoid power table parsing memory leaks
Avoid leaving a hanging pre-allocated clock_info if last mode is
invalid, and avoid heap corruption if no valid modes are found.
Bug: https://bugzilla.kernel.org/show_bug.cgi?id=211537
Fixes: 6991b8f ("drm/radeon/kms: fix segfault in pm rework")
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>1 parent 5bbf219 commit c69f271
1 file changed
Lines changed: 15 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2120 | 2120 | | |
2121 | 2121 | | |
2122 | 2122 | | |
2123 | | - | |
2124 | | - | |
2125 | | - | |
| 2123 | + | |
| 2124 | + | |
| 2125 | + | |
| 2126 | + | |
| 2127 | + | |
| 2128 | + | |
2126 | 2129 | | |
2127 | | - | |
| 2130 | + | |
2128 | 2131 | | |
2129 | 2132 | | |
2130 | 2133 | | |
| |||
2243 | 2246 | | |
2244 | 2247 | | |
2245 | 2248 | | |
| 2249 | + | |
| 2250 | + | |
| 2251 | + | |
| 2252 | + | |
| 2253 | + | |
| 2254 | + | |
| 2255 | + | |
2246 | 2256 | | |
2247 | | - | |
| 2257 | + | |
2248 | 2258 | | |
2249 | 2259 | | |
2250 | 2260 | | |
| |||
0 commit comments