From patchwork Wed Oct 19 15:29:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 5717 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp398125wrs; Wed, 19 Oct 2022 08:49:01 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5UMvQbzR+1tHxf1L9xQdTmFUCNPmXpCvbXtGgoYpn1Zqy1gKLPUN55tZkxJg1Wcs8bzl3j X-Received: by 2002:a17:902:d14d:b0:185:31b5:808f with SMTP id t13-20020a170902d14d00b0018531b5808fmr9355669plt.36.1666194530579; Wed, 19 Oct 2022 08:48:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666194530; cv=none; d=google.com; s=arc-20160816; b=TEcKQn6n3mx4jMyiPmSL5ou9rShcmZP+1hgIhN8mBo9FF4RaFBgkyXus5q1OmldNgV bfQkNHGN0lHnL9ezaQsk6RvjArzBj/kHDlepKhU2xBQ5YUlSHLsT7yjaBIrAkpkDmsXX 7MVkWBqJ5HzhFDyoNCONvJoXZEnfatMQmVTn5u9bZtqjKRoGC9A56LGM7HZ+5GdqgdfI /7t23zWRfS8ZS21dYNLkOrEfuxgng8/VC3XULXcFvYBY7P2ugBlx4uzhbn+JvahJbPP/ hk2qpV+JIUMPdpq943ueDRg9mTaMph7DrMjGoajpHF2WQwYjfXq5VYi3f06GOe1geF9c TFdw== 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 :dkim-signature; bh=Dxtpll6mxyUjoKvcWho1Ii8bX+ye1tJ7YiCI/pOWXZA=; b=p1hgZ3AKJtGdMyORP42WXd/yt8rmfpyFBIcQfNMXWj9ZAlFGOGhfymEWbPeX9LyChQ POZIDxPxLARTHfdWxTmKvWz5N4/XkrobAqlDz1f+gIS5bZJgYfFlUAYLVY0lZyfjzZXM vSYn/lvwJQaS/lbVys2LGu46wYJjKBrdyzZwAH6HYWuCYcay/4zgOlo8WmKsg5i4dU3m OwVRRlTvgyIUEWqK/j0MnpV1pKMlbLTnnRreRbdmdyI0U42Rw3Qn21k4GyvFcvBOU3Xd OWG70Fh/fh0AWR2joo/Sg7d7JzYUtyrL6Tk8ZFSuKPVJkoji8LRcwb2Gv2LeDVo8L4tp Bw1w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="K6/PnkUS"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v190-20020a6389c7000000b0044c7a49befesi15712984pgd.258.2022.10.19.08.48.35; Wed, 19 Oct 2022 08:48:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="K6/PnkUS"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232582AbiJSPnr (ORCPT + 99 others); Wed, 19 Oct 2022 11:43:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51656 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231363AbiJSPnN (ORCPT ); Wed, 19 Oct 2022 11:43:13 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7E76F27DC1 for ; Wed, 19 Oct 2022 08:38:50 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id CFF1061908 for ; Wed, 19 Oct 2022 15:37:32 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4841BC433D6; Wed, 19 Oct 2022 15:37:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1666193852; bh=0Pt8ZEBcDFoM+kJKswCp3Alo0JKy8gPb9ihepHTIFqw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=K6/PnkUSuDkr0Us354pM/N4EBjSCHkV15kkVl//aq3vvlnYalb1JAoWZ6+h2+52XQ ljiD2oSQxLA9u8n4D2ScDbDYOCFLTXDvuJ+UDdjjyyRbgmY1bH9IWcvf1R0RJ0B8c7 EuTL/tDag/30cd4OZjomdeO9FR/Z1Hri3OfTS70HYl6HGuFuSC6JVdDIkoA8w5RiJ2 eatvOiGUHZuylTuMwQXg7EN+HWNICe82G2SD44CLxJFxk0MUKdAy1VNjgtz8RCcBFP ZBrEcwHrGSZivH3EA3pI4FyPYJxFR02dZfAtO6+8BJQRsIF2EIOQFqy97JhrbvoKJD Zzragzg5cOVjQ== From: Arnd Bergmann To: Sekhar Nori , Bartosz Golaszewski , linux-arm-kernel@lists.infradead.org, Lee Jones Cc: linux-kernel@vger.kernel.org, Kevin Hilman , Arnd Bergmann , Hans de Goede , Andy Shevchenko Subject: [PATCH 10/14] mfd: remove davinci voicecodec driver Date: Wed, 19 Oct 2022 17:29:36 +0200 Message-Id: <20221019152947.3857217-11-arnd@kernel.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20221019152947.3857217-1-arnd@kernel.org> References: <20221019152947.3857217-1-arnd@kernel.org> MIME-Version: 1.0 X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747131596167636711?= X-GMAIL-MSGID: =?utf-8?q?1747131596167636711?= From: Arnd Bergmann The ASoC davinci voicecodec support is no longer used after the removal of the dm3xx SoC platform, so the MFD driver is never selected. Signed-off-by: Arnd Bergmann Acked-by: Bartosz Golaszewski --- drivers/mfd/Kconfig | 5 -- drivers/mfd/Makefile | 2 - drivers/mfd/davinci_voicecodec.c | 136 ------------------------------- 3 files changed, 143 deletions(-) delete mode 100644 drivers/mfd/davinci_voicecodec.c diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig index 31751cd3c4ed..e05474ba687c 100644 --- a/drivers/mfd/Kconfig +++ b/drivers/mfd/Kconfig @@ -1423,11 +1423,6 @@ config MFD_SYSCON Select this option to enable accessing system control registers via regmap. -config MFD_DAVINCI_VOICECODEC - tristate - select MFD_CORE - select REGMAP_MMIO - config MFD_TI_AM335X_TSCADC tristate "TI ADC / Touch Screen chip support" select MFD_CORE diff --git a/drivers/mfd/Makefile b/drivers/mfd/Makefile index a3a304f8c762..38d9bf03c249 100644 --- a/drivers/mfd/Makefile +++ b/drivers/mfd/Makefile @@ -22,8 +22,6 @@ obj-$(CONFIG_HTC_PASIC3) += htc-pasic3.o obj-$(CONFIG_MFD_TI_LP873X) += lp873x.o obj-$(CONFIG_MFD_TI_LP87565) += lp87565.o - -obj-$(CONFIG_MFD_DAVINCI_VOICECODEC) += davinci_voicecodec.o obj-$(CONFIG_MFD_TI_AM335X_TSCADC) += ti_am335x_tscadc.o obj-$(CONFIG_MFD_STA2X11) += sta2x11-mfd.o diff --git a/drivers/mfd/davinci_voicecodec.c b/drivers/mfd/davinci_voicecodec.c deleted file mode 100644 index 965820481f1e..000000000000 --- a/drivers/mfd/davinci_voicecodec.c +++ /dev/null @@ -1,136 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0-or-later -/* - * DaVinci Voice Codec Core Interface for TI platforms - * - * Copyright (C) 2010 Texas Instruments, Inc - * - * Author: Miguel Aguilar - */ - -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -#include - -static const struct regmap_config davinci_vc_regmap = { - .reg_bits = 32, - .val_bits = 32, -}; - -static int __init davinci_vc_probe(struct platform_device *pdev) -{ - struct davinci_vc *davinci_vc; - struct resource *res; - struct mfd_cell *cell = NULL; - dma_addr_t fifo_base; - int ret; - - davinci_vc = devm_kzalloc(&pdev->dev, - sizeof(struct davinci_vc), GFP_KERNEL); - if (!davinci_vc) - return -ENOMEM; - - davinci_vc->clk = devm_clk_get(&pdev->dev, NULL); - if (IS_ERR(davinci_vc->clk)) { - dev_dbg(&pdev->dev, - "could not get the clock for voice codec\n"); - return -ENODEV; - } - clk_enable(davinci_vc->clk); - - davinci_vc->base = devm_platform_get_and_ioremap_resource(pdev, 0, &res); - if (IS_ERR(davinci_vc->base)) { - ret = PTR_ERR(davinci_vc->base); - goto fail; - } - fifo_base = (dma_addr_t)res->start; - - davinci_vc->regmap = devm_regmap_init_mmio(&pdev->dev, - davinci_vc->base, - &davinci_vc_regmap); - if (IS_ERR(davinci_vc->regmap)) { - ret = PTR_ERR(davinci_vc->regmap); - goto fail; - } - - res = platform_get_resource(pdev, IORESOURCE_DMA, 0); - if (!res) { - dev_err(&pdev->dev, "no DMA resource\n"); - ret = -ENXIO; - goto fail; - } - - davinci_vc->davinci_vcif.dma_tx_channel = res->start; - davinci_vc->davinci_vcif.dma_tx_addr = fifo_base + DAVINCI_VC_WFIFO; - - res = platform_get_resource(pdev, IORESOURCE_DMA, 1); - if (!res) { - dev_err(&pdev->dev, "no DMA resource\n"); - ret = -ENXIO; - goto fail; - } - - davinci_vc->davinci_vcif.dma_rx_channel = res->start; - davinci_vc->davinci_vcif.dma_rx_addr = fifo_base + DAVINCI_VC_RFIFO; - - davinci_vc->dev = &pdev->dev; - davinci_vc->pdev = pdev; - - /* Voice codec interface client */ - cell = &davinci_vc->cells[DAVINCI_VC_VCIF_CELL]; - cell->name = "davinci-vcif"; - cell->platform_data = davinci_vc; - cell->pdata_size = sizeof(*davinci_vc); - - /* Voice codec CQ93VC client */ - cell = &davinci_vc->cells[DAVINCI_VC_CQ93VC_CELL]; - cell->name = "cq93vc-codec"; - cell->platform_data = davinci_vc; - cell->pdata_size = sizeof(*davinci_vc); - - ret = mfd_add_devices(&pdev->dev, pdev->id, davinci_vc->cells, - DAVINCI_VC_CELLS, NULL, 0, NULL); - if (ret != 0) { - dev_err(&pdev->dev, "fail to register client devices\n"); - goto fail; - } - - return 0; - -fail: - clk_disable(davinci_vc->clk); - - return ret; -} - -static int davinci_vc_remove(struct platform_device *pdev) -{ - struct davinci_vc *davinci_vc = platform_get_drvdata(pdev); - - mfd_remove_devices(&pdev->dev); - - clk_disable(davinci_vc->clk); - - return 0; -} - -static struct platform_driver davinci_vc_driver = { - .driver = { - .name = "davinci_voicecodec", - }, - .remove = davinci_vc_remove, -}; - -module_platform_driver_probe(davinci_vc_driver, davinci_vc_probe); - -MODULE_AUTHOR("Miguel Aguilar"); -MODULE_DESCRIPTION("Texas Instruments DaVinci Voice Codec Core Interface"); -MODULE_LICENSE("GPL");