diff options
author | David S. Miller <davem@davemloft.net> | 2017-10-18 12:40:40 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-10-18 12:40:40 +0100 |
commit | 2af55f460738c78e63596e320f6dbde0cd4cfb84 (patch) | |
tree | 149c0e1ec9e7711d559c76ea0e5d82893d92b168 /drivers/net/ethernet/amd/amd8111e.c | |
parent | 1bbc728988f09e40c83585cf3322b1f6c1aa17b5 (diff) | |
parent | ff861c4d64f2df1c7eaabaf2ba8f2f8ebc4b28e3 (diff) | |
download | linux-2af55f460738c78e63596e320f6dbde0cd4cfb84.tar.gz linux-2af55f460738c78e63596e320f6dbde0cd4cfb84.tar.xz |
Merge branch 'networking-Convert-timers-to-use-timer_setup'
Kees Cook says:
====================
networking: Convert timers to use timer_setup()
This is the current set of outstanding networking patches to perform
conversions to the new timer interface (rebased to -next). This is not
all expected conversions, but it contains everything needed in networking
to eliminate init_timer(), and all the non-standard setup_*_timer() uses.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/amd/amd8111e.c')
-rw-r--r-- | drivers/net/ethernet/amd/amd8111e.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/ethernet/amd/amd8111e.c b/drivers/net/ethernet/amd/amd8111e.c index 7f22af6e37e0..358f7ab77c70 100644 --- a/drivers/net/ethernet/amd/amd8111e.c +++ b/drivers/net/ethernet/amd/amd8111e.c @@ -1669,9 +1669,9 @@ static int amd8111e_resume(struct pci_dev *pci_dev) return 0; } -static void amd8111e_config_ipg(struct net_device *dev) +static void amd8111e_config_ipg(struct timer_list *t) { - struct amd8111e_priv *lp = netdev_priv(dev); + struct amd8111e_priv *lp = from_timer(lp, t, ipg_data.ipg_timer); struct ipg_info *ipg_data = &lp->ipg_data; void __iomem *mmio = lp->mmio; unsigned int prev_col_cnt = ipg_data->col_cnt; @@ -1883,8 +1883,7 @@ static int amd8111e_probe_one(struct pci_dev *pdev, /* Initialize software ipg timer */ if(lp->options & OPTION_DYN_IPG_ENABLE){ - setup_timer(&lp->ipg_data.ipg_timer, - (void *)&amd8111e_config_ipg, (unsigned long)dev); + timer_setup(&lp->ipg_data.ipg_timer, amd8111e_config_ipg, 0); lp->ipg_data.ipg_timer.expires = jiffies + IPG_CONVERGE_JIFFIES; lp->ipg_data.ipg = DEFAULT_IPG; |