summaryrefslogtreecommitdiff
path: root/include/linux/phy
diff options
context:
space:
mode:
authorHeikki Krogerus <heikki.krogerus@linux.intel.com>2014-11-19 17:28:17 +0200
committerKishon Vijay Abraham I <kishon@ti.com>2014-11-21 19:48:50 +0530
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 {
.port = _port, \
}
-#define to_phy(dev) (container_of((dev), struct phy, dev))
+#define to_phy(a) (container_of((a), struct phy, dev))
#define of_phy_provider_register(dev, xlate) \
__of_phy_provider_register((dev), THIS_MODULE, (xlate))