improve 8042 status defines
This commit is contained in:
1 parent
575ab46109
commit
8e5761f610
2 files changed
+6
-4
No files matched your search
@@ -645,7 +645,7 @@ intel_8042_wait_write:
|
|||||||
; Read the 8042 status register.
|
; Read the 8042 status register.
|
||||||
in al, INTEL_8042_IN_STATUS
|
in al, INTEL_8042_IN_STATUS
|
||||||
; Input buffer status flag set means the input buffer is full, so loop in this case.
|
; Input buffer status flag set means the input buffer is full, so loop in this case.
|
||||||
test al, (1 << INTEL_8042_STATUS_IBUF)
|
test al, INTEL_8042_STATUS_MASK_IBUF
|
||||||
jnz .loop
|
jnz .loop
|
||||||
ret
|
ret
|
||||||
|
|
||||||
@@ -659,7 +659,7 @@ intel_8042_wait_read:
|
|||||||
; Read the 8042 status register.
|
; Read the 8042 status register.
|
||||||
in al, INTEL_8042_IN_STATUS
|
in al, INTEL_8042_IN_STATUS
|
||||||
; Output buffer status flag unset means output buffer is empty, so loop in this case.
|
; Output buffer status flag unset means output buffer is empty, so loop in this case.
|
||||||
test al, (1 << INTEL_8042_STATUS_OBUF)
|
test al, INTEL_8042_STATUS_MASK_OBUF
|
||||||
jz .loop
|
jz .loop
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
|||||||
@@ -15,8 +15,10 @@
|
|||||||
%define INTEL_8042_IN_STATUS 0x64
|
%define INTEL_8042_IN_STATUS 0x64
|
||||||
%define INTEL_8042_OUT_CMD 0x64
|
%define INTEL_8042_OUT_CMD 0x64
|
||||||
|
|
||||||
%define INTEL_8042_STATUS_OBUF 0
|
%define INTEL_8042_STATUS_BIT_OBUF 0
|
||||||
%define INTEL_8042_STATUS_IBUF 1
|
%define INTEL_8042_STATUS_BIT_IBUF 1
|
||||||
|
%define INTEL_8042_STATUS_MASK_OBUF (1 << INTEL_8042_STATUS_BIT_OBUF)
|
||||||
|
%define INTEL_8042_STATUS_MASK_IBUF (1 << INTEL_8042_STATUS_BIT_IBUF)
|
||||||
|
|
||||||
%define INTEL_8042_CMD_PS2_1_DISABLE 0xad
|
%define INTEL_8042_CMD_PS2_1_DISABLE 0xad
|
||||||
%define INTEL_8042_CMD_PS2_1_ENABLE 0xae
|
%define INTEL_8042_CMD_PS2_1_ENABLE 0xae
|
||||||
|
|||||||
Reference in new issue
Block a user