aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/phy
diff options
context:
space:
mode:
authorHeikki Krogerus <heikki.krogerus@linux.intel.com>2014-11-19 10:28:17 -0500
committerKishon Vijay Abraham I <kishon@ti.com>2014-11-21 09:18:50 -0500
commitd451057464a7ea2fe400e56c8a7e004c875f2a84 (patch)
tree55f0183803f2c64afc06bf69efd5430378bc8934 /include/linux/phy
parent2f3fa3a0e5672f87f5b972910737a2ef60941b62 (diff)
phy: safer to_phy() macro
This makes to_phy() macro work with other variable names besides "dev". Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Tested-by: Vivek Gautam <gautam.vivek@samsung.com> Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
Diffstat (limited to 'include/linux/phy')
-rw-r--r--include/linux/phy/phy.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/phy/phy.h b/include/linux/phy/phy.h
index 8cb6f815475b..9fda68324298 100644
--- a/include/linux/phy/phy.h
+++ b/include/linux/phy/phy.h
@@ -110,7 +110,7 @@ struct phy_init_data {
110 .port = _port, \ 110 .port = _port, \
111} 111}
112 112
113#define to_phy(dev) (container_of((dev), struct phy, dev)) 113#define to_phy(a) (container_of((a), struct phy, dev))
114 114
115#define of_phy_provider_register(dev, xlate) \ 115#define of_phy_provider_register(dev, xlate) \
116 __of_phy_provider_register((dev), THIS_MODULE, (xlate)) 116 __of_phy_provider_register((dev), THIS_MODULE, (xlate))