All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] removed unused as_io_context
@ 2010-01-08 19:09 Kirill Afonshin
  2010-01-11 13:25 ` Jens Axboe
  0 siblings, 1 reply; 2+ messages in thread
From: Kirill Afonshin @ 2010-01-08 19:09 UTC (permalink / raw)
  To: Jens Axboe; +Cc: Linux-Kernel

Jens, as_io_context isn't used anymore.
---
 block/blk-ioc.c           |    5 -----
 include/linux/iocontext.h |   27 ---------------------------
 2 files changed, 0 insertions(+), 32 deletions(-)

diff --git a/block/blk-ioc.c b/block/blk-ioc.c
index cbdabb0..98e6bf6 100644
--- a/block/blk-ioc.c
+++ b/block/blk-ioc.c
@@ -39,8 +39,6 @@ int put_io_context(struct io_context *ioc)
 
 	if (atomic_long_dec_and_test(&ioc->refcount)) {
 		rcu_read_lock();
-		if (ioc->aic && ioc->aic->dtor)
-			ioc->aic->dtor(ioc->aic);
 		cfq_dtor(ioc);
 		rcu_read_unlock();
 
@@ -76,8 +74,6 @@ void exit_io_context(struct task_struct *task)
 	task_unlock(task);
 
 	if (atomic_dec_and_test(&ioc->nr_tasks)) {
-		if (ioc->aic && ioc->aic->exit)
-			ioc->aic->exit(ioc->aic);
 		cfq_exit(ioc);
 
 	}
@@ -97,7 +93,6 @@ struct io_context *alloc_io_context(gfp_t gfp_flags, int node)
 		ret->ioprio = 0;
 		ret->last_waited = jiffies; /* doesn't matter... */
 		ret->nr_batch_requests = 0; /* because this is 0 */
-		ret->aic = NULL;
 		INIT_RADIX_TREE(&ret->radix_root, GFP_ATOMIC | __GFP_HIGH);
 		INIT_HLIST_HEAD(&ret->cic_list);
 		ret->ioc_data = NULL;
diff --git a/include/linux/iocontext.h b/include/linux/iocontext.h
index a632359..78ef023 100644
--- a/include/linux/iocontext.h
+++ b/include/linux/iocontext.h
@@ -4,32 +4,6 @@
 #include <linux/radix-tree.h>
 #include <linux/rcupdate.h>
 
-/*
- * This is the per-process anticipatory I/O scheduler state.
- */
-struct as_io_context {
-	spinlock_t lock;
-
-	void (*dtor)(struct as_io_context *aic); /* destructor */
-	void (*exit)(struct as_io_context *aic); /* called on task exit */
-
-	unsigned long state;
-	atomic_t nr_queued; /* queued reads & sync writes */
-	atomic_t nr_dispatched; /* number of requests gone to the drivers */
-
-	/* IO History tracking */
-	/* Thinktime */
-	unsigned long last_end_request;
-	unsigned long ttime_total;
-	unsigned long ttime_samples;
-	unsigned long ttime_mean;
-	/* Layout pattern */
-	unsigned int seek_samples;
-	sector_t last_request_pos;
-	u64 seek_total;
-	sector_t seek_mean;
-};
-
 struct cfq_queue;
 struct cfq_io_context {
 	void *key;
@@ -78,7 +52,6 @@ struct io_context {
 	unsigned long last_waited; /* Time last woken after wait for request */
 	int nr_batch_requests;     /* Number of requests left in the batch */
 
-	struct as_io_context *aic;
 	struct radix_tree_root radix_root;
 	struct hlist_head cic_list;
 	void *ioc_data;
-- 
1.6.3.3

Best regards,
Kirill Afonshin

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] removed unused as_io_context
  2010-01-08 19:09 [PATCH] removed unused as_io_context Kirill Afonshin
@ 2010-01-11 13:25 ` Jens Axboe
  0 siblings, 0 replies; 2+ messages in thread
From: Jens Axboe @ 2010-01-11 13:25 UTC (permalink / raw)
  To: Kirill Afonshin; +Cc: Linux-Kernel

On Fri, Jan 08 2010, Kirill Afonshin wrote:
> Jens, as_io_context isn't used anymore.

Thanks, yes that's definitely an oversight. Applied.

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-01-11 13:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-08 19:09 [PATCH] removed unused as_io_context Kirill Afonshin
2010-01-11 13:25 ` Jens Axboe

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.