From patchwork Thu Apr 28 13:18:09 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Murphy X-Patchwork-Id: 12830698 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 038E4C433EF for ; Thu, 28 Apr 2022 13:25:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: 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: List-Owner; bh=TaFYJNyPBkcEtfZnHe2lObvJRobUvCAOGniz5q9roNk=; b=uVmj+RE3gNcyR6 0WRU7h3wCgbvuV/Ke8HbgkeWwEuHVtkrI+u1D//mBZtfTrdEQKXX4NBCAAYBwoKzg62riZp8dO1X5 0pIrAKIxAvEdb3gjt3iVAKP9YK9yYxNtThuDG+g1oJPbhrF4HzW09NCB/V4FoWO5osLYhN2EJRHK7 7wsxcns1stuiQoza/rPSgVmCuEpBudoh9JIkYD8a9jqZoAfhwG3cktyzcm/pUlZ0dhK3eV2BiYs65 nu2J+Jt0udNHsfBJnxnOPHhZdDIlCVHBtlGF2JLqkZdElszzp6uXpR9H5HLyi1tfyvOQjC/A0+yFH 335OyRQY2eBDA8NrbdBQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nk48B-0070vn-Lg; Thu, 28 Apr 2022 13:24:28 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nk42g-006y0S-5C for linux-arm-kernel@lists.infradead.org; Thu, 28 Apr 2022 13:18:47 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 994FE1480; Thu, 28 Apr 2022 06:18:45 -0700 (PDT) Received: from e121345-lin.cambridge.arm.com (e121345-lin.cambridge.arm.com [10.1.196.40]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 8AF483F73B; Thu, 28 Apr 2022 06:18:43 -0700 (PDT) From: Robin Murphy To: joro@8bytes.org, will@kernel.org Subject: [PATCH v2 08/14] iommu/exynos: Clean up bus_set_iommu() Date: Thu, 28 Apr 2022 14:18:09 +0100 Message-Id: <9a92e01323e988eeea80655105db3f1fc4051362.1650890638.git.robin.murphy@arm.com> X-Mailer: git-send-email 2.35.3.dirty In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220428_061846_276896_0BA1C52E X-CRM114-Status: UNSURE ( 8.39 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jean-philippe@linaro.org, mjrosato@linux.ibm.com, sven@svenpeter.dev, zhang.lyra@gmail.com, robdclark@gmail.com, linux-kernel@vger.kernel.org, iommu@lists.linux-foundation.org, thierry.reding@gmail.com, linux-arm-kernel@lists.infradead.org, gerald.schaefer@linux.ibm.com, baolu.lu@linux.intel.com, yong.wu@mediatek.com, m.szyprowski@samsung.com Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Stop calling bus_set_iommu() since it's now unnecessary, and simplify the init failure path accordingly. Tested-by: Marek Szyprowski Signed-off-by: Robin Murphy --- drivers/iommu/exynos-iommu.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/drivers/iommu/exynos-iommu.c b/drivers/iommu/exynos-iommu.c index 71f2018e23fe..359b255b3924 100644 --- a/drivers/iommu/exynos-iommu.c +++ b/drivers/iommu/exynos-iommu.c @@ -1356,16 +1356,7 @@ static int __init exynos_iommu_init(void) goto err_zero_lv2; } - ret = bus_set_iommu(&platform_bus_type, &exynos_iommu_ops); - if (ret) { - pr_err("%s: Failed to register exynos-iommu driver.\n", - __func__); - goto err_set_iommu; - } - return 0; -err_set_iommu: - kmem_cache_free(lv2table_kmem_cache, zero_lv2_table); err_zero_lv2: platform_driver_unregister(&exynos_sysmmu_driver); err_reg_driver: