From: Adam Manzanares Date: Mon, 4 Jun 2018 17:59:56 +0000 (-0700) Subject: fs: aio ioprio add explicit block layer dependence X-Git-Tag: v5.4.17~5873^2~1 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=b0966e7b894035dba6710aa4e9f18d7a3a3d5b22;p=arm%2Flinux.git fs: aio ioprio add explicit block layer dependence Previously, the ioprio_check_cap function was only defined when CONFIG_BLOCK was set. Make this relationship explicit and add a stub for !CONFIG_BLOCK. Signed-off-by: Adam Manzanares Signed-off-by: Al Viro --- diff --git a/include/linux/ioprio.h b/include/linux/ioprio.h index 4a28cec49ec3..9e30ed6443db 100644 --- a/include/linux/ioprio.h +++ b/include/linux/ioprio.h @@ -77,6 +77,13 @@ extern int ioprio_best(unsigned short aprio, unsigned short bprio); extern int set_task_ioprio(struct task_struct *task, int ioprio); +#ifdef CONFIG_BLOCK extern int ioprio_check_cap(int ioprio); +#else +static inline int ioprio_check_cap(int ioprio) +{ + return -ENOTBLK; +} +#endif /* CONFIG_BLOCK */ #endif