Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp658196pxb; Tue, 5 Apr 2022 17:37:03 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz5Hk4LXBlhpCwdWNrJmG9zAp0WWG/qBL7RoSPcKbDDC6m1AfnVWUoPtodSOx7Q2l5kwtmj X-Received: by 2002:a05:6402:1148:b0:416:a4fb:3c2e with SMTP id g8-20020a056402114800b00416a4fb3c2emr6214957edw.182.1649205339106; Tue, 05 Apr 2022 17:35:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649205339; cv=none; d=google.com; s=arc-20160816; b=H/tS5aQb7hwhyCLMjoX1H/GaVfebspLVQ9ssYPUW6OTazvxOPcoW6MEPLgO+M+8wXp gVjhCEntKvXi20Ik+vcunU+/CJmhiskYSIYiu0Un7bYseWP2ViI4hPIywuLxGKYp+xAe /6CZdWXi66LXMNw7TIZ3NH4Xy/26RNbRqDSpLQr4VwN9v+osrUJZ1a6lKKNoxUzsHLsz hHiAyC+EYhST+feyYDqL94QYzrJhSzzyZxlmtO3vmHyonkEvO+/wPibl15w3sB+1kwRZ YebGGn4rflmqVcj4HmWp3G4UD06n6ikQjmpaHPOLCjD8hOBeY3MnlFRM38aaS+AFR2xu LhHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=2FP+HfJw4xoiD6KHq6an/b9ttE6If6K56wqm0ub8xIQ=; b=UarTven9Nxa8wvNY+pI8fcHUcyDLe3eL10t5936IbgpZwCUFu1SrlQyv1Cwc8kSRAL we0rVA7TXCi7gdnu5cK5Ys1ASaHHhu8qAsfGAEI3Iowr+C+uHGjryGFc3qjAzgmTM9jG g3b3Tfmb2zsz4fFaE4PD6YlhAFb03xprG7NcWmiCIN4zXsZ2Cb88ikQU4k8jcKpGZjEj +MESNxUe31m969tdi5KTIlRD9v/QnoxzG6ge7SFWLzFM8hqoZvjElZF1iXGXFY5ld2VT xwLqmdcsMwxgTw81TBaV1ZLibf41w+i2bjSFXpr04wese7/eHUm55ZxpbB0zoHfzEjVJ deGg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PSGZrzyB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id eb11-20020a0564020d0b00b00418c2b5be00si12633487edb.226.2022.04.05.17.35.14; Tue, 05 Apr 2022 17:35:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PSGZrzyB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245028AbiDEMCO (ORCPT + 99 others); Tue, 5 Apr 2022 08:02:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46614 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243056AbiDEItt (ORCPT ); Tue, 5 Apr 2022 04:49:49 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0D7981D0DD; Tue, 5 Apr 2022 01:38:13 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 06D1AB81B18; Tue, 5 Apr 2022 08:37:48 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 692BFC385A1; Tue, 5 Apr 2022 08:37:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1649147866; bh=+cvy/v5TGZXagD6fIYk4pEytVC1K83ILUAf1awavJYs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PSGZrzyBO5vhLMgFcgWU7Zk2GIkTQHaXIL3ioYzRC6Jv7N67AXeSLFzWadrLOaT1a V25oc34QF5gr8Oo7L2xBe03CVgae9UPB1BfDfKACscmjIumZeLjmVM7sDm0gVRQm4i +wGgN6Z34R0K2lIAyjeBBE9WzNr2PvmjNR3goj5I= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jani Nikula , Shawn C Lee , intel-gfx , Cooper Chiou Subject: [PATCH 5.16 0149/1017] drm/edid: check basic audio support on CEA extension block Date: Tue, 5 Apr 2022 09:17:42 +0200 Message-Id: <20220405070358.630157664@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220405070354.155796697@linuxfoundation.org> References: <20220405070354.155796697@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Cooper Chiou commit 5662abf6e21338be6d085d6375d3732ac6147fd2 upstream. Tag code stored in bit7:5 for CTA block byte[3] is not the same as CEA extension block definition. Only check CEA block has basic audio support. v3: update commit message. Cc: stable@vger.kernel.org Cc: Jani Nikula Cc: Shawn C Lee Cc: intel-gfx Signed-off-by: Cooper Chiou Signed-off-by: Lee Shawn C Fixes: e28ad544f462 ("drm/edid: parse CEA blocks embedded in DisplayID") Reviewed-by: Jani Nikula Signed-off-by: Jani Nikula Link: https://patchwork.freedesktop.org/patch/msgid/20220324061218.32739-1-shawn.c.lee@intel.com Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/drm_edid.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) --- a/drivers/gpu/drm/drm_edid.c +++ b/drivers/gpu/drm/drm_edid.c @@ -4848,7 +4848,8 @@ bool drm_detect_monitor_audio(struct edi if (!edid_ext) goto end; - has_audio = ((edid_ext[3] & EDID_BASIC_AUDIO) != 0); + has_audio = (edid_ext[0] == CEA_EXT && + (edid_ext[3] & EDID_BASIC_AUDIO) != 0); if (has_audio) { DRM_DEBUG_KMS("Monitor has basic audio support\n");