Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 26004207 authored by AnilKumar Chimata's avatar AnilKumar Chimata Committed by Gerrit - the friendly Code Review server
Browse files

md: Remove unnecessary check



Remove unnecessary if condition check, which is always false. Compile
with stringent warning option reports below error,

drivers/md/dm-req-crypt.c:926:5: warning: 'and' of mutually exclusive
equal-tests is always 0 [enabled by default]
error, forbidden warning: dm-req-crypt.c:926
make[4]: *** [drivers/md/dm-req-crypt.o] Error 1
make[3]: *** [drivers/md] Error 2

Change-Id: I604b7e682dd776a941589f0a54f3ee311b858115
Signed-off-by: default avatarAnilKumar Chimata <anilc@codeaurora.org>
parent 6b6b4c37
Loading
Loading
Loading
Loading
+0 −7
Original line number Diff line number Diff line
@@ -912,13 +912,6 @@ static int req_crypt_map(struct dm_target *ti, struct request *clone,
	int error = DM_REQ_CRYPT_ERROR, copy_bio_sector_to_req = 0;
	struct bio *bio_src = NULL;

	if ((rq_data_dir(clone) != READ) &&
			 (rq_data_dir(clone) != WRITE)) {
		error = DM_REQ_CRYPT_ERROR;
		DMERR("%s Unknown request\n", __func__);
		goto submit_request;
	}

	req_io = mempool_alloc(req_io_pool, GFP_NOWAIT);
	if (!req_io) {
		DMERR("%s req_io allocation failed\n", __func__);