Commit c91a9cfe authored by Stanislaw Gruszka's avatar Stanislaw Gruszka Committed by Kalle Valo

rt2x00: initialize last_reset

Initialize last_reset variable to INITIAL_JIFFIES, otherwise it is not
possible to test H/W reset for first 5 minutes of system run.

Fixes: e403fa31 ("rt2x00: add restart hw")
Reported-and-tested-by: default avatarJonathan Liu <net147@gmail.com>
Signed-off-by: default avatarStanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent 54ecb8f7
...@@ -555,7 +555,7 @@ static ssize_t rt2x00debug_write_restart_hw(struct file *file, ...@@ -555,7 +555,7 @@ static ssize_t rt2x00debug_write_restart_hw(struct file *file,
{ {
struct rt2x00debug_intf *intf = file->private_data; struct rt2x00debug_intf *intf = file->private_data;
struct rt2x00_dev *rt2x00dev = intf->rt2x00dev; struct rt2x00_dev *rt2x00dev = intf->rt2x00dev;
static unsigned long last_reset; static unsigned long last_reset = INITIAL_JIFFIES;
if (!rt2x00_has_cap_restart_hw(rt2x00dev)) if (!rt2x00_has_cap_restart_hw(rt2x00dev))
return -EOPNOTSUPP; return -EOPNOTSUPP;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment