Skip to contentSkip to conversation

: Remove dead copy_io_context()

PATCH New Vladislav Bolkhovitin 1 participant 1 message Mar 25, 2010 Block layer

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 : Remove dead copy_io_context()

Since anticipatory IO scheduler was removed, copy_io_context() function isn't used anymore, so this patch removes it.

---
 block/blk-ioc.c           |   14 --------------
 include/linux/iocontext.h |    1 -
 2 files changed, 15 deletions(-)
block/blk-ioc.c +0 -14
diff -upkr linux-2.6.33/block/blk-ioc.c linux-2.6.33/block/blk-ioc.c
@@ -152,20 +152,6 @@ struct io_context *get_io_context(gfp_t 
 }
 EXPORT_SYMBOL(get_io_context);
 
-void copy_io_context(struct io_context **pdst, struct io_context **psrc)
-{
-	struct io_context *src = *psrc;
-	struct io_context *dst = *pdst;
-
-	if (src) {
-		BUG_ON(atomic_long_read(&src->refcount) == 0);
-		atomic_long_inc(&src->refcount);
-		put_io_context(dst);
-		*pdst = src;
-	}
-}
-EXPORT_SYMBOL(copy_io_context);
-
 static int __init blk_ioc_init(void)
 {
 	iocontext_cachep = kmem_cache_create("blkdev_ioc",
include/linux/iocontext.h +0 -1
diff -upkr linux-2.6.33/include/linux/iocontext.h linux-2.6.33/include/linux/iocontext.h
@@ -77,7 +77,6 @@ int put_io_context(struct io_context *io
 void exit_io_context(struct task_struct *task);
 struct io_context *get_io_context(gfp_t gfp_flags, int node);
 struct io_context *alloc_io_context(gfp_t gfp_flags, int node);
-void copy_io_context(struct io_context **pdst, struct io_context **psrc);
 #else
 static inline void exit_io_context(struct task_struct *task)
 {