From: jsg Date: Mon, 19 Jul 2021 10:51:58 +0000 (+0000) Subject: drm/i915/display: Do not zero past infoframes.vsc X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=0abc5c1f423b1dfaf5246579ce89f28217b31cda;p=openbsd drm/i915/display: Do not zero past infoframes.vsc From Kees Cook 3f9c2a058e61b8df9fef196ad6180fbf9932ed80 in linux 5.10.y/5.10.51 07b72960d2b4a087ff2445e286159e69742069cc in mainline linux --- diff --git a/sys/dev/pci/drm/i915/display/intel_dp.c b/sys/dev/pci/drm/i915/display/intel_dp.c index 6beb5d14656..7f2727c077a 100644 --- a/sys/dev/pci/drm/i915/display/intel_dp.c +++ b/sys/dev/pci/drm/i915/display/intel_dp.c @@ -5080,7 +5080,7 @@ static int intel_dp_vsc_sdp_unpack(struct drm_dp_vsc_sdp *vsc, if (size < sizeof(struct dp_sdp)) return -EINVAL; - memset(vsc, 0, size); + memset(vsc, 0, sizeof(*vsc)); if (sdp->sdp_header.HB0 != 0) return -EINVAL;