From patchwork Tue Apr 5 11:56:59 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ming Lei X-Patchwork-Id: 8750341 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 B554CC0553 for ; Tue, 5 Apr 2016 12:01:47 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E6E952034F for ; Tue, 5 Apr 2016 12:01:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E8AFF203A4 for ; Tue, 5 Apr 2016 12:01:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757479AbcDEMBV (ORCPT ); Tue, 5 Apr 2016 08:01:21 -0400 Received: from mail-pa0-f65.google.com ([209.85.220.65]:36233 "EHLO mail-pa0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932998AbcDEMBR (ORCPT ); Tue, 5 Apr 2016 08:01:17 -0400 Received: by mail-pa0-f65.google.com with SMTP id 1so1120435pal.3; Tue, 05 Apr 2016 05:01:16 -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=o15JNCxSYaprVJx5QwBiHR/q0ufo9BIaWHCtw1rguC8=; b=UQyFP596iIgReTEWDSh7sfe77HDQzplXIx4MWc92wtEYA2Betkwu+r8OHXXnkY4O/p QttDkFAjjBz0G40CXLOqgct5a1AdmVQZhQmUU48sihDfnLba8Le2UygKuQBAIowopA7d VDkxl0yzKFNEIj8cP5VwiAFtDvHmnoMRe87U+7PtVlzdLGYdNUgcSn3/bkxIjMWzqCWS NZbB6XxtzkhfDzEiDlZXxutroA77Qun2VxwvAoJp3T9C1gAOJtDwhjdcMilO8lzjnF6m 2FF+Ze2bdSmUKxa+fYKsJSIjGvDLJIB2Bb9NIrOiuE+n8zA/wbKJ+dbWtNvEajFpg3jz wKyg== 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=o15JNCxSYaprVJx5QwBiHR/q0ufo9BIaWHCtw1rguC8=; b=k6ALryTM2Xv5rAlxnzOJpvdftnkkde5lqFpTWIWzojdhMvRqo55tXMe4Zohx2KHffq rL1fEAWu7BZ7d4NvJGhbFp9dWFCFOxgGtiJc3wsGIZKfsTdL3BuV6KLdDbw0yB+KKy3B JP0YSRagKRU1DR4bHmRD3aE4F4cW12ZoSZ9d6okAzxi06eXAXEfjqsQSiFoy3zGEcK1Y IuR2OopJNK3LSFbAeMRAI02DZQ6475CgJTO5ApRS+xbZfrbJybkiM3rvcpSbPsgpHhxS aLj3QX9cTLPL1szsqdvGAfHkHVVghm+LNrpvuHDyZ98C6+dOJX9PNLF+YJISvaxbLD23 KbfQ== X-Gm-Message-State: AD7BkJLwf4isasgiM6Iw05RrIXdZlzEoUZVnWwq37WrfvthHdaCowQabXnR0MWoXHIJyMw== X-Received: by 10.66.63.98 with SMTP id f2mr34000327pas.123.1459857676266; Tue, 05 Apr 2016 05:01:16 -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 x18sm46516100pfi.42.2016.04.05.05.01.08 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Tue, 05 Apr 2016 05:01:15 -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 14/27] bcache: writeback: use bio_set_vec_table() Date: Tue, 5 Apr 2016 19:56:59 +0800 Message-Id: <1459857443-20611-15-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/writeback.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/md/bcache/writeback.c b/drivers/md/bcache/writeback.c index b9346cd..49a8f8a 100644 --- a/drivers/md/bcache/writeback.c +++ b/drivers/md/bcache/writeback.c @@ -112,9 +112,9 @@ static void dirty_init(struct keybuf_key *w) bio_set_prio(bio, IOPRIO_PRIO_VALUE(IOPRIO_CLASS_IDLE, 0)); bio->bi_iter.bi_size = KEY_SIZE(&w->key) << 9; - bio->bi_max_vecs = DIV_ROUND_UP(KEY_SIZE(&w->key), PAGE_SECTORS); bio->bi_private = w; - bio->bi_io_vec = bio->bi_inline_vecs; + bio_set_vec_table(bio, bio->bi_inline_vecs, + DIV_ROUND_UP(KEY_SIZE(&w->key), PAGE_SECTORS)); bch_bio_map(bio, NULL); }