Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1467861rbb; Mon, 26 Feb 2024 10:06:48 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCV/PcOvjsAiBY1Qt3E/qUtL+WAcO+nrJJoiulZ3oluaGKlbwl/mMEEc3hLWthnWBT2q9A8tnBsoK6bN/YvfPbUdtQK3SgPHK++iQS5ihg== X-Google-Smtp-Source: AGHT+IHfrmwnj7NPs6hVQnjhXr7vy+YvISSPdeynsOI9rxjPKv+LazlxDYuXX9AUPTJHb28H2H2O X-Received: by 2002:a17:903:1104:b0:1dc:75ea:85f0 with SMTP id n4-20020a170903110400b001dc75ea85f0mr8676847plh.7.1708970808389; Mon, 26 Feb 2024 10:06:48 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708970808; cv=pass; d=google.com; s=arc-20160816; b=OWhNDQQTma6l1Y6PCgM8QkZgcj9WSSIuFRD2HCotyxwtYk0EK8xyZZOXMv4pPxa+8p Ssxmckxm3tRCS+zaD3OZdwJA4h72152py8uV92QyVxdNHbdIykN0sQiL1QWJa4BAfMla qqCswJJicH/mpkzyPkql2uLPt5JzR5fFFqkQ/GvOQjDsaCfS8eVXB/4iJLPEF7JuIlO+ 539F4eP7TteSs35zFC3QQ1LuMnD9YfBlK3CTD/JA9ROQn0NAjBVZ5K9kVrYx0hC7MzYe ar17aK/ZExFrJ+BlzU5oJfwBtw+CpZhvP62qgg78AokJvyM36RL1mgUE/Le/YMVPA+yS 1rXw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :message-id:subject:cc:to:from:date:dkim-signature; bh=4w0pyzX13oH7yLsHCQxEK+jhZJgnfrrDCDdIA5IXYd4=; fh=rNcZLWj2guZleTqFdYN7CB3tX5/vQ//+8ShwnxSpWXs=; b=aObLy3m7KE3wAVbGbvqKvLO4NYOAD27PsMMSrdELJQ9doePrF02rCnqzd47vQaaUbG gXXRiEGgu83pdHj/zOCBNldXeurcEmiGUdc5/1m0+zNlmItd+WdQrh4aH15peYkie+FF 4+Xa2chtlKSglFeaXXAZ6Qgw8/pT2qF2cVJIYIPUFDjRYGjmFpVvmY0vTahSwQZKF0vU mc+DxKs7sZ1IWq4QdmVQ/pTEvdJ4bDS8/RZFnVh2JVW2CFGYkgJ6YCNTVJzitsfYkElQ roFph6QgcNojF90GwqNPxvW+C9kTiHSq41wopKZQC8ggPrPmDMt4KPSehJiJx93hYwkP IWyA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=z8FjqaeI; arc=pass (i=1 dkim=pass dkdomain=infradead.org); spf=pass (google.com: domain of linux-kernel+bounces-81865-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81865-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id u13-20020a170903124d00b001d4ca2fcc4asi4048133plh.291.2024.02.26.10.06.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 10:06:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-81865-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=@infradead.org header.s=bombadil.20210309 header.b=z8FjqaeI; arc=pass (i=1 dkim=pass dkdomain=infradead.org); spf=pass (google.com: domain of linux-kernel+bounces-81865-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81865-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 4D78F287D2E for ; Mon, 26 Feb 2024 16:06:41 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D3E3712CD8F; Mon, 26 Feb 2024 16:06:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="z8FjqaeI" Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AE23912C819 for ; Mon, 26 Feb 2024 16:06:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.137.202.133 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708963576; cv=none; b=WJJYnYAmQowfIhddfJHKpAY8nRz5TN2JfCdmO2JgOuaMvh/EUJFv/MqjSk/E1FFOYTVBJpt7c94VYkuj6MN5h9XLG7eM8a2rV5iysFlZ2KiT/jpNBBZ1zRohezLe2BDF5hbJRxiQ5QkURpGygpg8/p5VubaWsMEyRiy/b6VdwIs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708963576; c=relaxed/simple; bh=0vWCW341aYdqTh1i18g1rVlJHLBtC/3TVzzqVYsIBwM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=R33XT6iEnX1Kui14iOcDLv3KhDwwevxn9Ikw8gSqH2L4X6u4NtoMKklDQJFcB/uUkuWdKb5OBaz8R2Vzgtrs4783SkipUihR9kInH9dssqr56Fom1ufi9NGi+NeQrykt8qt2cRUoGjNF0nwdIEJyefCADXrbpdCdOYudci4uekY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org; spf=none smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=z8FjqaeI; arc=none smtp.client-ip=198.137.202.133 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=4w0pyzX13oH7yLsHCQxEK+jhZJgnfrrDCDdIA5IXYd4=; b=z8FjqaeIAOZZfC5MFb+Xs4/vCB HwnEct+tTsPNSnbxcmxb/SYlMfMwT4KjUdaCdRIlCBFm/5bJ055WLFshTnVSmvoybocid2vLb3uB4 NHH4IxuqSHTgK5sAQ/ISJXyXOwSTX5lbOoh5GNH6odn0gVRZsBpNGYLxnXsblJcMksO2y772ESNcy 7EN0z0EqIc206fNGT+R9oxDSFZ0zlK8VW+tJx5fWXM7BZrZMb2Bkhm3a47RG262+X5hzFAWBpQ6Y+ kOlMGEpRS4SuFKsIECQoclDN/cm7V2OoLxMb+gmYfBMNmP1IiM0eQeKhfdOC1KQxAE5LV8RusT24J +LXuHhlA==; Received: from mcgrof by bombadil.infradead.org with local (Exim 4.97.1 #2 (Red Hat Linux)) id 1redUb-00000001ZMw-01gl; Mon, 26 Feb 2024 16:06:13 +0000 Date: Mon, 26 Feb 2024 08:06:12 -0800 From: Luis Chamberlain To: Mukesh Ojha Cc: Greg KH , russ.weight@linux.dev, rafael@kernel.org, linux-kernel@vger.kernel.org, cocci@systeme.lip6.fr Subject: Re: [PATCH vRFC 3/8] treewide: rename firmware_request_platform() Message-ID: References: <20240222180033.23775-1-quic_mojha@quicinc.com> <20240222180033.23775-4-quic_mojha@quicinc.com> <2024022347-ribcage-clench-37c4@gregkh> <2024022323-accustom-eradicate-8af4@gregkh> <2024022452-unwilling-pancake-3b2a@gregkh> <2024022644-trough-humility-12b8@gregkh> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: Luis Chamberlain On Mon, Feb 26, 2024 at 06:52:49PM +0530, Mukesh Ojha wrote: > > > On 2/26/2024 6:39 PM, Greg KH wrote: > > On Mon, Feb 26, 2024 at 04:22:09PM +0530, Mukesh Ojha wrote: > > > > > > > > > On 2/24/2024 11:06 AM, Greg KH wrote: > > > > On Fri, Feb 23, 2024 at 11:42:35AM -0800, Luis Chamberlain wrote: > > > > > On Fri, Feb 23, 2024 at 04:33:40PM +0100, Greg KH wrote: > > > > > > On Fri, Feb 23, 2024 at 07:15:45AM -0800, Luis Chamberlain wrote: > > > > > > > On Fri, Feb 23, 2024 at 07:21:31AM +0100, Greg KH wrote: > > > > > > > > On Thu, Feb 22, 2024 at 11:30:28PM +0530, Mukesh Ojha wrote: > > > > > > > > > Rename firmware_request_platform() to request_firmware_platform() > > > > > > > > > to be more concrete and align with the name of other request > > > > > > > > > firmware family functions. > > > > > > > > > > > > > > > > Sorry, but no, it should be "noun_verb" for public functions. > > > > > > > > > > > > > > News to me, do we have this documented somewhere? > > > > > > > > > > > > Not really, but searching makes it nicer. > > > > > > > > > > > > And yes, I violated this in the past in places, and have regretted it... > > > > > > > > > > Care to share a few examples of regret? > > > > > > > > get_device() > > > > put_device() > > > > kill_device() > > > > > > > > vs. a saner: > > > > kobject_get() > > > > kobject_put() > > > > kobject_del() > > > > > > > > Learn from the mistakes of my youth please :) > > > > > > Thanks for the history., > > > In that case, should we fix this verb_noun cases ? > > > > > > request_firmware() > > > request_firmware_into_buf() > > > request_firmware_nowarn() > > > request_firmware_direct() > > > request_firmware_cache() > > > request_partial_firmware_into_buf() > > > release_firmware() > > > > That would provide consistency, right? > > Yes, Below names look better.. > > firmware_request() > firmware_request_into_buf() > firmware_request_nowarn() > firmware_request_direct() > firmware_request_cache() > firmware_request_partial_into_buf() > firmware_release() > > @Luis/Others, Can we do this change ? Go for it. I just also think we might as well document from the learnt lessons, and our preference, instead of making this just one developer's personal preference because the moon made them feel a different way than two years ago. From my part it is best we *strive* to stick to one convention, whatever it is. As for the *why* to document this, I suspect it allows easier namespace grep'ing for symbols related to one thing or another, as to why it shoudl go first, I'll let Greg chime in. Long term I see value in having anything we decide to stick to, to make it easier for debugging heuristics. Luis