summaryrefslogtreecommitdiff
path: root/drivers/memory
diff options
context:
space:
mode:
authorBartosz Golaszewski <bartosz.golaszewski@linaro.org>2024-08-09 16:15:54 +0200
committerKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>2024-08-12 12:32:10 +0200
commit8c38617722bdf57a90e6c77ed9ee5ebb60958d2a (patch)
treeace45a716904f3832894e87955d8d2bd30b86e93 /drivers/memory
parente3e4e77140b4a240865309cc543141a593be4a21 (diff)
downloadlwn-8c38617722bdf57a90e6c77ed9ee5ebb60958d2a.tar.gz
lwn-8c38617722bdf57a90e6c77ed9ee5ebb60958d2a.zip
memory: ti-aemif: remove platform data support
There are no longer any users of the ti-aemif driver that set up platform data from board files. We can shrink the driver by removing support for it. Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Link: https://lore.kernel.org/r/20240809-ti-aemif-v1-1-27b1e5001390@linaro.org Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Diffstat (limited to 'drivers/memory')
-rw-r--r--drivers/memory/ti-aemif.c25
1 files changed, 1 insertions, 24 deletions
diff --git a/drivers/memory/ti-aemif.c b/drivers/memory/ti-aemif.c
index e192db9e0e4b..b92cab455cbb 100644
--- a/drivers/memory/ti-aemif.c
+++ b/drivers/memory/ti-aemif.c
@@ -17,7 +17,6 @@
#include <linux/of.h>
#include <linux/of_platform.h>
#include <linux/platform_device.h>
-#include <linux/platform_data/ti-aemif.h>
#define TA_SHIFT 2
#define RHOLD_SHIFT 4
@@ -332,16 +331,11 @@ static int aemif_probe(struct platform_device *pdev)
struct device_node *np = dev->of_node;
struct device_node *child_np;
struct aemif_device *aemif;
- struct aemif_platform_data *pdata;
- struct of_dev_auxdata *dev_lookup;
aemif = devm_kzalloc(dev, sizeof(*aemif), GFP_KERNEL);
if (!aemif)
return -ENOMEM;
- pdata = dev_get_platdata(&pdev->dev);
- dev_lookup = pdata ? pdata->dev_lookup : NULL;
-
platform_set_drvdata(pdev, aemif);
aemif->clk = devm_clk_get(dev, NULL);
@@ -358,8 +352,6 @@ static int aemif_probe(struct platform_device *pdev)
if (np && of_device_is_compatible(np, "ti,da850-aemif"))
aemif->cs_offset = 2;
- else if (pdata)
- aemif->cs_offset = pdata->cs_offset;
aemif->base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(aemif->base)) {
@@ -381,11 +373,6 @@ static int aemif_probe(struct platform_device *pdev)
goto error;
}
}
- } else if (pdata && pdata->num_abus_data > 0) {
- for (i = 0; i < pdata->num_abus_data; i++, aemif->num_cs++) {
- aemif->cs_data[i].cs = pdata->abus_data[i].cs;
- aemif_get_hw_params(pdev, i);
- }
}
for (i = 0; i < aemif->num_cs; i++) {
@@ -403,22 +390,12 @@ static int aemif_probe(struct platform_device *pdev)
*/
if (np) {
for_each_available_child_of_node(np, child_np) {
- ret = of_platform_populate(child_np, NULL,
- dev_lookup, dev);
+ ret = of_platform_populate(child_np, NULL, NULL, dev);
if (ret < 0) {
of_node_put(child_np);
goto error;
}
}
- } else if (pdata) {
- for (i = 0; i < pdata->num_sub_devices; i++) {
- pdata->sub_devices[i].dev.parent = dev;
- ret = platform_device_register(&pdata->sub_devices[i]);
- if (ret) {
- dev_warn(dev, "Error register sub device %s\n",
- pdata->sub_devices[i].name);
- }
- }
}
return 0;