Message ID | 20201105144517.1826692-6-lee.jones@linaro.org |
---|---|
State | Superseded |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a92:7b12:0:0:0:0:0 with SMTP id w18csp509580ilc; Thu, 5 Nov 2020 06:52:32 -0800 (PST) X-Google-Smtp-Source: ABdhPJwvxTRbBsCigI2ObBQJIzWHUayoew82LH3KYwB2hticoCCa1r2IDn86kwhCdeCmflsb8jIR X-Received: by 2002:a63:7cc:: with SMTP id 195mr2714336pgh.445.1604587952174; Thu, 05 Nov 2020 06:52:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604587952; cv=none; d=google.com; s=arc-20160816; b=XvKkuVzXDD8vXafBeaxgqfwTfII/wKAXMPY59Rl4hyatVhHdnjsyPBGUeR/3pXRu6R VLaTYCqg95gd8c0wa3qA/gzgANQB3am1nNG6A7ipcgBa3P/AGVm42OJ+VgYGjb0HmpA0 0zpn4fk0Bd1a7BH22XI1oUcbLB4CSZNEIVmNV9AdbQ/Ow5JJlXcRYWWwHUK7tLT/t18u WdpUvULANQiUUmblHHqHBHKp8XEXyPyfdDoHpCf3pK0miY7BaIxd6JAcglkbzqD/H64k si1l9dG5Vb3kuqJR0G0nxeolUkHye85OAf9nW5y+1kNYNcU4ywAmrZzUQQKS4sIFW8yA apbA== 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:references:in-reply-to:message-id:date :subject:to:from:dkim-signature:delivered-to; bh=fBXzztNMLuxedMg6aG/u8U+eAR1Om+SJtQF6kFgdCXk=; b=ZPzQ68u70WYFMJyF248wENbS3dPyvrXTN4DgpGSNACoOWuN5EawtHM1URxjDZpwioD 3b2zZycRfM4jlnTE945aUmC8rb4N9vWj5ycKs+psiOwXy8CLfIbMwd4s5FEVHAsWtWku LW9eaeaUPArY6zzMxCoNfizsPmKFCNG9ujxdNUSFZkmYLp1kP6KBNeA9qkCIZNSsOgQm XIEZ7qsyN8DK89pQr3LV8CU4v5mFuomZVrBRCWpe+l1JDOSz++MlLTwCa2k31XnI1OQW l2fSXVSen0Rz67rNQFfcIHTeNoJkPkrQIFqYNbXL8HaWSYqwfj65YPYNz7Os3t/9ubUd Zl3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Fam3S7jh; 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=linaro.org Return-Path: <dri-devel-bounces@lists.freedesktop.org> Received: from gabe.freedesktop.org (gabe.freedesktop.org. [2610:10:20:722:a800:ff:fe36:1795]) by mx.google.com with ESMTPS id g130si1537317pgc.247.2020.11.05.06.52.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Nov 2020 06:52:32 -0800 (PST) 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=@linaro.org header.s=google header.b=Fam3S7jh; 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=linaro.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7F1806ED9A; Thu, 5 Nov 2020 14:52:27 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wr1-x444.google.com (mail-wr1-x444.google.com [IPv6:2a00:1450:4864:20::444]) by gabe.freedesktop.org (Postfix) with ESMTPS id 0B6306ED94 for <dri-devel@lists.freedesktop.org>; Thu, 5 Nov 2020 14:52:22 +0000 (UTC) Received: by mail-wr1-x444.google.com with SMTP id x12so2084333wrm.8 for <dri-devel@lists.freedesktop.org>; Thu, 05 Nov 2020 06:52:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=wbt6Bt9xb+nEOL+sC88FIyMMDCRwxeU6Sb1wX9bISpg=; b=Fam3S7jhyYU7Z3NVpeOT6nsSRFnhdHgQmCdaWhPs/Yr784DIvf4lSZhyZHm2kJR56B xFeYjjLXHYSZXkqWhyT2ShuGYnKzxLHPnefwdaOp8hMNZV2apCFXYCYmtM2cgs1iwSfU /9VZfe69vuzcpbQb11b7TYnFXBRK9Ha/1DN1lG5nS5Tg/bckPfi2G8c4ImLNv6WThk4y kiAwvcINQwP5e8wsl/NVsQ1wfRvGCXS77nJZpnFrQuQvrJvGByjSikVklVVtzAl/Pa0a jXTSoylLp28E6q1VPfcZ60zbGwaQ4FEK5FQQu2wjmDXStRYgwELevsk7O/w7zazaDndl GIHg== 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:mime-version:content-transfer-encoding; bh=wbt6Bt9xb+nEOL+sC88FIyMMDCRwxeU6Sb1wX9bISpg=; b=VHFustvNLt75K1kiHn9eApytCTREUrLcL3WKz/nrag2zQei3Sl6K64Gf1rSJabaGKS cu74dQbhjLLMW92cSYxliP6BVjjS8sWKX5Yvv3/cTppcgu+fInfxJhEaUnihHVPWZcOd gUZtzoyxH7P+Wlqje4BA3P0HewWLCvarv8hKUwwGqLUAMGZY7x27z5GBNg+pxBnqrZbG MLwfsLJIb7CCNZNeAXnpROjFbwTD6USIpDS0Dc2OiM6km0C4xhcn/HR9rjLd0tTsWfJf Y+ztEa/ga9adenanedxcXdCW3R93bE1weeElkxbsZEEMY41IpAyo1L8k0VXIHQf589UP 8iew== X-Gm-Message-State: AOAM531w84x+VutuN4NCE6xEpO89B2LOKhisXwbNtGYq2XFOak7Tfk/R bm4SilLcdt7h2oYObjMZlebkhw== X-Received: by 2002:a05:6000:8d:: with SMTP id m13mr3373575wrx.216.1604587940699; Thu, 05 Nov 2020 06:52:20 -0800 (PST) Received: from dell.default ([91.110.221.242]) by smtp.gmail.com with ESMTPSA id f5sm2631243wmh.16.2020.11.05.06.52.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Nov 2020 06:52:20 -0800 (PST) From: Lee Jones <lee.jones@linaro.org> To: lee.jones@linaro.org Subject: [PATCH 05/19] gpu: drm: selftests: test-drm_mm: Mark 'hole_end' as always_unused Date: Thu, 5 Nov 2020 14:45:03 +0000 Message-Id: <20201105144517.1826692-6-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201105144517.1826692-1-lee.jones@linaro.org> References: <20201105144517.1826692-1-lee.jones@linaro.org> 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 <dri-devel.lists.freedesktop.org> List-Unsubscribe: <https://lists.freedesktop.org/mailman/options/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=unsubscribe> List-Archive: <https://lists.freedesktop.org/archives/dri-devel> List-Post: <mailto:dri-devel@lists.freedesktop.org> List-Help: <mailto:dri-devel-request@lists.freedesktop.org?subject=help> List-Subscribe: <https://lists.freedesktop.org/mailman/listinfo/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=subscribe> Cc: David Airlie <airlied@linux.ie>, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, =?utf-8?q?Christian_K=C3=B6nig?= <christian.koenig@amd.com>, Nirmoy Das <nirmoy.aiemd@gmail.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" <dri-devel-bounces@lists.freedesktop.org> |
Series |
Rid W=1 warnings from GPU
|
expand
|
diff --git a/drivers/gpu/drm/selftests/test-drm_mm.c b/drivers/gpu/drm/selftests/test-drm_mm.c index 95e212a9a74d2..b768b53c4aee3 100644 --- a/drivers/gpu/drm/selftests/test-drm_mm.c +++ b/drivers/gpu/drm/selftests/test-drm_mm.c @@ -54,7 +54,7 @@ static int igt_sanitycheck(void *ignored) static bool assert_no_holes(const struct drm_mm *mm) { struct drm_mm_node *hole; - u64 hole_start, hole_end; + u64 hole_start, __always_unused hole_end; unsigned long count; count = 0;
In the macro drm_mm_for_each_hole() 'hole_end' is provided as a container for 'hole_start + pos->hole_size', but is not utilised in this use-case. We cannot simply delete the variable, so here we tell the compiler that we're intentionally discarding the read value. Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/selftests/test-drm_mm.c: In function ‘assert_no_holes’: drivers/gpu/drm/selftests/test-drm_mm.c:57:18: warning: variable ‘hole_end’ set but not used [-Wunused-but-set-variable] Cc: David Airlie <airlied@linux.ie> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: "Christian König" <christian.koenig@amd.com> Cc: Nirmoy Das <nirmoy.aiemd@gmail.com> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Lee Jones <lee.jones@linaro.org> --- drivers/gpu/drm/selftests/test-drm_mm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)