diff options
| author | Miguel <m.i@gmx.at> | 2018-10-19 13:30:01 +0200 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2018-10-19 13:30:01 +0200 |
| commit | c9c26727a11c37f61bc51662c3ca498737ce523f (patch) | |
| tree | 0032f002df36292e1b07c6add5c73a0b050a76c3 /driver | |
| parent | 45ce8728224caa44d31dca3117992b193fa3cd98 (diff) | |
compositor stuff
Diffstat (limited to 'driver')
| -rw-r--r-- | driver/mouse.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/driver/mouse.c b/driver/mouse.c index c292d97..787c7a6 100644 --- a/driver/mouse.c +++ b/driver/mouse.c @@ -33,7 +33,6 @@ bool mouse_worker() { kpanic("mouse buffer full"); // heavy debugging } - bool wake=false; while(ringbuffer_has(&mouse_in)){ mouse_handler(ringbuffer_get(&mouse_in)); @@ -146,14 +145,18 @@ void mouse_action() if(mouse_byte[0]&0x80) { +#ifdef LOG_MOUSE_WARN + klog("x overflow"); +#endif return; - // klog("x overflow"); } if(mouse_byte[0]&0x40) { +#ifdef LOG_MOUSE_WARN + klog("y overflow"); +#endif return; - // klog("y overflow"); } rel_x = mouse_byte[1] - ((mouse_byte[0] << 4) & 0x100); @@ -176,7 +179,9 @@ void mouse_handler(uint8_t byte)//struct regs *a_r) //struct regs *a_r (not used // this bit is ALWAYS one, otherwise we are out of sync! if(!(mouse_byte[0]&0x8)) { -// klog("mouse out of sync (try next packet) ..."); +#ifdef LOG_MOUSE_WARN + klog("mouse out of sync"); +#endif mouse_cycle--; } |
