exynos_hdmiphy.c 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. /*
  2. * Copyright (C) 2011 Samsung Electronics Co.Ltd
  3. * Authors:
  4. * Seung-Woo Kim <sw0312.kim@samsung.com>
  5. * Inki Dae <inki.dae@samsung.com>
  6. *
  7. * This program is free software; you can redistribute it and/or modify it
  8. * under the terms of the GNU General Public License as published by the
  9. * Free Software Foundation; either version 2 of the License, or (at your
  10. * option) any later version.
  11. *
  12. */
  13. #include <drm/drmP.h>
  14. #include <linux/kernel.h>
  15. #include <linux/i2c.h>
  16. #include "exynos_drm_drv.h"
  17. #include "exynos_hdmi.h"
  18. static int hdmiphy_probe(struct i2c_client *client,
  19. const struct i2c_device_id *id)
  20. {
  21. hdmi_attach_hdmiphy_client(client);
  22. dev_info(&client->adapter->dev, "attached s5p_hdmiphy "
  23. "into i2c adapter successfully\n");
  24. return 0;
  25. }
  26. static int hdmiphy_remove(struct i2c_client *client)
  27. {
  28. dev_info(&client->adapter->dev, "detached s5p_hdmiphy "
  29. "from i2c adapter successfully\n");
  30. return 0;
  31. }
  32. static const struct i2c_device_id hdmiphy_id[] = {
  33. { "s5p_hdmiphy", 0 },
  34. { "exynos5-hdmiphy", 0 },
  35. { },
  36. };
  37. #ifdef CONFIG_OF
  38. static struct of_device_id hdmiphy_match_types[] = {
  39. {
  40. .compatible = "samsung,exynos5-hdmiphy",
  41. }, {
  42. .compatible = "samsung,exynos4210-hdmiphy",
  43. }, {
  44. .compatible = "samsung,exynos4212-hdmiphy",
  45. }, {
  46. /* end node */
  47. }
  48. };
  49. #endif
  50. struct i2c_driver hdmiphy_driver = {
  51. .driver = {
  52. .name = "exynos-hdmiphy",
  53. .owner = THIS_MODULE,
  54. .of_match_table = of_match_ptr(hdmiphy_match_types),
  55. },
  56. .id_table = hdmiphy_id,
  57. .probe = hdmiphy_probe,
  58. .remove = hdmiphy_remove,
  59. .command = NULL,
  60. };
  61. EXPORT_SYMBOL(hdmiphy_driver);