Received: by 10.192.165.148 with SMTP id m20csp2071675imm; Thu, 26 Apr 2018 05:59:01 -0700 (PDT) X-Google-Smtp-Source: AIpwx49Ci/odfl5I9NabCjRkj/5QvhrKJ0Wh47Wt0QNv/wGRlukPCSr2lzJ/ZEtP5QUM7j0QUeWA X-Received: by 2002:a17:902:9886:: with SMTP id s6-v6mr33575129plp.380.1524747541414; Thu, 26 Apr 2018 05:59:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524747541; cv=none; d=google.com; s=arc-20160816; b=xXIcpf+WX21W4KXAlmMK+W3/tdbYFBxQP5Lu1nmoPVw9K4s3O79yjxUHG8VaDwmRQ1 7Ly57JL9Bw3l0QbuyL5ey6HnUc9gCdGItC1EF0J6vNELCM7KPTTJ9ii5DRPcOC30d3qX Wupj1Py680k1zeHPkYddt8EsE1tmmvodbD14Uo/AkDcx1qw4hb0OO6Kzbga63ynAa0y/ /jDkgDp8Zxx7bUYPrPsmvGFFhXUEWmZ6AwbkwF9+I+a80ERp1CC0tCgOCLOiJc6uNQ8I zqcIyHu16Rv5/dRcKvLHE71iHnBdgzF3tLy9GlK/6tPTRxoLM2fVmBWWswNJkXzfzfA4 Gt3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=wBL3JGbRHb7tqLsmjcjdDsXwgDAapJEkXZEOqg6B57M=; b=XiKr/8PaPcw9P4YWGD/g0OAqV/oqCuo7C+k8V50XtyUG5NqjWaSosoINHqroNGU/yA jpdFalaY+hO1tND7I9pG3yWCTtnlU+0aX2ysiVaJogLzQ+i/QkXfOcxIioX5vHIC+EEj WuiS30ZTOxOA/3VwCVjHqV1o78PeTOMDlDsMzvfDOrhydRIPCO+4ixDgRR1jkUKZYU3S QQxI/ewGzs7fKp7nI3haN0tP6T5fNmax2EGWmZKChDt0FNqHjGlTd3jnv6w5ketgpgfO gfiQX/WThenRMi8owhehnFSK3mb2WJN4S9vlX5lZkmOtsbKZHYI1vrarMGj0eDGV/KGm eV7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ovlSTIUR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o10si2419293pgv.636.2018.04.26.05.58.46; Thu, 26 Apr 2018 05:59:01 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ovlSTIUR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756165AbeDZM5Y (ORCPT + 99 others); Thu, 26 Apr 2018 08:57:24 -0400 Received: from mail-lf0-f68.google.com ([209.85.215.68]:41812 "EHLO mail-lf0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754516AbeDZM5V (ORCPT ); Thu, 26 Apr 2018 08:57:21 -0400 Received: by mail-lf0-f68.google.com with SMTP id o123-v6so28005162lfe.8; Thu, 26 Apr 2018 05:57:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=wBL3JGbRHb7tqLsmjcjdDsXwgDAapJEkXZEOqg6B57M=; b=ovlSTIURWENLFqlqEeP8WhpQwSkWLBiJUx8xgPuMrCRlHx6AKre2BJLX4GzgJDECcn hNd5uVE6jb3QVcKPMaC84/xLuG5Zmi/Pr0v+3bJYTLBNUllMF8G36ixMgwT/GEkkXTeM 2z+vm5raJzEgHteM5/wDArsi38461xEmYp0M1iw38uc2dQlEbsW+Kp8MaUGw28Vdcs32 UXWsmAVJrcunNN4eqi5RI9gpVpxkChj5Lia70K76HU27M+8khDKnW/P1mDKVEJ8Jrjc3 JUKclaCyJNzizNSJ723KgG7zL3iOfun/Ct2QMjcxUX5VYbPnyXrzivxrnc4nGO1XMXgI AtxQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=wBL3JGbRHb7tqLsmjcjdDsXwgDAapJEkXZEOqg6B57M=; b=AMhpXnYirTiK+T/DqzllSlLPrJ8kUZjhBiMYcSTJWg6h8vCoLlhiAB0WkFUxckYHxg AjqKuuibPcONO++Mmrh0vPw/Eg+TB1nU8e3j2jnrqxY1UvG9CZIvyHuh1T1HWCdeLa4W oaI1mg5GC1fNuICVcS4L23VOgKABSO1F/WOaJep1qIWIef0njaqBj8OSilTR0UG3Ahqw zkICCEOkNY7lpugHrvV9KkLk4wPZezH+quHKkiWvF+zFS5MR6PoVlbDF3Jb5cneBSPQr Dp+oPoorv8W7JtmjPCNjbzgzS888cJlFPIuNDaQJl5Q0YsHdYM190HVhSTCcvFhtOCe7 4inA== X-Gm-Message-State: ALQs6tBO96TbS1hGLx5xI1PpziczrglJxNdf8710PzDlh7LGuEdynJjN 2HT8JZZYanJY7YQ82kE9qPNR3h5Scz5RVyJlv+M= X-Received: by 10.46.133.24 with SMTP id j24mr1892845lji.12.1524747438744; Thu, 26 Apr 2018 05:57:18 -0700 (PDT) MIME-Version: 1.0 Received: by 10.46.156.1 with HTTP; Thu, 26 Apr 2018 05:57:18 -0700 (PDT) In-Reply-To: <1556510.Xu6NnhyFGZ@avalon> References: <20180426102819.6985-1-vthakkar1994@gmail.com> <20180426123615.GA12521@phenom.ffwll.local> <1556510.Xu6NnhyFGZ@avalon> From: Vaishali Thakkar Date: Thu, 26 Apr 2018 18:27:18 +0530 Message-ID: Subject: Re: [Intel-gfx] [PATCH] drm/core: Remove drm_dev_unref() and it's uses To: Laurent Pinchart Cc: Daniel Vetter , alexander.deucher@amd.com, linux-renesas-soc@vger.kernel.org, alexandre.belloni@bootlin.com, Heiko Stuebner , airlied@linux.ie, Linus Walleij , stefan@agner.ch, hjc@rock-chips.com, kraxel@redhat.com, Benjamin Gaignard , nouveau@lists.freedesktop.org, =?UTF-8?B?TWFyZWsgVmHFoXV0?= , David1.Zhou@amd.com, linux-samsung-soc@vger.kernel.org, jy0922.shim@samsung.com, linux-rockchip@lists.infradead.org, Tomi Valkeinen , linux@armlinux.org.uk, krzk@kernel.org, jonathanh@nvidia.com, z.liuxinliang@hisilicon.com, maxime.ripard@bootlin.com, kong.kongxinwei@hisilicon.com, Kukjin Kim , bskeggs@redhat.com, linux-arm-msm@vger.kernel.org, CK HU , airlied@redhat.com, virtualization@lists.linux-foundation.org, linux-tegra@vger.kernel.org, puck.chen@hisilicon.com, intel-gfx@lists.freedesktop.org, etnaviv@lists.freedesktop.org, brodkin@synopsys.com, dri-devel@lists.freedesktop.org, rodrigo.vivi@intel.com, Matthias Brugger , wen , vincent.abriou@st.com, linux-arm-kernel@lists.infradead.org, inki.dae@samsung.com, amd-gfx@lists.freedesktop.org, alison.wang@freescale.com, freedreno@lists.freedesktop.org, sw0312.kim@samsung.com, nicolas.ferre@microchip.com, Philippe Cornu , Linux Kernel Mailing List , yannick.fertre@st.com, Kyungmin Park , =?UTF-8?Q?Noralf_Tr=C3=B8nnes?= , p.zabel@pengutronix.de, Zou Rongrong , linux-mediatek@lists.infradead.org, shawnguo@kernel.org, christian.koenig@amd.com, l.stach@pengutronix.de Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 26, 2018 at 6:15 PM, Laurent Pinchart wrote: > Hi Daniel, > > On Thursday, 26 April 2018 15:36:15 EEST Daniel Vetter wrote: >> On Thu, Apr 26, 2018 at 03:58:19PM +0530, Vaishali Thakkar wrote: >> > It's been a while since we introduced drm_dev{get/put} functions >> > to replace reference/unreference in drm subsystem for the >> > consistency purpose. So, with this patch, let's just replace >> > all current use cases of drm_dev_unref() with drm_dev_put and remove >> > the function itself. >> > >> > Coccinelle was used for mass-patching. >> > >> > Signed-off-by: Vaishali Thakkar >> >> Thanks for doing this. Unfortunately drm moves pretty fast, so already a >> conflict when I tried to apply this. Some drivers are also in their own >> trees, so this might lead to more fun :-/ >> >> Can you pls split it up per-driver (just the directories under >> drivers/gpu/drm/ is enough)? Final patch to remove the function might then >> get stalled a bit ofc. > > I requested a single patch instead of splitting it per driver, you might want > to blame me for that. > >> Also can you pls update ./scripts/coccinelle/api/drm-get-put.cocci and >> remove that spatch hunk in the final patch, since we no longer need it? > > How about just rerunning the coccinelle patch when it's time to apply this ? > There's precedent for performing such automated changes, and it would ensure > that no driver is left out. I was planning to send patches to remove all remaining reference/unreference functions by the weekend [as there aren't much remaining now and I see that new drivers keeps adding them instead of new API]. So, wanted to delete whole cocci file after that. I thought of dividing a patch per function because Laurent requested to send a single patch for all files. But if we are going to split it per driver under gpu/drm, would it work if per driver patch contains all function cases? Also, would you be fine with taking a patch for removal of coccinelle file via your tree? Then I can include that in the same patchset as well. Thanks! >> > --- >> > >> > drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 ++-- >> > drivers/gpu/drm/arc/arcpgu_drv.c | 4 ++-- >> > drivers/gpu/drm/armada/armada_drv.c | 6 +++--- >> > drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 4 ++-- >> > drivers/gpu/drm/drm_drv.c | 13 ------------- >> > drivers/gpu/drm/etnaviv/etnaviv_drv.c | 4 ++-- >> > drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ++-- >> > drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 4 ++-- >> > drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c | 4 ++-- >> > drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 8 ++++---- >> > drivers/gpu/drm/i915/selftests/huge_pages.c | 2 +- >> > drivers/gpu/drm/i915/selftests/i915_gem_dmabuf.c | 2 +- >> > drivers/gpu/drm/i915/selftests/i915_gem_evict.c | 2 +- >> > drivers/gpu/drm/i915/selftests/i915_gem_gtt.c | 2 +- >> > drivers/gpu/drm/i915/selftests/i915_gem_object.c | 2 +- >> > drivers/gpu/drm/i915/selftests/i915_request.c | 2 +- >> > drivers/gpu/drm/i915/selftests/i915_vma.c | 2 +- >> > drivers/gpu/drm/i915/selftests/intel_breadcrumbs.c | 2 +- >> > drivers/gpu/drm/imx/imx-drm-core.c | 4 ++-- >> > drivers/gpu/drm/mediatek/mtk_drm_drv.c | 6 +++--- >> > drivers/gpu/drm/msm/msm_drv.c | 8 ++++---- >> > drivers/gpu/drm/mxsfb/mxsfb_drv.c | 4 ++-- >> > drivers/gpu/drm/nouveau/nouveau_platform.c | 2 +- >> > drivers/gpu/drm/omapdrm/omap_drv.c | 4 ++-- >> > drivers/gpu/drm/pl111/pl111_drv.c | 4 ++-- >> > drivers/gpu/drm/qxl/qxl_drv.c | 2 +- >> > drivers/gpu/drm/rcar-du/rcar_du_drv.c | 2 +- >> > drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 4 ++-- >> > drivers/gpu/drm/shmobile/shmob_drm_drv.c | 4 ++-- >> > drivers/gpu/drm/sti/sti_drv.c | 8 ++++---- >> > drivers/gpu/drm/stm/drv.c | 4 ++-- >> > drivers/gpu/drm/sun4i/sun4i_drv.c | 4 ++-- >> > drivers/gpu/drm/tegra/drm.c | 4 ++-- >> > drivers/gpu/drm/tinydrm/core/tinydrm-core.c | 6 +++--- >> > drivers/gpu/drm/tve200/tve200_drv.c | 4 ++-- >> > drivers/gpu/drm/udl/udl_drv.c | 2 +- >> > drivers/gpu/drm/vc4/vc4_drv.c | 4 ++-- >> > drivers/gpu/drm/vgem/vgem_drv.c | 2 +- >> > drivers/gpu/drm/virtio/virtgpu_drm_bus.c | 2 +- >> > drivers/gpu/drm/zte/zx_drm_drv.c | 4 ++-- >> > include/drm/drm_drv.h | 1 - >> > 41 files changed, 73 insertions(+), 87 deletions(-) > > -- > Regards, > > Laurent Pinchart > > > -- Vaishali http://vaishalithakkar.in/