Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp3513551lqp; Tue, 26 Mar 2024 11:05:26 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVVxBPVJDbIs1AtzSAZtjM7mztbUofER+zOfuv7GQ+dNNN6S8MPECpd5uRXZj5d7iVA1ldq1JCOGKfvh4Fn1g2ZopLbfv/hLCwBxxxLDw== X-Google-Smtp-Source: AGHT+IEsRu72RZZ4ZmH/oR2GhiQcfVzTFbGxKFIKiZ206hOF969nBSQRDdjEONH4D34/q72I/vT9 X-Received: by 2002:a17:90a:e2c9:b0:29f:8b48:b390 with SMTP id fr9-20020a17090ae2c900b0029f8b48b390mr8382605pjb.16.1711476326041; Tue, 26 Mar 2024 11:05:26 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711476326; cv=pass; d=google.com; s=arc-20160816; b=GTYXj7ukeUwYvhinV9zKeDgWU8+TfJWCxL6t7c8XFvu4tIYhgxLDXCweJoKvId49Ec XRsGWpI5wJD73xsen1wDZ8qp2dt3LuZIfzREkKV/uluxwLZoT8CX6KBYN6kCshTSwrPu 9CTzgBchjkvCgXrseOWsOApqWAw67aXrId6QEsX38C46yT03oCWbPZvZPUBGE3k1UoRG eCw/CTtxXjCxHi66bScuIzjiwBLMRfb1bieGwK0fx1lFaeO+VL/7kXOeZ9yjCi2/qoYa Ix4KCGYHyLVIxek5D47F9HNTD3sHIiduNb2Ztlw21+rkD76jCiwpTSK0As3L1To58/zO yisg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:subject:message-id:date:from:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:dkim-signature; bh=InAZ9/C9EDyJhkW+bEV5eavwbh4jrGbQhGajHqMOaXs=; fh=0JObP8D70raOgbl+uESRilBsU5GurHFM3MQFxFtvmLs=; b=W5DFhCZ0bdsfKML9aRDpPXw4GuaQl45kokOX1295Xsa1mBL9kdSmU0gj47YMMzWchZ 2f7Ta8Slgao4O2f7qlbsO+8zk33ydppCcmq9IhDYWAkXgmd5cBilBtcmuk+RTK3NZgfS +Ez8Quo8x4OHR/sBMXQB/uIW55u+zidgOPKVa+zlDV7ZpZ/YDjFevAV8J10VauUqvVVP PTJAxtfTwrAoXCIlG8VVa6WRhzkXfhu2HN0HcZK+Jg/B3+4kiF/l9duJn6NVaCi8FV/4 EyjFvc+GMjA+nWHA02X4J3y+I6zte3RHF/thNUsVAFUoyzy25YdFizxCl6O43I8/wSbV CBow==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=T8k8uz2T; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-119645-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-119645-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id nb16-20020a17090b35d000b002a07edca226si2863276pjb.76.2024.03.26.11.05.25 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 Mar 2024 11:05:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-119645-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=T8k8uz2T; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-119645-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-119645-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id B417432018D for ; Tue, 26 Mar 2024 18:05:25 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5D28386646; Tue, 26 Mar 2024 18:05:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="T8k8uz2T" Received: from mail-pj1-f54.google.com (mail-pj1-f54.google.com [209.85.216.54]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3691B84D34 for ; Tue, 26 Mar 2024 18:05:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.54 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711476305; cv=none; b=rm4geP30nkXKPwBlfrPFoPgKKd0CtrvKgD/MCsL465cOr5cp+tmG00Ujrc0tFj/PBnASVwyygz96egnHTWBy7jAhDoG3m0ay6dijhnMgRzYyBFmcjNiijYDfeM78KBMVHk2RW5YaiKtendB7UYDrNIqIqGMQWl95L7OfTg6kbrc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711476305; c=relaxed/simple; bh=1HtAEn3GUDU1rNP6LZWmBuVwhufr+rjFcdlx8t9YYvw=; h=MIME-Version:From:Date:Message-ID:Subject:To:Cc:Content-Type; b=RpKaelVFOXlJPvwBULwSBzr4/l90GV33dHRsMqzdFd33ew8jC4T4aUho5L64ch73YAstUFjs05vKDxIB+8T0F7KOkkQmwwByd2jPBBImX9MHh3XZR7ipL4//jSsapVU//k3HxXUPlpSjEvhJGr8O/+CgZL5mesuNJa51Jr+cjAg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=T8k8uz2T; arc=none smtp.client-ip=209.85.216.54 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pj1-f54.google.com with SMTP id 98e67ed59e1d1-2a07b092c4fso1437949a91.0 for ; Tue, 26 Mar 2024 11:05:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1711476303; x=1712081103; darn=vger.kernel.org; h=cc:to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=InAZ9/C9EDyJhkW+bEV5eavwbh4jrGbQhGajHqMOaXs=; b=T8k8uz2T2njzNwO9uuJCZUPbgR7UFW3VEzMiwRNl2nNnkzK0CQ0ib/Ud1d8W/cZ7zR gs/sTUjSgsy+g9XB4s3HmW8K2Z4QH674pe38Y9CdG6pxuzLH60WLj2VLrdQvh5R9nK07 /TF0KH0xwUpPyLq8WJbFiuKVsH9uwJO8/hywywXg6O5vOjbVAvxYEAnanO899MyHqdoQ PY3wMbQkBRl1gRtwlQcRV822sE+pi9QwTeRAvUWRIbtTYkfvLgOowj6kxQd0W/YpziZS nKNAjMIhDWSu+Hr4SVNSGMF61ufFq7KGK9RBnHoWjajT0jqvruf8XqYrxvaxcTqVENfD fv7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711476303; x=1712081103; h=cc:to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=InAZ9/C9EDyJhkW+bEV5eavwbh4jrGbQhGajHqMOaXs=; b=pWXkrvEv7H8s6aGXqyITehsameVNCy6Ejt1sAOSxNzspON3iQW56pq+1PmjZugKsy7 I+OMQ36d5GCraGFf/aw12+xpvFJ2tH+AdjTla91CQk1toai3Os/A81A/jqK6izJO2Lbi VsG0uhVnL/vQPTkrM4yHX1R3ZJ5FzQNUSJHEAYGranX+oUtXvXdT5aAoJt9JXAg2J6K3 bu9Jl9WdtwzgGXpdpkYlUe2jlQnNFlGdJnPPOOFiEuQIplLgeaF8WkGuAcrT20sD+ZAO 73kgq72eviF2F6V0Sno1PdqUQC4uR5mcmsprngh7D5t3x2VpSayPd4EyBKUMpnWSnwgQ QT0Q== X-Forwarded-Encrypted: i=1; AJvYcCXn6/1VmaaTzDrsqxY85zMiiDg4Zq0FSwt2K57L/m9QLrLWxT4WUS+knFz3bEDwRLkUihnSS1RSejYPgrzWq1d9ZdDI5MV8Faq/O+Lv X-Gm-Message-State: AOJu0YypFzQOebOc/9YC3VS8FsANXlRvTIaKetu+vZIG//37fcdSGMtc slTZZ4FS+TecPaIfEHoyN7ueR8ObzuRPp5H4XFXuXjxFrQ5KgmbhosJ8DI1CLaQuKRaHkbTogWw wT1Wx3AmQh3BdmkszAqDL8R10OkE= X-Received: by 2002:a17:90b:380c:b0:29f:e443:204f with SMTP id mq12-20020a17090b380c00b0029fe443204fmr8861033pjb.18.1711476303337; Tue, 26 Mar 2024 11:05:03 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Miguel Ojeda Date: Tue, 26 Mar 2024 19:04:34 +0100 Message-ID: Subject: drivers/gpu/drm/qxl/qxl_cmd.c:424:6: error: variable 'count' set but not used To: Dave Airlie , Gerd Hoffmann Cc: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , virtualization@lists.linux.dev, spice-devel@lists.freedesktop.org, dri-devel , linux-kernel Content-Type: text/plain; charset="UTF-8" Hi, In today's next, I got: drivers/gpu/drm/qxl/qxl_cmd.c:424:6: error: variable 'count' set but not used [-Werror,-Wunused-but-set-variable] `count` seems to be there since commit f64122c1f6ad ("drm: add new QXL driver. (v1.4)"). Untested diff below -- if you want a formal patch, please let me know. Cheers, Miguel diff --git a/drivers/gpu/drm/qxl/qxl_cmd.c b/drivers/gpu/drm/qxl/qxl_cmd.c index 281edab518cd..d6ea01f3797b 100644 --- a/drivers/gpu/drm/qxl/qxl_cmd.c +++ b/drivers/gpu/drm/qxl/qxl_cmd.c @@ -421,7 +421,6 @@ int qxl_surface_id_alloc(struct qxl_device *qdev, { uint32_t handle; int idr_ret; - int count = 0; again: idr_preload(GFP_ATOMIC); spin_lock(&qdev->surf_id_idr_lock); @@ -433,7 +432,6 @@ int qxl_surface_id_alloc(struct qxl_device *qdev, handle = idr_ret; if (handle >= qdev->rom->n_surfaces) { - count++; spin_lock(&qdev->surf_id_idr_lock); idr_remove(&qdev->surf_id_idr, handle); spin_unlock(&qdev->surf_id_idr_lock);