Skip to content

Commit

Permalink
dm crypt: remove waitqueue
Browse files Browse the repository at this point in the history
Remove waitqueue no longer needed with the async crypto interface.

Signed-off-by: Milan Broz <mbroz@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
  • Loading branch information
Milan Broz authored and Alasdair G Kergon committed Oct 21, 2008
1 parent 393b47e commit 0a4a104
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions drivers/md/dm-crypt.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@ struct crypt_config {

struct workqueue_struct *io_queue;
struct workqueue_struct *crypt_queue;
wait_queue_head_t writeq;

/*
* crypto related data
Expand Down Expand Up @@ -656,10 +655,7 @@ static void kcryptd_io_read(struct dm_crypt_io *io)
static void kcryptd_io_write(struct dm_crypt_io *io)
{
struct bio *clone = io->ctx.bio_out;
struct crypt_config *cc = io->target->private;

generic_make_request(clone);
wake_up(&cc->writeq);
}

static void kcryptd_io(struct work_struct *work)
Expand Down Expand Up @@ -791,9 +787,6 @@ static void kcryptd_crypt_write_convert(struct dm_crypt_io *io)

io = new_io;
}

if (unlikely(remaining))
wait_event(cc->writeq, !atomic_read(&io->ctx.pending));
}

crypt_dec_pending(io);
Expand Down Expand Up @@ -1120,7 +1113,6 @@ static int crypt_ctr(struct dm_target *ti, unsigned int argc, char **argv)
goto bad_crypt_queue;
}

init_waitqueue_head(&cc->writeq);
ti->private = cc;
return 0;

Expand Down

0 comments on commit 0a4a104

Please sign in to comment.