Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp1068975ybl; Wed, 14 Aug 2019 10:11:54 -0700 (PDT) X-Google-Smtp-Source: APXvYqxzBoptDQ+hw+As1lwPWAWFZbFpgb4qqIvMPTp5zOL8zIAO/XvAOKP/15Ly3BBbofxMcPQX X-Received: by 2002:a17:90a:cc13:: with SMTP id b19mr702323pju.117.1565802714115; Wed, 14 Aug 2019 10:11:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565802714; cv=none; d=google.com; s=arc-20160816; b=hl2JktHUcjChlt9swZVyLqavA6PSM1STbHGG47TunnfQgKKA45t3lNDXZ4U2MKa+BD lk6kVdsMG/U1xtX3/aMc9SI5szkoNlSX+y9zzjjLQW+MWjAuUMbrIw3+757b3DVnEoBq PsB2erXGsU8S+I8SJJb5bJuKGhCA/TGfyk/ZJfHw14A0NzwOe5eglobqH7aMz86s31f1 32Bg5vl6sWFJAlFg+aKLAV5rWYYmINamyZA9FRkyU41zp6ft2XhSq5mWV7pEiqbzUO7B BOQcrpm9zEV3g45pNEF5f+HCbmRXIX/sDqnJm2fsuVBnTTes7u3xw+5M6l9ZR3ObFwoC s/Hg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=FKJkD4CDRjpKTzs4K1t/OJoGKKl/qSwPxeNyTWPBv9c=; b=z8VNJJTi85E9e0espKkWI0Qq6O6oOe7yjMXL1jaFG1bxjjqjjOya/cQEOR41roj/cG Fn7Qryv0tv9yDqf4o/idn+QEu0xCa6ScbqoBGySD4ZUReBq2c6971p1BJ+o/xSCp+bc/ ofSZpmwuC6pCSeB9j1PfwyiTWTtyaqzjLU6W0+/tBrqLMNjbH7YmdnQC6aC5fUACql2x sagV7O6q/cZCzpwal59hTtniTEEx1W2YhSINE4swA6fxHNJjU4ajZndAqUgfy8srjtBo YAiQjeMDWcNyAF4E0Ezw6Wbai7f4lL2CLPFwo/D5Cp8TyKqvwl20h/XI+YcBXmnLhPX3 NzaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=rUu+zpGE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e3si21974pfi.148.2019.08.14.10.11.38; Wed, 14 Aug 2019 10:11:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=rUu+zpGE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730551AbfHNRLH (ORCPT + 99 others); Wed, 14 Aug 2019 13:11:07 -0400 Received: from mail.kernel.org ([198.145.29.99]:34100 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729956AbfHNRLA (ORCPT ); Wed, 14 Aug 2019 13:11:00 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DEC24208C2; Wed, 14 Aug 2019 17:10:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1565802659; bh=BLwjPdtqgfNhqbOrTefGQ/E12D/Jkr6BQ+YzX/qBtxE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=rUu+zpGEM1/0oPFBhblEoUsJdOevC0ZZ+hp1JyU4FyuMtsrJ/Sy8d102u+OmsKtx3 ve7AeAXq1WoMi83g+QQ8VTmXkXEc0DhuvE4E5slTlZPWgAPWwGMbFqdbafYiK4XF+T CcUpK2F2IFWYEJJflev3gM/jv3jxmAgxpeJp6Pg4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Alvin Lee , Jun Lei , Leo Li , Alex Deucher , Sasha Levin Subject: [PATCH 4.19 42/91] drm/amd/display: Only enable audio if speaker allocation exists Date: Wed, 14 Aug 2019 19:01:05 +0200 Message-Id: <20190814165751.409847047@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190814165748.991235624@linuxfoundation.org> References: <20190814165748.991235624@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ Upstream commit 6ac25e6d5b2fbf251e9fa2f4131d42c815b43867 ] [Why] In dm_helpers_parse_edid_caps, there is a corner case where no speakers can be allocated even though the audio mode count is greater than 0. Enabling audio when no speaker allocations exists can cause issues in the video stream. [How] Add a check to not enable audio unless one or more speaker allocations exist (since doing this can cause issues in the video stream). Signed-off-by: Alvin Lee Reviewed-by: Jun Lei Acked-by: Leo Li Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c index 19a951e5818ac..f0d68aa7c8fcc 100644 --- a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c +++ b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c @@ -1956,7 +1956,7 @@ enum dc_status resource_map_pool_resources( /* TODO: Add check if ASIC support and EDID audio */ if (!stream->sink->converter_disable_audio && dc_is_audio_capable_signal(pipe_ctx->stream->signal) && - stream->audio_info.mode_count) { + stream->audio_info.mode_count && stream->audio_info.flags.all) { pipe_ctx->stream_res.audio = find_first_free_audio( &context->res_ctx, pool, pipe_ctx->stream_res.stream_enc->id); -- 2.20.1