Skip to content

Commit

Permalink
net: phy: at803x: fix coccinelle warnings
Browse files Browse the repository at this point in the history
drivers/net/phy/at803x.c:196:26-32: ERROR: application of sizeof to pointer

 sizeof when applied to a pointer typed expression gives the size of
 the pointer

Generated by: scripts/coccinelle/misc/noderef.cocci

Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Acked-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Fengguang Wu authored and David S. Miller committed Jun 23, 2014
1 parent 960b1f4 commit 8f2877c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/phy/at803x.c
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ static int at803x_probe(struct phy_device *phydev)
struct device *dev = &phydev->dev;
struct at803x_priv *priv;

priv = devm_kzalloc(dev, sizeof(priv), GFP_KERNEL);
priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL);
if (!priv)
return -ENOMEM;

Expand Down

0 comments on commit 8f2877c

Please sign in to comment.