mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Rosen Penev <rosenp@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Krzysztof Kozlowski <krzk@kernel.org>
Subject: [PATCHv2 4/4] memory: fsl_ifc: drop simple-bus emulation
Date: Tue, 21 Jul 2026 13:24:49 -0700	[thread overview]
Message-ID: <20260721202450.485171-5-rosenp@gmail.com> (raw)
In-Reply-To: <20260721202450.485171-1-rosenp@gmail.com>

of_platform_default_populate() in fsl_ifc_ctrl_probe() was a workaround
for legacy device trees that lacked "simple-bus" on the IFC node.
Commit 103478597591 ("powerpc/85xx: Add fsl,ifc to common device ids")
ensures the IFC node is populated as a platform device via
of_platform_bus_probe(), so the driver no longer needs to manually
populate its children -- they are handled by their own dedicated
drivers (NAND, NOR, etc.) matching on their own compatibles.

Drop the of_platform_default_populate() call and the corresponding
of_platform_depopulate() in fsl_ifc_ctrl_remove(), which is now dead
code and can be removed entirely.

Assisted-by: opencode:big-pickle
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
 drivers/memory/fsl_ifc.c | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/drivers/memory/fsl_ifc.c b/drivers/memory/fsl_ifc.c
index 7fea6a356b55..c591b89a1dd4 100644
--- a/drivers/memory/fsl_ifc.c
+++ b/drivers/memory/fsl_ifc.c
@@ -15,7 +15,6 @@
 #include <linux/slab.h>
 #include <linux/io.h>
 #include <linux/of.h>
-#include <linux/of_platform.h>
 #include <linux/platform_device.h>
 #include <linux/fsl_ifc.h>
 #include <linux/irqdomain.h>
@@ -84,11 +83,6 @@ static int fsl_ifc_ctrl_init(struct fsl_ifc_ctrl *ctrl)
 	return 0;
 }
 
-static void fsl_ifc_ctrl_remove(struct platform_device *dev)
-{
-	of_platform_depopulate(&dev->dev);
-}
-
 /*
  * NAND events are split between an operational interrupt which only
  * receives OPC, and an error interrupt that receives everything else,
@@ -270,8 +264,7 @@ static int fsl_ifc_ctrl_probe(struct platform_device *dev)
 			return ret;
 	}
 
-	/* legacy dts may still use "simple-bus" compatible */
-	return of_platform_default_populate(dev->dev.of_node, NULL, &dev->dev);
+	return 0;
 }
 
 static const struct of_device_id fsl_ifc_match[] = {
@@ -287,7 +280,6 @@ static struct platform_driver fsl_ifc_ctrl_driver = {
 		.of_match_table = fsl_ifc_match,
 	},
 	.probe       = fsl_ifc_ctrl_probe,
-	.remove  = fsl_ifc_ctrl_remove,
 };
 
 static int __init fsl_ifc_init(void)
-- 
2.55.0


      parent reply	other threads:[~2026-07-21 20:24 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-21 20:24 [PATCHv2 0/4] memory: fsl_ifc: Switch to modern devm and platform IRQ APIs Rosen Penev
2026-07-21 20:24 ` [PATCHv2 1/4] memory: fsl_ifc: Fix optional NAND IRQ handling and migrate to platform IRQ API Rosen Penev
2026-07-21 20:24 ` [PATCHv2 2/4] memory: fsl_ifc: Use devm_platform_ioremap_resource and fix error paths Rosen Penev
2026-07-21 20:24 ` [PATCHv2 3/4] memory: fsl_ifc: Use devm_request_irq and simplify remove Rosen Penev
2026-07-21 20:24 ` Rosen Penev [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260721202450.485171-5-rosenp@gmail.com \
    --to=rosenp@gmail.com \
    --cc=krzk@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®