Skip to content

Commit

Permalink
stmmac: fixed a compilation error when use the external timer
Browse files Browse the repository at this point in the history
Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Giuseppe CAVALLARO authored and David S. Miller committed Nov 23, 2009
1 parent 7357031 commit e6e3625
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/stmmac/stmmac_timer.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,15 @@ int stmmac_open_ext_timer(struct net_device *dev, struct stmmac_timer *tm)

stmmac_rtc = rtc_class_open(CONFIG_RTC_HCTOSYS_DEVICE);
if (stmmac_rtc == NULL) {
pr_error("open rtc device failed\n");
pr_err("open rtc device failed\n");
return -ENODEV;
}

rtc_irq_register(stmmac_rtc, &stmmac_task);

/* Periodic mode is not supported */
if ((rtc_irq_set_freq(stmmac_rtc, &stmmac_task, tm->freq) < 0)) {
pr_error("set periodic failed\n");
pr_err("set periodic failed\n");
rtc_irq_unregister(stmmac_rtc, &stmmac_task);
rtc_class_close(stmmac_rtc);
return -1;
Expand Down

0 comments on commit e6e3625

Please sign in to comment.