Message ID | cover.1671952191.git.drv@mailo.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp434161wrt; Sat, 24 Dec 2022 23:47:22 -0800 (PST) X-Google-Smtp-Source: AMrXdXvpjup4ehDM5HObrE8UREXUpyLVzR+0XfEEALDLuaCVy90PaLuoNl4feZeJulwt9+DA574M X-Received: by 2002:a17:902:da86:b0:189:747e:97cc with SMTP id j6-20020a170902da8600b00189747e97ccmr21836921plx.26.1671954442427; Sat, 24 Dec 2022 23:47:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671954442; cv=none; d=google.com; s=arc-20160816; b=zfX6e/0oQ9DJbesLtYi4XRo33lfL05hwWxw8jLbjFtW2QzC44xCHgwBq7fsRWXIabQ Bo61JL9ecwBdwPTm8B6pY3UkF7LJG+T4k+OBdKiHt4JCUBy63LzioIlbWbcEVsGPDBsH iA9ZKtIeBKn5U/vfFNqiXaLDUi4SSujr1fuNYW2d4+6r10hn0WkLptnG6vU+QQTuT+KG pI+bglgJzribZkKR+PMIbnG12eMMaJcpykbAahXSe/Vk2mTVxbhxBcq68LWjUDKLkUGE rMKC5pYc+7ZbtT3nGbSt5PbOOWIONg+YzSbqThX/m8SgLCDpABGStVtjushnt1rs0CIr AALA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-disposition:mime-version:message-id :subject:cc:to:from:date:dkim-signature; bh=Cj5HsufPgIpHJ/T6uB2TuV91iYW5Qu/Zr5TEqe7e7x8=; b=yDFSvqx/18vxRD4yjBCeTzzlcc64KbCnVR4Cwggl+i1oiNlGnb3IvmBpDY/hxn/7yr sXYUSXU0oGAt8jRez+C4Yzj8ShlNl/jbZ4ZcAJO6UJWUX4N6ydxUYouxubKZNQOaYchk /9Gx+ZXlwWvSS6bcfKaXndApC+d/xLkDsJ7KoxE/+a4VYJtpuhxo4WXz3cbH0LDdek7m M+yjpAwmttY/J3XpkugJUUA9Dtp0nttRA7Dlz3V9yhw/b0HWPeGIIIR0zP5EDw19rhGM 5/Y3qcTl4iVxWsmPqrOT26IY34W5ad6sVJ/jpPRFJ/WezxKkcW0eGu5vucy1ay0cTlzn 54uw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mailo.com header.s=mailo header.b=hT8MGQHc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mailo.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id jj13-20020a170903048d00b00189b15ea35bsi7611815plb.208.2022.12.24.23.46.58; Sat, 24 Dec 2022 23:47:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@mailo.com header.s=mailo header.b=hT8MGQHc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mailo.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229464AbiLYHqH (ORCPT <rfc822;eddaouddi.ayoub@gmail.com> + 99 others); Sun, 25 Dec 2022 02:46:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52924 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229441AbiLYHqF (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Sun, 25 Dec 2022 02:46:05 -0500 Received: from msg-1.mailo.com (msg-1.mailo.com [213.182.54.11]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7F874389 for <linux-kernel@vger.kernel.org>; Sat, 24 Dec 2022 23:46:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mailo.com; s=mailo; t=1671954340; bh=kIWqE+E0JGmITgwgejM1umauZcQEjS6DlPrgkewDNns=; h=X-EA-Auth:Date:From:To:Cc:Subject:Message-ID:MIME-Version: Content-Type; b=hT8MGQHcwFZ8TaF+9tq5nChzLggDwzzja91VJqbvKNvCKAnhKui11JMSsW0i8q1If qsBUW+1m+HS40TMC+Ur9SwupmyqUbU+jln4fxsedC3RMtpzbii5+Vj6BVnDsBNGC+H rd+0L45mbwqUrYooK1GF0t/9g9Cr/75Ftu7UytgM= Received: by b-6.in.mailobj.net [192.168.90.16] with ESMTP via ip-206.mailobj.net [213.182.55.206] Sun, 25 Dec 2022 08:45:40 +0100 (CET) X-EA-Auth: SrvNuKhM0jsdFEciaDSFOfF6CMnwpo7D7zWfDAnDFd1e6Yf782WQEAuKphbmRKBT0KjVVog75FmD0Hxg2u8fWFVw5HseKqx2 Date: Sun, 25 Dec 2022 13:15:33 +0530 From: Deepak R Varma <drv@mailo.com> To: Jani Nikula <jani.nikula@linux.intel.com>, Joonas Lahtinen <joonas.lahtinen@linux.intel.com>, Rodrigo Vivi <rodrigo.vivi@intel.com>, Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>, David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>, intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Cc: Saurabh Singh Sengar <ssengar@microsoft.com>, Praveen Kumar <kumarpraveen@linux.microsoft.com>, Deepak R Varma <drv@mailo.com> Subject: [PATCH v2 0/2] convert i915_active.count from atomic_t to refcount_t Message-ID: <cover.1671952191.git.drv@mailo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753171301227547458?= X-GMAIL-MSGID: =?utf-8?q?1753171301227547458?= |
Series |
convert i915_active.count from atomic_t to refcount_t
|
|
Message
Deepak R Varma
Dec. 25, 2022, 7:45 a.m. UTC
Transition the reference count member variable count of struct i915_active from atomic_t type to refcount_t type. This proposal is based on issues identified using the atomic_as_refcounter.cocci Coccinelle semantic patch script. Patch 1/2: proposes to convert the base implementation of variable count from atomic_t to refcount_t. This also includes the transition of atomic_*() API calls to their equivalent refcount_*() API calls. Patch 2/2: proposes to transition the atomic_*() API calls in i915 selftest use cases to their equivalent refcount_*() API calls. Please Note: 1. Patch 1/2 should be applied before patch 2/2 due to interdependency. 2. I did not enable to the selftest and debug configurations earlier while building the i915 base driver. With the build failures reported by the Kernel Test Robot, I have now included those changes. I did not find any other configurations that required additional atomic_* API call transition for this member variable of struct i915_active. Please let me know if there are other related disabled configurations that I should be enable for additional code coverage. 3. Any guidance on working with i915/selftests would be very helpful for my learning. Changes in v2: 1. Patch series introduced. 2. Handle build issues Reported-by: kernel test robot <lkp@intel.com> Earlier a standalone patch was sent for the i915 base driver only. The Kernel Test Robot reported failure for additional atomic_*() calls specific to i915 debugging support when enabled. This version now includes those changes as well. 3. Handle build issues Reported-by: kernel test robot <lkp@intel.com> for i915/selftests Include changes for i915/selftests use cases for atomic_* to refcount_* transition. Deepak R Varma (2): drm/i915: convert i915_active.count from atomic_t to refcount_t drm/i915/selftests: Convert atomic_* API calls for i915_active.count refcount_* drivers/gpu/drm/i915/i915_active.c | 28 +++++++++++--------- drivers/gpu/drm/i915/i915_active.h | 6 ++--- drivers/gpu/drm/i915/i915_active_types.h | 4 +-- drivers/gpu/drm/i915/selftests/i915_active.c | 8 +++--- 4 files changed, 24 insertions(+), 22 deletions(-) -- 2.34.1