Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp2719355imj; Mon, 11 Feb 2019 07:28:19 -0800 (PST) X-Google-Smtp-Source: AHgI3IYSaLA8k32gFJn4sQtWH2ve+XXB5skTXKtjARaWiGQ77JucpGny0YncjvxKahCgwy4w4o6M X-Received: by 2002:a17:902:8686:: with SMTP id g6mr35543548plo.149.1549898899017; Mon, 11 Feb 2019 07:28:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549898899; cv=none; d=google.com; s=arc-20160816; b=PvWbxX0VOgRUF1eB72pQpPAllm5Sz7z8j86lZB0t0VgGzGclmdPtsDxG+DfgV7ToiE anQON/g8LtGy32k7TfR5w9YpHSsaGq7mg8j+PntFmfWwQ1zRmWd3yfXuZkA/KuH2nVSQ UVU6NgCmOnhlupvpAI0GltPhM8zoXuasRrBSbopIS6ulQdXEFTbwSTyx1pCWpLX+W0i8 Ej4xAHUMbz1JdXhXUQv2M6HwuPyJzSWMJMe6gE5tBcAP4Jjh+fd7JFAoVTTlHa4vKLeS bfYKazwBXvdfgoy67ItpDOknpCO8W/hMOzD5PGnk1JL+g9madMUqeBOZlmk0R+q2pROl OrmQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Wb9N55ZmaZQNG9SSVfj9ZS11cvu8nKXkqSeixyyZyoM=; b=nv2WZE11kZAqYt/KGSRBDqkSxwCXEU4T4OtWgWc+TDjiCS1WYH1SdT8mRWyAWaDmhL j3k0HWL4J+IBujtL27eXGwOhyXwn25bEa40SJkrN5M57ImhhWUG88z8VCYy9Xnl6sgH2 sKvNvtgscl9xjRWS08wD6i05GtEGW1yFmisO7YXYnz2xZM+aWdnERADPHACw+GmSKQOg AB1w7KEUf1Fp7ofRnc0b4ZFg8e/2M6Tl1V1SAKz4RgrxrGTvIoQH7Pg3jO6mYOpA+dL/ jjLYdpkttewwPpX61Yv5TDxGKBdEmQkPd5lowD6VMzTVSagvWaWZonrDSqAItrcUU1m3 kP/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=A9tl00bT; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f17si546856pff.171.2019.02.11.07.28.02; Mon, 11 Feb 2019 07:28:18 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=A9tl00bT; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390071AbfBKPA4 (ORCPT + 99 others); Mon, 11 Feb 2019 10:00:56 -0500 Received: from mail.kernel.org ([198.145.29.99]:48856 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389667AbfBKPAx (ORCPT ); Mon, 11 Feb 2019 10:00:53 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4BE9D222A4; Mon, 11 Feb 2019 15:00:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549897252; bh=5RbqsYXNXRwIty+3ofiESqHYruU/j2jO7VhVxoy8w5k=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=A9tl00bT6L95FELHIY9fGU8OGeuGNDfz6HIM7nEFdVLChovDvT+AHXRb1mTfRpHv1 +kLcWo9SQ6Dewxp0V/22n0Hg5kUXcilbWey+qV5hXxduetRDzfx90ahYhbo0BXtIbP ND+UmQAlx9uHydnsxgRjnLeznbOdGcW+DdzrvkSI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Nathan Chancellor , Nick Desaulniers , Herbert Xu , Sasha Levin Subject: [PATCH 4.14 140/205] crypto: ux500 - Use proper enum in hash_set_dma_transfer Date: Mon, 11 Feb 2019 15:18:58 +0100 Message-Id: <20190211141837.541151839@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190211141827.214852402@linuxfoundation.org> References: <20190211141827.214852402@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.14-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit 5ac93f808338f4dd465402e91869702eb87db241 ] Clang warns when one enumerated type is implicitly converted to another: drivers/crypto/ux500/hash/hash_core.c:169:4: warning: implicit conversion from enumeration type 'enum dma_data_direction' to different enumeration type 'enum dma_transfer_direction' [-Wenum-conversion] direction, DMA_CTRL_ACK | DMA_PREP_INTERRUPT); ^~~~~~~~~ 1 warning generated. dmaengine_prep_slave_sg expects an enum from dma_transfer_direction. We know that the only direction supported by this function is DMA_TO_DEVICE because of the check at the top of this function so we can just use the equivalent value from dma_transfer_direction. DMA_TO_DEVICE = DMA_MEM_TO_DEV = 1 Signed-off-by: Nathan Chancellor Reviewed-by: Nick Desaulniers Signed-off-by: Herbert Xu Signed-off-by: Sasha Levin --- drivers/crypto/ux500/hash/hash_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/crypto/ux500/hash/hash_core.c b/drivers/crypto/ux500/hash/hash_core.c index 9acccad26928..17c8e2b28c42 100644 --- a/drivers/crypto/ux500/hash/hash_core.c +++ b/drivers/crypto/ux500/hash/hash_core.c @@ -165,7 +165,7 @@ static int hash_set_dma_transfer(struct hash_ctx *ctx, struct scatterlist *sg, __func__); desc = dmaengine_prep_slave_sg(channel, ctx->device->dma.sg, ctx->device->dma.sg_len, - direction, DMA_CTRL_ACK | DMA_PREP_INTERRUPT); + DMA_MEM_TO_DEV, DMA_CTRL_ACK | DMA_PREP_INTERRUPT); if (!desc) { dev_err(ctx->device->dev, "%s: dmaengine_prep_slave_sg() failed!\n", __func__); -- 2.19.1