From e6de516854381b4a916c3e6304b5bfe1afe9540d Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Wed, 5 Oct 2011 11:44:05 +1100 Subject: [PATCH] dio-inline-the-complete-submission-path-v2-checkpatch-fixes WARNING: line over 80 characters #46: FILE: fs/direct-io.c:248: +static inline struct page *dio_get_page(struct dio *dio, struct dio_submit *sdio) ERROR: inline keyword should sit between storage class and type #55: FILE: fs/direct-io.c:379: +static void inline ERROR: trailing whitespace #91: FILE: fs/direct-io.c:634: +static inline int dio_new_bio(struct dio *dio, struct dio_submit *sdio, $ ERROR: code indent should use tabs where possible #111: FILE: fs/direct-io.c:693: +^I ^I^I ^I struct buffer_head *map_bh)$ WARNING: please, no space before tabs #111: FILE: fs/direct-io.c:693: +^I ^I^I ^I struct buffer_head *map_bh)$ WARNING: line over 80 characters #129: FILE: fs/direct-io.c:845: +static inline void dio_zero_block(struct dio *dio, struct dio_submit *sdio, int end, ERROR: trailing whitespace #146: FILE: fs/direct-io.c:1216: + * $ ERROR: trailing whitespace #149: FILE: fs/direct-io.c:1219: + * individual fields and will generate much worse code. $ total: 5 errors, 3 warnings, 109 lines checked NOTE: whitespace errors detected, you may wish to use scripts/cleanpatch or scripts/cleanfile ./patches/dio-inline-the-complete-submission-path-v2.patch has style problems, please review. If any of these errors are false positives, please report them to the maintainer, see CHECKPATCH in MAINTAINERS. Please run checkpatch prior to sending patches Cc: Andi Kleen Signed-off-by: Andrew Morton --- fs/direct-io.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/fs/direct-io.c b/fs/direct-io.c index 716ee23f3053..14f219dedf4f 100644 --- a/fs/direct-io.c +++ b/fs/direct-io.c @@ -376,10 +376,8 @@ void dio_end_io(struct bio *bio, int error) } EXPORT_SYMBOL_GPL(dio_end_io); -static void inline -dio_bio_alloc(struct dio *dio, struct dio_submit *sdio, - struct block_device *bdev, - sector_t first_sector, int nr_vecs) +static inline void dio_bio_alloc(struct dio *dio, struct dio_submit *sdio, + struct block_device *bdev, sector_t first_sector, int nr_vecs) { struct bio *bio; @@ -627,7 +625,7 @@ static int get_more_blocks(struct dio *dio, struct dio_submit *sdio, /* * There is no bio. Make one now. */ -static inline int dio_new_bio(struct dio *dio, struct dio_submit *sdio, +static inline int dio_new_bio(struct dio *dio, struct dio_submit *sdio, sector_t start_sector, struct buffer_head *map_bh) { sector_t sector; @@ -686,7 +684,7 @@ static inline int dio_bio_add_page(struct dio *dio, struct dio_submit *sdio) * dio, and for dropping the refcount which came from that presence. */ static inline int dio_send_cur_page(struct dio *dio, struct dio_submit *sdio, - struct buffer_head *map_bh) + struct buffer_head *map_bh) { int ret = 0; @@ -1209,10 +1207,10 @@ direct_io_worker(int rw, struct kiocb *iocb, struct inode *inode, * expected that filesystem provide exclusion between new direct I/O * and truncates. For DIO_LOCKING filesystems this is done by i_mutex, * but other filesystems need to take care of this on their own. - * + * * NOTE: if you pass "sdio" to anything by pointer make sure that function * is always inlined. Otherwise gcc is unable to split the structure into - * individual fields and will generate much worse code. + * individual fields and will generate much worse code. * This is important for the whole file. */ ssize_t -- 2.39.5