Message ID | 20190111110127.21664-18-ming.lei@redhat.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B58A81515 for <patchwork-linux-mm@patchwork.kernel.org>; Fri, 11 Jan 2019 11:06:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A582429C0E for <patchwork-linux-mm@patchwork.kernel.org>; Fri, 11 Jan 2019 11:06:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 996F929C13; Fri, 11 Jan 2019 11:06:12 +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=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 357E329C24 for <patchwork-linux-mm@patchwork.kernel.org>; Fri, 11 Jan 2019 11:06:12 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C26128E0013; Fri, 11 Jan 2019 06:06:10 -0500 (EST) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id BD42D8E0001; Fri, 11 Jan 2019 06:06:10 -0500 (EST) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A77E78E0013; Fri, 11 Jan 2019 06:06:10 -0500 (EST) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-qt1-f199.google.com (mail-qt1-f199.google.com [209.85.160.199]) by kanga.kvack.org (Postfix) with ESMTP id 77A908E0001 for <linux-mm@kvack.org>; Fri, 11 Jan 2019 06:06:10 -0500 (EST) Received: by mail-qt1-f199.google.com with SMTP id d35so16263360qtd.20 for <linux-mm@kvack.org>; Fri, 11 Jan 2019 03:06:10 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-original-authentication-results:x-gm-message-state:from:to:cc :subject:date:message-id:in-reply-to:references; bh=wNodGZU7EcFMVOxNqWEpjAbmpaD39TDM+4us0d0SSCc=; b=kmPLmLBpzv49dJ4t6parBdPm0iUk48weAnS0ZX7nAiy6iklsfEi8d0Ahy7U12q8mL5 t55lfagKnAmVaWEzbVWT7tMjW2cUgQLoAo3Zno+bvLqfXg4HZS49cAa1kkIcRLqJdqOl t2VSUBF0iaJPloeSZDdw4fnYrW3eGQxA8ZMSeoJv93SKmchqC1PkFI2LcvfWcBrwCQon ZRhM/FYJJCjKlXPHwl3+4A1SYamo6FmUMmqu4eY3XwsDfTefGb9VDuvtMHjmpLHJhxav 1i0YZexz98ArVcVJlCAnuO93MHlM9F76Rj/QVH/JnbRQEZGLevC5o3JZ/7IZzqwU6xGk xN/w== X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of ming.lei@redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=ming.lei@redhat.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com X-Gm-Message-State: AJcUukejoYb5RKpFjNHUMnYpqWjliZMJDPVAH6p0qTLy2VaBKZ/rZy54 8J0HbNOwk20G9cqkSigHKW8CAMr7piE/pqnSs651c1YARiqabnc5seEyA5CCq8sH28PpdW9PLB3 A63Zts0vCHN6NARfXDyn8OteFa4qxjoWYgFaZPetYz4pW4x36zGyOvoPexoLe4cYwTQ== X-Received: by 2002:a05:6214:c7:: with SMTP id f7mr13762025qvs.44.1547204770207; Fri, 11 Jan 2019 03:06:10 -0800 (PST) X-Google-Smtp-Source: ALg8bN533PyXtMit6qhzrEiQ/GrEYGL1nJsoxygr7cZjSoxZP8vua6lcM6LxzEkVqJjnWO5f8bp6 X-Received: by 2002:a05:6214:c7:: with SMTP id f7mr13761991qvs.44.1547204769644; Fri, 11 Jan 2019 03:06:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547204769; cv=none; d=google.com; s=arc-20160816; b=YFv8W5zLFsfA7b90DYcEYHb1pCIktih8PLSiLvjHij/Q8uJFAtSGvcppcQxy7NqxLA cM/OYWYVaBcVytiGjQlBaFinIQ0rj39OLA+46nSWMUMy279TUghJr4rcw8dF2P588aws Wirel6R9fAoXKjuDPoup0GXUJL8O4cMKSbosyncAVSpL6T0p9RNsSwgkv0OF3h0hMZjS kOzNRnp8RsKA4foeEVviaCDWtN870OD92Iw7fAJtxAlg4bfv3JkArcqk98Zb3TfbuwaQ aiE7eZmAc6/feqczGP6FGbDzjaCLS98tCGQWdYQjGiuU3KAUboABe1GUF0YWKnkJhHqB dn0Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:message-id:date:subject:cc:to:from; bh=wNodGZU7EcFMVOxNqWEpjAbmpaD39TDM+4us0d0SSCc=; b=VBzPq7CQluKeIlmaqaZDYTBKLIQ+gnOFeZfxRSwGZ1LRYS0Yu3+mjVlXPc03b+dH9k DydwH+oAHS9a9QfbnEHjsrcndyEQXoezLj6wCbVJPxx5IU0umk2cKXDVpE12wqiFBxp6 jW1uZn9Ik97qVq17bU+CbEnrAkQWuZy0DnQWnAz6hoBs5tw/IKfAzcZ6AUEzCwLhlJVw o/RP9YgsqG/yHlH8Sen7Rkz0XHA8d/f3wcHgo0gF5wmgBv5iaSGXSQ7OP0r9UpvND0RU u9DY/TBk/RLeDO6XJeoiKI5fMXDOwxBTTqf4PkDkDJ3U5S081G0bFnUi1nr9PenIzpWR 4c3g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of ming.lei@redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=ming.lei@redhat.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from mx1.redhat.com (mx1.redhat.com. [209.132.183.28]) by mx.google.com with ESMTPS id o51si501121qtj.204.2019.01.11.03.06.09 for <linux-mm@kvack.org> (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 11 Jan 2019 03:06:09 -0800 (PST) Received-SPF: pass (google.com: domain of ming.lei@redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; Authentication-Results: mx.google.com; spf=pass (google.com: domain of ming.lei@redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=ming.lei@redhat.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 9E464144194; Fri, 11 Jan 2019 11:06:08 +0000 (UTC) Received: from localhost (ovpn-8-28.pek2.redhat.com [10.72.8.28]) by smtp.corp.redhat.com (Postfix) with ESMTP id C618A6B460; Fri, 11 Jan 2019 11:06:07 +0000 (UTC) From: Ming Lei <ming.lei@redhat.com> To: Jens Axboe <axboe@kernel.dk> Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Theodore Ts'o <tytso@mit.edu>, Omar Sandoval <osandov@fb.com>, Sagi Grimberg <sagi@grimberg.me>, Dave Chinner <dchinner@redhat.com>, Kent Overstreet <kent.overstreet@gmail.com>, Mike Snitzer <snitzer@redhat.com>, dm-devel@redhat.com, Alexander Viro <viro@zeniv.linux.org.uk>, linux-fsdevel@vger.kernel.org, linux-raid@vger.kernel.org, David Sterba <dsterba@suse.com>, linux-btrfs@vger.kernel.org, "Darrick J . Wong" <darrick.wong@oracle.com>, linux-xfs@vger.kernel.org, Gao Xiang <gaoxiang25@huawei.com>, Christoph Hellwig <hch@lst.de>, linux-ext4@vger.kernel.org, Coly Li <colyli@suse.de>, linux-bcache@vger.kernel.org, Boaz Harrosh <ooo@electrozaur.com>, Bob Peterson <rpeterso@redhat.com>, cluster-devel@redhat.com, Ming Lei <ming.lei@redhat.com> Subject: [PATCH V13 17/19] block: document usage of bio iterator helpers Date: Fri, 11 Jan 2019 19:01:25 +0800 Message-Id: <20190111110127.21664-18-ming.lei@redhat.com> In-Reply-To: <20190111110127.21664-1-ming.lei@redhat.com> References: <20190111110127.21664-1-ming.lei@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Fri, 11 Jan 2019 11:06:08 +0000 (UTC) X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> X-Virus-Scanned: ClamAV using ClamSMTP |
Series |
block: support multi-page bvec
|
expand
|
diff --git a/Documentation/block/biovecs.txt b/Documentation/block/biovecs.txt index 25689584e6e0..ce6eccaf5df7 100644 --- a/Documentation/block/biovecs.txt +++ b/Documentation/block/biovecs.txt @@ -117,3 +117,28 @@ Other implications: size limitations and the limitations of the underlying devices. Thus there's no need to define ->merge_bvec_fn() callbacks for individual block drivers. + +Usage of helpers: +================= + +* The following helpers whose names have the suffix of "_all" can only be used +on non-BIO_CLONED bio. They are usually used by filesystem code. Drivers +shouldn't use them because the bio may have been split before it reached the +driver. + + bio_for_each_segment_all() + bio_first_bvec_all() + bio_first_page_all() + bio_last_bvec_all() + +* The following helpers iterate over single-page segment. The passed 'struct +bio_vec' will contain a single-page IO vector during the iteration + + bio_for_each_segment() + bio_for_each_segment_all() + +* The following helpers iterate over multi-page bvec. The passed 'struct +bio_vec' will contain a multi-page IO vector during the iteration + + bio_for_each_bvec() + rq_for_each_bvec()