linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mmc: sdhci-of-arasan: Add shutdown callback
@ 2025-05-22  9:49 Paul Alvin
  2025-05-22 12:53 ` Adrian Hunter
  2025-05-23  8:21 ` kernel test robot
  0 siblings, 2 replies; 3+ messages in thread
From: Paul Alvin @ 2025-05-22  9:49 UTC (permalink / raw)
  To: michal.simek, adrian.hunter, ulf.hansson
  Cc: git, alvin.paulp, linux-arm-kernel, linux-mmc, linux-kernel

Implement shutdown hook to suspend host, power off PHY if enabled and
disable all mmc clocks.

Signed-off-by: Paul Alvin <alvin.paulp@amd.com>
---
 drivers/mmc/host/sdhci-of-arasan.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/mmc/host/sdhci-of-arasan.c b/drivers/mmc/host/sdhci-of-arasan.c
index 8c29676ab662..af4643e24ecc 100644
--- a/drivers/mmc/host/sdhci-of-arasan.c
+++ b/drivers/mmc/host/sdhci-of-arasan.c
@@ -2056,6 +2056,13 @@ static void sdhci_arasan_remove(struct platform_device *pdev)
 	clk_disable_unprepare(clk_ahb);
 }
 
+static void sdhci_arasan_shutdown(struct platform_device *pdev)
+{
+	struct device *dev = &pdev->dev;
+
+	sdhci_arasan_suspend(dev);
+}
+
 static struct platform_driver sdhci_arasan_driver = {
 	.driver = {
 		.name = "sdhci-arasan",
@@ -2065,6 +2072,7 @@ static struct platform_driver sdhci_arasan_driver = {
 	},
 	.probe = sdhci_arasan_probe,
 	.remove = sdhci_arasan_remove,
+	.shutdown = sdhci_arasan_shutdown,
 };
 
 module_platform_driver(sdhci_arasan_driver);
-- 
2.25.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] mmc: sdhci-of-arasan: Add shutdown callback
  2025-05-22  9:49 [PATCH] mmc: sdhci-of-arasan: Add shutdown callback Paul Alvin
@ 2025-05-22 12:53 ` Adrian Hunter
  2025-05-23  8:21 ` kernel test robot
  1 sibling, 0 replies; 3+ messages in thread
From: Adrian Hunter @ 2025-05-22 12:53 UTC (permalink / raw)
  To: Paul Alvin, michal.simek, ulf.hansson
  Cc: git, linux-arm-kernel, linux-mmc, linux-kernel

On 22/05/2025 12:49, Paul Alvin wrote:
> Implement shutdown hook to suspend host, power off PHY if enabled and
> disable all mmc clocks.

Please extend commit message to say why you want to do that.

> 
> Signed-off-by: Paul Alvin <alvin.paulp@amd.com>
> ---
>  drivers/mmc/host/sdhci-of-arasan.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/drivers/mmc/host/sdhci-of-arasan.c b/drivers/mmc/host/sdhci-of-arasan.c
> index 8c29676ab662..af4643e24ecc 100644
> --- a/drivers/mmc/host/sdhci-of-arasan.c
> +++ b/drivers/mmc/host/sdhci-of-arasan.c
> @@ -2056,6 +2056,13 @@ static void sdhci_arasan_remove(struct platform_device *pdev)
>  	clk_disable_unprepare(clk_ahb);
>  }
>  
> +static void sdhci_arasan_shutdown(struct platform_device *pdev)
> +{
> +	struct device *dev = &pdev->dev;
> +
> +	sdhci_arasan_suspend(dev);
> +}
> +
>  static struct platform_driver sdhci_arasan_driver = {
>  	.driver = {
>  		.name = "sdhci-arasan",
> @@ -2065,6 +2072,7 @@ static struct platform_driver sdhci_arasan_driver = {
>  	},
>  	.probe = sdhci_arasan_probe,
>  	.remove = sdhci_arasan_remove,
> +	.shutdown = sdhci_arasan_shutdown,
>  };
>  
>  module_platform_driver(sdhci_arasan_driver);



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] mmc: sdhci-of-arasan: Add shutdown callback
  2025-05-22  9:49 [PATCH] mmc: sdhci-of-arasan: Add shutdown callback Paul Alvin
  2025-05-22 12:53 ` Adrian Hunter
@ 2025-05-23  8:21 ` kernel test robot
  1 sibling, 0 replies; 3+ messages in thread
From: kernel test robot @ 2025-05-23  8:21 UTC (permalink / raw)
  To: Paul Alvin, michal.simek, adrian.hunter, ulf.hansson
  Cc: llvm, oe-kbuild-all, git, alvin.paulp, linux-arm-kernel,
	linux-mmc, linux-kernel

Hi Paul,

kernel test robot noticed the following build errors:

[auto build test ERROR on v6.15-rc7]
[also build test ERROR on linus/master next-20250522]
[cannot apply to xilinx-xlnx/master]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Paul-Alvin/mmc-sdhci-of-arasan-Add-shutdown-callback/20250522-175110
base:   v6.15-rc7
patch link:    https://lore.kernel.org/r/20250522094932.4187301-1-alvin.paulp%40amd.com
patch subject: [PATCH] mmc: sdhci-of-arasan: Add shutdown callback
config: arm64-randconfig-002-20250523 (https://download.01.org/0day-ci/archive/20250523/202505231550.RaoPUrmq-lkp@intel.com/config)
compiler: clang version 16.0.6 (https://github.com/llvm/llvm-project 7cbf1a2591520c2491aa35339f227775f4d3adf6)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250523/202505231550.RaoPUrmq-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202505231550.RaoPUrmq-lkp@intel.com/

All errors (new ones prefixed by >>):

>> drivers/mmc/host/sdhci-of-arasan.c:2063:2: error: call to undeclared function 'sdhci_arasan_suspend'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
           sdhci_arasan_suspend(dev);
           ^
   1 error generated.


vim +/sdhci_arasan_suspend +2063 drivers/mmc/host/sdhci-of-arasan.c

  2058	
  2059	static void sdhci_arasan_shutdown(struct platform_device *pdev)
  2060	{
  2061		struct device *dev = &pdev->dev;
  2062	
> 2063		sdhci_arasan_suspend(dev);
  2064	}
  2065	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-05-23  8:45 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-22  9:49 [PATCH] mmc: sdhci-of-arasan: Add shutdown callback Paul Alvin
2025-05-22 12:53 ` Adrian Hunter
2025-05-23  8:21 ` kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).