From patchwork Fri Apr 6 11:44:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tvrtko Ursulin X-Patchwork-Id: 10325893 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 2611D60541 for ; Fri, 6 Apr 2018 11:44:22 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 151F6294E9 for ; Fri, 6 Apr 2018 11:44:22 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 05FBE294ED; Fri, 6 Apr 2018 11:44:22 +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=-5.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 9F845294E9 for ; Fri, 6 Apr 2018 11:44:21 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 022506E003; Fri, 6 Apr 2018 11:44:20 +0000 (UTC) X-Original-To: Intel-gfx@lists.freedesktop.org Delivered-To: Intel-gfx@lists.freedesktop.org Received: from mail-wm0-x244.google.com (mail-wm0-x244.google.com [IPv6:2a00:1450:400c:c09::244]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6CB546E003 for ; Fri, 6 Apr 2018 11:44:18 +0000 (UTC) Received: by mail-wm0-x244.google.com with SMTP id p9so2931390wmc.3 for ; Fri, 06 Apr 2018 04:44:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ursulin-net.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=fZcTpHf8OTkDV4caae9i5qGWhKC7LoUzTBRRb6B2HoE=; b=lm1/OfZojFlrq4WMW2VGEDj2Qri3arFgD+3JRldlv9rNvmWDckNMn3yQx78e4uwnUn XAOOI8YSbWE1Tir2aPA1ucFB4PV+VVVcl/zvmj8N/vSHPr+F49S4kiRPJ+jugRd2Rw1r 4g3es9T6oyDiKl5sFJcHWfOryu1/PGrwGrPthsQo0Zr2QjxmoNBxAVBBIG9JxEvXzQT6 KzYqniC4TWHOU7g0atn1RWBaJ2Nnfl4PfxwiKjT35uViw1C9eCDLcjVPPELBhOpGc4kx J3hxWBPrgHq3vlzOTtbv/nfhpiMwtqdDRKCaebWI5BoGrVsR58OsRDv49VtkaEmF+Akf A9CA== 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:in-reply-to :references; bh=fZcTpHf8OTkDV4caae9i5qGWhKC7LoUzTBRRb6B2HoE=; b=qSZPIhvt++WnZKB75yu1dG5/rI/WK5P3DRbG+RN/8jO2Qqv2ThslZQst0EWc+0QAvW J6dt33t3gZoNsiy5ZHqLhyR9/ldGNhTj91TfiiJ4OVIQPXQ/llrH/XVH/42dAFCN58+5 rfs1Ui8xzZLG7X+CQZEm6bq6Zjpo7SS+FUr0dwBvDstCxFIxhC9OaMZK85d55YcLS9vr T8UAVMuNTLwbvObj/WWfXjX4L2CB6GTJEGZWpRMGicUgQmk/bI1ueXUy7KhfTODLsu2G ALlKyRC5lTUXL4NK5K5D2p5HVonKZ95SF+dedrvHVIlthJysUICiIxRO0HcPu/80PhYY 6epw== X-Gm-Message-State: AElRT7E83CWfgtKK4TUQtxoYXi4BhP9/Pqy9O4PeRScHpvVWf2+lSH9R kcpztYd+sZ2wOL30URmCUYntxHBX X-Google-Smtp-Source: AIpwx48kw5tPJuJw1D8YoEQrBbIUim73DTqxKuDVgSpjTAGJx1mIxt66dPqMjTpvfwnReYx3eUG0xg== X-Received: by 10.28.139.18 with SMTP id n18mr12514673wmd.26.1523015056930; Fri, 06 Apr 2018 04:44:16 -0700 (PDT) Received: from localhost.localdomain ([95.146.144.186]) by smtp.gmail.com with ESMTPSA id e27sm16865089wre.86.2018.04.06.04.44.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 Apr 2018 04:44:16 -0700 (PDT) From: Tvrtko Ursulin X-Google-Original-From: Tvrtko Ursulin To: Intel-gfx@lists.freedesktop.org Date: Fri, 6 Apr 2018 12:44:07 +0100 Message-Id: <20180406114407.25360-1-tvrtko.ursulin@linux.intel.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180406092417.2466-1-tvrtko.ursulin@linux.intel.com> References: <20180406092417.2466-1-tvrtko.ursulin@linux.intel.com> Subject: [Intel-gfx] [PATCH v2] drm/i915: Enclose for_each_engine_masked macro arguments in parentheses X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP From: Tvrtko Ursulin Enclose for_each_engine_masked macro arguments in parentheses. v2: * Fixup whitespace to satisfy checkpatch. * Likewise reformat to 80 chars. Signed-off-by: Tvrtko Ursulin Reviewed-by: Chris Wilson --- drivers/gpu/drm/i915/i915_drv.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index 5373b171bb96..d25713bab416 100644 --- a/drivers/gpu/drm/i915/i915_drv.h +++ b/drivers/gpu/drm/i915/i915_drv.h @@ -2149,8 +2149,10 @@ static inline struct drm_i915_private *huc_to_i915(struct intel_huc *huc) /* Iterator over subset of engines selected by mask */ #define for_each_engine_masked(engine__, dev_priv__, mask__, tmp__) \ - for (tmp__ = mask__ & INTEL_INFO(dev_priv__)->ring_mask; \ - tmp__ ? (engine__ = (dev_priv__)->engine[__mask_next_bit(tmp__)]), 1 : 0; ) + for ((tmp__) = (mask__) & INTEL_INFO(dev_priv__)->ring_mask; \ + (tmp__) ? \ + ((engine__) = (dev_priv__)->engine[__mask_next_bit(tmp__)]), 1 : \ + 0;) enum hdmi_force_audio { HDMI_AUDIO_OFF_DVI = -2, /* no aux data for HDMI-DVI converter */