From patchwork Thu Oct 28 16:35:48 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 516375 Delivered-To: patch@linaro.org Received: by 2002:ac0:c404:0:0:0:0:0 with SMTP id t4csp1916570imj; Thu, 28 Oct 2021 09:34:03 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxAstVDEPbwveFv5RRjjgSaU4CEpNJyYVzIJ66Z7A9YEyY0Lto6X9rJfIWF3wuXu3Mi8x1o X-Received: by 2002:a17:90b:3841:: with SMTP id nl1mr14118450pjb.12.1635438843126; Thu, 28 Oct 2021 09:34:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635438843; cv=none; d=google.com; s=arc-20160816; b=avEwDUcU8lAdH5hGbAto4UjCaS+SKMVyqF4H5Bst+bBShx7CaSQBmQpIlSktl6SDnL 4kp/ZuEAGG7QOSq0SVkt0XqUvCQucly4kWDA42NGhGrYIgYlOXYZ+cU7fBHKDMJ/GxT4 0aVYTXPG7BH1cwXzGm0OHxzk/rMXdrRd+2La6EWxLICpR9M5CY6higMuGqi+oHsiNz94 MZgnxf/GemjbKnWR/ciPFRs/BM20qRoaeynC+jcSWwnD3XGzl+ZLnTPgwEOEYIaX7VxS t/62k1MyhcWX0lG1Wmr21cs1ZTY1s1F5i3MvriI6TgTqOTCzo3Wq3TqTSdha6tcVH/p8 meuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature :delivered-to; bh=nem2XTY5QU11TIb5tpm+rntM/cfQ1YaYLiw0IXoaZ+w=; b=hdv0w5MF6G+3Uba90EUyCJS55oWL9Y6U2I0KkdnbsmoDooByKQEn3M0+saQDpSGbTc Dyb8+ellKUygLqosoPCKM2j22c14vE/LlGa48RBkf0Oaj6ydqA0RIkRrLaEf49BxAckp C8RBTepEMSWdQaQvlW6qU19Y2rAwNdyMt7m1DyW7xIH1WVVjnG6a/yFxJDP30UdNOl+V OldlN1EJ4Zz4sba06aSiBIBQ0Qy8tlyf5MM1S3XiY55ZcWYPhF4ThlD1pT4hG6K0H9Ee XbW4YbXFihLgPyqMicTtUW1h53cFEkMcwQQDFFW8yKA8+yN1+aHmqnUn4U37Pa6Qjfp0 NJSA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Y3qFNcE1; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTPS id y23si3103585plp.281.2021.10.28.09.34.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Oct 2021 09:34:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Y3qFNcE1; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 604F26E05F; Thu, 28 Oct 2021 16:34:00 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-oi1-x22c.google.com (mail-oi1-x22c.google.com [IPv6:2607:f8b0:4864:20::22c]) by gabe.freedesktop.org (Postfix) with ESMTPS id 604B86E05F for ; Thu, 28 Oct 2021 16:33:59 +0000 (UTC) Received: by mail-oi1-x22c.google.com with SMTP id y207so9038982oia.11 for ; Thu, 28 Oct 2021 09:33:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=nem2XTY5QU11TIb5tpm+rntM/cfQ1YaYLiw0IXoaZ+w=; b=Y3qFNcE15hVggRrMhiAeClG/Hnfm+SplZEeWKDF6zQdWbTj1BeHIubrS60YhBSk9FD 6NshmXy756/SwcXKW7YKdIa1eKHzXYn7Sv0sCtio1Rc0MsZxsVULUDOTwj2Vue+T+FMI C0cChZdf1dEZGcbEFPab7NJ153OsC19SbmM88Xd5Zpe89W49OIEiFs4G8p3/Uui7TuXM e/F4QKlhelC1nXa0FSH5uWEaREI7Pg6Jhof/tmCZRqlp5X4XCAqpYVB8AiHqzG6LBzVu qhMe8xxNj6xIa1xQjFM3vadRTjG8vKWDaarULUoL6E1jbwVrc/sn9hdJGg0jBl/UKOaV e+Bw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=nem2XTY5QU11TIb5tpm+rntM/cfQ1YaYLiw0IXoaZ+w=; b=vJK0JPtiCy73y5o55iEMx2S78LwBCwje5YAZULeG5JBoKgbIikv9HFRWy+G/FCI1dY jLplXyjLs/Zx4hcuC308WX5zs/jIO3JJn3qw4+hO8KJD9DSCDedw6cnfAR+CVrOd4NLu JQsNYh4Wd4WzSJ5yP7h/J76STPnX9ZlsoaQl2bEYYsXsHOYGLXMgrJjXynKgL7eMoM2m 4RRoxMIR9lVsOPrgZP/zp/UpVzD5t9Erhkb70fvBGG3N38dqInssSebOt/ptOVApSmZY 0OlTe0mET5Ew3af0OOd6yi2x6sxOE0hibV9E6y2vuTarok6PoVCOJ+FD/01M3UQ0dDAy RhEA== X-Gm-Message-State: AOAM533zdgtK6lI6yDZ737glrVs+TfgeAvd68PjfF0w3jr5MMJr2yKcz hjZ4HZRXolf3ZFoZTikQgGlnyQ== X-Received: by 2002:a05:6808:1a0c:: with SMTP id bk12mr3929768oib.48.1635438838563; Thu, 28 Oct 2021 09:33:58 -0700 (PDT) Received: from ripper.. (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id x13sm1058721ooj.37.2021.10.28.09.33.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Oct 2021 09:33:58 -0700 (PDT) From: Bjorn Andersson To: Robert Foss Cc: Andrzej Hajda , Neil Armstrong , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , David Airlie , Daniel Vetter , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, kernel test robot Subject: [PATCH] drm/bridge: sn65dsi86: ti_sn65dsi86_read_u16() __maybe_unused Date: Thu, 28 Oct 2021 09:35:48 -0700 Message-Id: <20211028163548.273736-1-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.33.1 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" When built without CONFIG_PWM there are no references to ti_sn65dsi86_read_u16(), avoid the W=1 build warning by marking the function as __maybe_unused. __maybe_unused is used insted of a #ifdef guard as it looks slighly cleaner and it avoids issues if in the future other permutations of the config options would use the function. Reported-by: kernel test robot Signed-off-by: Bjorn Andersson Reviewed-by: Robert Foss --- Robert, I believe you pushed out the driver patch introducing this issue yesterday. Can you please add the relevant Fixes? drivers/gpu/drm/bridge/ti-sn65dsi86.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.33.1 diff --git a/drivers/gpu/drm/bridge/ti-sn65dsi86.c b/drivers/gpu/drm/bridge/ti-sn65dsi86.c index 430067a3071c..e1f43b73155b 100644 --- a/drivers/gpu/drm/bridge/ti-sn65dsi86.c +++ b/drivers/gpu/drm/bridge/ti-sn65dsi86.c @@ -215,8 +215,8 @@ static const struct regmap_config ti_sn65dsi86_regmap_config = { .cache_type = REGCACHE_NONE, }; -static int ti_sn65dsi86_read_u16(struct ti_sn65dsi86 *pdata, - unsigned int reg, u16 *val) +static int __maybe_unused ti_sn65dsi86_read_u16(struct ti_sn65dsi86 *pdata, + unsigned int reg, u16 *val) { u8 buf[2]; int ret;