Received: by 2002:a05:6500:1b45:b0:1f5:f2ab:c469 with SMTP id cz5csp763196lqb; Wed, 17 Apr 2024 09:57:48 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXzG01p3L0rJC8GAwkBt8O0lyq0XPuDGdiAyrJwfqn8+grB6yEKn8EVyN/xbyQOLxEtqL9MD9EnuagoN6TnhennKtyk/f0xhEH5ElX+Qg== X-Google-Smtp-Source: AGHT+IFIAe2i6QX8n+S73PtBJpqYnE4ncT5H5Q9BDx2wJsfFtuQH/IovTuw2Z74jQw0NxdlPWQ/X X-Received: by 2002:a17:90a:9f97:b0:2a6:46af:8881 with SMTP id o23-20020a17090a9f9700b002a646af8881mr16434707pjp.15.1713373068627; Wed, 17 Apr 2024 09:57:48 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713373068; cv=pass; d=google.com; s=arc-20160816; b=PPgw0/8VvqQG8er3VTfj8VJiwfy8G2TEZiJZTf30Ld80dGOdmaCmbCRX6BboR2yP7j l8MlYe4RQ+X6VoOCvo2+3IeJkdOJg2nCbBFBqfDyuIqPlSbns9g4idFnKLbXXYFgwnLd 3PuNsve5WwtFaWzxUW9K3HXo2q5SNf2Iy4SZeajVmELMxm6+R7WnVoUR2iFRvkulRvmv eC1ZV7HKgeClQF4L+Ilsh3LKeXG9tkVgy2sXRe01uCYg2C2vtR0E7N5E9CFtjdVooi4K yyqG498937ifH3+MPVdJRvmB7xfyFlWhhmh33YsSEKwTTTsXBGLO3e+AQ+nHFn435l4m zfYA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=qwAWrhx8M72B4Ynsl0R5Yw8FEQwRflDYg9tB4o6qSJo=; fh=Oa7WDOAnB9UQhJx/enhYgrkQOAKa+3uP7pweq4d3Xks=; b=pCSi1ccxh+HFKpBXCX8YVzo0kbVD3mPURQmx9qijeFMqFWMlxq1IucCFg4D8yBMkRg r1+xWhLSvMP4lkom/kyR+O8Z7cVodKdkgBePm6Vf/aAy5HzuVfnhGVCG793feSSY4SoB f1qWeBwhtc69eoJqTyMIcXduz/iaIVOGntf91XRq3WRmoJA8eV+b/Hp1QDJ1UmR2Jo5g XXeg/mCMF/yUDSbfg8h84V4w+6voMDm+tH3OfnNQ5XY7L0MrZeRusHxZqyOtTbpBZzBT qwgDkDR3DmV6VzGhBEe/jHTotVy65yIjzfeF+R2IMzMMw0inSfWAUuK8kSezpOsuCF24 nxHQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=XvWzwf5I; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-148944-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-148944-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id p12-20020a17090b010c00b002a283b05fb3si1572792pjz.79.2024.04.17.09.57.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Apr 2024 09:57:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-148944-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=XvWzwf5I; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-148944-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-148944-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id C0997284EE0 for ; Wed, 17 Apr 2024 16:57:43 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AFD36171666; Wed, 17 Apr 2024 16:57:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="XvWzwf5I" Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6DA5B17107D; Wed, 17 Apr 2024 16:57:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.17 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713373038; cv=none; b=IjPWv+KjTzChhFXY81m/h0AFjj3woGZK/Jy3WotWpnCt2AoOxnUVHEtG++uUqesQw5EgkFIYWFqXW9hG9MU2CtbNPzwcvNpniZdEh+MtDoNsAyp5YmS/VQWxLKZq6RRdYF8b2vr3yQI+PilAVkTRF1dwxunxzeDOgEDRbLQG1hQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713373038; c=relaxed/simple; bh=EY0oW8gWzFx+UyQ5mI7eQESReZJaeFrBusZVAd3sm0g=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=CwBFbaqSPTTqe2Jp+RBrMQXIBTsK4cXMcBmzGiSCPeINYOuI4jpIb5l2OEOdNws4fVdhdnMGeK3C7EjUt6YTbAkj/fNLVh4BWEupqC9jyReuHYchKxsRT+5Ik4sWvYARqECGBLiA30tAZ45BupBfmZ6eEHCgClgYkbLyaxlpCZA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=XvWzwf5I; arc=none smtp.client-ip=192.198.163.17 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1713373038; x=1744909038; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=EY0oW8gWzFx+UyQ5mI7eQESReZJaeFrBusZVAd3sm0g=; b=XvWzwf5I9K4/KN9xVy0nLaCVDKtQM+5grCyoMPoCTToi39Oc9vCztft/ DrYMEWm1Nrw1XT4Ivnb4GHHVwPkqA/AQES+V9LYAAhQdiwQBSF87WFFn4 ygazXgy9YkWGL2OTZWUa8+1K6qBU9gCpn1MH2FQ1kEk6RJmElpNCFYxeP nKb3F4IzU+3Tmw45XS0q1rHA20NixlCHS8euPH1AaUouXg4dnvTKH2UsJ nRQoNJHi9AdCch6s7Y+jMPYX8zXz8wux2gr2oFUKw30k2qf27guZUwwtU QOOQ1DyO0QCrHF3I6mbvEXYT+vg9eGJRwQzKuc6JcZdCq09oV60OYgok8 w==; X-CSE-ConnectionGUID: FF9hUofhQRaaHP6HHtmR2w== X-CSE-MsgGUID: ZafO1nk8TJaLmTz/3lj1bQ== X-IronPort-AV: E=McAfee;i="6600,9927,11046"; a="8737012" X-IronPort-AV: E=Sophos;i="6.07,209,1708416000"; d="scan'208";a="8737012" Received: from orviesa010.jf.intel.com ([10.64.159.150]) by fmvoesa111.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Apr 2024 09:57:15 -0700 X-CSE-ConnectionGUID: U7LXLfYBRfqoKFFlXjA0RA== X-CSE-MsgGUID: KuzNvTAhTWiD4ahfD3nqEw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,209,1708416000"; d="scan'208";a="22571635" Received: from black.fi.intel.com ([10.237.72.28]) by orviesa010.jf.intel.com with ESMTP; 17 Apr 2024 09:57:13 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id 95DCA68; Wed, 17 Apr 2024 19:57:11 +0300 (EEST) From: Andy Shevchenko To: Andy Shevchenko , linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: Aubin Constans , Ulf Hansson , Nicolas Ferre , Alexandre Belloni , Claudiu Beznea Subject: [PATCH v1 1/5] mmc: atmel-mci: Get rid of platform data leftovers Date: Wed, 17 Apr 2024 19:55:13 +0300 Message-ID: <20240417165708.2965612-2-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.43.0.rc1.1336.g36b5255a03ac In-Reply-To: <20240417165708.2965612-1-andriy.shevchenko@linux.intel.com> References: <20240417165708.2965612-1-andriy.shevchenko@linux.intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit The commit d2c6d518c21d ("mmc: atmel-mci: move atmel MCI header file") made sure that there is no in-kernel user of the platform data. But at the same time it hadn't removed the code around that data structure. Finish the job here and remove a dead code. Fixes: d2c6d518c21d ("mmc: atmel-mci: move atmel MCI header file") Signed-off-by: Andy Shevchenko --- drivers/mmc/host/atmel-mci.c | 43 +++++------------------------------- 1 file changed, 6 insertions(+), 37 deletions(-) diff --git a/drivers/mmc/host/atmel-mci.c b/drivers/mmc/host/atmel-mci.c index dba826db739a..87c2855f64c2 100644 --- a/drivers/mmc/host/atmel-mci.c +++ b/drivers/mmc/host/atmel-mci.c @@ -226,13 +226,9 @@ struct mci_slot_pdata { /** * struct mci_platform_data - board-specific MMC/SDcard configuration - * @dma_slave: DMA slave interface to use in data transfers. - * @dma_filter: Filtering function to filter the DMA channel * @slot: Per-slot configuration data. */ struct mci_platform_data { - void *dma_slave; - dma_filter_fn dma_filter; struct mci_slot_pdata slot[ATMCI_MAX_NR_SLOTS]; }; @@ -626,7 +622,6 @@ static void atmci_init_debugfs(struct atmel_mci_slot *slot) &host->completed_events); } -#if defined(CONFIG_OF) static const struct of_device_id atmci_dt_ids[] = { { .compatible = "atmel,hsmci" }, { /* sentinel */ } @@ -700,13 +695,6 @@ atmci_of_init(struct platform_device *pdev) return pdata; } -#else /* CONFIG_OF */ -static inline struct mci_platform_data* -atmci_of_init(struct platform_device *dev) -{ - return ERR_PTR(-EINVAL); -} -#endif static inline unsigned int atmci_get_version(struct atmel_mci *host) { @@ -2388,23 +2376,6 @@ static void atmci_cleanup_slot(struct atmel_mci_slot *slot, static int atmci_configure_dma(struct atmel_mci *host) { host->dma.chan = dma_request_chan(&host->pdev->dev, "rxtx"); - - if (PTR_ERR(host->dma.chan) == -ENODEV) { - struct mci_platform_data *pdata = host->pdev->dev.platform_data; - dma_cap_mask_t mask; - - if (!pdata || !pdata->dma_filter) - return -ENODEV; - - dma_cap_zero(mask); - dma_cap_set(DMA_SLAVE, mask); - - host->dma.chan = dma_request_channel(mask, pdata->dma_filter, - pdata->dma_slave); - if (!host->dma.chan) - host->dma.chan = ERR_PTR(-ENODEV); - } - if (IS_ERR(host->dma.chan)) return PTR_ERR(host->dma.chan); @@ -2492,13 +2463,11 @@ static int atmci_probe(struct platform_device *pdev) regs = platform_get_resource(pdev, IORESOURCE_MEM, 0); if (!regs) return -ENXIO; - pdata = pdev->dev.platform_data; - if (!pdata) { - pdata = atmci_of_init(pdev); - if (IS_ERR(pdata)) { - dev_err(&pdev->dev, "platform data not available\n"); - return PTR_ERR(pdata); - } + + pdata = atmci_of_init(pdev); + if (IS_ERR(pdata)) { + dev_err(&pdev->dev, "platform data not available\n"); + return PTR_ERR(pdata); } irq = platform_get_irq(pdev, 0); @@ -2701,7 +2670,7 @@ static struct platform_driver atmci_driver = { .driver = { .name = "atmel_mci", .probe_type = PROBE_PREFER_ASYNCHRONOUS, - .of_match_table = of_match_ptr(atmci_dt_ids), + .of_match_table = atmci_dt_ids, .pm = &atmci_dev_pm_ops, }, }; -- 2.43.0.rc1.1336.g36b5255a03ac