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=-10.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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 EA279C43460 for ; Fri, 14 May 2021 01:01:37 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C05D7611AB for ; Fri, 14 May 2021 01:01:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232065AbhENBCr (ORCPT ); Thu, 13 May 2021 21:02:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42550 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231265AbhENBCn (ORCPT ); Thu, 13 May 2021 21:02:43 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5E594C061574; Thu, 13 May 2021 18:01:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=AewoeCdKzupjrAmmf0ZaCNC8yUlU7sjr3AelIO0F/XM=; b=aeMzHZzq2PEe+UoOqIrdKwzBHp SpD13pChgGsdAlUV5up3rlgtz61ceBqKB4YVlPxrnpfIlr7qixm35r1pzxJdKP5QLSEv8lpn96D0y XzkuZ5dWtc2OwZ5MLmRA63ZiRfVsiuzDjvNofa4ETRslxO8M2Jiy0ABimf/OQBBIBKNe6+XoAKHKm jnu6IBehlAN86e5u5i1YiDGMdh6HbEFpXvmqZfg0uWWZ0RgIYELAbrImjCvmT3Mj3MNXddpgvVD4Q wk2S0O02ZQlAvoJJaMqZAfsaJd5UMN1xmGhYemsBXOmYPilm+wJEFjNiGZw6xjlSivEfoga3pOTMt bF+rEfzQ==; Received: from willy by casper.infradead.org with local (Exim 4.94 #2 (Red Hat Linux)) id 1lhMBp-009wQq-20; Fri, 14 May 2021 01:00:50 +0000 Date: Fri, 14 May 2021 02:00:29 +0100 From: Matthew Wilcox To: Matteo Croce Cc: netdev@vger.kernel.org, linux-mm@kvack.org, Ayush Sawal , Vinay Kumar Yadav , Rohit Maheshwari , "David S. Miller" , Jakub Kicinski , Thomas Petazzoni , Marcin Wojtas , Russell King , Mirko Lindner , Stephen Hemminger , Tariq Toukan , Jesper Dangaard Brouer , Ilias Apalodimas , Alexei Starovoitov , Daniel Borkmann , John Fastabend , Boris Pismenny , Arnd Bergmann , Andrew Morton , "Peter Zijlstra (Intel)" , Vlastimil Babka , Yu Zhao , Will Deacon , Fenghua Yu , Roman Gushchin , Hugh Dickins , Peter Xu , Jason Gunthorpe , Jonathan Lemon , Alexander Lobakin , Cong Wang , wenxu , Kevin Hao , Jakub Sitnicki , Marco Elver , Willem de Bruijn , Miaohe Lin , Yunsheng Lin , Guillaume Nault , linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org, bpf@vger.kernel.org, Eric Dumazet , David Ahern , Lorenzo Bianconi , Saeed Mahameed , Andrew Lunn , Paolo Abeni , Sven Auhagen Subject: Re: [PATCH net-next v5 1/5] mm: add a signature in struct page Message-ID: References: <20210513165846.23722-1-mcroce@linux.microsoft.com> <20210513165846.23722-2-mcroce@linux.microsoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210513165846.23722-2-mcroce@linux.microsoft.com> Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Thu, May 13, 2021 at 06:58:42PM +0200, Matteo Croce wrote: > struct { /* page_pool used by netstack */ > + /** > + * @pp_magic: magic value to avoid recycling non > + * page_pool allocated pages. > + * It aliases with page->lru.next I'm not really keen on documenting what aliases with what. pp_magic also aliases with compound_head, 'next' (for slab), and dev_pagemap. This is an O(n^2) documentation problem ... I feel like I want to document the pfmemalloc bit in mm_types.h, but I don't have a concrete suggestion yet. > +++ b/include/net/page_pool.h > @@ -63,6 +63,8 @@ > */ > #define PP_ALLOC_CACHE_SIZE 128 > #define PP_ALLOC_CACHE_REFILL 64 > +#define PP_SIGNATURE (POISON_POINTER_DELTA + 0x40) I wonder if this wouldn't be better in linux/poison.h?