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.6 required=3.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL 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 B631BC4332D for ; Thu, 7 Jan 2021 04:46:34 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8AA4023118 for ; Thu, 7 Jan 2021 04:46:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727468AbhAGEqP (ORCPT ); Wed, 6 Jan 2021 23:46:15 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49908 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727432AbhAGEqN (ORCPT ); Wed, 6 Jan 2021 23:46:13 -0500 Received: from mail-ua1-x933.google.com (mail-ua1-x933.google.com [IPv6:2607:f8b0:4864:20::933]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 83112C0612F1 for ; Wed, 6 Jan 2021 20:45:32 -0800 (PST) Received: by mail-ua1-x933.google.com with SMTP id 17so1873253uaq.4 for ; Wed, 06 Jan 2021 20:45:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=0FqBU0DzyxHE7rFaChTOl0+T3ooasosngTw/QRkuqug=; b=CZXxilFUsoVBDX44Kjfrzt9xXAty5ZhWzDyCfu4kVQ1Qo7a3UIOFlzJNPFs95RNjS0 ZN10TTyBRYb1pGd42ZVV5Ye/gKqpiI1F1/ZYRe4zpZCRwURUzeK/vVrMEj3gTkBcL6UG X8k18HXjmGb6OQ8yhG0ja6Jihr8cO+X/QbbJ0GHHnz01kf020ABkEMGfVWK4uYwWeqg9 S7jayEzgXB0rMOb4Zp1b+MDVvEVnFQSS6EWBjOqwPcp3GGDOxvZ2lVleaeKv0/UwwZSs tNS0H6biAIo1Z8ias28x1iHdU4MjG9lBmQ6jUuAqTA38xOKplbSbO4nFVyA9eamm66or hE7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=0FqBU0DzyxHE7rFaChTOl0+T3ooasosngTw/QRkuqug=; b=oOVhI+Dq6ZY3Z8m9T4DlfOl9frURwXRwRJV5DgBiIk1TjEfoT6XDOzfg8F4OVal1fU Ngcik/+vXo/iOsCLsHpFxLeEgs5TgRerOp/JFh9lx9UjMHZ4zViGJt2Q51N8IeJndPK3 Pq4kAOLbc2gxsTKKmiRCEUn8zjprAHxkIvXpfKBMKTblijslGJLK2R5Oiwl8fSLOMwPT 0zz9ZDSZ7FTo5TrTqwZ6BI2cI96s9/+Bo3c0b1HCY0jsJpFgqu3QnpdydP2MyJgaBHAO PwIDGFzIaIhOShSM1nMkhqjFiuh68n7B2kMfDbpz9ug9OOR5uGurrq5zEM7o8NH2eqUS gxhQ== X-Gm-Message-State: AOAM533T4RxEREkwmM+vg/7i3qoL31earJIoAkIHwIBxS9FF5hhslbLN SoIWLwHTUrW4jnL+dPqKC++nEhmm8NozC8GnJ9We8w== X-Google-Smtp-Source: ABdhPJyDMe9TseuG/qIjyrE/SGPXVQo4rz/hxHrw+SPyifPGylrTHwJJ73DrnQGq6u9/vLT5zVMzVyS5VSmNBVCTiGk= X-Received: by 2002:ab0:7386:: with SMTP id l6mr6184246uap.141.1609994731526; Wed, 06 Jan 2021 20:45:31 -0800 (PST) MIME-Version: 1.0 References: <20201118194838.753436396@linutronix.de> <20201118204007.169209557@linutronix.de> <20210106180132.41dc249d@gandalf.local.home> <20210106174917.3f8ad0d8@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> In-Reply-To: From: Willem de Bruijn Date: Wed, 6 Jan 2021 23:44:54 -0500 Message-ID: Subject: Re: [BUG] from x86: Support kmap_local() forced debugging To: Jakub Kicinski Cc: Linus Torvalds , Steven Rostedt , David Miller , Jonathan Lemon , Thomas Gleixner , LKML , "the arch/x86 maintainers" , Christoph Hellwig , Matthew Wilcox , Daniel Vetter , Andrew Morton , Linux-MM , Peter Zijlstra , Ingo Molnar , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Ben Segall , Mel Gorman , Daniel Bristot de Oliveira , Netdev Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 6, 2021 at 9:11 PM Willem de Bruijn wrote: > > On Wed, Jan 6, 2021 at 8:49 PM Jakub Kicinski wrote: > > > > On Wed, 6 Jan 2021 17:03:48 -0800 Linus Torvalds wrote: > > > I wonder whether there is other code that "knows" about kmap() only > > > affecting PageHighmem() pages thing that is no longer true. > > > > > > Looking at some other code, skb_gro_reset_offset() looks suspiciously > > > like it also thinks highmem pages are special. > > > > > > Adding the networking people involved in this area to the cc too. But there are three other kmap_atomic callers under net/ that do not loop at all, so assume non-compound pages. In esp_output_head, esp6_output_head and skb_seq_read. The first two directly use skb_page_frag_refill, which can allocate compound (but not __GFP_HIGHMEM) pages, and the third can be inserted with netfilter xt_string in the path of tcp transmit skbs, which can also have compound pages. I think that these could similarly access data beyond the end of the kmap_atomic mapped page. I'll take a closer look.