From patchwork Thu May 14 12:46:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Joerg Roedel X-Patchwork-Id: 11548653 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D105A739 for ; Thu, 14 May 2020 12:46:39 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A12982065D for ; Thu, 14 May 2020 12:46:39 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="CJ4cE8mw" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A12982065D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=8bytes.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=C4welo8tvap4Z3jG/ND9E1pGfogydNiHMw25OLSGozA=; b=CJ4cE8mwH69fSD DnxGmDkDuxAowUqelYfFtR6ihsZ21RKGum/WvCWa0LKMk8uLO1bhAbdZTBPRSmd1vv/PrRR/XOtfa D3k/wUBrJhGVtTy1FLb+zY5gdxjWralRVLAECeXDL3jw6EixfhyQ5kHAaj6i4bspyI/epPd66FYAE fTd2RX8T/SGZ2FOmfoyrwdAGcKrJlh9TG8dgmTUZIvKasBTRNrp6pT6TlMGuYv1SEARWhOeDiA2hv 6McA+DykRTk5169mmmsDze8GUPHZUJrWRl+lzfrzYdrp6BdLvskpNP3oDkwjBjPbDxoYpNJju411I Akk3bIgZVSx7cNcaVehQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jZDFw-0004Bn-MY; Thu, 14 May 2020 12:46:32 +0000 Received: from 8bytes.org ([81.169.241.247] helo=theia.8bytes.org) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jZDFs-0004AX-PX for linux-arm-kernel@lists.infradead.org; Thu, 14 May 2020 12:46:30 +0000 Received: by theia.8bytes.org (Postfix, from userid 1000) id 9035C452; Thu, 14 May 2020 14:46:22 +0200 (CEST) From: Joerg Roedel To: Maxime Ripard Subject: [PATCH 1/2] iommu/sun50i: Fix compile warnings Date: Thu, 14 May 2020 14:46:20 +0200 Message-Id: <20200514124621.25999-1-joro@8bytes.org> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200514_054629_475802_52E77C8A X-CRM114-Status: UNSURE ( 8.94 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on bombadil.infradead.org summary: Content analysis details: (-0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [81.169.241.247 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jroedel@suse.de, joro@8bytes.org, iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Chen-Yu Tsai , Maxime Ripard , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org From: Joerg Roedel A few compile warnings show up when building this driver: CC drivers/iommu/sun50i-iommu.o drivers/iommu/sun50i-iommu.c: In function ‘sun50i_dte_get_page_table’: drivers/iommu/sun50i-iommu.c:486:16: warning: unused variable ‘flags’ [-Wunused-variable] 486 | unsigned long flags; | ^~~~~ drivers/iommu/sun50i-iommu.c: In function ‘sun50i_iommu_unmap’: drivers/iommu/sun50i-iommu.c:559:23: warning: unused variable ‘iommu’ [-Wunused-variable] 559 | struct sun50i_iommu *iommu = sun50i_domain->iommu; | ^~~~~ drivers/iommu/sun50i-iommu.c: In function ‘sun50i_iommu_probe_device’: drivers/iommu/sun50i-iommu.c:749:22: warning: unused variable ‘group’ [-Wunused-variable] 749 | struct iommu_group *group; | ^~~~~ Remove the unused variables. Cc: Maxime Ripard Signed-off-by: Joerg Roedel --- drivers/iommu/sun50i-iommu.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/iommu/sun50i-iommu.c b/drivers/iommu/sun50i-iommu.c index 989d87aa4426..a52f52eff7c8 100644 --- a/drivers/iommu/sun50i-iommu.c +++ b/drivers/iommu/sun50i-iommu.c @@ -483,7 +483,6 @@ static u32 *sun50i_dte_get_page_table(struct sun50i_iommu_domain *sun50i_domain, dma_addr_t iova, gfp_t gfp) { struct sun50i_iommu *iommu = sun50i_domain->iommu; - unsigned long flags; u32 *page_table; u32 *dte_addr; u32 old_dte; @@ -556,7 +555,6 @@ static size_t sun50i_iommu_unmap(struct iommu_domain *domain, unsigned long iova size_t size, struct iommu_iotlb_gather *gather) { struct sun50i_iommu_domain *sun50i_domain = to_sun50i_domain(domain); - struct sun50i_iommu *iommu = sun50i_domain->iommu; phys_addr_t pt_phys; dma_addr_t pte_dma; u32 *pte_addr; @@ -746,7 +744,6 @@ static int sun50i_iommu_attach_device(struct iommu_domain *domain, static struct iommu_device *sun50i_iommu_probe_device(struct device *dev) { struct sun50i_iommu *iommu; - struct iommu_group *group; iommu = sun50i_iommu_from_dev(dev); if (!iommu)