Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp2101099pxb; Thu, 4 Nov 2021 14:06:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzzMRFa7sfM1Q5lnYnBFXLNfogGU3Qr31Vmbvv37WRCG70hKbgwCdSSH+cy27Ob+aS+c+o5 X-Received: by 2002:a05:6602:2dd5:: with SMTP id l21mr21764459iow.87.1636060010947; Thu, 04 Nov 2021 14:06:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1636060010; cv=none; d=google.com; s=arc-20160816; b=B2JvJJadQunTbwJgj3q3Zf79Sq9oIUbuJPSdBcDOW71bLaMBe2hPfs9PIsbVagoPbE 1JpdQJniwax8nymv+TzCQw1crWdkMWISyYdbMJwhxEaKBRUt7cGJhvRm0AWoxPgU/bPZ MUCl0acyoro+X2igMq0HAUA6HErsvs5UTuxCidt2sWHn6aYOPpUPErcoSneMfs11Ud9J 131AYfoiC68xhk796Ivd0Zpsyg77PnlRcCMnuEyq1s4x+zALriNWoveSC43LDVOVkJeg O/5iKEeRGap5XgvWevOqcKJ36UXDWh8chutl3BenpxhgYF+ANJG/7j/lyd8ulhholPzg RB2g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=Bq4tNMI44duy5gStAC9/koIu9ir5RqQr9dPHfcHLD5M=; b=T5EEDhZ9z2yUjER6yjADk5qXsIGyqS/mIrHKsFcEi16Nh7Ns8/8kn8946PA4aBJ2tm FEHjmsE+8lLqNNQoIOoaqjsLp3t64Ppf2N6ijH6lBH6lAwS1q/YkuAeLjTZ+4V7N+jgT H+2KLmWl4XOFnrK17AbH1NUY7fDZa0wA99urMHUBFoScxA2GWcY9py9BzN/wRwkSYdfq BP+tXrdaulaiYZufKGzXvt6Jft/McNCwMpZO/sZbeiuRlcPvKtJbECW8f16gdldrSj1c Qo0y2YNuP/JjonEBdQ21mApfOO8PSOuczUsOURVsJkS+jE6nBPMqyzXuysq9Xpx/hDfb NG9Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=hMZPfTtv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y15si13357784ilu.148.2021.11.04.14.06.36; Thu, 04 Nov 2021 14:06:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=hMZPfTtv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232295AbhKDVFZ (ORCPT + 99 others); Thu, 4 Nov 2021 17:05:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48718 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231983AbhKDVFZ (ORCPT ); Thu, 4 Nov 2021 17:05:25 -0400 Received: from mail-lf1-x12d.google.com (mail-lf1-x12d.google.com [IPv6:2a00:1450:4864:20::12d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 89ABEC061714 for ; Thu, 4 Nov 2021 14:02:46 -0700 (PDT) Received: by mail-lf1-x12d.google.com with SMTP id d21so14522941lfg.7 for ; Thu, 04 Nov 2021 14:02:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Bq4tNMI44duy5gStAC9/koIu9ir5RqQr9dPHfcHLD5M=; b=hMZPfTtv+EhsjGdIcH16mAZzdVz4fL1d35blRrUFmsmFaTErgyobsVEm78IGiZPb7L zHjWgLn5ROhjkcg7s4vW4NbsFBLcJ5YaWw8UdiUQqZU+/7FFiaOJTd/xqJGryO6knOvd 711vd8csqK17V/vYfs/xwvkJGuoDHYzgzfIe8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Bq4tNMI44duy5gStAC9/koIu9ir5RqQr9dPHfcHLD5M=; b=p92QmxZzvRDve9fOuB3LmPn1czmZTQOQw1loPjcqtMjveaet5VGlf8PSS4IKApz6at 9VgjPOwY1dHEzR1yR/CYDeOC3wH/jEoFPbx7zNbaxBBhdpM2UNzHS6xKcE3oQGJHczZY gSusCbdMCliC8zFaVbkUQ5EtgIc8KjP03PaO2UT6w3ELyyttuwM9g81X+c2H8UlyJW74 gkMSmhbfUCOc+b1VZ6zQbaoOpMOTZAOheSvHTkCFExeCLOukj0LZYv9IaswComRpp8Uk mS/Y+7NNjHeXWprXC5D6iQ0fx0910bI0DacHONl3llSxqrN1xr0IvO7t1pceMb95uKyv uY9w== X-Gm-Message-State: AOAM533HmY7R7uge0A0NEPqjWOSntfOZQnRjGBjXxpuQV8SO42dD4Ww+ fPGrtVJ4UacIeHxvczDh4px0ULO/O3m26qPJ X-Received: by 2002:a05:6512:3c93:: with SMTP id h19mr48695784lfv.411.1636059764279; Thu, 04 Nov 2021 14:02:44 -0700 (PDT) Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com. [209.85.167.51]) by smtp.gmail.com with ESMTPSA id u5sm649393lfr.290.2021.11.04.14.02.41 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 04 Nov 2021 14:02:42 -0700 (PDT) Received: by mail-lf1-f51.google.com with SMTP id bi35so14516827lfb.9 for ; Thu, 04 Nov 2021 14:02:41 -0700 (PDT) X-Received: by 2002:a05:6512:3993:: with SMTP id j19mr46421657lfu.402.1636059760874; Thu, 04 Nov 2021 14:02:40 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Linus Torvalds Date: Thu, 4 Nov 2021 14:02:25 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: flush_dcache_page vs kunmap_local To: Matthew Wilcox Cc: Christoph Hellwig , linux-arch , Ira Weiny , Andrew Morton , Linux Kernel Mailing List , Thomas Gleixner Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Nov 4, 2021 at 11:39 AM Matthew Wilcox wrote: > > On Thu, Nov 04, 2021 at 08:30:55AM -0700, Linus Torvalds wrote: > > Why did this come up? Do you actually have some hardware or situation > > that cares? > > Oh, we're doing review of the XFS/iomap folio patches, which led to > looking at zero_user_segments(), and I realised that memzero_page() > was now functionally identical to zero_user(). And you'd been quite > specific about not having flush_dcache_page() in there, so ... I wondered > if you'd had a change of mind. Ugh. I guess it ends up being there whether I like it or not. All that "zero_user_segments() stuff is too ugly for words, though, so I think whoever wrote it must have been on some interesting pharmaceuticals. What the hell are the two start/end things? And most users actually just want a single page and should never have used that thing. Nasty. I'm not touching that with a ten-foot pole. Linus