From patchwork Tue Apr 5 11:56:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ming Lei X-Patchwork-Id: 8750461 Return-Path: X-Original-To: patchwork-linux-block@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 72092C0553 for ; Tue, 5 Apr 2016 12:04:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B0A6B20109 for ; Tue, 5 Apr 2016 12:04:00 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E2979200ED for ; Tue, 5 Apr 2016 12:03:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933137AbcDEMDk (ORCPT ); Tue, 5 Apr 2016 08:03:40 -0400 Received: from mail-pa0-f68.google.com ([209.85.220.68]:34026 "EHLO mail-pa0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932147AbcDEMAd (ORCPT ); Tue, 5 Apr 2016 08:00:33 -0400 Received: by mail-pa0-f68.google.com with SMTP id hb4so1125694pac.1; Tue, 05 Apr 2016 05:00:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=BSoA9qHcEmBuvDZornJcKtN/rniC3gmsL5DvOfmAunU=; b=xOyGsWubbHtsMrs6srM2F47wjhYs34UgMFfD/JSsP36Mhm04OlCUSQZ/t6HNf5Gkht ca5n5Q4orqGQht6GuW+XKGu+QV2T02tEk2nwVpFTGHuF1FB2MCBiU0NmCUzZz5aRKM7b lIsrEoSBpxSIjuUQQTu6w5/GXUVic0DgsEb84hYLT76MM7wZCW5sEn05V5Eu7aLhLzN7 jdaWqhkEKfylVs2oSwAEqPTjYjF2o+EP/cGU+TT7b+PGDZHP30Ssahlsj6GWFsThO9rK kCUmG/9QIYSS9AF8Bw2+sIlbSeO7WmQY4XQsrs5ytZkIVPtv1tLjdSP4jd2hc2iyeZaW p5Pw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=BSoA9qHcEmBuvDZornJcKtN/rniC3gmsL5DvOfmAunU=; b=H+XJE/eUcUMBWbzfagRCvoxRWWQJ2d4LT/tRUyx0Qfv4e21nvd8wAEHA+8U+UAc3/i 7OCcS3g6nOVJpVF8aatcKv0AOaXmZGV5I3WUfFU4blYcE3q4AAqQUbjC4IuqIBvS9Xv8 GwxXay70/w4lJbVYehmRrsO4QoVKich5vft1YWxxu2KH1fXhGM0F07j6zbYGKNQcB4kh VeCeyA0TEyoztC3PCcVekICscqPA1hLXgeM4DtHKEwzbScHzJ7oWpqYinc1g5RuVuK7g LUhyUpx9syrlhPpF3/cOqGd2b/AwT5jTXm+/WUb4Mopp3RBSk1fg9TMm93/BGuVwNV7t zMVg== X-Gm-Message-State: AD7BkJL4el2RL3HQbTU1YC6N6szjP4TK5fRpm+XrZDnaG5YX64tOK0+GwSBWf7+MommFhg== X-Received: by 10.66.193.202 with SMTP id hq10mr60125649pac.6.1459857632790; Tue, 05 Apr 2016 05:00:32 -0700 (PDT) Received: from localhost (56.34.213.162.lcy-01.canonistack.canonical.com. [162.213.34.56]) by smtp.gmail.com with ESMTPSA id i9sm46467235pfi.95.2016.04.05.05.00.31 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Tue, 05 Apr 2016 05:00:32 -0700 (PDT) From: Ming Lei To: Jens Axboe , linux-kernel@vger.kernel.org Cc: linux-block@vger.kernel.org, Christoph Hellwig , Boaz Harrosh , Ming Lei , Kent Overstreet , Shaohua Li , linux-bcache@vger.kernel.org (open list:BCACHE (BLOCK LAYER CACHE)), linux-raid@vger.kernel.org (open list:SOFTWARE RAID (Multiple Disks) SUPPORT) Subject: [PATCH 11/27] bcache: io.c: use bio_set_vec_table Date: Tue, 5 Apr 2016 19:56:56 +0800 Message-Id: <1459857443-20611-12-git-send-email-tom.leiming@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1459857443-20611-1-git-send-email-tom.leiming@gmail.com> References: <1459857443-20611-1-git-send-email-tom.leiming@gmail.com> Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Spam-Status: No, score=-7.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Ming Lei --- drivers/md/bcache/io.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/md/bcache/io.c b/drivers/md/bcache/io.c index 86a0bb8..1c48462 100644 --- a/drivers/md/bcache/io.c +++ b/drivers/md/bcache/io.c @@ -26,8 +26,7 @@ struct bio *bch_bbio_alloc(struct cache_set *c) bio_init(bio); bio->bi_flags |= BIO_POOL_NONE << BIO_POOL_OFFSET; - bio->bi_max_vecs = bucket_pages(c); - bio->bi_io_vec = bio->bi_inline_vecs; + bio_set_vec_table(bio, bio->bi_inline_vecs, bucket_pages(c)); return bio; }