Skip to content

Commit

Permalink
drivers/net: Use of_match_ptr() macro in smc91x.c
Browse files Browse the repository at this point in the history
This eliminates having an #ifdef returning NULL for the case
when OF is disabled.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Sachin Kamat authored and David S. Miller committed Dec 19, 2012
1 parent bd77902 commit 89ce376
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/net/ethernet/smsc/smc91x.c
Original file line number Diff line number Diff line change
Expand Up @@ -2386,8 +2386,6 @@ static const struct of_device_id smc91x_match[] = {
{},
};
MODULE_DEVICE_TABLE(of, smc91x_match);
#else
#define smc91x_match NULL
#endif

static struct dev_pm_ops smc_drv_pm_ops = {
Expand All @@ -2402,7 +2400,7 @@ static struct platform_driver smc_driver = {
.name = CARDNAME,
.owner = THIS_MODULE,
.pm = &smc_drv_pm_ops,
.of_match_table = smc91x_match,
.of_match_table = of_match_ptr(smc91x_match),
},
};

Expand Down

0 comments on commit 89ce376

Please sign in to comment.