Skip to content

Commit

Permalink
block: add __init to elv_register
Browse files Browse the repository at this point in the history
elv_register is only called by elevator init functions:

__init cfq_init
__init deadline_init
__init noop_init

Cc: Andrew Morton <[email protected]>
Signed-off-by: Fabian Frederick <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
  • Loading branch information
Fabian Frederick authored and axboe committed Jun 10, 2014
1 parent 58a4915 commit b5097e9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion block/elevator.c
Original file line number Diff line number Diff line change
Expand Up @@ -845,7 +845,7 @@ void elv_unregister_queue(struct request_queue *q)
}
EXPORT_SYMBOL(elv_unregister_queue);

int elv_register(struct elevator_type *e)
int __init elv_register(struct elevator_type *e)
{
char *def = "";

Expand Down
2 changes: 1 addition & 1 deletion include/linux/elevator.h
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ extern void elv_drain_elevator(struct request_queue *);
* io scheduler registration
*/
extern void __init load_default_elevator_module(void);
extern int elv_register(struct elevator_type *);
extern int __init elv_register(struct elevator_type *);
extern void elv_unregister(struct elevator_type *);

/*
Expand Down

0 comments on commit b5097e9

Please sign in to comment.