Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp3879797pxb; Tue, 26 Jan 2021 07:06:18 -0800 (PST) X-Google-Smtp-Source: ABdhPJweu5xDbtDT5DHWSNS854DpDc1HK9aRaevM3stSALSqmkl4KSUCmKUjDZg9gTM5AOzVTxrK X-Received: by 2002:a17:906:2c0e:: with SMTP id e14mr3615628ejh.299.1611673578070; Tue, 26 Jan 2021 07:06:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611673578; cv=none; d=google.com; s=arc-20160816; b=W1leVdTCZeXA6AcTM7ohDFZQx6hp8jCzndCnMSTlgz++nyr8C76oDM4hORwhl4+bGb gr8Vm1oFhzieYe2rvYMw+MQlhm5qiY5CVFUQtPLkCvFYq44jA9KBKf3bS0MVcCm62kh1 zqIRjp4VIwTSSss2zeK2qmv5zI73eqCJbRpCv9PjKJXrZqWGQyt7g+o2ReGS3SWUS6Ta JIVB3mckdeNGXrKA9cPPev4N3pvTnHYOGMHcQioXU7KVJN+pO6ifXMU+xRhJt6Lj0c+J zxWSCZ+3KDCQYHg755S7jpHLrfE+lECm34nZzq3ccQ7jF4CVFg+qk8a2/44sdC2lOM5Z NdcQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Tvv/hngq/dBU/TVoa7iwWv/YX1vhiuaE4wP7JKrNMhk=; b=kOmjdfCT9Ric3x4nRP1AHVMhVC4YVvY+sM2djaZr1Tz9Qiq/lawYgdnca7ICOYMwL/ Q2FZ70XOCSW/CUdTadjR3EQsNzDTSPskGV764ogePCpSXPwi5oZBShLYPYWM0BWz6cOU Q2ezA8r6EbW/MgJroShH5TTrkygx/hy0REStXTnmlmYFd+sbhK724i90mSUE4UjrfjkW 2ItI7BSXvvnL0n4VD0k9iQCUMakpJku3qjPCA81XrHpmF5Vz+nQuhRUxCg4eweqdDcW8 mzlczTe+nAY8oFqmbYs61t4fhIKEwmSDEa/MyS1xuDinZPr/YsulauLqbub9leErmBHn 9MnA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=k+FYANNO; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-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 cf11si8635718edb.381.2021.01.26.07.05.52; Tue, 26 Jan 2021 07:06:18 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs-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=k+FYANNO; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387815AbhAZPCU (ORCPT + 99 others); Tue, 26 Jan 2021 10:02:20 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52416 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391173AbhAZPBk (ORCPT ); Tue, 26 Jan 2021 10:01:40 -0500 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 589F8C061A29; Tue, 26 Jan 2021 07:01:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description; bh=Tvv/hngq/dBU/TVoa7iwWv/YX1vhiuaE4wP7JKrNMhk=; b=k+FYANNOZNSV7d80UmzTAyJIKL sjR3uLRaK2TwHcBUsVcl9IndBEPxYkEu006OvPkkzK4tvMff5Z+dVhL0IjaUHx8BBuZ0yyw0kvg4G U3KPy3sIpICR9kG1TUy5jK8QjcY8sM8tPsbnAwnAg6bU60/F72Zv6QiuZCxnnZ+olHIVHWG6zEu9H vbj18B9ZyF73S0P0GskthCvFSLA42B1MNOQoLGT1DCJY5RV9hIWsDq7qtgSf3bFvuu11dMCIUC78m O5PhvXXW4p1xsC37+azC3ghr00JUxWPW0MIn1botrn443lpgRWINUt2FYChxfCgxAeBHpwqT6P5I5 ybwQ3v+w==; Received: from [2001:4bb8:191:e347:5918:ac86:61cb:8801] (helo=localhost) by casper.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1l4Pl3-005mG9-Rr; Tue, 26 Jan 2021 14:56:33 +0000 From: Christoph Hellwig To: Jens Axboe , Song Liu Cc: Jaegeuk Kim , Chao Yu , Philipp Reisner , Lars Ellenberg , Coly Li , Mike Snitzer , Josef Bacik , David Sterba , Damien Le Moal , Naohiro Aota , Andrew Morton , Ryusuke Konishi , linux-nilfs@vger.kernel.org, dm-devel@redhat.com, linux-f2fs-devel@lists.sourceforge.net, linux-block@vger.kernel.org, drbd-dev@lists.linbit.com, linux-bcache@vger.kernel.org, linux-raid@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-btrfs@vger.kernel.org, linux-nfs@vger.kernel.org, linux-mm@kvack.org Subject: [PATCH 02/17] btrfs: use bio_kmalloc in __alloc_device Date: Tue, 26 Jan 2021 15:52:32 +0100 Message-Id: <20210126145247.1964410-3-hch@lst.de> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210126145247.1964410-1-hch@lst.de> References: <20210126145247.1964410-1-hch@lst.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Use bio_kmalloc instead of open coding it. Signed-off-by: Christoph Hellwig --- fs/btrfs/volumes.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index 0a6de859eb2226..584ba093cf4966 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -421,7 +421,7 @@ static struct btrfs_device *__alloc_device(struct btrfs_fs_info *fs_info) * Preallocate a bio that's always going to be used for flushing device * barriers and matches the device lifespan */ - dev->flush_bio = bio_alloc_bioset(GFP_KERNEL, 0, NULL); + dev->flush_bio = bio_kmalloc(GFP_KERNEL, 0); if (!dev->flush_bio) { kfree(dev); return ERR_PTR(-ENOMEM); -- 2.29.2