compiling troubles : part 1
Posted: Mon Jan 27, 2003 5:42 am
I have a problem when compiling my kernel with NASM. The problem is related to interrupt vector routines (SetVector, GetVector).
-- GetVector --
...
mov bx, es:[di] ; put low byte in BX
mov ax, es:[di]+2 ; put high byte in AX
...
-- SetVector --
...
mov word es:[al*4], dx ; put low byte first
mov es:[al*4+2], ds ; put high byte then
...
For these 4 lines, compiler says :
intvec.inc:25: error: invalid combination of opcode and operands
intvec.inc:26: error: invalid combination of opcode and operands
intvec.inc:46: error: invalid combination of opcode and operands
intvec.inc:47: error: invalid combination of opcode and operands
Please H E L P :'(
-- GetVector --
...
mov bx, es:[di] ; put low byte in BX
mov ax, es:[di]+2 ; put high byte in AX
...
-- SetVector --
...
mov word es:[al*4], dx ; put low byte first
mov es:[al*4+2], ds ; put high byte then
...
For these 4 lines, compiler says :
intvec.inc:25: error: invalid combination of opcode and operands
intvec.inc:26: error: invalid combination of opcode and operands
intvec.inc:46: error: invalid combination of opcode and operands
intvec.inc:47: error: invalid combination of opcode and operands
Please H E L P :'(