pinctrl-vf610.c 1020 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. // SPDX-License-Identifier: GPL-2.0+
  2. /*
  3. * Copyright (C) 2018 DENX Software Engineering
  4. * Lukasz Majewski, DENX Software Engineering, lukma@denx.de
  5. */
  6. #include <common.h>
  7. #include <dm.h>
  8. #include <dm/pinctrl.h>
  9. #include "pinctrl-imx.h"
  10. static struct imx_pinctrl_soc_info vf610_pinctrl_soc_info = {
  11. .flags = SHARE_MUX_CONF_REG | ZERO_OFFSET_VALID,
  12. };
  13. static int vf610_pinctrl_probe(struct udevice *dev)
  14. {
  15. struct imx_pinctrl_soc_info *info =
  16. (struct imx_pinctrl_soc_info *)dev_get_driver_data(dev);
  17. return imx_pinctrl_probe(dev, info);
  18. }
  19. static const struct udevice_id vf610_pinctrl_match[] = {
  20. { .compatible = "fsl,vf610-iomuxc",
  21. .data = (ulong)&vf610_pinctrl_soc_info },
  22. { /* sentinel */ }
  23. };
  24. U_BOOT_DRIVER(vf610_pinctrl) = {
  25. .name = "vf610-pinctrl",
  26. .id = UCLASS_PINCTRL,
  27. .of_match = of_match_ptr(vf610_pinctrl_match),
  28. .probe = vf610_pinctrl_probe,
  29. .remove = imx_pinctrl_remove,
  30. .priv_auto_alloc_size = sizeof(struct imx_pinctrl_priv),
  31. .ops = &imx_pinctrl_ops,
  32. .flags = DM_FLAG_PRE_RELOC,
  33. };