Skip to content
Navigation Menu
Toggle navigation
Sign in
In this repository
All GitHub Enterprise
↵
Jump to
↵
No suggested jump to results
In this repository
All GitHub Enterprise
↵
Jump to
↵
In this organization
All GitHub Enterprise
↵
Jump to
↵
In this repository
All GitHub Enterprise
↵
Jump to
↵
Sign in
Reseting focus
You signed in with another tab or window.
Reload
to refresh your session.
You signed out in another tab or window.
Reload
to refresh your session.
You switched accounts on another tab or window.
Reload
to refresh your session.
Dismiss alert
{{ message }}
mariux64
/
linux
Public
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Issues
2
Pull requests
0
Actions
Projects
0
Wiki
Security
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security
Insights
Files
529e5fb
Documentation
arch
alpha
arc
arm
boot
common
configs
crypto
include
asm
hardware
mach
xen
Kbuild
a.out-core.h
arch_timer.h
asm-offsets.h
assembler.h
atomic.h
barrier.h
bitops.h
bug.h
bugs.h
cache.h
cacheflush.h
cachetype.h
checksum.h
clkdev.h
cmpxchg.h
compiler.h
cp15.h
cpu.h
cpuidle.h
cputype.h
cti.h
delay.h
device.h
div64.h
dma-contiguous.h
dma-iommu.h
dma-mapping.h
dma.h
domain.h
ecard.h
edac.h
elf.h
entry-macro-multi.S
exception.h
fb.h
fiq.h
fixmap.h
flat.h
floppy.h
fncpy.h
fpstate.h
ftrace.h
futex.h
glue-cache.h
glue-df.h
glue-pf.h
glue-proc.h
glue.h
gpio.h
hardirq.h
highmem.h
hw_breakpoint.h
hw_irq.h
hwcap.h
hypervisor.h
ide.h
idmap.h
io.h
irq.h
irqflags.h
jump_label.h
kexec.h
kgdb.h
kmap_types.h
kprobes.h
kvm_arch_timer.h
kvm_arm.h
kvm_asm.h
kvm_coproc.h
kvm_emulate.h
kvm_host.h
kvm_mmio.h
kvm_mmu.h
kvm_psci.h
kvm_vgic.h
limits.h
linkage.h
localtimer.h
mach-types.h
mc146818rtc.h
memblock.h
memory.h
mmu.h
mmu_context.h
module.h
mtd-xip.h
mutex.h
nwflash.h
opcodes-sec.h
opcodes-virt.h
opcodes.h
outercache.h
page-nommu.h
page.h
pci.h
percpu.h
perf_event.h
pgalloc.h
pgtable-2level-hwdef.h
pgtable-2level-types.h
pgtable-2level.h
pgtable-3level-hwdef.h
pgtable-3level-types.h
pgtable-3level.h
pgtable-hwdef.h
pgtable-nommu.h
pgtable.h
pmu.h
proc-fns.h
processor.h
procinfo.h
prom.h
psci.h
ptrace.h
scatterlist.h
sched_clock.h
seccomp.h
setup.h
shmparam.h
signal.h
smp.h
smp_plat.h
smp_scu.h
smp_twd.h
sparsemem.h
spinlock.h
spinlock_types.h
stackprotector.h
stacktrace.h
string.h
suspend.h
swab.h
switch_to.h
sync_bitops.h
syscall.h
system.h
system_info.h
system_misc.h
tcm.h
therm.h
thread_info.h
thread_notify.h
timex.h
tlb.h
tlbflush.h
tls.h
topology.h
traps.h
uaccess.h
ucontext.h
unified.h
unistd.h
unwind.h
user.h
vfp.h
vfpmacros.h
vga.h
virt.h
word-at-a-time.h
xor.h
debug
uapi
kernel
kvm
lib
mach-at91
mach-bcm
mach-bcm2835
mach-clps711x
mach-cns3xxx
mach-davinci
mach-dove
mach-ebsa110
mach-ep93xx
mach-exynos
mach-footbridge
mach-gemini
mach-h720x
mach-highbank
mach-imx
mach-integrator
mach-iop13xx
mach-iop32x
mach-iop33x
mach-ixp4xx
mach-kirkwood
mach-ks8695
mach-l7200
mach-lpc32xx
mach-mmp
mach-msm
mach-mv78xx0
mach-mvebu
mach-mxs
mach-netx
mach-nomadik
mach-omap1
mach-omap2
mach-orion5x
mach-picoxcell
mach-prima2
mach-pxa
mach-realview
mach-rpc
mach-s3c24xx
mach-s3c64xx
mach-s5p64x0
mach-s5pc100
mach-s5pv210
mach-sa1100
mach-shark
mach-shmobile
mach-socfpga
mach-spear13xx
mach-spear3xx
mach-spear6xx
mach-sunxi
mach-tegra
mach-u300
mach-ux500
mach-versatile
mach-vexpress
mach-virt
mach-vt8500
mach-w90x900
mach-zynq
mm
net
nwfpe
oprofile
plat-iop
plat-omap
plat-orion
plat-pxa
plat-samsung
plat-spear
plat-versatile
tools
vfp
xen
Kconfig
Kconfig-nommu
Kconfig.debug
Makefile
arm64
avr32
blackfin
c6x
cris
frv
h8300
hexagon
ia64
m32r
m68k
microblaze
mips
mn10300
openrisc
parisc
powerpc
s390
score
sh
sparc
tile
um
unicore32
x86
xtensa
.gitignore
Kconfig
block
crypto
drivers
firmware
fs
include
init
ipc
kernel
lib
mm
net
samples
scripts
security
sound
tools
usr
virt
.gitignore
.mailmap
COPYING
CREDITS
Kbuild
Kconfig
MAINTAINERS
Makefile
README
REPORTING-BUGS
Breadcrumbs
linux
/
arch
/
arm
/
include
/
asm
/
delay.h
Copy path
Blame
Blame
Latest commit
History
History
72 lines (58 loc) · 1.99 KB
Breadcrumbs
linux
/
arch
/
arm
/
include
/
asm
/
delay.h
Top
File metadata and controls
Code
Blame
72 lines (58 loc) · 1.99 KB
Raw
/* * Copyright (C) 1995-2004 Russell King * * Delay routines, using a pre-computed "loops_per_second" value. */ #ifndef __ASM_ARM_DELAY_H #define __ASM_ARM_DELAY_H #include <asm/memory.h> #include <asm/param.h> /* HZ */ #define MAX_UDELAY_MS 2 #define UDELAY_MULT ((UL(2199023) * HZ) >> 11) #define UDELAY_SHIFT 30 #ifndef __ASSEMBLY__ struct delay_timer { unsigned long (*read_current_timer)(void); unsigned long freq; }; extern struct arm_delay_ops { void (*delay)(unsigned long); void (*const_udelay)(unsigned long); void (*udelay)(unsigned long); bool const_clock; } arm_delay_ops; #define __delay(n) arm_delay_ops.delay(n) /* * This function intentionally does not exist; if you see references to * it, it means that you're calling udelay() with an out of range value. * * With currently imposed limits, this means that we support a max delay * of 2000us. Further limits: HZ<=1000 and bogomips<=3355 */ extern void __bad_udelay(void); /* * division by multiplication: you don't have to worry about * loss of precision. * * Use only for very small delays ( < 2 msec). Should probably use a * lookup table, really, as the multiplications take much too long with * short delays. This is a "reasonable" implementation, though (and the * first constant multiplications gets optimized away if the delay is * a constant) */ #define __udelay(n) arm_delay_ops.udelay(n) #define __const_udelay(n) arm_delay_ops.const_udelay(n) #define udelay(n) \ (__builtin_constant_p(n) ? \ ((n) > (MAX_UDELAY_MS * 1000) ? __bad_udelay() : \ __const_udelay((n) * UDELAY_MULT)) : \ __udelay(n)) /* Loop-based definitions for assembly code. */ extern void __loop_delay(unsigned long loops); extern void __loop_udelay(unsigned long usecs); extern void __loop_const_udelay(unsigned long); /* Delay-loop timer registration. */ #define ARCH_HAS_READ_CURRENT_TIMER extern void register_current_timer_delay(const struct delay_timer *timer); #endif /* __ASSEMBLY__ */ #endif /* defined(_ARM_DELAY_H) */
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
You can’t perform that action at this time.