From patchwork Tue Dec 27 16:04:54 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ming Lei X-Patchwork-Id: 9489583 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4B390601D2 for ; Tue, 27 Dec 2016 16:12:18 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3CD1D223B2 for ; Tue, 27 Dec 2016 16:12:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2FFF425E13; Tue, 27 Dec 2016 16:12:18 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C83FE200E7 for ; Tue, 27 Dec 2016 16:12:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932928AbcL0QMN (ORCPT ); Tue, 27 Dec 2016 11:12:13 -0500 Received: from mail-pf0-f195.google.com ([209.85.192.195]:32777 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932972AbcL0QGl (ORCPT ); Tue, 27 Dec 2016 11:06:41 -0500 Received: by mail-pf0-f195.google.com with SMTP id 127so8380983pfg.0; Tue, 27 Dec 2016 08:06:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=xg53/NQgvq0/GedWViHVWlgP+dQ6q+c69nEqYYTDJmI=; b=rfqRroHBZjgbTgQSyXE8bcVmZdCjuDQFoJK54Tm+1Z7c9wAGadMFZ/7jLJJh7oZcSr x28dpwqB9VpCjoCOweOlPGfH/UmwJQGa56YDLUG5BqZQDFi4C/m6kVrvNRw2FyUBwyLk TYKFce+0aeFo997A7fKg+k8XFJ5Pchqv4BMM5B3vUG5PI7xpbvlHe33y71ibKNeFjuBV Idia3T7a6e+/IQHsIPX+Rhs4LTBWu7DFS0vIMOeMjIpMHs4YXsiEdp6H+mrPDT7W2ro8 Yd/1njy3jGSn0dQdHTRqSqFzTmtEXy/RSgxI19xPOttplzhkgZiuOQ0q3yX/5ngbAjya 689w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=xg53/NQgvq0/GedWViHVWlgP+dQ6q+c69nEqYYTDJmI=; b=f0UlbrfvjWdoqBxrcoBrxwf7II9RBxDrP4gmEIOFGVnswrfc/MD1zSblaM7PAsb6+g e/sf61EcaMEdoSBaB7+VYuvrYmE/R/hr3oGjO/0sQ+uCAXs9E4HItQtFvsdktWTMSo8l Lq+Yc2EtSBEpL4COr98AxxMdrDjFv9m2LBmfGI/F47KgtmdOHOMSd2IPV5S7UZ+r3fRB 1V3skA9lMrpHF6W7F7auu3a39P4EMWqdNfzczXefkcwbGHUt2XNLIj+d6YjQfsKqCL9k l6d1HCUIvDavJCP5PkXZ32+2WmetrtXpFd9zCvoxSMa8VlGQX67icIFrTishQysulA+U Gqgw== X-Gm-Message-State: AIkVDXLWEDhma6ppJxOU4FgNcecRxffX6FvKkMxDl5sK8OGiDTiiUEHkD3T1s1rjors29Q== X-Received: by 10.98.102.18 with SMTP id a18mr25630489pfc.29.1482854800681; Tue, 27 Dec 2016 08:06:40 -0800 (PST) Received: from localhost ([45.35.47.137]) by smtp.gmail.com with ESMTPSA id q2sm91361056pga.8.2016.12.27.08.06.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 27 Dec 2016 08:06:39 -0800 (PST) From: Ming Lei To: Jens Axboe , linux-kernel@vger.kernel.org Cc: linux-block@vger.kernel.org, Christoph Hellwig , Ming Lei , Boaz Harrosh , Benny Halevy , osd-dev@open-osd.org (open list:OSD LIBRARY and FILESYSTEM) Subject: [PATCH v1 45/54] exofs: convert to bio_for_each_segment_all_sp() Date: Wed, 28 Dec 2016 00:04:54 +0800 Message-Id: <1482854706-14128-14-git-send-email-tom.leiming@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1482854706-14128-1-git-send-email-tom.leiming@gmail.com> References: <1482854706-14128-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-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Ming Lei --- fs/exofs/ore.c | 3 ++- fs/exofs/ore_raid.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/fs/exofs/ore.c b/fs/exofs/ore.c index 8bb72807e70d..38a7d8bfdd4c 100644 --- a/fs/exofs/ore.c +++ b/fs/exofs/ore.c @@ -406,8 +406,9 @@ static void _clear_bio(struct bio *bio) { struct bio_vec *bv; unsigned i; + struct bvec_iter_all bia; - bio_for_each_segment_all(bv, bio, i) { + bio_for_each_segment_all_sp(bv, bio, i, bia) { unsigned this_count = bv->bv_len; if (likely(PAGE_SIZE == this_count)) diff --git a/fs/exofs/ore_raid.c b/fs/exofs/ore_raid.c index 27cbdb697649..37c0a9aa2ec2 100644 --- a/fs/exofs/ore_raid.c +++ b/fs/exofs/ore_raid.c @@ -429,6 +429,7 @@ static void _mark_read4write_pages_uptodate(struct ore_io_state *ios, int ret) { struct bio_vec *bv; unsigned i, d; + struct bvec_iter_all bia; /* loop on all devices all pages */ for (d = 0; d < ios->numdevs; d++) { @@ -437,7 +438,7 @@ static void _mark_read4write_pages_uptodate(struct ore_io_state *ios, int ret) if (!bio) continue; - bio_for_each_segment_all(bv, bio, i) { + bio_for_each_segment_all_sp(bv, bio, i, bia) { struct page *page = bv->bv_page; SetPageUptodate(page);