Gong Yuanjun
28fd384c78
drm/radeon: fix a possible null pointer dereference
...
[ Upstream commit a2b28708b645c5632dc93669ab06e97874c8244f ]
In radeon_fp_native_mode(), the return value of drm_mode_duplicate()
is assigned to mode, which will lead to a NULL pointer dereference
on failure of drm_mode_duplicate(). Add a check to avoid npd.
The failure status of drm_cvt_mode() on the other path is checked too.
Signed-off-by: Gong Yuanjun <ruc_gongyuanjun@163.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-06-14 18:12:01 +02:00
..
2022-06-14 18:11:46 +02:00
2022-06-14 18:11:32 +02:00
2019-08-14 18:31:10 +02:00
2020-12-30 11:51:01 +01:00
2019-09-19 16:24:24 -07:00
2020-02-11 04:35:36 -08:00
2020-08-11 15:33:37 +02:00
2022-06-14 18:11:47 +02:00
2022-06-14 18:11:47 +02:00
2021-09-22 12:26:34 +02:00
2019-08-10 15:41:48 +02:00
2022-06-14 18:11:49 +02:00
2021-03-07 12:20:45 +01:00
2019-08-14 18:30:52 +02:00
2019-12-13 08:42:56 +01:00
2022-06-06 08:33:50 +02:00
2022-06-14 18:11:58 +02:00
2020-09-03 11:26:52 +02:00
2022-01-27 09:19:40 +01:00
2020-12-30 11:51:01 +01:00
2022-06-14 18:11:32 +02:00
2021-08-18 08:56:59 +02:00
2019-06-30 09:48:05 +02:00
2019-12-21 11:04:54 +01:00
2022-06-14 18:11:38 +02:00
2021-07-19 08:53:07 +02:00
2022-06-14 18:11:47 +02:00
2020-12-30 11:51:09 +01:00
2022-04-27 13:50:49 +02:00
2021-09-22 12:26:38 +02:00
2019-08-09 09:15:05 +02:00
2021-07-14 16:53:28 +02:00
2019-07-17 12:52:55 +02:00
2022-06-14 18:12:01 +02:00
2020-06-30 15:37:11 -04:00
2022-06-14 18:11:35 +02:00
2021-07-19 08:53:08 +02:00
2020-03-12 13:00:11 +01:00
2019-07-15 18:11:31 +02:00
2019-08-07 13:54:17 +02:00
2020-08-19 08:16:11 +02:00
2022-03-16 13:21:45 +01:00
2019-07-17 12:52:55 +02:00
2022-04-15 14:18:14 +02:00
2022-06-14 18:11:49 +02:00
2019-10-10 15:15:51 +02:00
2021-11-06 13:59:45 +01:00
2020-12-30 11:51:01 +01:00
2021-11-26 10:47:22 +01:00
2021-11-17 09:48:34 +01:00
2019-08-18 12:52:52 +02:00
2022-06-14 18:11:32 +02:00
2020-08-26 10:40:47 +02:00
2019-09-24 15:54:08 -07:00
2022-06-14 18:11:24 +02:00
2021-05-11 14:04:10 +02:00
2022-05-18 09:47:28 +02:00
2020-09-03 11:26:50 +02:00
2021-07-19 08:53:07 +02:00
2019-07-19 23:24:16 +02:00
2019-07-16 11:25:02 +02:00
2021-01-27 11:47:42 +01:00
2019-09-18 18:43:36 +02:00
2019-09-18 18:42:57 +02:00
2019-09-23 15:31:53 +08:00
2021-06-16 11:59:39 +02:00
2019-07-15 19:04:27 -07:00
2020-03-25 08:25:50 +01:00
2019-08-01 15:01:29 +02:00
2022-03-19 13:40:17 +01:00
2019-08-16 15:50:27 +03:00
2019-12-13 08:42:55 +01:00
2020-10-29 09:57:37 +01:00
2021-09-22 12:26:27 +02:00
2019-07-16 11:25:02 +02:00
2020-12-30 11:51:41 +01:00
2019-07-17 12:45:30 -04:00
2022-05-25 09:14:34 +02:00
2019-09-18 11:27:18 +02:00
2019-08-07 11:56:48 -04:00
2022-06-14 18:11:31 +02:00
2020-06-24 17:50:47 +02:00
2021-03-04 10:26:19 +01:00
2019-07-22 16:04:53 -04:00
2019-08-13 09:09:30 +02:00
2021-03-17 17:03:38 +01:00
2019-08-06 08:21:54 +02:00
2020-08-19 08:16:05 +02:00
2019-08-06 13:18:42 +05:30
2021-09-03 10:08:15 +02:00
2021-07-28 13:31:01 +02:00
2019-08-22 10:41:06 +03:00
2020-03-25 08:25:56 +01:00
2019-07-16 11:25:02 +02:00
2019-07-16 11:25:02 +02:00
2019-07-16 11:25:02 +02:00
2020-08-05 09:59:44 +02:00
2020-08-19 08:16:08 +02:00
2019-06-26 21:13:12 +01:00
2019-09-18 11:27:18 +02:00
2020-03-12 13:00:11 +01:00
2019-07-16 12:21:41 -07:00
2022-04-15 14:18:31 +02:00
2019-08-10 15:41:48 +02:00
2020-04-17 10:50:20 +02:00
2021-11-17 09:48:44 +01:00
2022-06-14 18:11:26 +02:00
2019-07-31 10:19:23 +02:00
2020-01-04 19:18:43 +01:00
2020-02-11 04:35:36 -08:00
2019-07-16 11:25:02 +02:00
2019-11-06 13:00:21 -05:00
2021-12-14 14:49:01 +01:00
2020-06-24 17:50:50 +02:00
2019-12-31 16:43:50 +01:00
2019-07-16 11:25:02 +02:00
2019-09-23 15:32:53 +08:00
2021-03-30 14:35:22 +02:00
2019-08-27 10:09:12 -05:00