lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Thu, 20 May 2021 18:00:36 +0800
From:   Yue Hu <zbestahu@...il.com>
To:     adrian.hunter@...el.com, riteshh@...eaurora.org,
        asutoshd@...eaurora.org, ulf.hansson@...aro.org
Cc:     linux-mmc@...r.kernel.org, linux-kernel@...r.kernel.org,
        huyue2@...ong.com, zbestahu@....com
Subject: [PATCH] mmc: cqhci: use data instead of mrq parameter from cqhci_dma_map()

From: Yue Hu <huyue2@...ong.com>

cqhci_dma_map() will be only called by cqhci_prep_tran_desc() which
already has 'mrq->data'.

Signed-off-by: Yue Hu <huyue2@...ong.com>
---
 drivers/mmc/host/cqhci-core.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/cqhci-core.c b/drivers/mmc/host/cqhci-core.c
index 93b0432..e759e3b 100644
--- a/drivers/mmc/host/cqhci-core.c
+++ b/drivers/mmc/host/cqhci-core.c
@@ -446,10 +446,9 @@ static void cqhci_prep_task_desc(struct mmc_request *mrq,
 	}
 }
 
-static int cqhci_dma_map(struct mmc_host *host, struct mmc_request *mrq)
+static int cqhci_dma_map(struct mmc_host *host, struct mmc_data *data)
 {
 	int sg_count;
-	struct mmc_data *data = mrq->data;
 
 	if (!data)
 		return -EINVAL;
@@ -499,7 +498,7 @@ static int cqhci_prep_tran_desc(struct mmc_request *mrq,
 	u8 *desc;
 	struct scatterlist *sg;
 
-	sg_count = cqhci_dma_map(mrq->host, mrq);
+	sg_count = cqhci_dma_map(mrq->host, data);
 	if (sg_count < 0) {
 		pr_err("%s: %s: unable to map sg lists, %d\n",
 				mmc_hostname(mrq->host), __func__, sg_count);
-- 
1.9.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ