1) import AttachIntHandler

2) skip log if interrupts masked 

git-svn-id: svn://kolibrios.org@1604 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Sergey Semyonov (Serge) 2010-09-05 14:31:18 +00:00
parent d83ca851d8
commit 875283e594
2 changed files with 12 additions and 1 deletions

View File

@ -7,6 +7,8 @@
.global _AllocPage
.global _AllocPages
.global _AttachIntHandler
.global _CreateRingBuffer
.global _Delay
.global _DestroyObject
@ -44,6 +46,8 @@
.def _AllocPage; .scl 2; .type 32; .endef
.def _AllocPages; .scl 2; .type 32; .endef
.def _AttachIntHandler; .scl 2; .type 32; .endef
.def _CreateRingBuffer; .scl 2; .type 32; .endef
.def _Delay; .scl 2; .type 32; .endef
@ -82,6 +86,8 @@
_AllocPage:
_AllocPages:
_AttachIntHandler:
_CreateRingBuffer:
_Delay:
@ -123,6 +129,8 @@ _SysMsgBoardStr:
.ascii " -export:AllocPage" # gcc ABI
.ascii " -export:AllocPages" # gcc ABI
.ascii " -export:AttachIntHandler" # stdcall
.ascii " -export:CreateRingBuffer" # stdcall
.ascii " -export:Delay" # stdcall

View File

@ -99,6 +99,7 @@ int dbg_open(char *path)
int vsnprintf(char *s, size_t n, const char *format, va_list arg);
int printf(const char* format, ...)
{
char txtbuf[256];
@ -135,7 +136,9 @@ int dbgprintf(const char* format, ...)
{
SysMsgBoardStr(txtbuf);
if(dbgfile.path)
/* do not write into log file if interrupts disabled */
if ( (get_eflags() & (1 << 9)) && dbgfile.path)
{
write_file(dbgfile.path,txtbuf,dbgfile.offset,len,&writes);
dbgfile.offset+=writes;