[NETLINK]: w1_int.c: fix default netlink group
[linux-2.6/verdex.git] / arch / um / sys-i386 / delay.c
blob2c11b9770e8b351c3756864237ff27b9be721e41
1 #include <linux/module.h>
2 #include <linux/kernel.h>
3 #include <linux/delay.h>
4 #include <asm/param.h>
6 void __delay(unsigned long time)
8 /* Stolen from the i386 __loop_delay */
9 int d0;
10 __asm__ __volatile__(
11 "\tjmp 1f\n"
12 ".align 16\n"
13 "1:\tjmp 2f\n"
14 ".align 16\n"
15 "2:\tdecl %0\n\tjns 2b"
16 :"=&a" (d0)
17 :"0" (time));
20 void __udelay(unsigned long usecs)
22 int i, n;
24 n = (loops_per_jiffy * HZ * usecs) / MILLION;
25 for(i=0;i<n;i++)
26 cpu_relax();
29 EXPORT_SYMBOL(__udelay);
31 void __const_udelay(unsigned long usecs)
33 int i, n;
35 n = (loops_per_jiffy * HZ * usecs) / MILLION;
36 for(i=0;i<n;i++)
37 cpu_relax();
40 EXPORT_SYMBOL(__const_udelay);