WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] disk io request structures

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] disk io request structures
From: Paresh Nakhe <paresh.nakhe@xxxxxxxxx>
Date: Wed, 2 Feb 2011 22:17:57 +0530
Delivery-date: Wed, 02 Feb 2011 13:08:45 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:from:date:message-id:subject:to :content-type; bh=5e4QGSQUNVTC45LVBrb7HbAfGZyrWWFqbzq8jJ7kd5M=; b=DM2O3qmR2FXNJJ2aHTgJNWTdep/hHwDHtDr88mkVI5BWUD+38ygqJzxqY4MqYDv91u 0rf7ovxONzia/VYwKCAxA2uYYpF0q9gw/CQCRW6+rFY5/J6m3Z4vt03wcQiqiNz5H04w o7ARLJwl1KtQ42uKYRzzh3GXKvdySW4blGiE8=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:from:date:message-id:subject:to:content-type; b=DBIuBoMj/9ui4qhNKcZBHBTJKKvdgRKKvyD8nnIHvat3yeVdBmoVdb14j6D+Ovmnn8 o1fT9E0fPkrdQSZDNYntRyxd9KKRGtFJdTQIjMLK9DYWIpUsTB0nIyqueeyAwiU2EwNh PhETsN22ObfEAvXigkjTS+0RjxsBNQz85wMpY=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Hi,
Following is the structure of an IO request which is inserted in the shared IO ring.

include/xen/interface/io/blkif.h

struct blkif_request {
    uint8_t        operation;    /* BLKIF_OP_???                         */
    uint8_t        nr_segments;  /* number of segments                   */
    blkif_vdev_t   handle;       /* only for read/write requests         */
    uint64_t       id;           /* private guest value, echoed in resp  */
    blkif_sector_t sector_number;/* start sector idx on disk (r/w only)  */
    struct blkif_request_segment {
        grant_ref_t gref;        /* reference to I/O buffer frame        */
        /* @first_sect: first sector in frame to transfer (inclusive).   */
        /* @last_sect: last sector in frame to transfer (inclusive).     */
        uint8_t     first_sect, last_sect;
    } seg[BLKIF_MAX_SEGMENTS_PER_REQUEST];
};

Sorry, if my questions seem obvious or trivial. I am a newbie in xen development. Right now, me and my group are trying to understand the disk io mechanism in XEN. We intend to modify the existing system. We expect better performance after this modification.

So, in the above structure,
 1. what is a "segment" referred in the structure.
 2. Why is there an array of blkif_request_segment (why not a single instance). What is it's purpose?
 3. In the structure blkif_request_segment, are the first_sect and last_sect physical sector numbers

Thanks.
Paresh Nakhe


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>