Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp2185457ybe; Tue, 3 Sep 2019 09:08:19 -0700 (PDT) X-Google-Smtp-Source: APXvYqy6/mBZvXlf2PbG6Hgg5YE2tS8qb22pgFEITSnp1JHYnTh93AjhLREb29pRc7yhERo5nUEL X-Received: by 2002:a62:3083:: with SMTP id w125mr21915188pfw.102.1567526898930; Tue, 03 Sep 2019 09:08:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567526898; cv=none; d=google.com; s=arc-20160816; b=djcAQFCVdUK7R8ctbbRXeoy+1PREZOXf0IV6Ot3tko0E+2U7KkEskfpJ9PScQkKotP 62LRkZQk4NunL4DFybnUIU2SKcgQ51xfdo1nKn9XFkSHwo39vLe/IGo59ePzY1y984A9 UgYs7JsBtJUXeUBzHaMz3xHz01xon/JIL/p7VfxYk58sJu2i3qiAEmBu/jjM1SQy/m5/ Sd/XPdj2F+uApUTjnenDJFHuBLDdNIlysPDOIVDF49GfULQDwT4gwpskaPj7I8dEKPKu 5QmPRuXaqBW2TUQpqBci47q4Qf2bfbrUo1mlNiXSSPQ/9XcznYDkkswbt62lD9PFq6Sh 0x1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=LViEBVo5/xlaUjZ5GSZNj0pM5S7KZYGyGn2HDxokJJk=; b=ckftzeuQoy7v6OdVSH9/oMUEr7UeZNw/+qfMD8STe5NKkZO1rDhr43k6k7pI4ZNWnK VfEhiIkHPB1O6nNKq8ag7Kukf7qFharN6f1F68ChfOpoAYLlgC54IPf+nfDwAvBv5sct qPPPd4OKGegIVUEG5KZ6geT46r23S78C3chdTpruH+eoOSVtZ8FV6VLvmetDCueWZ4ut Fn/6RycU1BovuECOU9TChAx53NFJkrP8OXt4vsq1wQGVo3YToOvT4uR2q3CfHOmTLmd3 vzarCtGRqskhEO8Y3SkjCZjDJv895ILESXSA2xrAN51KTkfPznnUZfqMZez2h+ENccQH 4prw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=P4H3OZmR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id 7si14416316pga.439.2019.09.03.09.08.02; Tue, 03 Sep 2019 09:08:18 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=P4H3OZmR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1729992AbfICQG0 (ORCPT + 99 others); Tue, 3 Sep 2019 12:06:26 -0400 Received: from mail-pl1-f196.google.com ([209.85.214.196]:34976 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728860AbfICQGZ (ORCPT ); Tue, 3 Sep 2019 12:06:25 -0400 Received: by mail-pl1-f196.google.com with SMTP id gn20so8082746plb.2 for ; Tue, 03 Sep 2019 09:06:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=LViEBVo5/xlaUjZ5GSZNj0pM5S7KZYGyGn2HDxokJJk=; b=P4H3OZmR9QVZgWZ2D/glNq5HSvTTrtqxFVkVeg/WZmiL9dTUo7HLjSs+UAauaHV7mt OmdGS37DH/UzzuxUriBbekvJtFfsZe4KNE++J97KcSHSY4zyUhWS44PKjvV53bG9d7Ow PpUs5C4moOLJL93jkoHpnAfyp4JoJ6d3dTTbCvi5lyfx/clI0zfp2Tpi5Ji7WwXp33Cv p7GCekESrk91miSi5xR5uSRp/dx2JHTaBLVp2x+t9peORo7Ett6DiFWSNaqQGa6W9rqY gOjY65Jb7D1y+WBAPwK7xtAOF2yavrCA41nuC3aJW27orC+W9Dn78nO5R9CUG9SDFRpL U6oQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=LViEBVo5/xlaUjZ5GSZNj0pM5S7KZYGyGn2HDxokJJk=; b=CsB91/h1RvdTaoTy/hCegDOWa/IdBCgVcIGShAVEugiaYqTnFAd6/FHqQl51JyjH3n Cl3TO3+7eACamBfCHSQZQZT1+4LerF+tjOqrHdV3X/pMiQ3kSOmiF9ntSYdXnX3xBwIB skofYW8cRXETf3bNAuppeogyRgfULWW8RlFYPlxlOqEQaLGrf87C77Z3CenEMiG2mwNV 6eteapLMB9t2pqb+eT3SGF5rQQ0o/IcbSIPRjm6irGMJteTwRDqXnxJyFQoZ1sJ0sNFe W7AKq0fkmZUyUBCkUmlk5fukzEFfjjFDtxnC1vqv4H5W6qYZRG5F0yu3j7w8nJbJ79Pk pNGw== X-Gm-Message-State: APjAAAVUGunMvH+NGcC8HDZT+K2Vr6i+/0DqUkdfxWAy07iPrsby/6wJ 2TznOcpvagXQ2EhhNQ2/6Gs= X-Received: by 2002:a17:902:7588:: with SMTP id j8mr18739799pll.280.1567526784988; Tue, 03 Sep 2019 09:06:24 -0700 (PDT) Received: from localhost.localdomain.localdomain ([2408:823c:c11:160:b8c3:8577:bf2f:3]) by smtp.gmail.com with ESMTPSA id t11sm18501567pgb.33.2019.09.03.09.06.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Sep 2019 09:06:24 -0700 (PDT) From: Pengfei Li To: akpm@linux-foundation.org Cc: cl@linux.com, penberg@kernel.org, rientjes@google.com, iamjoonsoo.kim@lge.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Pengfei Li Subject: [PATCH 4/5] mm, slab_common: Make 'type' is enum kmalloc_cache_type Date: Wed, 4 Sep 2019 00:04:29 +0800 Message-Id: <20190903160430.1368-5-lpf.vector@gmail.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190903160430.1368-1-lpf.vector@gmail.com> References: <20190903160430.1368-1-lpf.vector@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The 'type' of the function new_kmalloc_cache should be enum kmalloc_cache_type instead of int, so correct it. Signed-off-by: Pengfei Li --- mm/slab_common.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mm/slab_common.c b/mm/slab_common.c index 8b542cfcc4f2..af45b5278fdc 100644 --- a/mm/slab_common.c +++ b/mm/slab_common.c @@ -1192,7 +1192,7 @@ void __init setup_kmalloc_cache_index_table(void) } static void __init -new_kmalloc_cache(int idx, int type, slab_flags_t flags) +new_kmalloc_cache(int idx, enum kmalloc_cache_type type, slab_flags_t flags) { if (type == KMALLOC_RECLAIM) flags |= SLAB_RECLAIM_ACCOUNT; @@ -1210,7 +1210,8 @@ new_kmalloc_cache(int idx, int type, slab_flags_t flags) */ void __init create_kmalloc_caches(slab_flags_t flags) { - int i, type; + int i; + enum kmalloc_cache_type type; for (type = KMALLOC_NORMAL; type <= KMALLOC_RECLAIM; type++) { for (i = KMALLOC_SHIFT_LOW; i <= KMALLOC_SHIFT_HIGH; i++) { -- 2.21.0