summaryrefslogtreecommitdiff
path: root/drivers/net/phy/phy.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/phy/phy.c')
-rw-r--r--drivers/net/phy/phy.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c
index 13dd1691886d..376bfa923349 100644
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
@@ -736,7 +736,7 @@ int phy_ethtool_set_plca_cfg(struct phy_device *phydev,
goto out;
}
- curr_plca_cfg = kmalloc(sizeof(*curr_plca_cfg), GFP_KERNEL);
+ curr_plca_cfg = kmalloc_obj(*curr_plca_cfg, GFP_KERNEL);
if (!curr_plca_cfg) {
ret = -ENOMEM;
goto out;