From patchwork Mon Mar 22 10:52:59 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 406098 Delivered-To: patch@linaro.org Received: by 2002:a02:8562:0:0:0:0:0 with SMTP id g89csp3455459jai; Mon, 22 Mar 2021 03:53:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxUQlAHGeDROIWHRKVZhpVXH0jnSriFgRvhF4CdvEqnNA8bA+cTysrq/C+/kPq6cJTo0f91 X-Received: by 2002:a62:8ccc:0:b029:1f6:c5e2:69ff with SMTP id m195-20020a628ccc0000b02901f6c5e269ffmr21589961pfd.46.1616410396069; Mon, 22 Mar 2021 03:53:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616410396; cv=none; d=google.com; s=arc-20160816; b=xLdZxqzeZyL55BUZNEDTKTf+dlKTnAwFcrQ8U6SVknkbBbTk28kvxgW3O/kAoT8HKx +Ied9Y5D9B6AI/LJQd1SMOPXLojjXoNHd9bnQLycXknEmq7+sYVlf/0otyiDGZkGCHx3 OD3uaVGDhyoMm8Qj+9MYs2gvZguznXOpbBVsd0KIu4UlgDevT4JqWYZUVviQHGm1QYyi uXPpdGh9U2VRIAUeX7v6a24dsQQ9GSTyZaFSX3SwDhRdEoEe6CJ9bs+KHt74xYEXR8/F Nyz8qgz/IYZrokykhDyIq4h+ZsS4rPBOpvPRN22tfxFiigm3j24QYmV/ofcgZ15K8x0y 5PJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mime-version:message-id:date:subject:to:from :dkim-signature:delivered-to; bh=GLMtWq5ptNbT2upzEjNRqw9pI/JNjLnacyec2Equ9io=; b=Hq6IlMS7Gt4K+4Du0ZKMj1vLVU90D04lKU0nsnWyLUzydAgNtKJL11dWbKNtTFE24D ZESsa9fjuOOe6tCn2HSufzkuyi5gGSGndvTlIoyrbfOduJapaw1XTtbsEo1vkoBg+pQC wOaF7Yj8QoptGZvNJ/cO39DpUwLiO4Q1ZLWh1cWDd+Nnar9t1OGWTSq0GF3dwxsR3nw/ ux24LAtN+aqhdoJktIK7sxwqu2G8jPxtQD3tpx4s72PnzOAnnfYN8OKZji/DO1JqCW5U p6JABv6U259dcV7aXRSlHQLSDzRLxnczcbFMht45XqVvmRcl6wDJxbIBUirulyl0AR33 wHzg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@kernel.org header.s=k20201202 header.b=RgVbcb5G; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [2610:10:20:722:a800:ff:fe36:1795]) by mx.google.com with ESMTPS id y11si15822536plt.292.2021.03.22.03.53.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Mar 2021 03:53:16 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) client-ip=2610:10:20:722:a800:ff:fe36:1795; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@kernel.org header.s=k20201202 header.b=RgVbcb5G; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 1E9D589E9E; Mon, 22 Mar 2021 10:53:15 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by gabe.freedesktop.org (Postfix) with ESMTPS id 20B3D89E9E for ; Mon, 22 Mar 2021 10:53:13 +0000 (UTC) Received: by mail.kernel.org (Postfix) with ESMTPSA id 4B10661983; Mon, 22 Mar 2021 10:53:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1616410391; bh=4U0eak1ORtelSunJ9eE7hPB3yqAxnqQRBSFUlGf+63c=; h=From:To:Cc:Subject:Date:From; b=RgVbcb5GDL09XMuNQ6ApRvSec2jt7qHQUtsB2qr0geekYNbvLm3amzMeHiPM946Uf Cx+8jLIVhr+YZxrmgmMTIGIK6bysN08+ys+ORnyf3sDus3Iyd2ziWZKI/bhctiXAfs Q/MXso1NWbkvBHfvVVZPv5XDYGuGq/aWV0534Qe4ljZHiFeYnyYz3fV/4vuI6FDzfS 7n4r6bbscyZZk8UJSFtvJPIlNUkx+Eglq3PM5ikRJEi/VzThTl1lTNdiriwlZ5tTj4 QZ2ZrJLUtkAYEvlxqhW2ssKRjo+eNWLSXpyZCuAu6X+CTxJzGI9JQ0jfNtmxL6/Blo TiIiMRucxsIew== From: Arnd Bergmann To: dri-devel@lists.freedesktop.org Subject: [PATCH 1/2] fbdev: omapfb: avoid -Wempty-body warning Date: Mon, 22 Mar 2021 11:52:59 +0100 Message-Id: <20210322105307.1291840-1-arnd@kernel.org> X-Mailer: git-send-email 2.29.2 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: linux-fbdev@vger.kernel.org, linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org, Arnd Bergmann Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Arnd Bergmann Building with 'make W=1' shows a few harmless warnings: drivers/video/fbdev/omap2/omapfb/omapfb-main.c: In function 'omapfb_calc_addr': drivers/video/fbdev/omap2/omapfb/omapfb-main.c:823:56: error: suggest braces around empty body in an 'if' statement [-Werror=empty-body] 823 | var->xoffset, var->yoffset, offset); | ^ drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c: In function 'omapfb_ioctl': drivers/video/fbdev/omap2/omapfb/omapfb-ioctl.c:911:45: error: suggest braces around empty body in an 'if' statement [-Werror=empty-body] 911 | DBG("ioctl failed: %d\n", r); Avoid these by using no_printk(), which adds format string checking as well. Signed-off-by: Arnd Bergmann --- drivers/video/fbdev/omap2/omapfb/omapfb.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.29.2 _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel Reviewed-by: Geert Uytterhoeven diff --git a/drivers/video/fbdev/omap2/omapfb/omapfb.h b/drivers/video/fbdev/omap2/omapfb/omapfb.h index d27abccb37bc..1c1b5201c8b6 100644 --- a/drivers/video/fbdev/omap2/omapfb/omapfb.h +++ b/drivers/video/fbdev/omap2/omapfb/omapfb.h @@ -29,7 +29,7 @@ extern bool omapfb_debug; printk(KERN_DEBUG "OMAPFB: " format, ## __VA_ARGS__); \ } while (0) #else -#define DBG(format, ...) +#define DBG(format, ...) no_printk(format, ## __VA_ARGS__) #endif #define FB2OFB(fb_info) ((struct omapfb_info *)(fb_info->par))