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 X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B67EAC433E2 for ; Mon, 8 Jun 2020 04:40:23 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 7CBAC206D5 for ; Mon, 8 Jun 2020 04:40:23 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="f4qzkrRX" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7CBAC206D5 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 261486B0022; Mon, 8 Jun 2020 00:40:23 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 1BDCF6B0023; Mon, 8 Jun 2020 00:40:23 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0D2F56B0024; Mon, 8 Jun 2020 00:40:23 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0227.hostedemail.com [216.40.44.227]) by kanga.kvack.org (Postfix) with ESMTP id E499A6B0022 for ; Mon, 8 Jun 2020 00:40:22 -0400 (EDT) Received: from smtpin21.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id AFF3A5A0F6 for ; Mon, 8 Jun 2020 04:40:22 +0000 (UTC) X-FDA: 76904793084.21.paste62_3b1638226db7 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin21.hostedemail.com (Postfix) with ESMTP id 93B6C18197ADE for ; Mon, 8 Jun 2020 04:40:22 +0000 (UTC) X-HE-Tag: paste62_3b1638226db7 X-Filterd-Recvd-Size: 3052 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf33.hostedemail.com (Postfix) with ESMTP for ; Mon, 8 Jun 2020 04:40:22 +0000 (UTC) Received: from localhost.localdomain (c-73-231-172-41.hsd1.ca.comcast.net [73.231.172.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0E7BB20814; Mon, 8 Jun 2020 04:40:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1591591221; bh=bApnU72BbBvG7NhQZ/lqbmMTagmxZ46Qj4HBM7qJs4g=; h=Date:From:To:Subject:In-Reply-To:From; b=f4qzkrRXvXUaDypSIsfP2wbrqr7hxmCkVjXf44s+jZIqVYOu5BY/L0fmOKhj8eIH5 OPZRl8qqU8eOlNip1CA+7Lxh/4j5en2VBLOViqYCxjv416hClSVVjjz8+DwRbwN+KZ AvltV9XZd0gL/2SIURauUaa9PlUNXN/cema49Qw4= Date: Sun, 07 Jun 2020 21:40:20 -0700 From: Andrew Morton To: akpm@linux-foundation.org, linux-mm@kvack.org, manfred@colorfullife.com, mm-commits@vger.kernel.org, torvalds@linux-foundation.org, willy@infradead.org Subject: [patch 06/54] xarray.h: correct return code documentation for xa_store_{bh,irq}() Message-ID: <20200608044020.tiS8hHoBP%akpm@linux-foundation.org> In-Reply-To: <20200607212615.b050e41fac139a1e16fe00bd@linux-foundation.org> User-Agent: s-nail v14.8.16 X-Rspamd-Queue-Id: 93B6C18197ADE X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam03 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: From: Manfred Spraul Subject: xarray.h: correct return code documentation for xa_store_{bh,irq}() __xa_store() and xa_store() document that the functions can fail, and that the return code can be an xa_err() encoded error code. xa_store_bh() and xa_store_irq() do not document that the functions can fail and that they can also return xa_err() encoded error codes. Thus: Update the documentation. Link: http://lkml.kernel.org/r/20200430111424.16634-1-manfred@colorfullife.com Signed-off-by: Manfred Spraul Cc: Matthew Wilcox Signed-off-by: Andrew Morton --- include/linux/xarray.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/include/linux/xarray.h~xarrayh-correct-return-code-for-xa_store_bhirq +++ a/include/linux/xarray.h @@ -576,7 +576,7 @@ void __xa_clear_mark(struct xarray *, un * * Context: Any context. Takes and releases the xa_lock while * disabling softirqs. - * Return: The entry which used to be at this index. + * Return: The old entry at this index or xa_err() if an error happened. */ static inline void *xa_store_bh(struct xarray *xa, unsigned long index, void *entry, gfp_t gfp) @@ -602,7 +602,7 @@ static inline void *xa_store_bh(struct x * * Context: Process context. Takes and releases the xa_lock while * disabling interrupts. - * Return: The entry which used to be at this index. + * Return: The old entry at this index or xa_err() if an error happened. */ static inline void *xa_store_irq(struct xarray *xa, unsigned long index, void *entry, gfp_t gfp) _