[PATCH] ieee1394: use time_before()

Use of time_before() macro, defined at linux/jiffies.h, which deal with
wrapping correctly and are nicer to read.

Signed-off-by: Marcelo Feitoza Parisi <marcelo@feitoza.com.br>
Signed-off-by: Domen Puncer <domen@coderock.org>
Signed-off-by: Ben Collins <bcollins@debian.org>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Signed-off-by: Jody McIntyre <scjody@steamballoon.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

authored by Jody McIntyre and committed by Linus Torvalds 63bea350 db2fd664

+2 -1
+2 -1
drivers/ieee1394/hosts.c
··· 18 18 #include <linux/slab.h> 19 19 #include <linux/pci.h> 20 20 #include <linux/timer.h> 21 + #include <linux/jiffies.h> 21 22 22 23 #include "csr1212.h" 23 24 #include "ieee1394.h" ··· 218 217 219 218 /* IEEE 1394a-2000 prohibits using the same generation number 220 219 * twice in a 60 second period. */ 221 - if (jiffies - host->csr.gen_timestamp[next_gen] < 60 * HZ) 220 + if (time_before(jiffies, host->csr.gen_timestamp[next_gen] + 60 * HZ)) 222 221 /* Wait 60 seconds from the last time this generation number was 223 222 * used. */ 224 223 reset_delay = (60 * HZ) + host->csr.gen_timestamp[next_gen] - jiffies;