Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp336895pxu; Thu, 7 Jan 2021 06:23:47 -0800 (PST) X-Google-Smtp-Source: ABdhPJx0IVxMQceM1jfc4jFD7tGjN0jMLrdi6sKU8ef4rJxnyhh5GJTXYMvfYQyTB7QikOkIkJf/ X-Received: by 2002:a17:907:414c:: with SMTP id od20mr6456149ejb.75.1610029427602; Thu, 07 Jan 2021 06:23:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610029427; cv=none; d=google.com; s=arc-20160816; b=k0+7PHLWqAenwN6iL+g2rnoulgSppJ0gqkyJxPXqiQo/qByPv9Xlj2b02Ca6Al/Mbr RtuJbRgxW02bouB6D7Zg0MT0LcEBVqD89K2y4ENEHQsdxHwpBI0GU2v/8F5otE4afZ7Z uRVPKKh90ON7jAHKeDLyKgrjN30n3DTjlwDlTo7qib8U4NzahPCLzOvuB5PxKJL9IfyO aA1011/UjrKo3BIUrW6MvTjI0zmXeOBxpIGXKx1NDot+vvz+Q5+rlRPoTURW857/CjOg 61LwfMxlftNbDHFnVIdodrfXIc8V81DZ2dT1MJnQtRp6F1oAgBjKj5TQzj4k5Sy7Nv9z KanQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:ironport-sdr :ironport-sdr; bh=yexjymdyYV0Xfsozvl/rkjXyQwo1nR6N/fp0KF1QtQg=; b=Yq1Mpdqo9ej1UWAREnkdUnl71bBQgX3Lg17l2zvCJH7ACpl/wD+BHO4BYodkSiWWor GH2fXynqwsb9pkxXBwEqTsGvLLaZl4dNjTCzU1n3O3w5iItrEHmBz532RyYnHDyF3poi /v3G3+YBucEhfixqxqbJXaxRJVBNNyHKRKv0jvrKAicLb0XoRBlg68MRE7kaFfXfhmv+ pE5c8Nf7DaAGC8hAIATCqrtWmHx85zmm7gNVS7OI3U7uJ/oEF7cvPpYAjZPRFyzPH496 7Q3JgWRgLRSZXRBYr75Oo1Cgll4HK511ecPBEKJBLTX6X0n2mGQQQ1iP7E6nIEP55dVN bzZQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c9si2407038edr.4.2021.01.07.06.23.23; Thu, 07 Jan 2021 06:23:47 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728836AbhAGOVZ (ORCPT + 99 others); Thu, 7 Jan 2021 09:21:25 -0500 Received: from mga09.intel.com ([134.134.136.24]:4351 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728803AbhAGOVW (ORCPT ); Thu, 7 Jan 2021 09:21:22 -0500 IronPort-SDR: wPTAZYM+dwrpEDle/8SEgdSClQuZjItfMNctDuXvsnkI7WZ5663BwnOVXiyPuiJKfXAe5rILKA cDZFaIIrNiOA== X-IronPort-AV: E=McAfee;i="6000,8403,9856"; a="177580001" X-IronPort-AV: E=Sophos;i="5.79,329,1602572400"; d="scan'208";a="177580001" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Jan 2021 06:19:36 -0800 IronPort-SDR: YfixWJrWgNYv8tr761IPsUQCwe+V6bkXofZSRYPG1yOiH8/5dqXajnm1QoN2lrPZvJ+HjfJDN4 6SrV3pu6uZAg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.79,329,1602572400"; d="scan'208";a="463047740" Received: from kuha.fi.intel.com ([10.237.72.162]) by fmsmga001.fm.intel.com with SMTP; 07 Jan 2021 06:19:33 -0800 Received: by kuha.fi.intel.com (sSMTP sendmail emulation); Thu, 07 Jan 2021 16:19:32 +0200 Date: Thu, 7 Jan 2021 16:19:32 +0200 From: Heikki Krogerus To: Daniel Scally Cc: Andy Shevchenko , linux-kernel@vger.kernel.org, rafael@kernel.org, gregkh@linuxfoundation.org, sakari.ailus@linux.intel.com Subject: Re: [PATCH] software_node: Add kernel-doc comments to exported symbols Message-ID: <20210107141932.GJ940479@kuha.fi.intel.com> References: <20210104234736.419493-1-djrscally@gmail.com> <20210105145329.GO4077@smile.fi.intel.com> <3d92e535-c955-502a-24ac-0655752796fc@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3d92e535-c955-502a-24ac-0655752796fc@gmail.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 05, 2021 at 03:39:42PM +0000, Daniel Scally wrote: > Hi Andy > > On 05/01/2021 14:53, Andy Shevchenko wrote: > > On Mon, Jan 04, 2021 at 11:47:36PM +0000, Daniel Scally wrote: > >> A number of functions which are exported via EXPORT_SYMBOL_GPL() lack any > >> kernel-doc comments; add those in so all exported symbols are documented. > > Thanks, it's helpful! > > Reviewed-by: Andy Shevchenko > > after addressing few nitpicks > Thanks for reviewing > >> Signed-off-by: Daniel Scally > >> --- > >> With a view to maybe writing some documentation once the fwnode_graph_*() > >> functions are also added. > > FWIW, Heikki used to have a draft patch of swnode documentation, not sure > > what's the current status of it. > Oh cool ok; I'll defer to him then. I actually had a similar patch prepared as part of the series adding the documentation for software nodes, but your comments are better than mine. So, after you have addressed Andy's comments: Reviewed-by: Heikki Krogerus > >> + * copy of the given array of properties and registers it as a new fwnode_handle. > >> + * Freeing of the allocated memory when the fwnode_handle is no longer needed is > >> + * handled via software_node_release() and does not need to be done separately. > >> + * > >> + * Returns: > >> + * * fwnode_handle * - On success > >> + * * -EINVAL - When @parent is not associated with a software_node > >> + * * -ENOMEM - When memory allocation fails > >> + * * -Other - Propagated errors from sub-functions > >> + */ > >> struct fwnode_handle * > >> fwnode_create_software_node(const struct property_entry *properties, > >> const struct fwnode_handle *parent) > >> @@ -832,6 +875,15 @@ fwnode_create_software_node(const struct property_entry *properties, > >> } > >> EXPORT_SYMBOL_GPL(fwnode_create_software_node); > >> > >> +/** > >> + * fwnode_remove_software_node() - Put a reference to a registered software_node > >> + * @fwnode: The pointer to the &struct fwnode_handle you want to release > >> + * > >> + * Release a reference to a registered &struct software_node. This function > >> + * differs from software_node_put() in that it takes no action if the > >> + * fwnode_handle passed to @fwnode turns out not to have been created by > >> + * registering a software_node > > Period at the end. > > > > I'm a bit confused by amount of fwnode_handle in the comments, can you replace > > them with better approach depending on the case: > > - &struct fwnode_handle > > - a parameter as @fwnode or so > > - a general mention (better to use plain English here, something like firmware > > node handle or so) > Yeah ok, I was trying to do &struct fwnode_handle on the first reference > (or at least earliest that it would fit) and then fwnode_handle > thereafter, but I think I like the suggestion to drop to plain English > at that point instead, so I'll do that (and ditto for software_node / > software node) -- heikki