Commit e01fd7eeb00f8078103f4ed3e8ef64474c11f300
1 parent
72727bad54
Exists in
master
and in
39 other branches
dm io: rename error to error_bits
Rename 'error' to 'error_bits' for clarity. Signed-off-by: Alasdair G Kergon <agk@redhat.com>
Showing 1 changed file with 7 additions and 7 deletions Side-by-side Diff
drivers/md/dm-io.c
... | ... | @@ -20,7 +20,7 @@ |
20 | 20 | |
21 | 21 | /* FIXME: can we shrink this ? */ |
22 | 22 | struct io { |
23 | - unsigned long error; | |
23 | + unsigned long error_bits; | |
24 | 24 | atomic_t count; |
25 | 25 | struct task_struct *sleeper; |
26 | 26 | struct dm_io_client *client; |
27 | 27 | |
... | ... | @@ -107,14 +107,14 @@ |
107 | 107 | static void dec_count(struct io *io, unsigned int region, int error) |
108 | 108 | { |
109 | 109 | if (error) |
110 | - set_bit(region, &io->error); | |
110 | + set_bit(region, &io->error_bits); | |
111 | 111 | |
112 | 112 | if (atomic_dec_and_test(&io->count)) { |
113 | 113 | if (io->sleeper) |
114 | 114 | wake_up_process(io->sleeper); |
115 | 115 | |
116 | 116 | else { |
117 | - unsigned long r = io->error; | |
117 | + unsigned long r = io->error_bits; | |
118 | 118 | io_notify_fn fn = io->callback; |
119 | 119 | void *context = io->context; |
120 | 120 | |
... | ... | @@ -357,7 +357,7 @@ |
357 | 357 | return -EIO; |
358 | 358 | } |
359 | 359 | |
360 | - io.error = 0; | |
360 | + io.error_bits = 0; | |
361 | 361 | atomic_set(&io.count, 1); /* see dispatch_io() */ |
362 | 362 | io.sleeper = current; |
363 | 363 | io.client = client; |
364 | 364 | |
... | ... | @@ -378,9 +378,9 @@ |
378 | 378 | return -EINTR; |
379 | 379 | |
380 | 380 | if (error_bits) |
381 | - *error_bits = io.error; | |
381 | + *error_bits = io.error_bits; | |
382 | 382 | |
383 | - return io.error ? -EIO : 0; | |
383 | + return io.error_bits ? -EIO : 0; | |
384 | 384 | } |
385 | 385 | |
386 | 386 | static int async_io(struct dm_io_client *client, unsigned int num_regions, |
... | ... | @@ -396,7 +396,7 @@ |
396 | 396 | } |
397 | 397 | |
398 | 398 | io = mempool_alloc(client->pool, GFP_NOIO); |
399 | - io->error = 0; | |
399 | + io->error_bits = 0; | |
400 | 400 | atomic_set(&io->count, 1); /* see dispatch_io() */ |
401 | 401 | io->sleeper = NULL; |
402 | 402 | io->client = client; |