Lines Matching refs:phy

23 struct phy;
57 int (*init)(struct phy *phy);
58 int (*exit)(struct phy *phy);
59 int (*power_on)(struct phy *phy);
60 int (*power_off)(struct phy *phy);
61 int (*set_mode)(struct phy *phy, enum phy_mode mode);
62 int (*reset)(struct phy *phy);
63 int (*calibrate)(struct phy *phy);
88 struct phy { struct
112 struct phy * (*of_xlate)(struct device *dev,
127 struct phy *phy; member
130 #define to_phy(a) (container_of((a), struct phy, dev))
144 static inline void phy_set_drvdata(struct phy *phy, void *data) in phy_set_drvdata() argument
146 dev_set_drvdata(&phy->dev, data); in phy_set_drvdata()
149 static inline void *phy_get_drvdata(struct phy *phy) in phy_get_drvdata() argument
151 return dev_get_drvdata(&phy->dev); in phy_get_drvdata()
155 int phy_pm_runtime_get(struct phy *phy);
156 int phy_pm_runtime_get_sync(struct phy *phy);
157 int phy_pm_runtime_put(struct phy *phy);
158 int phy_pm_runtime_put_sync(struct phy *phy);
159 void phy_pm_runtime_allow(struct phy *phy);
160 void phy_pm_runtime_forbid(struct phy *phy);
161 int phy_init(struct phy *phy);
162 int phy_exit(struct phy *phy);
163 int phy_power_on(struct phy *phy);
164 int phy_power_off(struct phy *phy);
165 int phy_set_mode(struct phy *phy, enum phy_mode mode);
166 static inline enum phy_mode phy_get_mode(struct phy *phy) in phy_get_mode() argument
168 return phy->attrs.mode; in phy_get_mode()
170 int phy_reset(struct phy *phy);
171 int phy_calibrate(struct phy *phy);
172 static inline int phy_get_bus_width(struct phy *phy) in phy_get_bus_width() argument
174 return phy->attrs.bus_width; in phy_get_bus_width()
176 static inline void phy_set_bus_width(struct phy *phy, int bus_width) in phy_set_bus_width() argument
178 phy->attrs.bus_width = bus_width; in phy_set_bus_width()
180 struct phy *phy_get(struct device *dev, const char *string);
181 struct phy *phy_optional_get(struct device *dev, const char *string);
182 struct phy *devm_phy_get(struct device *dev, const char *string);
183 struct phy *devm_phy_optional_get(struct device *dev, const char *string);
184 struct phy *devm_of_phy_get(struct device *dev, struct device_node *np,
186 struct phy *devm_of_phy_get_by_index(struct device *dev, struct device_node *np,
188 void phy_put(struct phy *phy);
189 void devm_phy_put(struct device *dev, struct phy *phy);
190 struct phy *of_phy_get(struct device_node *np, const char *con_id);
191 struct phy *of_phy_simple_xlate(struct device *dev,
193 struct phy *phy_create(struct device *dev, struct device_node *node,
195 struct phy *devm_phy_create(struct device *dev, struct device_node *node,
197 void phy_destroy(struct phy *phy);
198 void devm_phy_destroy(struct device *dev, struct phy *phy);
201 struct phy * (*of_xlate)(struct device *dev,
205 struct phy * (*of_xlate)(struct device *dev,
210 int phy_create_lookup(struct phy *phy, const char *con_id, const char *dev_id);
211 void phy_remove_lookup(struct phy *phy, const char *con_id, const char *dev_id);
213 static inline int phy_pm_runtime_get(struct phy *phy) in phy_pm_runtime_get() argument
215 if (!phy) in phy_pm_runtime_get()
220 static inline int phy_pm_runtime_get_sync(struct phy *phy) in phy_pm_runtime_get_sync() argument
222 if (!phy) in phy_pm_runtime_get_sync()
227 static inline int phy_pm_runtime_put(struct phy *phy) in phy_pm_runtime_put() argument
229 if (!phy) in phy_pm_runtime_put()
234 static inline int phy_pm_runtime_put_sync(struct phy *phy) in phy_pm_runtime_put_sync() argument
236 if (!phy) in phy_pm_runtime_put_sync()
241 static inline void phy_pm_runtime_allow(struct phy *phy) in phy_pm_runtime_allow() argument
246 static inline void phy_pm_runtime_forbid(struct phy *phy) in phy_pm_runtime_forbid() argument
251 static inline int phy_init(struct phy *phy) in phy_init() argument
253 if (!phy) in phy_init()
258 static inline int phy_exit(struct phy *phy) in phy_exit() argument
260 if (!phy) in phy_exit()
265 static inline int phy_power_on(struct phy *phy) in phy_power_on() argument
267 if (!phy) in phy_power_on()
272 static inline int phy_power_off(struct phy *phy) in phy_power_off() argument
274 if (!phy) in phy_power_off()
279 static inline int phy_set_mode(struct phy *phy, enum phy_mode mode) in phy_set_mode() argument
281 if (!phy) in phy_set_mode()
286 static inline enum phy_mode phy_get_mode(struct phy *phy) in phy_get_mode() argument
291 static inline int phy_reset(struct phy *phy) in phy_reset() argument
293 if (!phy) in phy_reset()
298 static inline int phy_calibrate(struct phy *phy) in phy_calibrate() argument
300 if (!phy) in phy_calibrate()
305 static inline int phy_get_bus_width(struct phy *phy) in phy_get_bus_width() argument
310 static inline void phy_set_bus_width(struct phy *phy, int bus_width) in phy_set_bus_width() argument
315 static inline struct phy *phy_get(struct device *dev, const char *string) in phy_get()
320 static inline struct phy *phy_optional_get(struct device *dev, in phy_optional_get()
326 static inline struct phy *devm_phy_get(struct device *dev, const char *string) in devm_phy_get()
331 static inline struct phy *devm_phy_optional_get(struct device *dev, in devm_phy_optional_get()
337 static inline struct phy *devm_of_phy_get(struct device *dev, in devm_of_phy_get()
344 static inline struct phy *devm_of_phy_get_by_index(struct device *dev, in devm_of_phy_get_by_index()
351 static inline void phy_put(struct phy *phy) in phy_put() argument
355 static inline void devm_phy_put(struct device *dev, struct phy *phy) in devm_phy_put() argument
359 static inline struct phy *of_phy_get(struct device_node *np, const char *con_id) in of_phy_get()
364 static inline struct phy *of_phy_simple_xlate(struct device *dev, in of_phy_simple_xlate()
370 static inline struct phy *phy_create(struct device *dev, in phy_create()
377 static inline struct phy *devm_phy_create(struct device *dev, in devm_phy_create()
384 static inline void phy_destroy(struct phy *phy) in phy_destroy() argument
388 static inline void devm_phy_destroy(struct device *dev, struct phy *phy) in devm_phy_destroy() argument
394 struct phy * (*of_xlate)(struct device *dev, in __of_phy_provider_register()
402 struct phy * (*of_xlate)(struct device *dev, in __devm_of_phy_provider_register()
417 phy_create_lookup(struct phy *phy, const char *con_id, const char *dev_id) in phy_create_lookup() argument
421 static inline void phy_remove_lookup(struct phy *phy, const char *con_id, in phy_remove_lookup() argument