From patchwork Wed Nov 22 21:15:58 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Josef Bacik X-Patchwork-Id: 10071107 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id EA4F260353 for ; Wed, 22 Nov 2017 21:17:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DB13F29D67 for ; Wed, 22 Nov 2017 21:17:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CD2BD29DA0; Wed, 22 Nov 2017 21:17:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7EF3229D67 for ; Wed, 22 Nov 2017 21:17:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751599AbdKVVRM (ORCPT ); Wed, 22 Nov 2017 16:17:12 -0500 Received: from mail-qk0-f194.google.com ([209.85.220.194]:39357 "EHLO mail-qk0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751895AbdKVVQO (ORCPT ); Wed, 22 Nov 2017 16:16:14 -0500 Received: by mail-qk0-f194.google.com with SMTP id w125so18592153qkb.6 for ; Wed, 22 Nov 2017 13:16:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=toxicpanda-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=e6bZBROOnPCRSYYO5xm665RJiNVKLbNEkJMVQkLhYe4=; b=De2lf9NR7lQdsN2e9WOF9B5T1rddA5TR2aj527NOtwcHk/6AXcxR3KLuhCBjZ9wVuK 3kgFom1S1Rzor0KG8Xsc7uODKmrLUFgzgoGVYLs857iccxwlgYhOgG26wNQS501dhvvx a01Nq1sM75JDbEyexoFh6r+VgdU7wYwgfKhvzBPx5AUev7UDBqybY4C29MhCiDtd6Jlr 8PSTw3QCrhELcI3GqCKPbG9FsVU/U0dqpCfpybsugB4NsFgctgwra6rmWIiKoVaWazES 8YE2zGQ+Ew7ZjMqpBmEkF48e1O96HC9aobUE4c5sgU32Ol4Ev8RfYFR9iBf0W2EUBEL5 jS/Q== 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; bh=e6bZBROOnPCRSYYO5xm665RJiNVKLbNEkJMVQkLhYe4=; b=MWLPNpyDTuBRcaI+ck0HNNGpvSa4Wn5DarR/DMZn/ZYx85QZm2iQnwth6xFCNLlVAk q6y688qho2tUkAbegad3eY8UxeXkKVY4bbpktjn1lhZSYG86A6sGc7kNBsO1/mtwmdXx xPLJafxYLYehhBEkI5M68NgPfYyTib/n3sRA6LFxRpMTBdmc4y1NQ3nS1CmzQDZLMVej Ute8uqbPXqyIlZKlBmRvn5Y/sQERiHXqI5kjQbGO9+wEYsNTho/iNXK6g65b6UFzCPU1 UXpIhR5fPwpBgSHm8JkF8Jdtl/uRyAoLxxfFYLnJM4rb5M9t5cGaJdVlTQxi1was0+p6 MiUg== X-Gm-Message-State: AJaThX7OXW4OwUHkVSv+yNoa5WEp61XCf46QUa2a48TIL0XCEjYiseH8 MDT64aEoa9zpyePkx/sEQVeYwQ== X-Google-Smtp-Source: AGs4zMZ0MAf0ITEo78cd7wryiy86P4xOnU4KQg8Cxmj7TL8h31B7Xn14eC/PkrFeeY6VQ5KW/3Wkxg== X-Received: by 10.55.145.197 with SMTP id t188mr20220387qkd.267.1511385373370; Wed, 22 Nov 2017 13:16:13 -0800 (PST) Received: from localhost (cpe-2606-A000-4381-1201-225-22FF-FEB3-E51A.dyn6.twc.com. [2606:a000:4381:1201:225:22ff:feb3:e51a]) by smtp.gmail.com with ESMTPSA id z6sm11242595qke.57.2017.11.22.13.16.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 22 Nov 2017 13:16:12 -0800 (PST) From: Josef Bacik To: hannes@cmpxchg.org, linux-mm@kvack.org, akpm@linux-foundation.org, jack@suse.cz, linux-fsdevel@vger.kernel.org, kernel-team@fb.com, linux-btrfs@vger.kernel.org Cc: Josef Bacik Subject: [PATCH v2 03/11] lib: make the fprop batch size a multiple of PAGE_SIZE Date: Wed, 22 Nov 2017 16:15:58 -0500 Message-Id: <1511385366-20329-4-git-send-email-josef@toxicpanda.com> X-Mailer: git-send-email 2.7.5 In-Reply-To: <1511385366-20329-1-git-send-email-josef@toxicpanda.com> References: <1511385366-20329-1-git-send-email-josef@toxicpanda.com> Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Josef Bacik We are converting the writeback counters to use bytes instead of pages, so we need to make the batch size for the percpu modifications align properly with the new units. Since we used pages before, just multiply by PAGE_SIZE to get the equivalent bytes for the batch size. Signed-off-by: Josef Bacik --- lib/flex_proportions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/flex_proportions.c b/lib/flex_proportions.c index 2cc1f94e03a1..b0343ae71f5e 100644 --- a/lib/flex_proportions.c +++ b/lib/flex_proportions.c @@ -166,7 +166,7 @@ void fprop_fraction_single(struct fprop_global *p, /* * ---- PERCPU ---- */ -#define PROP_BATCH (8*(1+ilog2(nr_cpu_ids))) +#define PROP_BATCH (8*PAGE_SIZE*(1+ilog2(nr_cpu_ids))) int fprop_local_init_percpu(struct fprop_local_percpu *pl, gfp_t gfp) {