xen-blkfront.c (b7e56edba4b02f2079042c326a8cd72a44635817) | xen-blkfront.c (086fa5ff0854c676ec333760f4c0154b3b242616) |
---|---|
1/* 2 * blkfront.c 3 * 4 * XenLinux virtual block device driver. 5 * 6 * Copyright (c) 2003-2004, Keir Fraser & Steve Hand 7 * Modifications by Mark A. Williamson are (c) Intel Research Cambridge 8 * Copyright (c) 2004, Christian Limpach --- 332 unchanged lines hidden (view full) --- 341 rq = blk_init_queue(do_blkif_request, &blkif_io_lock); 342 if (rq == NULL) 343 return -1; 344 345 queue_flag_set_unlocked(QUEUE_FLAG_VIRT, rq); 346 347 /* Hard sector size and max sectors impersonate the equiv. hardware. */ 348 blk_queue_logical_block_size(rq, sector_size); | 1/* 2 * blkfront.c 3 * 4 * XenLinux virtual block device driver. 5 * 6 * Copyright (c) 2003-2004, Keir Fraser & Steve Hand 7 * Modifications by Mark A. Williamson are (c) Intel Research Cambridge 8 * Copyright (c) 2004, Christian Limpach --- 332 unchanged lines hidden (view full) --- 341 rq = blk_init_queue(do_blkif_request, &blkif_io_lock); 342 if (rq == NULL) 343 return -1; 344 345 queue_flag_set_unlocked(QUEUE_FLAG_VIRT, rq); 346 347 /* Hard sector size and max sectors impersonate the equiv. hardware. */ 348 blk_queue_logical_block_size(rq, sector_size); |
349 blk_queue_max_sectors(rq, 512); | 349 blk_queue_max_hw_sectors(rq, 512); |
350 351 /* Each segment in a request is up to an aligned page in size. */ 352 blk_queue_segment_boundary(rq, PAGE_SIZE - 1); 353 blk_queue_max_segment_size(rq, PAGE_SIZE); 354 355 /* Ensure a merged request will fit in a single I/O ring slot. */ 356 blk_queue_max_phys_segments(rq, BLKIF_MAX_SEGMENTS_PER_REQUEST); 357 blk_queue_max_hw_segments(rq, BLKIF_MAX_SEGMENTS_PER_REQUEST); --- 687 unchanged lines hidden (view full) --- 1045 .owner = THIS_MODULE, 1046 .open = blkif_open, 1047 .release = blkif_release, 1048 .getgeo = blkif_getgeo, 1049 .locked_ioctl = blkif_ioctl, 1050}; 1051 1052 | 350 351 /* Each segment in a request is up to an aligned page in size. */ 352 blk_queue_segment_boundary(rq, PAGE_SIZE - 1); 353 blk_queue_max_segment_size(rq, PAGE_SIZE); 354 355 /* Ensure a merged request will fit in a single I/O ring slot. */ 356 blk_queue_max_phys_segments(rq, BLKIF_MAX_SEGMENTS_PER_REQUEST); 357 blk_queue_max_hw_segments(rq, BLKIF_MAX_SEGMENTS_PER_REQUEST); --- 687 unchanged lines hidden (view full) --- 1045 .owner = THIS_MODULE, 1046 .open = blkif_open, 1047 .release = blkif_release, 1048 .getgeo = blkif_getgeo, 1049 .locked_ioctl = blkif_ioctl, 1050}; 1051 1052 |
1053static struct xenbus_device_id blkfront_ids[] = { | 1053static const struct xenbus_device_id blkfront_ids[] = { |
1054 { "vbd" }, 1055 { "" } 1056}; 1057 1058static struct xenbus_driver blkfront = { 1059 .name = "vbd", 1060 .owner = THIS_MODULE, 1061 .ids = blkfront_ids, --- 34 unchanged lines hidden --- | 1054 { "vbd" }, 1055 { "" } 1056}; 1057 1058static struct xenbus_driver blkfront = { 1059 .name = "vbd", 1060 .owner = THIS_MODULE, 1061 .ids = blkfront_ids, --- 34 unchanged lines hidden --- |