Re: [PATCH 075/190] Revert "gma/gma500: fix a memory disclosure bug due to uninitialized bytes"
From: Pavel Machek
Date: Thu Apr 29 2021 - 16:23:04 EST
Hi!
> drivers/gpu/drm/gma500/cdv_intel_display.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/gma500/cdv_intel_display.c b/drivers/gpu/drm/gma500/cdv_intel_display.c
> index 5d3302249779..f89c2088dc2d 100644
> --- a/drivers/gpu/drm/gma500/cdv_intel_display.c
> +++ b/drivers/gpu/drm/gma500/cdv_intel_display.c
> @@ -405,8 +405,6 @@ static bool cdv_intel_find_dp_pll(const struct gma_limit_t *limit,
> struct gma_crtc *gma_crtc = to_gma_crtc(crtc);
> struct gma_clock_t clock;
>
> - memset(&clock, 0, sizeof(clock));
> -
> switch (refclk) {
> case 27000:
> if (target < 200000) {
Original description is correct, we are returning with .vco and .dot
unitialized which is at least very very ugly, so we should keep the
memset and not revert this.
Best regards,
Pavel
--
http://www.livejournal.com/~pavelmachek
Attachment:
signature.asc
Description: Digital signature