diff options
author | Jens Axboe <axboe@fb.com> | 2014-05-29 10:09:00 -0400 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2014-05-29 10:09:00 -0400 |
commit | 4d92a9beb39d80a7d8ff7c04ae12a10290105ae5 (patch) | |
tree | 6c0c28e1e1e3edf9958bedbe9d5e6c2f84a13b92 /block | |
parent | cdef54dd85ad66e77262ea57796a3e81683dd5d6 (diff) |
block: remove 'magic' from struct blk_plug
I don't think we've ever caught any bugs with this, and there's the
list poisoning for the plug lists to catch uninitialized cases.
So remove the magic member and save 8 bytes in the struct.
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/blk-core.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/block/blk-core.c b/block/blk-core.c index d87be5b4e554..40d654861c33 100644 --- a/block/blk-core.c +++ b/block/blk-core.c | |||
@@ -2957,8 +2957,6 @@ int kblockd_schedule_delayed_work_on(int cpu, struct delayed_work *dwork, | |||
2957 | } | 2957 | } |
2958 | EXPORT_SYMBOL(kblockd_schedule_delayed_work_on); | 2958 | EXPORT_SYMBOL(kblockd_schedule_delayed_work_on); |
2959 | 2959 | ||
2960 | #define PLUG_MAGIC 0x91827364 | ||
2961 | |||
2962 | /** | 2960 | /** |
2963 | * blk_start_plug - initialize blk_plug and track it inside the task_struct | 2961 | * blk_start_plug - initialize blk_plug and track it inside the task_struct |
2964 | * @plug: The &struct blk_plug that needs to be initialized | 2962 | * @plug: The &struct blk_plug that needs to be initialized |
@@ -2977,7 +2975,6 @@ void blk_start_plug(struct blk_plug *plug) | |||
2977 | { | 2975 | { |
2978 | struct task_struct *tsk = current; | 2976 | struct task_struct *tsk = current; |
2979 | 2977 | ||
2980 | plug->magic = PLUG_MAGIC; | ||
2981 | INIT_LIST_HEAD(&plug->list); | 2978 | INIT_LIST_HEAD(&plug->list); |
2982 | INIT_LIST_HEAD(&plug->mq_list); | 2979 | INIT_LIST_HEAD(&plug->mq_list); |
2983 | INIT_LIST_HEAD(&plug->cb_list); | 2980 | INIT_LIST_HEAD(&plug->cb_list); |
@@ -3074,8 +3071,6 @@ void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) | |||
3074 | LIST_HEAD(list); | 3071 | LIST_HEAD(list); |
3075 | unsigned int depth; | 3072 | unsigned int depth; |
3076 | 3073 | ||
3077 | BUG_ON(plug->magic != PLUG_MAGIC); | ||
3078 | |||
3079 | flush_plug_callbacks(plug, from_schedule); | 3074 | flush_plug_callbacks(plug, from_schedule); |
3080 | 3075 | ||
3081 | if (!list_empty(&plug->mq_list)) | 3076 | if (!list_empty(&plug->mq_list)) |