Skip to content

Commit

Permalink
kernel/workqueue: Use __printf markup to silence compiler in function…
Browse files Browse the repository at this point in the history
… 'alloc_workqueue'

Silence warnings (triggered at W=1) by adding relevant __printf attributes.

  kernel/workqueue.c:4249:2: warning: function 'alloc_workqueue' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]

Signed-off-by: Mathieu Malaterre <malat@debian.org>
Signed-off-by: Tejun Heo <tj@kernel.org>
  • Loading branch information
Mathieu Malaterre authored and Tejun Heo committed Mar 15, 2019
1 parent f261c4e commit a2775bb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions kernel/workqueue.c
Original file line number Diff line number Diff line change
Expand Up @@ -4208,6 +4208,7 @@ static int init_rescuer(struct workqueue_struct *wq)
return 0;
}

__printf(1, 4)
struct workqueue_struct *alloc_workqueue(const char *fmt,
unsigned int flags,
int max_active, ...)
Expand Down

0 comments on commit a2775bb

Please sign in to comment.