From patchwork Sun Jan 24 04:40:10 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Mario Kleiner X-Patchwork-Id: 12042043 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9A591C433E0 for ; Sun, 24 Jan 2021 04:40:25 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 42B3822573 for ; Sun, 24 Jan 2021 04:40:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 42B3822573 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6E13C89D1D; Sun, 24 Jan 2021 04:40:24 +0000 (UTC) Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) by gabe.freedesktop.org (Postfix) with ESMTPS id B632589D1D for ; Sun, 24 Jan 2021 04:40:23 +0000 (UTC) Received: by mail-wm1-x329.google.com with SMTP id m2so7682501wmm.1 for ; Sat, 23 Jan 2021 20:40:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Rhg44bLk8YwUZNcfhaZg+ceWvGExFDKu36X7UInozoM=; b=qv5UKKsCL2PaW2W9iICDzftCQBA0FaUlDOTH1zd6M4roqRE+eUl7oowslJaTlddx+e KVlI7Laf0wPk7p3h89FMPx2iOjF/Y/PNp/gjkSjCSvGMqFkWAr7l7r/so2750rkFnKmK XtkWuXVQvgsxpbIEfRM20bXcglwYEeuqeLeQ+jpfpbTm45Vfkd1qfM+L5c42WF1fGQyn KHiceiPnR6546MsMADopbKQXlF6v6BSDzbrLHcR1fy1LkPwdEU7y9giTJhFBhjiReKmA 5e9deE4IEVlbRg+2IVHx0I9ru0zGCvaxqqIP2f85KnSGFK1ctqLuhOQHjxkIs1D3YHOv WP+Q== 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=Rhg44bLk8YwUZNcfhaZg+ceWvGExFDKu36X7UInozoM=; b=SkIgwu368NKa6p4bLe9Yb5pSIXCFiy/A6o45t5NXzRiUYKdLblrwbXSjRBgapCakjg V6JNb50h5jToah9irKaJyJYT8dY1JpVWL2YIEId2seNQeagc/Dh8t5dwuBpnEgV81wIe uck/NRW8xVaTOmFFuY56aHrhPuzMkmn3hWpD9JxBt82/2z89KHiCQOMyf+vRl/XP3lbN B4ypp9xeJhAZIyruMTV8gZu1jqyGP2LDNqmUnPwEsgzAgG7GPCjbuppjtjzXfi/DkJjZ JKDv+7GHwbVhrvsENNdHTJeVHtG4wUc0f4a3fN/IXWtulz4++wbZTFbJOtfZHYFwqA/c ajYA== X-Gm-Message-State: AOAM530aAS+iJGp1J9d6GIpCTrF+fUtEnbgf7NMNn0E27erxvYWk2HXz MIf+6aJqLNc8kfQHiwGbreIMBrLQ2/8= X-Google-Smtp-Source: ABdhPJzGQtXLALiKgKXXLCqZ+jkUfcD/YA8VyKoFGcg6KM+qsPNwilgM7S7ItxYXKABomvv+hDBotA== X-Received: by 2002:a05:600c:198e:: with SMTP id t14mr1198914wmq.109.1611463222148; Sat, 23 Jan 2021 20:40:22 -0800 (PST) Received: from twisty.localdomain (dynamic-2a01-0c22-d4ca-c600-6cbb-50d4-b91e-5b37.c22.pool.telefonica.de. [2a01:c22:d4ca:c600:6cbb:50d4:b91e:5b37]) by smtp.gmail.com with ESMTPSA id z130sm16508092wmb.33.2021.01.23.20.40.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 23 Jan 2021 20:40:21 -0800 (PST) From: Mario Kleiner To: dri-devel@lists.freedesktop.org Subject: [PATCH] drm: Fix HDMI_STATIC_METADATA_TYPE1 constant. Date: Sun, 24 Jan 2021 05:40:10 +0100 Message-Id: <20210124044010.18678-1-mario.kleiner.de@gmail.com> X-Mailer: git-send-email 2.24.0 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Uma Shankar , Shashank Sharma Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" According to the CTA 861.G spec, HDMI_STATIC_METADATA_TYPE1 is not 1, but zero, so fix this enum. While this doesn't cause problems in the kernel yet, as the constant isn't actively used by drivers yet, it did create confusion while debugging HDR problems in yours truly, and also potential bugs in userspace components, as the wrong enum propagates to components, e.g., like it did already into intel-gpu-tools (tests/kms_hdr.c) or is used as wrong reference when writing future new userspace HDR components like compositors. Fixes: fbb5d0353c62 ("drm: Add HDR source metadata property") Signed-off-by: Mario Kleiner Cc: Uma Shankar Cc: Shashank Sharma Cc: Ville Syrjälä Reviewed-by: Simon Ser --- include/linux/hdmi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/hdmi.h b/include/linux/hdmi.h index 9850d59d6f1c..c8ec982ff498 100644 --- a/include/linux/hdmi.h +++ b/include/linux/hdmi.h @@ -156,7 +156,7 @@ enum hdmi_content_type { }; enum hdmi_metadata_type { - HDMI_STATIC_METADATA_TYPE1 = 1, + HDMI_STATIC_METADATA_TYPE1 = 0, }; enum hdmi_eotf {