Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp4739266rwl; Tue, 28 Mar 2023 10:36:34 -0700 (PDT) X-Google-Smtp-Source: AKy350Z+WDtofZUlBF0RdRkVuEAXlHU2wekzcGE/AF9A4k74t46W+Qv/gFgKvB/Ehh8jEJspFeBR X-Received: by 2002:a17:902:c405:b0:199:2a89:f912 with SMTP id k5-20020a170902c40500b001992a89f912mr22018928plk.20.1680024994023; Tue, 28 Mar 2023 10:36:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680024994; cv=none; d=google.com; s=arc-20160816; b=rB2XLrVzuF9C6FtpioQSEoEpLq0u2FksQ6FPrK0nDWsCrcSAo8rJF5qPvp1MflmTGC OwmoqunAJmn80rVr9Py768zFprAmARp1gNydbH7adeOZvEPlsGqE0ixFTxlbjHoUPZsK 9YXDvI/zX8gCizawFEaU569KHTBoK7HGjIF/S5GdGEzTiXBhMznXLgwVea7lS3SzAgtk eRjYamhBc8cpUE5k1dEvnLAGLuxALZf8GbZxxxNeMrDCmNjx3DW2pzs2XEo2bQiXVsOG w4SfjR3JS0hxAwA/jr8wuuZJMZHn3QNhSoUgM6Qan1JmUfYOlf72eL3SNR4l+dZP0qFW lNVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=DY7YgCh1iZeJKq9EsheOBiDYaF9Q7m8O4sVVQRTEOtQ=; b=w3bfFf4JKWem+KN63UHGOkxJylH2PBvFj+U9joAMWPC/b8WrPSdOA7LH80tTAd8RHs 3HT5B45fTzNMTLnag8+jViJA6w0YmL8CkDi5RYyCgi/g+Ehtp9d1/7iTl9YSTnRe8Wiu lJVIkT4S964h3OG15m9SyKQlOw6QL3XTk2gcxuurrTuAubWdH219Ik+oLiEvN5krCbxk dFdm3YTZ2K7DMag5R9kZXY7BvsAKp/eX8u6DOfe6FKeE33ZZFTVU7Hq+eM48NFE832xk eUfpvpeGrH17juUnF8pK9XWPOVH9/4TaYk66GV/IEeENcilOo6pD4CtxYRQ+s8cclusB EPww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=r86BZXlK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ld14-20020a170902face00b0019a826d3054si27984788plb.640.2023.03.28.10.36.15; Tue, 28 Mar 2023 10:36:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=r86BZXlK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229980AbjC1Rb5 (ORCPT + 99 others); Tue, 28 Mar 2023 13:31:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40550 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229838AbjC1Rb4 (ORCPT ); Tue, 28 Mar 2023 13:31:56 -0400 Received: from mail-yb1-xb36.google.com (mail-yb1-xb36.google.com [IPv6:2607:f8b0:4864:20::b36]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 283BEC651 for ; Tue, 28 Mar 2023 10:31:55 -0700 (PDT) Received: by mail-yb1-xb36.google.com with SMTP id r187so16091177ybr.6 for ; Tue, 28 Mar 2023 10:31:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; t=1680024714; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=DY7YgCh1iZeJKq9EsheOBiDYaF9Q7m8O4sVVQRTEOtQ=; b=r86BZXlKh2IQx67G5OPEubqsNljPE7UW5dQk3KKfx0taW0k2gLEGJ0KskGNsNmSvO5 49z49W6/HN+WNnhR5uyF48EEh7C7W8ub/+SpF9yZH0T+dJHYF7nWJ8BjIQ7nCQ8cEqcP FjxmTw+W06HCkU6L7A+QeVwwX+kk9XFZfDJFVbPdomeL4zw4VXErylakiGdBTlvwQdCC cZUC6upH5mIciQ7/JCHmGyFCoQSyQ8pUC4GRXKkEGipvNn/qkiS+PBwTmnuFJPmHpQaG uHLgDfWcJx2honDZ9BMj8fCdDxqYMlirsqd6jrQ+hg+RmCYNdqx2SHYQGbAPSWfxRXzA PmFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680024714; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=DY7YgCh1iZeJKq9EsheOBiDYaF9Q7m8O4sVVQRTEOtQ=; b=Pw+wwQ/wniKLz7GyCRakQ4aj2VtTGm3mYjRI8SGN+tXr+Sv6WZNWcypnmHxGkctbZK 4ceaPszwWx94qC+7g/OIRpTjhrJSIuw1OYQeR25oxeVSzqsELn0c0rqowAONvdzNPVQp VVSTLuVsHbNmcegwt3O8DDEFaF22pKy0DuGez0Ez2DB95MC5SjWYw4/sYCdf8WJaEwSV s8vKfqWQOLAbiEhP5zZDkvcQSHGfPE959iPSxOYz+n4xIAztxtQJKV6GkszMKgKFHuMu XCRY3SV6MEwt373JG4/29ZSsNZUgG4g5/axtg+qoSUSDy2wMrzwP0LgHCUP2X7Wt4lkb fFzA== X-Gm-Message-State: AAQBX9fMfJ4BpYRGPCXtiqGZGMi5pxEMR0S1ZFMyX5rbjmYIipwLQJX1 Zb+CbS7nbzsnShlkl+oAXiiQlnx4UgVcT3WeZDS6MQ== X-Received: by 2002:a05:6902:1009:b0:b6b:e967:920d with SMTP id w9-20020a056902100900b00b6be967920dmr8469098ybt.13.1680024714097; Tue, 28 Mar 2023 10:31:54 -0700 (PDT) MIME-Version: 1.0 References: <20230306224127.1689967-1-vipinsh@google.com> <20230306224127.1689967-15-vipinsh@google.com> In-Reply-To: From: Vipin Sharma Date: Tue, 28 Mar 2023 10:31:18 -0700 Message-ID: Subject: Re: [Patch v4 14/18] KVM: mmu: Initialize kvm_mmu_memory_cache.gfp_zero to __GFP_ZERO by default To: David Matlack Cc: seanjc@google.com, pbonzini@redhat.com, bgardon@google.com, jmattson@google.com, mizhang@google.com, kvm@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-15.7 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,ENV_AND_HDR_SPF_MATCH, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL, USER_IN_DEF_SPF_WL autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 23, 2023 at 3:28=E2=80=AFPM David Matlack = wrote: > > On Mon, Mar 06, 2023 at 02:41:23PM -0800, Vipin Sharma wrote: > > Set __GFP_ZERO to gfp_zero in default initizliation of struct > > kvm_mmu_memory_cache{} > > > > All of the users of default initialization code of struct > > kvm_mmu_memory_cache{} explicitly sets gfp_zero to __GFP_ZERO. This can > > be moved to common initialization logic. > > If that were true we could get rid of gfp_zero entirely and hard-code > __GFP_ZERO in the memory allocator! mmu_shadowed_info_cache is the one > that does not set __GFP_ZERO. > Can we use __GFP_ZERO for mmu_shadowed_info_cache? Also, MIPS doesn't use __GFP_ZERO, I think it might be a missed thing in MIPS rather than intentional.