Skip to content

Commit 4c19e2f

Browse files
karimeshapaLinuxdavem330
authored andcommitted
drivers: net: wimax: i2400m: i2400m-usb: Use time_after for time comparison
Use time_after() for time comparison with the new fix. Signed-off-by: Karim Eshapa <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent f92ceb0 commit 4c19e2f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/wimax/i2400m/i2400m-usb.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ static inline int edc_inc(struct edc *edc, u16 max_err, u16 timeframe)
131131
unsigned long now;
132132

133133
now = jiffies;
134-
if (now - edc->timestart > timeframe) {
134+
if (time_after(now, edc->timestart + timeframe)) {
135135
edc->errorcount = 1;
136136
edc->timestart = now;
137137
} else if (++edc->errorcount > max_err) {

0 commit comments

Comments
 (0)