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=-13.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 7651AC433E0 for ; Mon, 15 Feb 2021 21:47:51 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id EDD9B64DEB for ; Mon, 15 Feb 2021 21:47:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EDD9B64DEB Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.ibm.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 641C78D0147; Mon, 15 Feb 2021 16:47:50 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 5F1E88D0140; Mon, 15 Feb 2021 16:47:50 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4E0178D0147; Mon, 15 Feb 2021 16:47:50 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0025.hostedemail.com [216.40.44.25]) by kanga.kvack.org (Postfix) with ESMTP id 35AC28D0140 for ; Mon, 15 Feb 2021 16:47:50 -0500 (EST) Received: from smtpin18.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 03EEE182F299D for ; Mon, 15 Feb 2021 21:47:50 +0000 (UTC) X-FDA: 77821839900.18.party60_130f7632763e Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin18.hostedemail.com (Postfix) with ESMTP id DF674100EC676 for ; Mon, 15 Feb 2021 21:47:49 +0000 (UTC) X-HE-Tag: party60_130f7632763e X-Filterd-Recvd-Size: 5601 Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by imf29.hostedemail.com (Postfix) with ESMTP for ; Mon, 15 Feb 2021 21:47:49 +0000 (UTC) Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 11FLfarJ094626; Mon, 15 Feb 2021 16:47:47 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=pp1; bh=8BIuk0Sbjax5i3806/AP7ebxHR7LH3kf4MzoWfZL2Uk=; b=JvY/iO0+KetODtW5Jvj7i7gecz7QebUvXoKFXJf2YSDMD9Ntm1SJQQouDCQi5bR0vS02 KXsxfYwz5AWxGqYQrOx32E7c2Vq3BAZdRDfwtk8/kyzHrn+T0PKOnGTtRDDjfQ+L0wi3 bJ3L7UZfTIYJeDR62Mqb8yZ11rg6vlyFoW3qGEpigJCEieTsSyi2RRCLrqBYdk+FiBHf BnXX26LkbTNP08gMO3OCzwyJJarEk4rKPK+TQIDdVFXZuYnZ03MXuaDyi7nc0sc0/wTe Oc5+EclKPioAGRggOAaS74M1WKpFnqa/agzokq7uAOf1VQaD/M346tIom0tV+ZbKyC8e 3w== Received: from ppma05fra.de.ibm.com (6c.4a.5195.ip4.static.sl-reverse.com [149.81.74.108]) by mx0b-001b2d01.pphosted.com with ESMTP id 36r13br3ff-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 15 Feb 2021 16:47:46 -0500 Received: from pps.filterd (ppma05fra.de.ibm.com [127.0.0.1]) by ppma05fra.de.ibm.com (8.16.0.42/8.16.0.42) with SMTP id 11FLd94K013204; Mon, 15 Feb 2021 21:47:45 GMT Received: from b06cxnps4076.portsmouth.uk.ibm.com (d06relay13.portsmouth.uk.ibm.com [9.149.109.198]) by ppma05fra.de.ibm.com with ESMTP id 36p6d8h4pg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 15 Feb 2021 21:47:45 +0000 Received: from b06wcsmtp001.portsmouth.uk.ibm.com (b06wcsmtp001.portsmouth.uk.ibm.com [9.149.105.160]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 11FLlh4i33096028 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 15 Feb 2021 21:47:43 GMT Received: from b06wcsmtp001.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 06067A4054; Mon, 15 Feb 2021 21:47:43 +0000 (GMT) Received: from b06wcsmtp001.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 7CA8EA4060; Mon, 15 Feb 2021 21:47:42 +0000 (GMT) Received: from linux.ibm.com (unknown [9.145.156.52]) by b06wcsmtp001.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Mon, 15 Feb 2021 21:47:42 +0000 (GMT) Date: Mon, 15 Feb 2021 23:47:40 +0200 From: Mike Rapoport To: "Matthew Wilcox (Oracle)" Cc: Andrew Morton , linux-mm@kvack.org Subject: Re: [PATCH v2 5/6] mm/mempolicy: Rewrite alloc_pages documentation Message-ID: <20210215214740.GU299309@linux.ibm.com> References: <20210215210203.3827513-1-willy@infradead.org> <20210215210203.3827513-6-willy@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210215210203.3827513-6-willy@infradead.org> X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.369,18.0.761 definitions=2021-02-15_16:2021-02-12,2021-02-15 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 priorityscore=1501 mlxscore=0 suspectscore=0 spamscore=0 clxscore=1015 mlxlogscore=999 impostorscore=0 lowpriorityscore=0 malwarescore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2102150160 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: On Mon, Feb 15, 2021 at 09:02:02PM +0000, Matthew Wilcox (Oracle) wrote: > Document alloc_pages() for both NUMA and non-NUMA cases as kernel-doc > doesn't care. > > Signed-off-by: Matthew Wilcox (Oracle) One nit below, otherwise Acked-by: Mike Rapoport > --- > mm/mempolicy.c | 21 ++++++++++----------- > 1 file changed, 10 insertions(+), 11 deletions(-) > > diff --git a/mm/mempolicy.c b/mm/mempolicy.c > index c71532b7e3f8..96c98ce16727 100644 > --- a/mm/mempolicy.c > +++ b/mm/mempolicy.c > @@ -2245,19 +2245,18 @@ alloc_pages_vma(gfp_t gfp, int order, struct vm_area_struct *vma, > EXPORT_SYMBOL(alloc_pages_vma); > > /** > - * alloc_pages - Allocate pages. > + * alloc_pages - Allocate pages. > + * @gfp: GFP flags. > + * @order: Power of two of number of pages to allocate. > * > - * @gfp: > - * %GFP_USER user allocation, > - * %GFP_KERNEL kernel allocation, > - * %GFP_HIGHMEM highmem allocation, > - * %GFP_FS don't call back into a file system. > - * %GFP_ATOMIC don't sleep. > - * @order: Power of two of allocation size in pages. 0 is a single page. > + * Allocate 1 << @order contiguous pages. The physical address of the > + * first page is naturally aligned (eg an order-3 allocation will be aligned > + * to a multiple of 8 * PAGE_SIZE bytes). The NUMA policy of the current > + * process is honoured when in process context. > * > - * Allocate a page from the kernel page pool. When not in > - * interrupt context and apply the current process NUMA policy. > - * Returns NULL when no page can be allocated. > + * Context: Can be called from any context, providing the appropriate GFP > + * flags are used. > + * Return: NULL when no page can be allocated. Don't you want to mention the return value on success? It is quite obvious, but still. > */ > struct page *alloc_pages(gfp_t gfp, unsigned order) > { > -- > 2.29.2 > -- Sincerely yours, Mike.