blob: 15032f1450631fb5a30cf36863f1b8b48f8fc033 [file] [log] [blame]
Thomas Gleixner2874c5f2019-05-27 08:55:01 +02001/* SPDX-License-Identifier: GPL-2.0-or-later */
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +05302/*
3 * phy.h -- generic phy header file
4 *
5 * Copyright (C) 2013 Texas Instruments Incorporated - http://www.ti.com
6 *
7 * Author: Kishon Vijay Abraham I <kishon@ti.com>
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +05308 */
9
10#ifndef __DRIVERS_PHY_H
11#define __DRIVERS_PHY_H
12
13#include <linux/err.h>
14#include <linux/of.h>
15#include <linux/device.h>
16#include <linux/pm_runtime.h>
Roger Quadros3be88122014-07-04 12:55:45 +030017#include <linux/regulator/consumer.h>
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +053018
Maxime Ripard2ed86992018-12-07 14:55:30 +010019#include <linux/phy/phy-mipi-dphy.h>
20
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +053021struct phy;
22
David Lechner300eb012016-05-09 18:39:59 -050023enum phy_mode {
24 PHY_MODE_INVALID,
25 PHY_MODE_USB_HOST,
Manu Gautam3b3cd242018-01-16 16:27:09 +053026 PHY_MODE_USB_HOST_LS,
27 PHY_MODE_USB_HOST_FS,
28 PHY_MODE_USB_HOST_HS,
29 PHY_MODE_USB_HOST_SS,
David Lechner300eb012016-05-09 18:39:59 -050030 PHY_MODE_USB_DEVICE,
Manu Gautam3b3cd242018-01-16 16:27:09 +053031 PHY_MODE_USB_DEVICE_LS,
32 PHY_MODE_USB_DEVICE_FS,
33 PHY_MODE_USB_DEVICE_HS,
34 PHY_MODE_USB_DEVICE_SS,
David Lechner300eb012016-05-09 18:39:59 -050035 PHY_MODE_USB_OTG,
Vivek Gautamfd3e4c92017-10-12 11:49:33 +053036 PHY_MODE_UFS_HS_A,
37 PHY_MODE_UFS_HS_B,
Quentin Schulzc2a90022018-10-04 14:22:03 +020038 PHY_MODE_PCIE,
Grygorii Strashko2af8cae2018-11-19 19:24:21 -060039 PHY_MODE_ETHERNET,
Maxime Ripardc8457822018-12-07 14:55:28 +010040 PHY_MODE_MIPI_DPHY,
John Hubbarde1706722019-01-12 17:29:09 -080041 PHY_MODE_SATA
David Lechner300eb012016-05-09 18:39:59 -050042};
43
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +053044/**
Maxime Ripardaeaac932018-12-07 14:55:29 +010045 * union phy_configure_opts - Opaque generic phy configuration
Maxime Ripard2ed86992018-12-07 14:55:30 +010046 *
47 * @mipi_dphy: Configuration set applicable for phys supporting
48 * the MIPI_DPHY phy mode.
Maxime Ripardaeaac932018-12-07 14:55:29 +010049 */
50union phy_configure_opts {
Maxime Ripard2ed86992018-12-07 14:55:30 +010051 struct phy_configure_opts_mipi_dphy mipi_dphy;
Maxime Ripardaeaac932018-12-07 14:55:29 +010052};
53
54/**
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +053055 * struct phy_ops - set of function pointers for performing phy operations
56 * @init: operation to be performed for initializing phy
57 * @exit: operation to be performed while exiting
58 * @power_on: powering on the phy
59 * @power_off: powering off the phy
David Lechner300eb012016-05-09 18:39:59 -050060 * @set_mode: set the mode of the phy
Randy Licac18ec2016-09-10 02:59:37 +080061 * @reset: resetting the phy
Andrzej Pietrasiewicz36914112017-10-09 14:00:50 +020062 * @calibrate: calibrate the phy
Kishon Vijay Abraham Ifec06b22019-04-05 16:38:30 +053063 * @release: ops to be performed while the consumer relinquishes the PHY
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +053064 * @owner: the module owner containing the ops
65 */
66struct phy_ops {
67 int (*init)(struct phy *phy);
68 int (*exit)(struct phy *phy);
69 int (*power_on)(struct phy *phy);
70 int (*power_off)(struct phy *phy);
Grygorii Strashko79a5a182018-11-19 19:24:20 -060071 int (*set_mode)(struct phy *phy, enum phy_mode mode, int submode);
Maxime Ripardaeaac932018-12-07 14:55:29 +010072
73 /**
74 * @configure:
75 *
76 * Optional.
77 *
78 * Used to change the PHY parameters. phy_init() must have
79 * been called on the phy.
80 *
81 * Returns: 0 if successful, an negative error code otherwise
82 */
83 int (*configure)(struct phy *phy, union phy_configure_opts *opts);
84
85 /**
86 * @validate:
87 *
88 * Optional.
89 *
90 * Used to check that the current set of parameters can be
91 * handled by the phy. Implementations are free to tune the
92 * parameters passed as arguments if needed by some
93 * implementation detail or constraints. It must not change
94 * any actual configuration of the PHY, so calling it as many
95 * times as deemed fit by the consumer must have no side
96 * effect.
97 *
98 * Returns: 0 if the configuration can be applied, an negative
99 * error code otherwise
100 */
101 int (*validate)(struct phy *phy, enum phy_mode mode, int submode,
102 union phy_configure_opts *opts);
Randy Licac18ec2016-09-10 02:59:37 +0800103 int (*reset)(struct phy *phy);
Andrzej Pietrasiewicz36914112017-10-09 14:00:50 +0200104 int (*calibrate)(struct phy *phy);
Kishon Vijay Abraham Ifec06b22019-04-05 16:38:30 +0530105 void (*release)(struct phy *phy);
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530106 struct module *owner;
107};
108
109/**
Matt Porter8feed342013-12-19 09:23:02 -0500110 * struct phy_attrs - represents phy attributes
111 * @bus_width: Data path width implemented by PHY
Robert P. J. Daya3c93112018-12-27 16:10:59 -0500112 * @mode: PHY mode
Matt Porter8feed342013-12-19 09:23:02 -0500113 */
114struct phy_attrs {
115 u32 bus_width;
Manu Gautam3b3cd242018-01-16 16:27:09 +0530116 enum phy_mode mode;
Matt Porter8feed342013-12-19 09:23:02 -0500117};
118
119/**
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530120 * struct phy - represents the phy device
121 * @dev: phy device
122 * @id: id of the phy device
123 * @ops: function pointers for performing phy operations
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530124 * @mutex: mutex to protect phy_ops
125 * @init_count: used to protect when the PHY is used by multiple consumers
126 * @power_count: used to protect when the PHY is used by multiple consumers
Dov Levenglickbecaf172018-02-02 18:34:50 +0200127 * @attrs: used to specify PHY specific attributes
128 * @pwr: power regulator associated with the phy
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530129 */
130struct phy {
131 struct device dev;
132 int id;
133 const struct phy_ops *ops;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530134 struct mutex mutex;
135 int init_count;
136 int power_count;
Matt Porter8feed342013-12-19 09:23:02 -0500137 struct phy_attrs attrs;
Roger Quadros3be88122014-07-04 12:55:45 +0300138 struct regulator *pwr;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530139};
140
141/**
142 * struct phy_provider - represents the phy provider
143 * @dev: phy provider device
Dov Levenglickbecaf172018-02-02 18:34:50 +0200144 * @children: can be used to override the default (dev->of_node) child node
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530145 * @owner: the module owner having of_xlate
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530146 * @list: to maintain a linked list of PHY providers
Dov Levenglickbecaf172018-02-02 18:34:50 +0200147 * @of_xlate: function pointer to obtain phy instance from phy pointer
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530148 */
149struct phy_provider {
150 struct device *dev;
Thierry Reding1140f7c2016-04-05 17:17:34 +0200151 struct device_node *children;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530152 struct module *owner;
153 struct list_head list;
154 struct phy * (*of_xlate)(struct device *dev,
155 struct of_phandle_args *args);
156};
157
Dov Levenglickbecaf172018-02-02 18:34:50 +0200158/**
159 * struct phy_lookup - PHY association in list of phys managed by the phy driver
160 * @node: list node
161 * @dev_id: the device of the association
162 * @con_id: connection ID string on device
163 * @phy: the phy of the association
164 */
Heikki Krogerusb7bc15b2014-11-19 17:28:18 +0200165struct phy_lookup {
166 struct list_head node;
167 const char *dev_id;
168 const char *con_id;
169 struct phy *phy;
170};
171
Heikki Krogerusd4510572014-11-19 17:28:17 +0200172#define to_phy(a) (container_of((a), struct phy, dev))
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530173
174#define of_phy_provider_register(dev, xlate) \
Thierry Reding1140f7c2016-04-05 17:17:34 +0200175 __of_phy_provider_register((dev), NULL, THIS_MODULE, (xlate))
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530176
177#define devm_of_phy_provider_register(dev, xlate) \
Thierry Reding1140f7c2016-04-05 17:17:34 +0200178 __devm_of_phy_provider_register((dev), NULL, THIS_MODULE, (xlate))
179
180#define of_phy_provider_register_full(dev, children, xlate) \
181 __of_phy_provider_register(dev, children, THIS_MODULE, xlate)
182
183#define devm_of_phy_provider_register_full(dev, children, xlate) \
184 __devm_of_phy_provider_register(dev, children, THIS_MODULE, xlate)
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530185
186static inline void phy_set_drvdata(struct phy *phy, void *data)
187{
188 dev_set_drvdata(&phy->dev, data);
189}
190
191static inline void *phy_get_drvdata(struct phy *phy)
192{
193 return dev_get_drvdata(&phy->dev);
194}
195
196#if IS_ENABLED(CONFIG_GENERIC_PHY)
197int phy_pm_runtime_get(struct phy *phy);
198int phy_pm_runtime_get_sync(struct phy *phy);
199int phy_pm_runtime_put(struct phy *phy);
200int phy_pm_runtime_put_sync(struct phy *phy);
201void phy_pm_runtime_allow(struct phy *phy);
202void phy_pm_runtime_forbid(struct phy *phy);
203int phy_init(struct phy *phy);
204int phy_exit(struct phy *phy);
205int phy_power_on(struct phy *phy);
206int phy_power_off(struct phy *phy);
Grygorii Strashko79a5a182018-11-19 19:24:20 -0600207int phy_set_mode_ext(struct phy *phy, enum phy_mode mode, int submode);
208#define phy_set_mode(phy, mode) \
209 phy_set_mode_ext(phy, mode, 0)
Maxime Ripardaeaac932018-12-07 14:55:29 +0100210int phy_configure(struct phy *phy, union phy_configure_opts *opts);
211int phy_validate(struct phy *phy, enum phy_mode mode, int submode,
212 union phy_configure_opts *opts);
Grygorii Strashko79a5a182018-11-19 19:24:20 -0600213
Manu Gautam3b3cd242018-01-16 16:27:09 +0530214static inline enum phy_mode phy_get_mode(struct phy *phy)
215{
216 return phy->attrs.mode;
217}
Randy Licac18ec2016-09-10 02:59:37 +0800218int phy_reset(struct phy *phy);
Andrzej Pietrasiewicz36914112017-10-09 14:00:50 +0200219int phy_calibrate(struct phy *phy);
Matt Porter8feed342013-12-19 09:23:02 -0500220static inline int phy_get_bus_width(struct phy *phy)
221{
222 return phy->attrs.bus_width;
223}
224static inline void phy_set_bus_width(struct phy *phy, int bus_width)
225{
226 phy->attrs.bus_width = bus_width;
227}
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530228struct phy *phy_get(struct device *dev, const char *string);
Andrew Lunn788a4d52014-02-04 18:33:12 +0100229struct phy *phy_optional_get(struct device *dev, const char *string);
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530230struct phy *devm_phy_get(struct device *dev, const char *string);
Andrew Lunn788a4d52014-02-04 18:33:12 +0100231struct phy *devm_phy_optional_get(struct device *dev, const char *string);
Kamil Debskib5d682f2014-03-06 12:16:47 +0100232struct phy *devm_of_phy_get(struct device *dev, struct device_node *np,
233 const char *con_id);
Arun Ramamurthy6be109b2015-04-22 16:04:11 -0700234struct phy *devm_of_phy_get_by_index(struct device *dev, struct device_node *np,
235 int index);
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530236void phy_put(struct phy *phy);
237void devm_phy_put(struct device *dev, struct phy *phy);
Kamil Debski0b3f3b22014-03-06 12:16:46 +0100238struct phy *of_phy_get(struct device_node *np, const char *con_id);
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530239struct phy *of_phy_simple_xlate(struct device *dev,
240 struct of_phandle_args *args);
Kishon Vijay Abraham If0ed8172014-07-14 15:55:02 +0530241struct phy *phy_create(struct device *dev, struct device_node *node,
Heikki Krogerusdbc98632014-11-19 17:28:21 +0200242 const struct phy_ops *ops);
Kishon Vijay Abraham If0ed8172014-07-14 15:55:02 +0530243struct phy *devm_phy_create(struct device *dev, struct device_node *node,
Heikki Krogerusdbc98632014-11-19 17:28:21 +0200244 const struct phy_ops *ops);
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530245void phy_destroy(struct phy *phy);
246void devm_phy_destroy(struct device *dev, struct phy *phy);
247struct phy_provider *__of_phy_provider_register(struct device *dev,
Thierry Reding1140f7c2016-04-05 17:17:34 +0200248 struct device_node *children, struct module *owner,
249 struct phy * (*of_xlate)(struct device *dev,
250 struct of_phandle_args *args));
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530251struct phy_provider *__devm_of_phy_provider_register(struct device *dev,
Thierry Reding1140f7c2016-04-05 17:17:34 +0200252 struct device_node *children, struct module *owner,
253 struct phy * (*of_xlate)(struct device *dev,
254 struct of_phandle_args *args));
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530255void of_phy_provider_unregister(struct phy_provider *phy_provider);
256void devm_of_phy_provider_unregister(struct device *dev,
257 struct phy_provider *phy_provider);
Heikki Krogerusb7bc15b2014-11-19 17:28:18 +0200258int phy_create_lookup(struct phy *phy, const char *con_id, const char *dev_id);
259void phy_remove_lookup(struct phy *phy, const char *con_id, const char *dev_id);
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530260#else
261static inline int phy_pm_runtime_get(struct phy *phy)
262{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530263 if (!phy)
264 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530265 return -ENOSYS;
266}
267
268static inline int phy_pm_runtime_get_sync(struct phy *phy)
269{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530270 if (!phy)
271 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530272 return -ENOSYS;
273}
274
275static inline int phy_pm_runtime_put(struct phy *phy)
276{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530277 if (!phy)
278 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530279 return -ENOSYS;
280}
281
282static inline int phy_pm_runtime_put_sync(struct phy *phy)
283{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530284 if (!phy)
285 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530286 return -ENOSYS;
287}
288
289static inline void phy_pm_runtime_allow(struct phy *phy)
290{
291 return;
292}
293
294static inline void phy_pm_runtime_forbid(struct phy *phy)
295{
296 return;
297}
298
299static inline int phy_init(struct phy *phy)
300{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530301 if (!phy)
302 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530303 return -ENOSYS;
304}
305
306static inline int phy_exit(struct phy *phy)
307{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530308 if (!phy)
309 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530310 return -ENOSYS;
311}
312
313static inline int phy_power_on(struct phy *phy)
314{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530315 if (!phy)
316 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530317 return -ENOSYS;
318}
319
320static inline int phy_power_off(struct phy *phy)
321{
Grygorii Strashko2b977892014-04-19 08:51:44 +0530322 if (!phy)
323 return 0;
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530324 return -ENOSYS;
325}
326
Grygorii Strashko79a5a182018-11-19 19:24:20 -0600327static inline int phy_set_mode_ext(struct phy *phy, enum phy_mode mode,
328 int submode)
David Lechner300eb012016-05-09 18:39:59 -0500329{
330 if (!phy)
331 return 0;
332 return -ENOSYS;
333}
334
Grygorii Strashko79a5a182018-11-19 19:24:20 -0600335#define phy_set_mode(phy, mode) \
336 phy_set_mode_ext(phy, mode, 0)
337
Manu Gautam3b3cd242018-01-16 16:27:09 +0530338static inline enum phy_mode phy_get_mode(struct phy *phy)
339{
340 return PHY_MODE_INVALID;
341}
342
Randy Li98430c72016-10-25 22:15:34 +0800343static inline int phy_reset(struct phy *phy)
344{
345 if (!phy)
346 return 0;
347 return -ENOSYS;
348}
349
Andrzej Pietrasiewicz36914112017-10-09 14:00:50 +0200350static inline int phy_calibrate(struct phy *phy)
351{
352 if (!phy)
353 return 0;
354 return -ENOSYS;
355}
356
Maxime Ripardaeaac932018-12-07 14:55:29 +0100357static inline int phy_configure(struct phy *phy,
358 union phy_configure_opts *opts)
359{
360 if (!phy)
361 return 0;
362
363 return -ENOSYS;
364}
365
366static inline int phy_validate(struct phy *phy, enum phy_mode mode, int submode,
367 union phy_configure_opts *opts)
368{
369 if (!phy)
370 return 0;
371
372 return -ENOSYS;
373}
374
Matt Porter8feed342013-12-19 09:23:02 -0500375static inline int phy_get_bus_width(struct phy *phy)
376{
377 return -ENOSYS;
378}
379
380static inline void phy_set_bus_width(struct phy *phy, int bus_width)
381{
382 return;
383}
384
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530385static inline struct phy *phy_get(struct device *dev, const char *string)
386{
387 return ERR_PTR(-ENOSYS);
388}
389
Andrew Lunn788a4d52014-02-04 18:33:12 +0100390static inline struct phy *phy_optional_get(struct device *dev,
391 const char *string)
392{
393 return ERR_PTR(-ENOSYS);
394}
395
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530396static inline struct phy *devm_phy_get(struct device *dev, const char *string)
397{
398 return ERR_PTR(-ENOSYS);
399}
400
Andrew Lunn788a4d52014-02-04 18:33:12 +0100401static inline struct phy *devm_phy_optional_get(struct device *dev,
402 const char *string)
403{
Maxime Ripard11a6e412017-09-04 14:53:13 +0200404 return NULL;
Andrew Lunn788a4d52014-02-04 18:33:12 +0100405}
406
Kamil Debskib5d682f2014-03-06 12:16:47 +0100407static inline struct phy *devm_of_phy_get(struct device *dev,
408 struct device_node *np,
409 const char *con_id)
410{
411 return ERR_PTR(-ENOSYS);
412}
413
Arun Ramamurthy6be109b2015-04-22 16:04:11 -0700414static inline struct phy *devm_of_phy_get_by_index(struct device *dev,
415 struct device_node *np,
416 int index)
417{
418 return ERR_PTR(-ENOSYS);
419}
420
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530421static inline void phy_put(struct phy *phy)
422{
423}
424
425static inline void devm_phy_put(struct device *dev, struct phy *phy)
426{
427}
428
Kamil Debski0b3f3b22014-03-06 12:16:46 +0100429static inline struct phy *of_phy_get(struct device_node *np, const char *con_id)
430{
431 return ERR_PTR(-ENOSYS);
432}
433
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530434static inline struct phy *of_phy_simple_xlate(struct device *dev,
435 struct of_phandle_args *args)
436{
437 return ERR_PTR(-ENOSYS);
438}
439
440static inline struct phy *phy_create(struct device *dev,
Kishon Vijay Abraham If0ed8172014-07-14 15:55:02 +0530441 struct device_node *node,
Heikki Krogerusdbc98632014-11-19 17:28:21 +0200442 const struct phy_ops *ops)
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530443{
444 return ERR_PTR(-ENOSYS);
445}
446
447static inline struct phy *devm_phy_create(struct device *dev,
Kishon Vijay Abraham If0ed8172014-07-14 15:55:02 +0530448 struct device_node *node,
Heikki Krogerusdbc98632014-11-19 17:28:21 +0200449 const struct phy_ops *ops)
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530450{
451 return ERR_PTR(-ENOSYS);
452}
453
454static inline void phy_destroy(struct phy *phy)
455{
456}
457
458static inline void devm_phy_destroy(struct device *dev, struct phy *phy)
459{
460}
461
462static inline struct phy_provider *__of_phy_provider_register(
Thierry Reding1140f7c2016-04-05 17:17:34 +0200463 struct device *dev, struct device_node *children, struct module *owner,
464 struct phy * (*of_xlate)(struct device *dev,
465 struct of_phandle_args *args))
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530466{
467 return ERR_PTR(-ENOSYS);
468}
469
470static inline struct phy_provider *__devm_of_phy_provider_register(struct device
Thierry Reding1140f7c2016-04-05 17:17:34 +0200471 *dev, struct device_node *children, struct module *owner,
472 struct phy * (*of_xlate)(struct device *dev,
473 struct of_phandle_args *args))
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530474{
475 return ERR_PTR(-ENOSYS);
476}
477
478static inline void of_phy_provider_unregister(struct phy_provider *phy_provider)
479{
480}
481
482static inline void devm_of_phy_provider_unregister(struct device *dev,
483 struct phy_provider *phy_provider)
484{
485}
Heikki Krogerusb7bc15b2014-11-19 17:28:18 +0200486static inline int
487phy_create_lookup(struct phy *phy, const char *con_id, const char *dev_id)
488{
489 return 0;
490}
491static inline void phy_remove_lookup(struct phy *phy, const char *con_id,
492 const char *dev_id) { }
Kishon Vijay Abraham Iff764962013-09-27 11:53:25 +0530493#endif
494
495#endif /* __DRIVERS_PHY_H */