Received: by 2002:a4a:3008:0:0:0:0:0 with SMTP id q8-v6csp3525149oof; Mon, 10 Sep 2018 16:20:49 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZZudsloM4meFOjSIBKxg/4gza6DoqfpSTyfuhC+c0twTbPTUEY/ICiBwactyY5pYX38ExD X-Received: by 2002:a63:5c10:: with SMTP id q16-v6mr24892320pgb.452.1536621649767; Mon, 10 Sep 2018 16:20:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536621649; cv=none; d=google.com; s=arc-20160816; b=fRdOAhvUlQutSR9rfF73tZqNp08/X9v3s4Zzk9FW+tobOUTic13DPIqbk0CRC8wyUi 2GezVTldwPRxfiKnrV68pUJism0eIhpRVtWXvm676jT6dOOQWIXAbRan10z8aZa0M5vD LbJeKBOzwtub/ZyiBpO20SqUwTtInuGmyxTONHjAHHP2bRZvw7eo/um8gHibDHpTFNBZ m8+AscfxUulcfft2UCxzl47fMnwGW/gt1np5rOwT/zEF8LIYLoLjn1XyO7t9AxM+RIwf GcLAgZTQ+zpI0ZK6swITbcqCZRjBJFNqV6O6akd/7r+82gZNRMbkDg2/jU2RD+0tljhT unlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=uUrBIoxGG+u7ybq7u23RT96tXQBQVEabqf2Uan7UOWQ=; b=GFbp77wEhUroKtpe6uvGZ/uq6yco27cOx4Ph8uaeBk0D0vwdXP/Y9TWLErbqyodWxJ qq4lbyZ4c/KTpnLvC3h0xJJO4O7sFKUqWzSuiNP641tyS0v+xTVj21Srm8Bp/BsgXHj1 Ap1jbuVyn0rLXEUANCraTbwL+VcqrZLQyyqaW6W21+tvYqEzIBNbXf938TlV7KOlqI3H zOCa+cE78zzc/GS5jnon7mDwSsMBrHPxagf8NhuRWO27LKmWv8s3BuIdU8tCIXXJstU4 aU3h6mRUTvIVRzWzx3lZx6VSFDgVW2CyJVH2hmSXpC7WZ3UlNNgPLueyg8LUKhdO+3Lx 3msg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@infradead.org header.s=bombadil.20170209 header.b=Iju0refZ; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k189-v6si11680428pgc.321.2018.09.10.16.20.34; Mon, 10 Sep 2018 16:20:49 -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=neutral (body hash did not verify) header.i=@infradead.org header.s=bombadil.20170209 header.b=Iju0refZ; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726282AbeIKEPJ (ORCPT + 99 others); Tue, 11 Sep 2018 00:15:09 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:40998 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725735AbeIKEPI (ORCPT ); Tue, 11 Sep 2018 00:15:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To: Subject:Sender:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=Od9L2cxTtYHSCFmlhgdTQ9UdXTzSb7DfcWq2VqUGbRI=; b=Iju0refZvHClrWlYTO+2E87Nb SzHpVjLqfRu5XLunINFhaIAA7+oEzToFlIe2KNIdMU4IfJvQfe4ELQBUiN6hVaGW/r/9AfQcUol/e p+m/7gKauSLzyDzfZ4jpwiX7TkkiY0rqrFsiia5NmaWlLR6c6oRkwLbG4LzX5ZCLfllUcH22SzqXd wqkAZQ6xQhgjKunzPqR/QEF4kHYPZ1YZMG37w2m+LVysuJgUhuwmvq4jCC7bIQVnOlSJmiNgOoynM iHusQt8wJmMITVk7adklk951dN6lppNzx4a6zkrYhrqg1O2/T69d/d4A2IGkPRjr5o1b/cBv66CmP JN1a8NhrQ==; Received: from static-50-53-52-16.bvtn.or.frontiernet.net ([50.53.52.16] helo=midway.dunlab) by bombadil.infradead.org with esmtpsa (Exim 4.90_1 #2 (Red Hat Linux)) id 1fzVS8-0006pU-Fd; Mon, 10 Sep 2018 23:18:47 +0000 Subject: [PATCH] Generic radix tree: add kernel-doc chapter To: Kent Overstreet , linux-kernel@vger.kernel.org Cc: Dave Hansen , Matthew Wilcox , "linux-doc@vger.kernel.org" References: <20180907165635.8469-1-kent.overstreet@gmail.com> <20180907165635.8469-5-kent.overstreet@gmail.com> From: Randy Dunlap Message-ID: Date: Mon, 10 Sep 2018 16:18:42 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 In-Reply-To: <20180907165635.8469-5-kent.overstreet@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Randy Dunlap Add a generic-radix-tree chapter to core-api kernel documentation. Also fix a few kernel-doc warnings for misssing function (or macro) parameters: ../include/linux/generic-radix-tree.h:93: warning: Function parameter or member '_radix' not described in 'genradix_free' ../include/linux/generic-radix-tree.h:161: warning: Function parameter or member '_idx' not described in 'genradix_iter_init' Signed-off-by: Randy Dunlap Cc: Kent Overstreet Cc: Matthew Wilcox Cc: Dave Hansen Cc: linux-doc@vger.kernel.org --- Documentation/core-api/generic-radix-tree.rst | 13 +++++++++++++ Documentation/core-api/index.rst | 1 + include/linux/generic-radix-tree.h | 12 ++++++++---- 3 files changed, 22 insertions(+), 4 deletions(-) --- /dev/null +++ linux-next-20180910/Documentation/core-api/generic-radix-tree.rst @@ -0,0 +1,13 @@ + +================================= +Generic radix trees/sparse arrays +================================= + +.. kernel-doc:: include/linux/generic-radix-tree.h + :doc: Generic radix trees/sparse arrays + +generic radix tree functions +---------------------------- + +.. kernel-doc:: include/linux/generic-radix-tree.h + :functions: --- linux-next-20180910.orig/Documentation/core-api/index.rst +++ linux-next-20180910/Documentation/core-api/index.rst @@ -27,6 +27,7 @@ Core utilities errseq printk-formats circular-buffers + generic-radix-tree mm-api gfp_mask-from-fs-io timekeeping --- linux-next-20180910.orig/include/linux/generic-radix-tree.h +++ linux-next-20180910/include/linux/generic-radix-tree.h @@ -1,16 +1,18 @@ #ifndef _LINUX_GENERIC_RADIX_TREE_H #define _LINUX_GENERIC_RADIX_TREE_H -/* - * Generic radix trees/sparse arrays: +/** + * DOC: Generic radix trees/sparse arrays * * Very simple and minimalistic, supporting arbitrary size entries up to * PAGE_SIZE. * * A genradix is defined with the type it will store, like so: + * * static GENRADIX(struct foo) foo_genradix; * * The main operations are: + * * - genradix_init(radix) - initialize an empty genradix * * - genradix_free(radix) - free all memory owned by the genradix and @@ -86,6 +88,7 @@ void __genradix_free(struct __genradix * /** * genradix_free: free all memory owned by a genradix + * @_radix: the genradix to free * * After freeing, @_radix will be reinitialized and empty */ @@ -130,7 +133,8 @@ void *__genradix_ptr(struct __genradix * void *__genradix_ptr_alloc(struct __genradix *, size_t, gfp_t); /** - * genradix_ptr - get a pointer to a genradix entry, allocating it if necessary + * genradix_ptr_alloc - get a pointer to a genradix entry, allocating it + * if necessary * @_radix: genradix to access * @_idx: index to fetch * @_gfp: gfp mask @@ -151,7 +155,7 @@ struct genradix_iter { /** * genradix_iter_init - initialize a genradix_iter * @_radix: genradix that will be iterated over - * @_idx index to start iterating from + * @_idx: index to start iterating from */ #define genradix_iter_init(_radix, _idx) \ ((struct genradix_iter) { \