aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIñaky Pérez-González <inaky.perez-gonzalez@intel.com>2004-08-22 23:05:25 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2004-08-22 23:05:25 -0700
commitd86f67713b53b625ab1fd1ef4b5b8cda9e3362d7 (patch)
treea3eb6b6087ba5104e3de9bf22fdeacdf362d0373
parent6e354f5cececd74a72c4f11bc5758cebbc7395d1 (diff)
downloadhistory-d86f67713b53b625ab1fd1ef4b5b8cda9e3362d7.tar.gz
[PATCH] aio.c: rename 'struct timeout' to 'struct aio_timeout'
This patch renames fs/aio.c:'struct timeout' to 'struct aio_timeout'. The rationale behind this decision is this type is used only inside the aforementioned aio.c file and being the type name very generic, it is likely to cause namespace conflicts in the future. I actually found it while working on an extended schedule_timeout()- like API used by robust mutexes but usable by anyone. There I declared a 'struct timeout' and aio.c complained about it. I could have also renamed the struct for the schedule_timeout() like API, but being the aio.c one specific to the file, I thought it might make more sense to rename the later. Signed-off-by: Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--fs/aio.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/aio.c b/fs/aio.c
index 9e7b5928e640f..c937114d90454 100644
--- a/fs/aio.c
+++ b/fs/aio.c
@@ -759,7 +759,7 @@ out:
return ret;
}
-struct timeout {
+struct aio_timeout {
struct timer_list timer;
int timed_out;
struct task_struct *p;
@@ -767,13 +767,13 @@ struct timeout {
static void timeout_func(unsigned long data)
{
- struct timeout *to = (struct timeout *)data;
+ struct aio_timeout *to = (struct aio_timeout *)data;
to->timed_out = 1;
wake_up_process(to->p);
}
-static inline void init_timeout(struct timeout *to)
+static inline void init_timeout(struct aio_timeout *to)
{
init_timer(&to->timer);
to->timer.data = (unsigned long)to;
@@ -782,7 +782,7 @@ static inline void init_timeout(struct timeout *to)
to->p = current;
}
-static inline void set_timeout(long start_jiffies, struct timeout *to,
+static inline void set_timeout(long start_jiffies, struct aio_timeout *to,
const struct timespec *ts)
{
to->timer.expires = start_jiffies + timespec_to_jiffies(ts);
@@ -792,7 +792,7 @@ static inline void set_timeout(long start_jiffies, struct timeout *to,
to->timed_out = 1;
}
-static inline void clear_timeout(struct timeout *to)
+static inline void clear_timeout(struct aio_timeout *to)
{
del_singleshot_timer_sync(&to->timer);
}
@@ -808,7 +808,7 @@ static int read_events(struct kioctx *ctx,
int ret;
int i = 0;
struct io_event ent;
- struct timeout to;
+ struct aio_timeout to;
/* needed to zero any padding within an entry (there shouldn't be
* any, but C is fun!