From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 41C0AC433EF for ; Mon, 18 Oct 2021 11:10:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 1DDAA6134F for ; Mon, 18 Oct 2021 11:10:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229644AbhJRLMR (ORCPT ); Mon, 18 Oct 2021 07:12:17 -0400 Received: from smtp-out2.suse.de ([195.135.220.29]:44958 "EHLO smtp-out2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229519AbhJRLMQ (ORCPT ); Mon, 18 Oct 2021 07:12:16 -0400 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 066041FD79; Mon, 18 Oct 2021 11:10:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1634555404; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qmFWWTxLru0FFDyFNahu7eQU4Qn5Tk89QoI5XxFGA3k=; b=FOy2N6fNR5sACCaSTXfHbcU/vQqj4CT5w3SMKPT1eRK+wznKTHyq99NXLrnhgtadPDynmY LqX/dLEmwKXA6FhaRpXQdm+Ly46sqJ8XKHUZfZqibMXIh1dZAKqSyVIOrRSkngcQIYbZ+3 k/wjURE0WSzOq9Mlvk4eLb7/eTILLrg= Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id B7F3513C14; Mon, 18 Oct 2021 11:10:03 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id Oa2GKgtWbWHhEAAAMHmgww (envelope-from ); Mon, 18 Oct 2021 11:10:03 +0000 Subject: Re: [PATCH v11 12/14] btrfs: send: allocate send buffer with alloc_page() and vmap() for v2 To: Omar Sandoval , linux-btrfs@vger.kernel.org Cc: kernel-team@fb.com, linux-fsdevel@vger.kernel.org, linux-api@vger.kernel.org References: <74a9595599ad41fa5b843473ce6e9d436def210f.1630514529.git.osandov@fb.com> From: Nikolay Borisov Message-ID: <5807a793-cc15-6d2d-6b80-bf3265dac660@suse.com> Date: Mon, 18 Oct 2021 14:10:03 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: <74a9595599ad41fa5b843473ce6e9d436def210f.1630514529.git.osandov@fb.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-api@vger.kernel.org On 1.09.21 г. 20:01, Omar Sandoval wrote: > From: Omar Sandoval > > For encoded writes, we need the raw pages for reading compressed data > directly via a bio. So, replace kvmalloc() with vmap() so we have access > to the raw pages. 144k is large enough that it usually gets allocated > with vmalloc(), anyways. > > Signed-off-by: Omar Sandoval Reviewed-by: Nikolay Borisov