1 include 'kglobals.inc'
\r
17 next dd ? ;next object in list
\r
18 prev dd ? ;prev object in list
\r
29 vendor_device_id dd ?
\r
34 owner dd ? ; pointer to SRV or 0
\r
46 ; The following macro assume that we are on uniprocessor machine.
\r
47 ; Serious work is needed for multiprocessor machines.
\r
48 macro spin_lock_irqsave spinlock
\r
53 macro spin_unlock_irqrestore spinlock
\r
57 macro spin_lock_irq spinlock
\r
61 macro spin_unlock_irq spinlock
\r
66 ; \begin{diamond}[29.09.2006]
\r
67 ; may be useful for kernel debugging
\r
69 ; dbgstr 'Hello, World!'
\r
71 ; dbgstr 'Hello, World!', save_flags
\r
72 macro dbgstr string*, f
\r
76 a db 'K : ',string,13,10,0
\r
83 if defined SysMsgBoardStr._pe_import
\r
84 invoke SysMsgBoardStr
\r
93 ; \end{diamond}[29.09.2006]
\r
96 ; Useful for things like movi eax,10:
\r
97 ; shorter than regular mov, but slightly slower,
\r
98 ; do not use it in performance-critical places.
\r
101 if imm >= -0x80 & imm <= 0x7F
\r
111 if name eqtype func & defined name#._pe_import
\r
112 err Use invoke, not call/stdcall for PE imports!
\r