changelog shortlog tags branches changeset file revisions annotate raw help

Mercurial > hg > plan9front / sys/src/cmd/aux/realemu/pit.c

revision 6246: 897d5d802e50
parent 25: 03b7d6c76e7c
     1.1--- a/sys/src/cmd/aux/realemu/pit.c
     1.2+++ b/sys/src/cmd/aux/realemu/pit.c
     1.3@@ -51,7 +51,7 @@ latchcount(Pit *ch)
     1.4 		return;
     1.5 	w = ch->count & 0xFFFF;
     1.6 	if(ch->bcd)
     1.7-		w = (w % 10) + ((w/10) % 10)<<4 + ((w/100) % 10)<<8 + ((w/1000) % 10)<<12;
     1.8+		w = (w % 10) | ((w/10) % 10)<<4 | ((w/100) % 10)<<8 | ((w/1000) % 10)<<12;
     1.9 	ch->rlatch[0] = w & 0xFF;
    1.10 	ch->rlatch[1] = (w >> 8) & 0xFF;
    1.11 	ch->rcount = 0;