Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp270146pxk; Thu, 1 Oct 2020 01:47:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxlqKtnI9dIXfw/vdcYlbZGJ3+YE2snvDwxzeb7nlPhzqLUAGNjZCNlwtOWGUU2hSm01LDi X-Received: by 2002:a50:8524:: with SMTP id 33mr7315951edr.123.1601542020302; Thu, 01 Oct 2020 01:47:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601542020; cv=none; d=google.com; s=arc-20160816; b=U+HDm2bvwqO8BhpIqlHEPtYa4tkxuEsmAYByFyB0W24L0hHNKywSD7NCN8BYVDXc6k m5RHFT+s3alxCn6tAGBpBlxohn3/j/mO4nKBxj0DM4csbwMKNT4hbWmBTgolsFen/gCe Nc+OV4IOTfSU3FIkSGqSRBk2oX3+qBCDWa6fj4XaPtviQBWUpE9LSZKQjKOetCjNJHxO zkGGqTHHm843L6tp1Dt3hIEdyiuoygivP3cKXUD0HuhkkeZnFQZKhhmfT1zl0pJCRMI/ N2ir5NxvBKprcoueLGf5lWjlv23+dCM8yubDwxMXSxrsCAEgvELWf0cwnu77buuqkqzc 4oSA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=MX72lidYXGjzrTMgVYPWeRvwabTIuTrY0h49qQmogus=; b=hynCfnsIdRIFNrncR0cbnQT32XHAlkdZ//LSp24FKC2xGebuwBX0UXF7QQjhg/sk33 gRciHdm0Mju03TYbOAFWerIu3g64ETfYwWB0HdP36TDREUIhaPm28lfT280sABbn/Gky h4ZvzI+/m6LSCh3VK3tWPdQcIv+xRku9hWBfI/xJmD2TbZ+EOAT3Q1vSi70DGXQattZo GLTsG84XgSXh03HBufxzG6nrdjibmVIHm6qPWs82NrhniidSrq6/B5NO/R7pfIkV2JlV UcpzUP9ro83+T4H4rdruZG9p4TWLW/+gZDYST84nKEwMrOoTF7orVJ1rTGJo6mKEPGmi f9dw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q22si2935930edb.85.2020.10.01.01.46.37; Thu, 01 Oct 2020 01:47:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731704AbgJAIpN (ORCPT + 99 others); Thu, 1 Oct 2020 04:45:13 -0400 Received: from alexa-out.qualcomm.com ([129.46.98.28]:17759 "EHLO alexa-out.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731666AbgJAIpK (ORCPT ); Thu, 1 Oct 2020 04:45:10 -0400 Received: from ironmsg07-lv.qualcomm.com (HELO ironmsg07-lv.qulacomm.com) ([10.47.202.151]) by alexa-out.qualcomm.com with ESMTP; 01 Oct 2020 01:45:09 -0700 X-QCInternal: smtphost Received: from ironmsg02-blr.qualcomm.com ([10.86.208.131]) by ironmsg07-lv.qulacomm.com with ESMTP/TLS/AES256-SHA; 01 Oct 2020 01:45:07 -0700 X-QCInternal: smtphost Received: from c-rojay-linux.qualcomm.com ([10.206.21.80]) by ironmsg02-blr.qualcomm.com with ESMTP; 01 Oct 2020 14:14:31 +0530 Received: by c-rojay-linux.qualcomm.com (Postfix, from userid 88981) id 72884253A; Thu, 1 Oct 2020 14:14:30 +0530 (IST) From: Roja Rani Yarubandi To: wsa@kernel.org Cc: swboyd@chromium.org, dianders@chromium.org, saiprakash.ranjan@codeaurora.org, gregkh@linuxfoundation.org, mka@chromium.org, akashast@codeaurora.org, msavaliy@qti.qualcomm.com, skakit@codeaurora.org, vkaur@codeaurora.org, pyarlaga@codeaurora.org, rnayak@codeaurora.org, agross@kernel.org, bjorn.andersson@linaro.org, linux-arm-msm@vger.kernel.org, linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org, sumit.semwal@linaro.org, linux-media@vger.kernel.org, Roja Rani Yarubandi Subject: [PATCH V5 1/3] soc: qcom: geni: Remove "iova" check Date: Thu, 1 Oct 2020 14:14:23 +0530 Message-Id: <20201001084425.23117-2-rojay@codeaurora.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201001084425.23117-1-rojay@codeaurora.org> References: <20201001084425.23117-1-rojay@codeaurora.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Remove "iova" check from geni_se_tx_dma_unprep and geni_se_rx_dma_unprep fucntions as invalidating with dma_mapping_error() is enough. Signed-off-by: Roja Rani Yarubandi --- Changes in V5: - This is newly added patch in V5. As per Stephen's comments separted this patch from shutdown callback patch. drivers/soc/qcom/qcom-geni-se.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/soc/qcom/qcom-geni-se.c b/drivers/soc/qcom/qcom-geni-se.c index d0e4f520cff8..0216b38c1e9a 100644 --- a/drivers/soc/qcom/qcom-geni-se.c +++ b/drivers/soc/qcom/qcom-geni-se.c @@ -705,7 +705,7 @@ void geni_se_tx_dma_unprep(struct geni_se *se, dma_addr_t iova, size_t len) { struct geni_wrapper *wrapper = se->wrapper; - if (iova && !dma_mapping_error(wrapper->dev, iova)) + if (!dma_mapping_error(wrapper->dev, iova)) dma_unmap_single(wrapper->dev, iova, len, DMA_TO_DEVICE); } EXPORT_SYMBOL(geni_se_tx_dma_unprep); @@ -722,7 +722,7 @@ void geni_se_rx_dma_unprep(struct geni_se *se, dma_addr_t iova, size_t len) { struct geni_wrapper *wrapper = se->wrapper; - if (iova && !dma_mapping_error(wrapper->dev, iova)) + if (!dma_mapping_error(wrapper->dev, iova)) dma_unmap_single(wrapper->dev, iova, len, DMA_FROM_DEVICE); } EXPORT_SYMBOL(geni_se_rx_dma_unprep); -- QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation