From patchwork Wed May 22 20:21:54 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Sean Paul X-Patchwork-Id: 10956687 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D9B1D76 for ; Wed, 22 May 2019 20:22:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DF0782239C for ; Wed, 22 May 2019 20:22:11 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CED68202A5; Wed, 22 May 2019 20:22:11 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2D7FC1FE84 for ; Wed, 22 May 2019 20:22:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729632AbfEVUWK (ORCPT ); Wed, 22 May 2019 16:22:10 -0400 Received: from mail-qk1-f195.google.com ([209.85.222.195]:44370 "EHLO mail-qk1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729619AbfEVUWK (ORCPT ); Wed, 22 May 2019 16:22:10 -0400 Received: by mail-qk1-f195.google.com with SMTP id w25so2351209qkj.11 for ; Wed, 22 May 2019 13:22:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=poorly.run; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=zmy7j+V2kfqtYYz1WddkagE0DXlderr4yqX5VeQ0jxE=; b=Wv7fYjcBuPUYR9MTgyDgURjkjHlUrU+vf2Rjh5kikh+aeZcuBsA45dQS0W772uQXyR wJy78nYNEK2ip1KWnGM2LE22p5ty2akRWDyauopLTLGmMOimVzjTRVfFCtf1un/wRAhF H39a8cuaCC555EA90d9ghjrpvYjUMsCiJYkUByOaPQzw83C2xylldr98kJUHCtnGmcLy ZKCvmW1B9b0npeIxz4U15fKa2mrqGczcA47ac45qCszR0woi68ptU/PdMxnm5xrBbvIY jqHC27QIKbDoyUxjHvLVb6+EEAh2qcJtkbObfDMEZWzFgOk5einIXqDBdrI/NOjAONzY Br6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=zmy7j+V2kfqtYYz1WddkagE0DXlderr4yqX5VeQ0jxE=; b=IEekn6nuMemDQ8AbvegKXI6ZYfHQCsP7uWjM1bMudfSVEhKuWzYuyX6GAlXRGdHngG yH/BSUFywvfw/dS94yJR/8IUdG8kRAj+SZs+28/7ZUQmV+At9qwq3T0QLLtaGRAK4NV6 xaVkfJsLPMRxJSYeu7MXwG9/KJhn95utgZ4jHLkfTXsd+uDt4BTBB9z+YiWmxl4Nm8Ry wWC3EpAOzTX8XkJ9qMlAJBAbNpyRfMcQFnOyc1k+HbYaj6D1+WQaoW1HpvGYoD99jQDr lPilBgQapITTbdLLS73AkkOaaQ4PfMasV8Bz0BHJhpYlFQKIFJuqLW0HvbhUqhLftJ4T G3vg== X-Gm-Message-State: APjAAAWPw4vbLPN9fyBLpjjL9AqkbclK9R4M/TzLGAhdq72rPyMWl0g3 eIMobBPitab0P79qT3NTzhIstA== X-Google-Smtp-Source: APXvYqyr5JtWJBxoh41hbTAkOsXHCvEtb3C3/m7M5P7Ry9zlF0gq04xYFw3DvF+dqaIxFQ/JKexWLA== X-Received: by 2002:a05:620a:141c:: with SMTP id d28mr40026915qkj.18.1558556529503; Wed, 22 May 2019 13:22:09 -0700 (PDT) Received: from rosewood.cam.corp.google.com ([2620:0:1013:11:89c6:2139:5435:371d]) by smtp.gmail.com with ESMTPSA id t187sm4546863qkh.10.2019.05.22.13.22.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 22 May 2019 13:22:09 -0700 (PDT) From: Sean Paul To: dri-devel@lists.freedesktop.org Cc: Sean Paul , Uma Shankar , Shashank Sharma , =?utf-8?b?VmlsbGUgU3lyasOkbMOk?= , Maarten Lankhorst , Maxime Ripard , Sean Paul , David Airlie , Daniel Vetter , Bartlomiej Zolnierkiewicz , Hans Verkuil , linux-fbdev@vger.kernel.org, CK Hu , Philipp Zabel , Matthias Brugger , linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: [PATCH] drm/mediatek: Fix warning about unhandled enum value Date: Wed, 22 May 2019 16:21:54 -0400 Message-Id: <20190522202207.223110-1-sean@poorly.run> X-Mailer: git-send-email 2.21.0.1020.gf2820cf01a-goog MIME-Version: 1.0 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Sean Paul Fixes the following build warning: drivers/gpu/drm/mediatek/mtk_hdmi.c:327:2: warning: enumeration value ‘HDMI_INFOFRAME_TYPE_DRM’ not handled in switch [-Wswitch] Introduced with the addition of HDMI_INFOFRAME_TYPE_DRM in the commit below, but the code really should have been future-proofed from the start. Fixes: 2cdbfd66a829 ("drm: Enable HDR infoframe support") Cc: Uma Shankar Cc: Shashank Sharma Cc: Ville Syrjälä Cc: Maarten Lankhorst Cc: Maxime Ripard Cc: Sean Paul Cc: David Airlie Cc: Daniel Vetter Cc: Bartlomiej Zolnierkiewicz Cc: "Ville Syrjälä" Cc: Hans Verkuil Cc: dri-devel@lists.freedesktop.org Cc: linux-fbdev@vger.kernel.org Signed-off-by: Sean Paul Acked-by: CK Hu --- drivers/gpu/drm/mediatek/mtk_hdmi.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_hdmi.c b/drivers/gpu/drm/mediatek/mtk_hdmi.c index e04e6c293d39..10cc9910f164 100644 --- a/drivers/gpu/drm/mediatek/mtk_hdmi.c +++ b/drivers/gpu/drm/mediatek/mtk_hdmi.c @@ -341,6 +341,9 @@ static void mtk_hdmi_hw_send_info_frame(struct mtk_hdmi *hdmi, u8 *buffer, ctrl_frame_en = VS_EN; ctrl_reg = GRL_ACP_ISRC_CTRL; break; + default: + dev_err(hdmi->dev, "Unknown infoframe type %d\n", frame_type); + return; } mtk_hdmi_clear_bits(hdmi, ctrl_reg, ctrl_frame_en); mtk_hdmi_write(hdmi, GRL_INFOFRM_TYPE, frame_type);