From: Dan Carpenter Subject: re: drm/radeon/kms: get HPD info for connectors Date: Fri, 21 Jun 2013 15:25:53 +0300 Message-ID: <20130621122553.GB24059@elgon.mountain> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from userp1040.oracle.com (userp1040.oracle.com [156.151.31.81]) by gabe.freedesktop.org (Postfix) with ESMTP id BEEEBE65C8 for ; Fri, 21 Jun 2013 05:26:02 -0700 (PDT) Content-Disposition: inline List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: alexdeucher@gmail.com Cc: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org Hello Alex Deucher, The patch eed45b30cd14: "drm/radeon/kms: get HPD info for connectors" from Dec 4, 2009, leads to the following warning: "drivers/gpu/drm/radeon/radeon_atombios.c:950 radeon_get_atom_connector_info_from_supported_devices_table() error: buffer overflow 'supported_devices->info.asConnInfo' 10 <= 15" drivers/gpu/drm/radeon/radeon_atombios.c 943 if (frev > 1) 944 max_device = ATOM_MAX_SUPPORTED_DEVICE; 945 else 946 max_device = ATOM_MAX_SUPPORTED_DEVICE_INFO; 947 948 for (i = 0; i < max_device; i++) { 949 ATOM_CONNECTOR_INFO_I2C ci = 950 supported_devices->info.asConnInfo[i]; If max_device is set to ATOM_MAX_SUPPORTED_DEVICE then we read beyond the end of the asConnInfo[] array and crash. 951 952 bios_connectors[i].valid = false; 953 regards, dan carpenter