History

phy: Add HDMI configuration options

Allow HDMI PHYs to be configured through the generic functions through a custom structure added to the generic union. The parameters added here are based on HDMI PHY implementation practices. The current set of parameters should cover the potential users.

Sandor Yu committed 1 year ago

Commit 10ed34d1 parent dfc820d2 files · +25 −1Browse files

Unified · Split

2 files
  1. include/linux/phy/phy-hdmi.h +19 −0
  2. include/linux/phy/phy.h +6 −1
include/linux/phy/phy-hdmi.h+19−0
@@ -0,0 +1,19 @@
1/* SPDX-License-Identifier: GPL-2.0 */
2/*
3 * Copyright 2022,2024 NXP
4 */
5
6#ifndef __PHY_HDMI_H_
7#define __PHY_HDMI_H_
8
9/**
10 * struct phy_configure_opts_hdmi - HDMI configuration set
11 * @tmds_char_rate: HDMI TMDS Character Rate in Hertz.
12 *
13 * This structure is used to represent the configuration state of a HDMI phy.
14 */
15struct phy_configure_opts_hdmi {
16 unsigned long long tmds_char_rate;
17};
18
19#endif /* __PHY_HDMI_H_ */
include/linux/phy/phy.h+6−1
@@ -17,6 +17,7 @@ · 16 unmodified lines
17#include <linux/regulator/consumer.h>17#include <linux/regulator/consumer.h>
18 18
19#include <linux/phy/phy-dp.h>19#include <linux/phy/phy-dp.h>
20#include <linux/phy/phy-hdmi.h>
20#include <linux/phy/phy-lvds.h>21#include <linux/phy/phy-lvds.h>
21#include <linux/phy/phy-mipi-dphy.h>22#include <linux/phy/phy-mipi-dphy.h>
22 23
@@ -42,7 +43,8 @@ enum phy_mode { · 19 unmodified lines
42 PHY_MODE_MIPI_DPHY,43 PHY_MODE_MIPI_DPHY,
43 PHY_MODE_SATA,44 PHY_MODE_SATA,
44 PHY_MODE_LVDS,45 PHY_MODE_LVDS,
45 PHY_MODE_DP46 PHY_MODE_DP,
47 PHY_MODE_HDMI,
46};48};
47 49
48enum phy_media {50enum phy_media {
@@ -60,11 +62,14 @@ enum phy_media { · 11 unmodified lines
60 * the DisplayPort protocol.62 * the DisplayPort protocol.
61 * @lvds: Configuration set applicable for phys supporting63 * @lvds: Configuration set applicable for phys supporting
62 * the LVDS phy mode.64 * the LVDS phy mode.
65 * @hdmi: Configuration set applicable for phys supporting
66 * the HDMI phy mode.
63 */67 */
64union phy_configure_opts {68union phy_configure_opts {
65 struct phy_configure_opts_mipi_dphy mipi_dphy;69 struct phy_configure_opts_mipi_dphy mipi_dphy;
66 struct phy_configure_opts_dp dp;70 struct phy_configure_opts_dp dp;
67 struct phy_configure_opts_lvds lvds;71 struct phy_configure_opts_lvds lvds;
72 struct phy_configure_opts_hdmi hdmi;
68};73};
69 74
70/**75/**