From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 12AB0C001DC for ; Mon, 31 Jul 2023 13:04:26 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2E07E10E296; Mon, 31 Jul 2023 13:04:25 +0000 (UTC) Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by gabe.freedesktop.org (Postfix) with ESMTPS id BBD2F10E296 for ; Mon, 31 Jul 2023 13:04:23 +0000 (UTC) Received: from [192.168.2.174] (109-252-150-127.dynamic.spd-mgts.ru [109.252.150.127]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: dmitry.osipenko) by madras.collabora.co.uk (Postfix) with ESMTPSA id 1C40366003AC; Mon, 31 Jul 2023 14:04:21 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1690808662; bh=zs4EmxmW2VcAgYRV4nogwdLhJIIVn/eyYKG/cygxAko=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=ZM3AVClBVajzg2zQqSLSCqOzAtBRRQfcz2+gYspXO0jaxYXJ7V1LJ/AwyTI8puPFl juUTV+FHfdrd7EBK6ptEm/eQni5TX1f/27Mi/MRtwMKMOANg5hFcseRJ1P4fNuDCgM IUVLhEp6HusCegRQmkU2hTmXRggSkekgxg8uBQ+oPjEHISaNILraLFMw+Ux+680vBv +8JpADdPcsPV9AS8KIPq2U5uJwbMwUsOtjn/GhEx4i7STJXjN4VhZ1qTyq5Xd9A+SW 7DcizxFQvPlzAH+eR+JBELDGL3nQP6zgKTshOW+udPaSBOgTJiEVa8IAAW+vHqk+/P dZcVFp2OJ/6hw== Message-ID: <0713eab4-1cb0-dbb1-fc8d-f9cbaf566a0f@collabora.com> Date: Mon, 31 Jul 2023 16:04:18 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.1 Subject: Re: [PATCH v14 12/12] drm/gem: Add _unlocked postfix to drm_gem_pin/unpin() Content-Language: en-US To: Boris Brezillon References: <20230722234746.205949-1-dmitry.osipenko@collabora.com> <20230722234746.205949-13-dmitry.osipenko@collabora.com> <20230725095303.07611834@collabora.com> From: Dmitry Osipenko In-Reply-To: <20230725095303.07611834@collabora.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: kernel@collabora.com, Thomas Zimmermann , Emma Anholt , =?UTF-8?Q?Christian_K=c3=b6nig?= , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Maxime Ripard , Gurchetan Singh , Melissa Wen , Gerd Hoffmann , Steven Price , virtualization@lists.linux-foundation.org, Qiang Yu Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On 7/25/23 10:53, Boris Brezillon wrote: > On Sun, 23 Jul 2023 02:47:46 +0300 > Dmitry Osipenko wrote: > >> Make clear that drm_gem_pin/unpin() functions take reservation lock by >> adding _unlocked postfix to the function names. >> >> Suggested-by: Boris Brezillon >> Signed-off-by: Dmitry Osipenko > > I'm still a bit confused by the fact we sometimes use the > xxx[_locked]() pattern (version without the _locked suffix takes the > lock) and other times the xxx[_unlocked]() pattern (version with the > _unlocked suffix takes the lock). It'd be good to chose one pattern and > stick to it, at least for all core functions... After a more close look, agree that the _locked variant is much more common in DRM. Alright, I'll rename the drm-gem funcs. -- Best regards, Dmitry