source:
trunk/enter.asm@
26
| Last change on this file since 26 was 26, checked in by , 12 years ago | |
|---|---|
| File size: 418 bytes | |
| Line | |
|---|---|
| 1 | section .text |
| 2 | global enter_section |
| 3 | |
| 4 | enter_section: |
| 5 | enter 0, 0 ; 0 bytes of local stack space |
| 6 | mov ebx,[ebp+8] ; first parameter to function |
| 7 | |
| 8 | |
| 9 | ;; bts bitbase bitoffset |
| 10 | ;; selects the bitoffset bit in bitbase, |
| 11 | ;; stores the value in the CF flag, and sets the bit to 1 |
| 12 | spin: lock bts dword [ebx], 0 |
| 13 | jc spin |
| 14 | |
| 15 | leave ; mov esp,ebp / pop ebp |
| 16 | ret |
| 17 |
Note:
See TracBrowser
for help on using the repository browser.