lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 22 Mar 2019 15:56:12 -0500
From:   Reza Arbab <arbab@...ux.ibm.com>
To:     Dave Airlie <airlied@...hat.com>, Sean Paul <sean@...rly.run>,
        David Airlie <airlied@...ux.ie>,
        Daniel Vetter <daniel@...ll.ch>,
        Robert Tarasov <tutankhamen@...omium.org>,
        Linus Walleij <linus.walleij@...aro.org>,
        dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org
Cc:     wzabolot@...ktron.elka.pw.edu.pl, Pavel Machek <pavel@....cz>,
        Alex Deucher <alexander.deucher@....com>,
        Noralf Trønnes <noralf@...nnes.org>,
        Ville Syrjälä 
        <ville.syrjala@...ux.intel.com>
Subject: [PATCH 1/2] drm/udl: Fix off-by-one error in udl_get_edid()

The loop which reads EDID extension blocks is off by one. Fix it.

Fixes: 75c65ee20ade ("drm/udl: Reading all edid blocks in DRM/UDL driver")
Signed-off-by: Reza Arbab <arbab@...ux.ibm.com>
---
 drivers/gpu/drm/udl/udl_connector.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/udl/udl_connector.c b/drivers/gpu/drm/udl/udl_connector.c
index 66885c24590f..820543415a78 100644
--- a/drivers/gpu/drm/udl/udl_connector.c
+++ b/drivers/gpu/drm/udl/udl_connector.c
@@ -71,7 +71,7 @@ static bool udl_get_edid(struct udl_device *udl, u8 **result_buff,
 			memcpy(buff_ptr, block_buff, EDID_LENGTH);
 			kfree(block_buff);
 			buff_ptr += EDID_LENGTH;
-			for (i = 1; i < extensions; ++i) {
+			for (i = 1; i <= extensions; ++i) {
 				if (udl_get_edid_block(udl, i, buff_ptr)) {
 					buff_ptr += EDID_LENGTH;
 				} else {
-- 
1.8.3.1

Powered by blists - more mailing lists