diff options
Diffstat (limited to 'drivers/pinctrl/imx-iomux-v3.c')
-rw-r--r-- | drivers/pinctrl/imx-iomux-v3.c | 31 |
1 files changed, 12 insertions, 19 deletions
diff --git a/drivers/pinctrl/imx-iomux-v3.c b/drivers/pinctrl/imx-iomux-v3.c index fb2b348883..673674c1dc 100644 --- a/drivers/pinctrl/imx-iomux-v3.c +++ b/drivers/pinctrl/imx-iomux-v3.c @@ -1,17 +1,8 @@ +// SPDX-License-Identifier: GPL-2.0-only /* * imx-iomux-v3.c - i.MX iomux-v3 pinctrl support * * Copyright (c) 2013 Sascha Hauer <s.hauer@pengutronix.de> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 - * as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * */ #include <common.h> @@ -20,8 +11,8 @@ #include <of.h> #include <pinctrl.h> #include <malloc.h> -#include <mach/iomux-v3.h> -#include <mach/generic.h> +#include <mach/imx/iomux-v3.h> +#include <mach/imx/generic.h> struct imx_iomux_v3 { void __iomem *base; @@ -86,7 +77,7 @@ static int imx_iomux_v3_set_state(struct pinctrl_device *pdev, struct device_nod const char *name; u32 share_conf_val = 0; - dev_dbg(iomux->pinctrl.dev, "set state: %s\n", np->full_name); + dev_dbg(iomux->pinctrl.dev, "set state: %pOF\n", np); if (share_conf) { u32 drive_strength, slew_rate; @@ -129,8 +120,7 @@ static int imx_iomux_v3_set_state(struct pinctrl_device *pdev, struct device_nod return -EINVAL; if (!size || size % fsl_pin_size) { - dev_err(iomux->pinctrl.dev, "Invalid fsl,pins property in %s\n", - np->full_name); + dev_err(iomux->pinctrl.dev, "Invalid fsl,pins property in %pOF\n", np); return -EINVAL; } @@ -165,7 +155,7 @@ static struct pinctrl_ops imx_iomux_v3_ops = { .set_state = imx_iomux_v3_set_state, }; -static int imx_pinctrl_dt(struct device_d *dev, void __iomem *base) +static int imx_pinctrl_dt(struct device *dev, void __iomem *base) { struct imx_iomux_v3 *iomux; const struct imx_iomux_v3_data *drvdata; @@ -188,7 +178,7 @@ static int imx_pinctrl_dt(struct device_d *dev, void __iomem *base) return ret; } -static int imx_iomux_v3_probe(struct device_d *dev) +static int imx_iomux_v3_probe(struct device *dev) { void __iomem *base; struct resource *iores; @@ -207,7 +197,7 @@ static int imx_iomux_v3_probe(struct device_d *dev) */ iomuxv3_base = base; - if (IS_ENABLED(CONFIG_PINCTRL) && dev->device_node) + if (IS_ENABLED(CONFIG_PINCTRL) && dev->of_node) ret = imx_pinctrl_dt(dev, base); return ret; @@ -257,11 +247,14 @@ static __maybe_unused struct of_device_id imx_iomux_v3_dt_ids[] = { }, { .compatible = "fsl,imx8mq-iomuxc", }, { + .compatible = "fsl,imx93-iomuxc", + }, { /* sentinel */ } }; +MODULE_DEVICE_TABLE(of, imx_iomux_v3_dt_ids); -static struct driver_d imx_iomux_v3_driver = { +static struct driver imx_iomux_v3_driver = { .name = "imx-iomuxv3", .probe = imx_iomux_v3_probe, .of_compatible = DRV_OF_COMPAT(imx_iomux_v3_dt_ids), |