diff options
author | Nikanth Karthikesan <knikanth@suse.de> | 2009-04-27 08:53:54 -0400 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-04-28 01:37:37 -0400 |
commit | 9eb55b030c4b3227334ee4482402096cd1d1a6fe (patch) | |
tree | e6c5c6e31692c715b911b18474ef6e4c627723bd /block/blk-core.c | |
parent | c69d48540c201394d08cb4d48b905e001313d9b8 (diff) |
block: catch trying to use more bits than request->cmd_flags has
Signed-off-by: Nikanth Karthikesan <knikanth@suse.de>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'block/blk-core.c')
-rw-r--r-- | block/blk-core.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/block/blk-core.c b/block/blk-core.c index 1e3b97f0ae6..394c5bd8127 100644 --- a/block/blk-core.c +++ b/block/blk-core.c | |||
@@ -2097,6 +2097,9 @@ EXPORT_SYMBOL(kblockd_schedule_work); | |||
2097 | 2097 | ||
2098 | int __init blk_dev_init(void) | 2098 | int __init blk_dev_init(void) |
2099 | { | 2099 | { |
2100 | BUILD_BUG_ON(__REQ_NR_BITS > 8 * | ||
2101 | sizeof(((struct request *)0)->cmd_flags)); | ||
2102 | |||
2100 | kblockd_workqueue = create_workqueue("kblockd"); | 2103 | kblockd_workqueue = create_workqueue("kblockd"); |
2101 | if (!kblockd_workqueue) | 2104 | if (!kblockd_workqueue) |
2102 | panic("Failed to create kblockd\n"); | 2105 | panic("Failed to create kblockd\n"); |