aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/blkdev.h27
-rw-r--r--include/linux/i2o.h2
2 files changed, 17 insertions, 12 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 57bc48446e9..ebd22dbed86 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -316,8 +316,7 @@ struct queue_limits {
316 unsigned int discard_alignment; 316 unsigned int discard_alignment;
317 317
318 unsigned short logical_block_size; 318 unsigned short logical_block_size;
319 unsigned short max_hw_segments; 319 unsigned short max_segments;
320 unsigned short max_phys_segments;
321 320
322 unsigned char misaligned; 321 unsigned char misaligned;
323 unsigned char discard_misaligned; 322 unsigned char discard_misaligned;
@@ -929,8 +928,19 @@ static inline void blk_queue_max_sectors(struct request_queue *q, unsigned int m
929 blk_queue_max_hw_sectors(q, max); 928 blk_queue_max_hw_sectors(q, max);
930} 929}
931 930
932extern void blk_queue_max_phys_segments(struct request_queue *, unsigned short); 931extern void blk_queue_max_segments(struct request_queue *, unsigned short);
933extern void blk_queue_max_hw_segments(struct request_queue *, unsigned short); 932
933static inline void blk_queue_max_phys_segments(struct request_queue *q, unsigned short max)
934{
935 blk_queue_max_segments(q, max);
936}
937
938static inline void blk_queue_max_hw_segments(struct request_queue *q, unsigned short max)
939{
940 blk_queue_max_segments(q, max);
941}
942
943
934extern void blk_queue_max_segment_size(struct request_queue *, unsigned int); 944extern void blk_queue_max_segment_size(struct request_queue *, unsigned int);
935extern void blk_queue_max_discard_sectors(struct request_queue *q, 945extern void blk_queue_max_discard_sectors(struct request_queue *q,
936 unsigned int max_discard_sectors); 946 unsigned int max_discard_sectors);
@@ -1055,14 +1065,9 @@ static inline unsigned int queue_max_hw_sectors(struct request_queue *q)
1055 return q->limits.max_hw_sectors; 1065 return q->limits.max_hw_sectors;
1056} 1066}
1057 1067
1058static inline unsigned short queue_max_hw_segments(struct request_queue *q) 1068static inline unsigned short queue_max_segments(struct request_queue *q)
1059{
1060 return q->limits.max_hw_segments;
1061}
1062
1063static inline unsigned short queue_max_phys_segments(struct request_queue *q)
1064{ 1069{
1065 return q->limits.max_phys_segments; 1070 return q->limits.max_segments;
1066} 1071}
1067 1072
1068static inline unsigned int queue_max_segment_size(struct request_queue *q) 1073static inline unsigned int queue_max_segment_size(struct request_queue *q)
diff --git a/include/linux/i2o.h b/include/linux/i2o.h
index 4c4e57d1f19..87018dc5527 100644
--- a/include/linux/i2o.h
+++ b/include/linux/i2o.h
@@ -385,7 +385,7 @@
385/* defines for max_sectors and max_phys_segments */ 385/* defines for max_sectors and max_phys_segments */
386#define I2O_MAX_SECTORS 1024 386#define I2O_MAX_SECTORS 1024
387#define I2O_MAX_SECTORS_LIMITED 128 387#define I2O_MAX_SECTORS_LIMITED 128
388#define I2O_MAX_PHYS_SEGMENTS MAX_PHYS_SEGMENTS 388#define I2O_MAX_PHYS_SEGMENTS BLK_MAX_SEGMENTS
389 389
390/* 390/*
391 * Message structures 391 * Message structures