Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3426670pxf; Mon, 22 Mar 2021 06:17:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxE4EXJyz+ASl03H0B0Cyd0HjGqAXnWMNOn/iDiFkw2n8fBAtYJXupBhGquO0gxyewyAuec X-Received: by 2002:a05:6402:12cf:: with SMTP id k15mr25096540edx.192.1616419042938; Mon, 22 Mar 2021 06:17:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616419042; cv=none; d=google.com; s=arc-20160816; b=LuUr6BqWpChijvtURLH9+qWTsAC7RwtFuwJ1Kpx9KoDfrFj4IMWOmMxcNLbHFnxZBn L0mWOnAocuV2lYTmu5SC9BtIVIlYUD+OjzyiAbGdub+MOHwWeT7OGUmyPcv/SXvY7dcl nLQLtMyppob1PNguiEBtVWG4eXwHym4kCGv/Vew9rbRNPe0dghTdrgIpBpyNE63QozDB IyduaM4AtwvPpQdXZ1Z6aj1JttoMcW5gdSbyyCPZFpx2o+h3uNUhz9wqkJmrSGZYmtXk ZBiy808gnozLltqMfrYjQBHNFWg3FuLCFD/9bxuyw4d+b17Zql2z8V04ZhEL1QKZY86m bYNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=0JBjeWyjhSFrKTKJO4lwg4PnWP3NbPeMlvDqUV3159w=; b=XfSyuA64AxFZomBr7nSiuH4ncYygQePW0Wtc3yI6sW5ZDiDU6p8Tuq0iQbCqNKFCYX LpiqJRkV4d3dnaWyN5QRhAHgupqw/dspVeT+NnsTWVL6JObMo5RLh6mvJntovwcrjYiH 3nA9HWOpmuAPBviPz9g5rf3h+zR1MGIGi5XOP+gBsDdjxiMtKk9lrE2MZEU6PuxoY+6i xapPzk6m5Q/BxSx7hdZc9405BW+QWgIeQg8k/emrpCZWIwJ8N2Y/JucUdyKNc8PagwmP baP8IjoSvzFs6TcdxNTIuFeP91UKvdxsw/q2idj86uXgfL21IvW/JEZeD3rjvUsEROVk Jc8g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=HeYsUbcm; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h1si11393921edn.233.2021.03.22.06.16.59; Mon, 22 Mar 2021 06:17:22 -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=@infradead.org header.s=casper.20170209 header.b=HeYsUbcm; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233151AbhCVNP7 (ORCPT + 99 others); Mon, 22 Mar 2021 09:15:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58902 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232280AbhCVNED (ORCPT ); Mon, 22 Mar 2021 09:04:03 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 82AFBC061756; Mon, 22 Mar 2021 06:04:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=0JBjeWyjhSFrKTKJO4lwg4PnWP3NbPeMlvDqUV3159w=; b=HeYsUbcmAYNz575uDB1kdZw8+G 0OUFPH/q99s3mFwZM/wKTbsbbMGE9K3gE/uue/WEtux2YchdR7ZPjQ/BxkMFe2L5IP7Hogv8P2PXH KwFceNsqE0J/TQNvJLHXcZPE51SWua8qgu+K381d4hGYdIAOILPDGZY2d67vdaqdju8eUwfWc5TNY DfPe+zQMVCF1wkxcaDfTF6H8IHLEUUi+7ikk+3/KBhTlfsxlmdowf5Px3G4Adlnwe+oXshiMmwZRZ XNkYnT/TgPe4jTYxmJbBVcIpPsGAowuHJwUVwkYoeNOBSRlYWDjCf9F5Cc3GQS8N24wbz7BczLliI l0yiWqQQ==; Received: from willy by casper.infradead.org with local (Exim 4.94 #2 (Red Hat Linux)) id 1lOKCg-008XPh-Ma; Mon, 22 Mar 2021 13:02:46 +0000 Date: Mon, 22 Mar 2021 13:02:42 +0000 From: Matthew Wilcox To: Sergey Senozhatsky Cc: Namjae Jeon , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-cifs@vger.kernel.org, linux-cifsd-devel@lists.sourceforge.net, Sergey Senozhatsky , linux-mm@vger.kernel.org, Uladzislau Rezki Subject: Re: [PATCH 3/5] cifsd: add file operations Message-ID: <20210322130242.GL1719932@casper.infradead.org> References: <20210322051344.1706-1-namjae.jeon@samsung.com> <20210322051344.1706-4-namjae.jeon@samsung.com> <20210322081512.GI1719932@casper.infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 22, 2021 at 06:03:21PM +0900, Sergey Senozhatsky wrote: > On (21/03/22 08:15), Matthew Wilcox wrote: > > > > What's the scenario for which your allocator performs better than slub > > > > IIRC request and reply buffers can be up to 4M in size. So this stuff > just allocates a number of fat buffers and keeps them around so that > it doesn't have to vmalloc(4M) for every request and every response. That makes a lot more sense; I was thrown off by the kvmalloc, which is usually used for allocations that might be smaller than PAGE_SIZE. So what this patch is really saying is that vmalloc() should include some caching, so it can defer freeing until there's memory pressure or it's built up a large (percpu) backlog of freed areas. Vlad, have you thought about this?