Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp280360ybt; Wed, 17 Jun 2020 00:18:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzsNcx7QKlqoYI7K2PUG0HDlnDwMVXg3vbXkezU7Lm/sjtF4zYIBDU+oMxAbcTOwI1cXmD4 X-Received: by 2002:aa7:c609:: with SMTP id h9mr5697551edq.155.1592378311680; Wed, 17 Jun 2020 00:18:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592378311; cv=none; d=google.com; s=arc-20160816; b=cg8k1VbfgXoaovjySGNDlPDnjSPD77IN4ruhCxI1oCn8jvH+83vLvBi3xvtmn06vgg CheahwSz/HrMzeFTKzPg4IAO7QIgDmZzRlnJ5OD3Ifs1LcUpImrr68hBsC8Q6pVuXghY 1U6DikLXRq2u3i6/PoIKrhZXIZ7+nqcHtaEww4dNyQ8rzOWHKDwc1+SQh3X8GQZ9HeyL NRNDJyLM51qP0zM6tKhX9FSgkqlGzwUcgLCFW+e3AfQRrhwCV7GQ2tVdo2arxXaxSsJi BDOD2ZGTJHDmiAIWMOnbEhu9TKuPz8qNqLWvya0dJWxHD4hGQD87oq3vawe+zL3pHyCR BL+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition:mime-version :message-id:subject:cc:to:from:date:dkim-signature; bh=rxDV988DUu6HasBuCrxRn743kfCSD3gv/yZvtfCKovM=; b=vsoxCqY4eVIZHdEgJ/vUI5NGVFqQ+pYUGmRCYXUZKSP+zYNsZOZttR8XurIlFdR3eO Sl8awGHn5jpAnArDB06zqqsbTzG/QcKv27L249KQikNTVAK+taP6ryuz9GrsClmlmN03 NxI1uYOrwEOIf3MZbf7f0Bau1GXjBqueo51eLGJkmDEr2f8nI+aqcTctgDih2XUVzRQZ XjoVlRlJMzaKAbcSKZtvmQEUyX520/A+Aouq4egnaSBSUIAqBI4NtPQp+dUCfkpf9VQF yuPp0TisB4SroC56A3eAfMLd93Mrgd3WYq1em+9CyHKIXbmgfRslj/eGkzfngGQJjEbt a+EA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=VxCU71un; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ha25si12690910ejb.180.2020.06.17.00.18.09; Wed, 17 Jun 2020 00:18:31 -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=@gmail.com header.s=20161025 header.b=VxCU71un; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726355AbgFQHQU (ORCPT + 99 others); Wed, 17 Jun 2020 03:16:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48502 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725860AbgFQHQU (ORCPT ); Wed, 17 Jun 2020 03:16:20 -0400 Received: from mail-ej1-x633.google.com (mail-ej1-x633.google.com [IPv6:2a00:1450:4864:20::633]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D26E7C061573 for ; Wed, 17 Jun 2020 00:16:19 -0700 (PDT) Received: by mail-ej1-x633.google.com with SMTP id p20so1121699ejd.13 for ; Wed, 17 Jun 2020 00:16:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:mime-version:content-disposition; bh=rxDV988DUu6HasBuCrxRn743kfCSD3gv/yZvtfCKovM=; b=VxCU71un4aaKfNH4wCTasrqnObw3DWCwMyY6Mn+nIzH9G22WrmAVRuzuWuYJ294bZD y2RLv8q3UtX4Z7s/HY45Eje6ZVx11COTdiBDuUB8u0zJDzawKsvLIMUpDe3pstuVqVXm iwnkJAT1QAzIBscIv45SmtiAgQa9b2b4PxACy07g1OwXg1+Aircpk0dEeSMCpyVQG5ZK 7IDsX02uIWO2JJ/N8CwhnHJ4IUkJtO6eaxi/4V6PhdtvOKN+HEPjJg2P3Cx2RU+F9H7C 1496JSpeMUT5vpOK462lfMqR22yFbQwwcWOYCiE2jkyjU0TtPGdf5UbBHE1Y4vcneV/+ wy2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition; bh=rxDV988DUu6HasBuCrxRn743kfCSD3gv/yZvtfCKovM=; b=AC0fc3nC0rXji9eET+3tRdKffsO1u+jvoFMobPBcerUSu0U6aYUYhjgCPhMR9I41pd QneiqJ3Y/k/7p2X3D6ck+2ItwPOWzsKR3qldTQcCiYOv+KtfYt2X7csw/yNyUHmDwjzh Xd/x5nsvZFnEsLzjF/jbwIK7urFatIgpy5U0idfN5gOJ4ovL4kbtj+W0kIwSML85v/ct HJyMM/ic/4uJBL/tUVN+7A0hglGMAMsbLpIOf0OLYmh9BlzhTuBfexKf/Hyg0VElohsS oYoX+h3Q0I7jYbvAl6X7+DO064T8NQEy9GCGwg299kesNNMCVQ8I0zVYkCtZbDY2fg2s nlmw== X-Gm-Message-State: AOAM531kZ7VnqQtZF01IbUUhDLWtJJJe8IeVIRuCAu0g6V8bmP3tK3Ym VoAzqoEge/3HMGqiYcJ3Ew== X-Received: by 2002:a17:906:4dc2:: with SMTP id f2mr6543648ejw.402.1592378178682; Wed, 17 Jun 2020 00:16:18 -0700 (PDT) Received: from localhost.localdomain ([46.53.253.15]) by smtp.gmail.com with ESMTPSA id bg21sm12689111ejb.90.2020.06.17.00.16.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Jun 2020 00:16:18 -0700 (PDT) Date: Wed, 17 Jun 2020 10:16:16 +0300 From: Alexey Dobriyan To: liao.pingfang@zte.com.cn Cc: linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm, slab: Use kmem_cache_zalloc() instead of kmem_cache_alloc() with flag GFP_ZERO. Message-ID: <20200617071616.GA4001@localhost.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > static inline void *kmem_cache_zalloc(struct kmem_cache *k, gfp_t flags) > { > - return kmem_cache_alloc(k, flags | __GFP_ZERO); > + return kmem_cache_zalloc(k, flags); > } That's a good one.