Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

block: blkdev.h cleanup, move iocontext stuff to iocontext.h

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>

+20 -17
-17
include/linux/blkdev.h
··· 33 33 #define BLKDEV_MIN_RQ 4 34 34 #define BLKDEV_MAX_RQ 128 /* Default maximum */ 35 35 36 - int put_io_context(struct io_context *ioc); 37 - void exit_io_context(void); 38 - struct io_context *get_io_context(gfp_t gfp_flags, int node); 39 - struct io_context *alloc_io_context(gfp_t gfp_flags, int node); 40 - void copy_io_context(struct io_context **pdst, struct io_context **psrc); 41 - 42 36 struct request; 43 37 typedef void (rq_end_io_fn)(struct request *, int); 44 38 ··· 974 980 { 975 981 return 0; 976 982 } 977 - 978 - static inline void exit_io_context(void) 979 - { 980 - } 981 - 982 - struct io_context; 983 - static inline int put_io_context(struct io_context *ioc) 984 - { 985 - return 1; 986 - } 987 - 988 983 989 984 #endif /* CONFIG_BLOCK */ 990 985
+18
include/linux/iocontext.h
··· 99 99 return NULL; 100 100 } 101 101 102 + #ifdef CONFIG_BLOCK 103 + int put_io_context(struct io_context *ioc); 104 + void exit_io_context(void); 105 + struct io_context *get_io_context(gfp_t gfp_flags, int node); 106 + struct io_context *alloc_io_context(gfp_t gfp_flags, int node); 107 + void copy_io_context(struct io_context **pdst, struct io_context **psrc); 108 + #else 109 + static inline void exit_io_context(void) 110 + { 111 + } 112 + 113 + struct io_context; 114 + static inline int put_io_context(struct io_context *ioc) 115 + { 116 + return 1; 117 + } 118 + #endif 119 + 102 120 #endif
+1
kernel/exit.c
··· 13 13 #include <linux/personality.h> 14 14 #include <linux/tty.h> 15 15 #include <linux/mnt_namespace.h> 16 + #include <linux/iocontext.h> 16 17 #include <linux/key.h> 17 18 #include <linux/security.h> 18 19 #include <linux/cpu.h>
+1
kernel/fork.c
··· 23 23 #include <linux/sem.h> 24 24 #include <linux/file.h> 25 25 #include <linux/fdtable.h> 26 + #include <linux/iocontext.h> 26 27 #include <linux/key.h> 27 28 #include <linux/binfmts.h> 28 29 #include <linux/mman.h>