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=-5.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 0C2B8C433E0 for ; Tue, 23 Feb 2021 17:14:09 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 8801864EC8 for ; Tue, 23 Feb 2021 17:14:08 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8801864EC8 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 F22598D0001; Tue, 23 Feb 2021 12:14:07 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id ED1616B0074; Tue, 23 Feb 2021 12:14:07 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id DE7EF8D0001; Tue, 23 Feb 2021 12:14:07 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0162.hostedemail.com [216.40.44.162]) by kanga.kvack.org (Postfix) with ESMTP id C76DC6B0073 for ; Tue, 23 Feb 2021 12:14:07 -0500 (EST) Received: from smtpin22.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 8A3B2180ACF75 for ; Tue, 23 Feb 2021 17:14:07 +0000 (UTC) X-FDA: 77850180534.22.79AA9DE Received: from mail-lf1-f48.google.com (mail-lf1-f48.google.com [209.85.167.48]) by imf28.hostedemail.com (Postfix) with ESMTP id 9954C2000380 for ; Tue, 23 Feb 2021 17:14:02 +0000 (UTC) Received: by mail-lf1-f48.google.com with SMTP id e7so12445320lft.2 for ; Tue, 23 Feb 2021 09:14:02 -0800 (PST) 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=3gExe93wosmSzhyTwQXk9LaYNy6KAG9KuAxNWYjdijs=; b=PmRPXaIRufMdXn11znSEzdNe2b7nW+xn8hiKWpkTwBcKRg7vqYs9aaJoAbxqGxuv7z EnigZQfkpGYgjbzOIrnB90HxpeLL1yaVXyCcQ1jHx4CGi8JmAp/Hgk6yWJqzhPgO3Q+l AIsHCrL6NAWifWmyc/g4ZZoRhfUMNkuCfI0DM= 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=3gExe93wosmSzhyTwQXk9LaYNy6KAG9KuAxNWYjdijs=; b=aMH7MWW7LzgA93iWAss85J1GoZG8sfGRAQzaAUVyGylztnYR6Gnh0S4f+njaxwe9IP zgIdtB3pOTXQhHpDceoeuT93l7MBS/SXSOR5UbSubFuSQ091RZYN5Sgl3VKyk8z7Qr+x yXEMlCTiGp5djo5utPJhXAyeCU4UaFcvUc4b9ysKgZ4Gtem3QfGF2bai1YNjB1a0wKBu 49OzZSKJ6xTNtVdQulFYaK9+epFO/W4wnK0GBKYjNHw5+6jz6Mh6FQKv6iESaXzAX/Vv bZa5hN0YAbzl/8UR4GbhLZHgua/oY1OaYYv5iqt+BCFHnE62OW4HKNyeF2mhayP+XG6z KRuw== X-Gm-Message-State: AOAM530dMECK5OOiZZmy+gD/uuH9/hnEwzXJJIAk/sQNcn2SRUZMZkGX j/Hjt3ZlFQhemqGVIh0qOZKiRGNi0d7FiA== X-Google-Smtp-Source: ABdhPJxU7F6ic/BbP6VCnNAqWrS2GY205L4zE/B8KQ/x+WHkh14ksbcpq57IDr2oXui+I10L446rfw== X-Received: by 2002:a19:c20b:: with SMTP id l11mr16648499lfc.271.1614100440268; Tue, 23 Feb 2021 09:14:00 -0800 (PST) Received: from mail-lf1-f41.google.com (mail-lf1-f41.google.com. [209.85.167.41]) by smtp.gmail.com with ESMTPSA id s6sm2733343lfe.97.2021.02.23.09.13.59 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 23 Feb 2021 09:13:59 -0800 (PST) Received: by mail-lf1-f41.google.com with SMTP id d24so12325025lfs.8 for ; Tue, 23 Feb 2021 09:13:59 -0800 (PST) X-Received: by 2002:a19:8186:: with SMTP id c128mr16927725lfd.377.1614100438784; Tue, 23 Feb 2021 09:13:58 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Linus Torvalds Date: Tue, 23 Feb 2021 09:13:42 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [GIT PULL] Kmap conversions for 5.12 To: David Sterba Cc: David Sterba , Linux Kernel Mailing List , Ira Weiny , Linux-MM Content-Type: text/plain; charset="UTF-8" X-Stat-Signature: usy4yf3mju48x3nicc3996f7wiy1c811 X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 9954C2000380 Received-SPF: none (linuxfoundation.org>: No applicable sender policy available) receiver=imf28; identity=mailfrom; envelope-from=""; helo=mail-lf1-f48.google.com; client-ip=209.85.167.48 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1614100442-180795 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 Tue, Feb 23, 2021 at 7:03 AM David Sterba wrote: > Ira Weiny (8): > iov_iter: Remove memzero_page() in favor of zero_user() Ugh. I absolutely _detest_ this patch. "zero_user()" is a completely horrendous function, and not at all the same as memzero_page(). Just look at it. Yes, it's mis-used in a lot of places that really always wanted "memzero_page()", but this conversion is going exactly the wrong way around. Existing users of that zero_user() should have been converted to memzero_page(), rather than doing it this way. The "user" naming should have given it away. It's a very very magical interface for user-mapped pages that have additional odd issues (ie look at the dcache flushing etc). I'll think some more about this pull request, but honestly, this one broken is pretty much enough for me to say "No way in hell", because it shows a complete disregard for sanity. The last commit in the series: > btrfs: convert to zero_user() is also very mixed up about whether it actually wants the dcache flushing or not (and thus zero_user() or memzero_page()). Honestly, I suspect all the dcache flushing is totally pointless, because any architecture with virtual caches that does kmap needs to flush at kunmap anyway, afaik. Some of it is probably just voodoo programming and copying a pattern. But in any case, zero_user() is not the same thing as memzero_page(), and even if they *were* the same thing, zero_user() is objectively the horribly much worse name. Linus