Changeset 22858 in vbox for trunk/src/VBox/Devices/Input/DevPS2.cpp
- Timestamp:
- Sep 9, 2009 10:12:39 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Input/DevPS2.cpp
r22810 r22858 1 #ifdef VBOX2 1 /* $Id: $ */ 3 2 /** @file … … 71 70 RT_C_DECLS_END 72 71 #endif /* !VBOX_DEVICE_STRUCT_TESTCASE */ 73 #endif /* VBOX */ 74 75 76 #ifndef VBOX 77 #include "vl.h" 78 #endif 79 80 #ifdef VBOX 72 81 73 /* debug PC keyboard */ 82 74 #define DEBUG_KBD … … 84 76 /* debug PC keyboard : only mouse */ 85 77 #define DEBUG_MOUSE 86 #endif /* VBOX */87 78 88 79 /* Keyboard Controller Commands */ … … 161 152 #define AUX_RESET 0xFF /* Reset aux device */ 162 153 #define AUX_ACK 0xFA /* Command byte ACK. */ 163 #ifdef VBOX 164 #define AUX_NACK 0xFE /* Command byte NACK. */ 165 #endif 154 #define AUX_NACK 0xFE /* Command byte NACK. */ 166 155 167 156 #define MOUSE_STATUS_REMOTE 0x40 … … 171 160 #define KBD_QUEUE_SIZE 256 172 161 173 #ifdef VBOX174 162 # define MOUSE_REPORT_HORIZONTAL 0x01 175 163 # define MOUSE_OUTSTANDING_CLICK 0x02 176 #endif177 164 178 165 typedef struct { 179 #ifndef VBOX180 uint8_t aux[KBD_QUEUE_SIZE];181 #endif /* !VBOX */182 166 uint8_t data[KBD_QUEUE_SIZE]; 183 167 int rptr, wptr, count; 184 168 } KBDQueue; 185 186 #ifdef VBOX187 169 188 170 #define MOUSE_CMD_QUEUE_SIZE 8 … … 201 183 } MouseEventQueue; 202 184 203 #endif /* VBOX */204 205 185 typedef struct KBDState { 206 186 KBDQueue queue; 207 #ifdef VBOX208 187 MouseCmdQueue mouse_command_queue; 209 188 MouseEventQueue mouse_event_queue; 210 #endif /* VBOX */211 189 uint8_t write_cmd; /* if non zero, write data to port 60 is expected */ 212 190 uint8_t status; … … 226 204 int32_t mouse_dy; 227 205 int32_t mouse_dz; 228 #ifdef VBOX229 206 int32_t mouse_dw; 230 207 int32_t mouse_flags; 231 #endif232 208 uint8_t mouse_buttons; 233 209 234 #ifdef VBOX235 210 /** Pointer to the device instance - RC. */ 236 211 PPDMDEVINSRC pDevInsRC; … … 272 247 R3PTRTYPE(PPDMIMOUSECONNECTOR) pDrv; 273 248 } Mouse; 274 #endif275 249 } KBDState; 276 250 277 251 #ifndef VBOX_DEVICE_STRUCT_TESTCASE 278 #ifndef VBOX279 KBDState kbd_state;280 #endif281 252 282 253 /* update irq and KBD_STAT_[MOUSE_]OBF */ … … 286 257 { 287 258 KBDQueue *q = &s->queue; 288 #ifdef VBOX289 259 MouseCmdQueue *mcq = &s->mouse_command_queue; 290 260 MouseEventQueue *meq = &s->mouse_event_queue; 291 #endif /* VBOX */292 261 int irq12_level, irq1_level; 293 262 … … 295 264 irq12_level = 0; 296 265 s->status &= ~(KBD_STAT_OBF | KBD_STAT_MOUSE_OBF); 297 #ifdef VBOX298 266 if (q->count != 0) 299 267 { … … 308 276 irq12_level = 1; 309 277 } 310 #else /* !VBOX */311 if (q->count != 0) {312 s->status |= KBD_STAT_OBF;313 if (q->aux[q->rptr]) {314 s->status |= KBD_STAT_MOUSE_OBF;315 if (s->mode & KBD_MODE_MOUSE_INT)316 irq12_level = 1;317 } else {318 if ((s->mode & KBD_MODE_KBD_INT) &&319 !(s->mode & KBD_MODE_DISABLE_KBD))320 irq1_level = 1;321 }322 }323 #endif /* !VBOX */324 #ifndef VBOX325 pic_set_irq(1, irq1_level);326 pic_set_irq(12, irq12_level);327 #else /* VBOX */328 278 PDMDevHlpISASetIrq(s->CTX_SUFF(pDevIns), 1, irq1_level); 329 279 PDMDevHlpISASetIrq(s->CTX_SUFF(pDevIns), 12, irq12_level); 330 #endif /* VBOX */331 280 } 332 281 … … 334 283 { 335 284 KBDQueue *q = &s->queue; 336 #ifdef VBOX337 285 MouseCmdQueue *mcq = &s->mouse_command_queue; 338 286 MouseEventQueue *meq = &s->mouse_event_queue; 339 #endif /* VBOX */340 287 341 288 #if defined(DEBUG_MOUSE) || defined(DEBUG_KBD) … … 349 296 #endif 350 297 #endif 351 #ifdef VBOX352 298 switch (aux) 353 299 { … … 379 325 AssertMsgFailed(("aux=%d\n", aux)); 380 326 } 381 #else /* !VBOX */382 if (q->count >= KBD_QUEUE_SIZE)383 return;384 q->aux[q->wptr] = aux;385 q->data[q->wptr] = b;386 if (++q->wptr == KBD_QUEUE_SIZE)387 q->wptr = 0;388 q->count++;389 #endif /* !VBOX */390 327 kbd_update_irq(s); 391 328 } … … 410 347 } 411 348 412 #ifndef VBOX413 static void kbd_write_command(void *opaque, uint32_t addr, uint32_t val)414 {415 #else /* VBOX (we need VMReset return code passed back) */416 349 static int kbd_write_command(void *opaque, uint32_t addr, uint32_t val) 417 350 { 418 351 int rc = VINF_SUCCESS; 419 #endif /* VBOX */420 352 KBDState *s = (KBDState*)opaque; 421 353 … … 464 396 /* XXX: check that */ 465 397 #ifdef TARGET_I386 466 # ifndef VBOX467 val = 0x01 | (ioport_get_a20() << 1);468 # else /* VBOX */469 398 val = 0x01 | (PDMDevHlpA20IsEnabled(s->CTX_SUFF(pDevIns)) << 1); 470 # endif /* VBOX */471 399 #else 472 400 val = 0x01; … … 480 408 #ifdef TARGET_I386 481 409 case KBD_CCMD_ENABLE_A20: 482 #ifndef VBOX483 ioport_set_a20(1);484 #else /* VBOX */485 410 # ifndef IN_RING3 486 411 if (!PDMDevHlpA20IsEnabled(s->CTX_SUFF(pDevIns))) … … 489 414 PDMDevHlpA20Set(s->CTX_SUFF(pDevIns), true); 490 415 # endif /* IN_RING3 */ 491 #endif /* VBOX */492 416 break; 493 417 case KBD_CCMD_DISABLE_A20: 494 #ifndef VBOX495 ioport_set_a20(0);496 #else /* VBOX */497 418 # ifndef IN_RING3 498 419 if (PDMDevHlpA20IsEnabled(s->CTX_SUFF(pDevIns))) … … 501 422 PDMDevHlpA20Set(s->CTX_SUFF(pDevIns), false); 502 423 # endif /* !IN_RING3 */ 503 #endif /* VBOX */504 424 break; 505 425 #endif … … 510 430 break; 511 431 case KBD_CCMD_RESET: 512 #ifndef VBOX 513 qemu_system_reset_request(); 514 #else /* VBOX */ 515 # ifndef IN_RING3 432 #ifndef IN_RING3 516 433 rc = VINF_IOM_HC_IOPORT_WRITE; 517 # 434 #else /* IN_RING3 */ 518 435 rc = PDMDevHlpVMReset(s->CTX_SUFF(pDevIns)); 519 # endif /* !IN_RING3 */ 520 #endif /* VBOX */ 436 #endif /* !IN_RING3 */ 521 437 break; 522 438 case 0xff: 523 439 /* ignore that - I don't know what is its use */ 524 440 break; 525 #ifdef VBOX/* Make OS/2 happy. */441 /* Make OS/2 happy. */ 526 442 /* The 8042 RAM is readble using commands 0x20 thru 0x3f, and writable 527 443 by 0x60 thru 0x7f. Now days only the firs byte, the mode, is used. … … 535 451 Log(("kbd: reading non-standard RAM addr %#x\n", val & 0x1f)); 536 452 break; 537 #endif538 453 default: 539 454 Log(("kbd: unsupported keyboard cmd=0x%02x\n", val)); 540 455 break; 541 456 } 542 #ifdef VBOX543 457 return rc; 544 #endif545 458 } 546 459 … … 549 462 KBDState *s = (KBDState*)opaque; 550 463 KBDQueue *q; 551 #ifdef VBOX552 464 MouseCmdQueue *mcq; 553 465 MouseEventQueue *meq; 554 #endif /* VBOX */555 466 int val, index, aux; 556 467 557 468 q = &s->queue; 558 #ifdef VBOX559 469 mcq = &s->mouse_command_queue; 560 470 meq = &s->mouse_event_queue; 561 471 if (q->count == 0 && mcq->count == 0 && meq->count == 0) { 562 #else /* !VBOX */563 if (q->count == 0) {564 #endif /* !VBOX */565 472 /* NOTE: if no data left, we return the last keyboard one 566 473 (needed for EMM386) */ … … 571 478 val = q->data[index]; 572 479 } else { 573 #ifdef VBOX574 480 aux = (s->status & KBD_STAT_MOUSE_OBF); 575 481 if (!aux) … … 597 503 } 598 504 } 599 #else /* !VBOX */600 aux = q->aux[q->rptr];601 val = q->data[q->rptr];602 if (++q->rptr == KBD_QUEUE_SIZE)603 q->rptr = 0;604 q->count--;605 #endif /* !VBOX */606 505 /* reading deasserts IRQ */ 607 #ifndef VBOX608 if (aux)609 pic_set_irq(12, 0);610 else611 pic_set_irq(1, 0);612 #else /* VBOX */613 506 if (aux) 614 507 PDMDevHlpISASetIrq(s->CTX_SUFF(pDevIns), 12, 0); 615 508 else 616 509 PDMDevHlpISASetIrq(s->CTX_SUFF(pDevIns), 1, 0); 617 #endif /* VBOX */618 510 } 619 511 /* reassert IRQs if data left */ … … 630 522 } 631 523 632 #ifndef VBOX633 static void kbd_write_keyboard(KBDState *s, int val)634 #else635 524 static int kbd_write_keyboard(KBDState *s, int val) 636 #endif637 525 { 638 526 switch(s->kbd_write_cmd) { … … 710 598 } 711 599 712 #ifdef VBOX713 600 static void kbd_mouse_send_packet(KBDState *s, bool fToCmdQueue) 714 #else /* !VBOX */ 715 static void kbd_mouse_send_packet(KBDState *s) 716 #endif /* !VBOX */ 717 { 718 #ifdef VBOX 601 { 719 602 int aux = fToCmdQueue ? 1 : 2; 720 #endif /* VBOX */721 603 unsigned int b; 722 604 int dx1, dy1, dz1, dw1; … … 738 620 dy1 = -127; 739 621 b = 0x08 | ((dx1 < 0) << 4) | ((dy1 < 0) << 5) | (s->mouse_buttons & 0x07); 740 #ifdef VBOX741 622 kbd_queue(s, b, aux); 742 623 kbd_queue(s, dx1 & 0xff, aux); 743 624 kbd_queue(s, dy1 & 0xff, aux); 744 #else /* !VBOX */745 kbd_queue(s, b, 1);746 kbd_queue(s, dx1 & 0xff, 1);747 kbd_queue(s, dy1 & 0xff, 1);748 #endif /* !VBOX */749 625 /* extra byte for IMPS/2 or IMEX */ 750 626 switch(s->mouse_type) { … … 756 632 else if (dz1 < -127) 757 633 dz1 = -127; 758 #ifdef VBOX759 634 kbd_queue(s, dz1 & 0xff, aux); 760 #else /* !VBOX */761 kbd_queue(s, dz1 & 0xff, 1);762 #endif /* !VBOX */763 635 break; 764 636 case 4: 765 #ifndef VBOX766 if (dz1 > 7)767 dz1 = 7;768 else if (dz1 < -7)769 dz1 = -7;770 #else771 637 if (dz1 > 1) 772 638 dz1 = 1; … … 779 645 if (dz1) 780 646 dw1 = 0; 781 #endif782 #ifdef VBOX783 647 if ((s->mouse_flags & MOUSE_REPORT_HORIZONTAL) && dw1) 784 648 b = 0x40 | (dw1 & 0x3f); … … 790 654 } 791 655 kbd_queue(s, b, aux); 792 #else /* !VBOX */793 b = (dz1 & 0x0f) | ((s->mouse_buttons & 0x18) << 1);794 kbd_queue(s, b, 1);795 #endif /* !VBOX */796 656 break; 797 657 } … … 801 661 s->mouse_dy -= dy1; 802 662 s->mouse_dz -= dz1; 803 #ifdef VBOX804 663 s->mouse_dw -= dw1; 805 #endif806 664 } 807 665 808 666 #ifdef IN_RING3 809 #ifndef VBOX810 static void pc_kbd_mouse_event(void *opaque,811 int dx, int dy, int dz, int buttons_state)812 #else813 667 static void pc_kbd_mouse_event(void *opaque, 814 668 int dx, int dy, int dz, int dw, int buttons_state) 815 #endif816 669 { 817 670 KBDState *s = (KBDState*)opaque; … … 824 677 s->mouse_dy -= dy; 825 678 s->mouse_dz += dz; 826 #ifdef VBOX827 679 s->mouse_dw += dw; 828 #endif829 #ifndef VBOX830 /* XXX: SDL sometimes generates nul events: we delete them */831 if (s->mouse_dx == 0 && s->mouse_dy == 0 && s->mouse_dz == 0 &&832 s->mouse_buttons == buttons_state)833 return;834 #else835 680 /* The issue described above does not affect VBox, and under some 836 681 * circumstances (which?) we may even wish to send null events to make … … 841 686 if ((s->mouse_buttons & 0x18) != (buttons_state & 0x18)) 842 687 s->mouse_flags |= MOUSE_OUTSTANDING_CLICK; 843 #endif844 688 s->mouse_buttons = buttons_state; 845 689 846 #ifdef VBOX847 690 if (!(s->mouse_status & MOUSE_STATUS_REMOTE) && 848 691 (s->mouse_event_queue.count < (MOUSE_EVENT_QUEUE_SIZE - 4))) { … … 855 698 } 856 699 } 857 #else /* !VBOX */858 if (!(s->mouse_status & MOUSE_STATUS_REMOTE) &&859 (s->queue.count < (KBD_QUEUE_SIZE - 16))) {860 for(;;) {861 /* if not remote, send event. Multiple events are sent if862 too big deltas */863 kbd_mouse_send_packet(s);864 if (s->mouse_dx == 0 && s->mouse_dy == 0 && s->mouse_dz == 0)865 break;866 }867 }868 #endif /* !VBOX */869 700 } 870 701 #endif /* IN_RING3 */ … … 875 706 LogRelFlowFunc(("kbd: write mouse 0x%02x\n", val)); 876 707 #endif 877 #ifdef VBOX878 708 /* Flush the mouse command response queue. */ 879 709 s->mouse_command_queue.count = 0; 880 710 s->mouse_command_queue.rptr = 0; 881 711 s->mouse_command_queue.wptr = 0; 882 #endif /* VBOX */883 712 switch(s->mouse_write_cmd) { 884 713 default: … … 933 762 case AUX_POLL: 934 763 kbd_queue(s, AUX_ACK, 1); 935 #ifdef VBOX936 764 kbd_mouse_send_packet(s, true); 937 #else /* !VBOX */938 kbd_mouse_send_packet(s);939 #endif /* !VBOX */940 765 break; 941 766 case AUX_ENABLE_DEV: … … 946 771 s->mouse_status &= ~MOUSE_STATUS_ENABLED; 947 772 kbd_queue(s, AUX_ACK, 1); 948 #ifdef VBOX949 773 /* Flush the mouse events queue. */ 950 774 s->mouse_event_queue.count = 0; 951 775 s->mouse_event_queue.rptr = 0; 952 776 s->mouse_event_queue.wptr = 0; 953 #endif /* VBOX */954 777 break; 955 778 case AUX_SET_DEFAULT: … … 967 790 kbd_queue(s, 0xaa, 1); 968 791 kbd_queue(s, s->mouse_type, 1); 969 #ifdef VBOX970 792 /* Flush the mouse events queue. */ 971 793 s->mouse_event_queue.count = 0; 972 794 s->mouse_event_queue.rptr = 0; 973 795 s->mouse_event_queue.wptr = 0; 974 #endif /* VBOX */975 796 break; 976 797 default: 977 #ifdef VBOX978 798 /* NACK all commands we don't know. 979 799 … … 994 814 /** @todo send error if we NACKed the previous command? */ 995 815 kbd_queue(s, AUX_NACK, 1); 996 #endif997 816 break; 998 817 } … … 1001 820 s->mouse_sample_rate = val; 1002 821 /* detect IMPS/2 or IMEX */ 1003 #ifdef VBOX1004 822 /* And enable horizontal scrolling reporting when requested */ 1005 #endif1006 823 switch(s->mouse_detect_state) { 1007 824 default: … … 1015 832 else if (val == 200) 1016 833 s->mouse_detect_state = 3; 1017 #ifdef VBOX1018 834 else if ((val == 80) && s->mouse_type == 4 /* IMEX */) 1019 835 /* enable horizontal scrolling, byte two */ 1020 836 s->mouse_detect_state = 4; 1021 #endif1022 837 else 1023 838 s->mouse_detect_state = 0; 1024 839 break; 1025 840 case 2: 1026 #ifdef VBOX1027 841 if (val == 80) 1028 842 { … … 1030 844 s->mouse_type = 3; /* IMPS/2 */ 1031 845 } 1032 #else1033 if (val == 80)1034 s->mouse_type = 3; /* IMPS/2 */1035 #endif1036 846 s->mouse_detect_state = 0; 1037 847 break; 1038 848 case 3: 1039 #ifdef VBOX1040 849 if (val == 80) 1041 850 { … … 1043 852 s->mouse_type = 4; /* IMEX */ 1044 853 } 1045 #else1046 if (val == 80)1047 s->mouse_type = 4; /* IMEX */1048 #endif1049 854 s->mouse_detect_state = 0; 1050 855 break; 1051 #ifdef VBOX1052 856 case 4: 1053 857 if (val == 40) … … 1058 862 s->mouse_detect_state = 0; 1059 863 break; 1060 #endif1061 864 } 1062 865 kbd_queue(s, AUX_ACK, 1); … … 1071 874 } 1072 875 1073 #ifndef VBOX1074 static void kbd_write_data(void *opaque, uint32_t addr, uint32_t val)1075 {1076 #else /* VBOX */1077 876 static int kbd_write_data(void *opaque, uint32_t addr, uint32_t val) 1078 877 { 1079 878 int rc = VINF_SUCCESS; 1080 #endif /* VBOX */1081 879 KBDState *s = (KBDState*)opaque; 1082 880 … … 1101 899 case KBD_CCMD_WRITE_OUTPORT: 1102 900 #ifdef TARGET_I386 1103 # ifndef VBOX1104 ioport_set_a20((val >> 1) & 1);1105 # else /* VBOX */1106 901 # ifndef IN_RING3 1107 902 if (PDMDevHlpA20IsEnabled(s->CTX_SUFF(pDevIns)) != !!(val & 2)) … … 1110 905 PDMDevHlpA20Set(s->CTX_SUFF(pDevIns), !!(val & 2)); 1111 906 # endif /* !IN_RING3 */ 1112 # endif /* VBOX */1113 907 #endif 1114 908 if (!(val & 1)) { 1115 #ifndef VBOX1116 qemu_system_reset_request();1117 #else /* VBOX */1118 909 # ifndef IN_RING3 1119 910 rc = VINF_IOM_HC_IOPORT_WRITE; … … 1121 912 rc = PDMDevHlpVMReset(s->CTX_SUFF(pDevIns)); 1122 913 # endif 1123 #endif /* VBOX */1124 914 } 1125 915 break; … … 1131 921 } 1132 922 s->write_cmd = 0; 1133 1134 #ifdef VBOX1135 923 return rc; 1136 #endif1137 924 } 1138 925 … … 1143 930 KBDState *s = (KBDState*)opaque; 1144 931 KBDQueue *q; 1145 #ifdef VBOX1146 932 MouseCmdQueue *mcq; 1147 933 MouseEventQueue *meq; 1148 #endif /* VBOX */1149 934 1150 935 s->kbd_write_cmd = -1; … … 1152 937 s->mode = KBD_MODE_KBD_INT | KBD_MODE_MOUSE_INT; 1153 938 s->status = KBD_STAT_CMD | KBD_STAT_UNLOCKED; 1154 #ifdef VBOX/* Resetting everything, keyword was not working right on NT4 reboot. */939 /* Resetting everything, keyword was not working right on NT4 reboot. */ 1155 940 s->write_cmd = 0; 1156 941 s->scan_enabled = 0; … … 1167 952 s->mouse_flags = 0; 1168 953 s->mouse_buttons = 0; 1169 #endif1170 954 q = &s->queue; 1171 955 q->rptr = 0; 1172 956 q->wptr = 0; 1173 957 q->count = 0; 1174 #ifdef VBOX1175 958 mcq = &s->mouse_command_queue; 1176 959 mcq->rptr = 0; … … 1181 964 meq->wptr = 0; 1182 965 meq->count = 0; 1183 #endif /* VBOX */1184 966 } 1185 967 1186 968 static void kbd_save(QEMUFile* f, void* opaque) 1187 969 { 1188 #ifdef VBOX1189 970 uint32_t cItems; 1190 971 int i; 1191 #endif /* VBOX */1192 972 KBDState *s = (KBDState*)opaque; 1193 973 … … 1207 987 qemu_put_be32s(f, &s->mouse_dy); 1208 988 qemu_put_be32s(f, &s->mouse_dz); 1209 #ifdef VBOX1210 989 qemu_put_be32s(f, &s->mouse_dw); 1211 990 qemu_put_be32s(f, &s->mouse_flags); 1212 #endif1213 991 qemu_put_8s(f, &s->mouse_buttons); 1214 992 1215 #ifdef VBOX1216 993 /* 1217 994 * We have to save the queues too. … … 1237 1014 /* terminator */ 1238 1015 SSMR3PutU32(f, ~0); 1239 #endif /* VBOX */1240 1016 } 1241 1017 1242 1018 static int kbd_load(QEMUFile* f, void* opaque, int version_id) 1243 1019 { 1244 #ifdef VBOX1245 1020 uint32_t u32, i; 1246 1021 int rc; 1247 #endif1248 1022 KBDState *s = (KBDState*)opaque; 1249 1023 1250 1024 if (version_id < 2 || version_id > PCKBD_SAVED_STATE_VERSION) 1251 #ifndef VBOX1252 return -EINVAL;1253 #else1254 1025 return VERR_SSM_UNSUPPORTED_DATA_UNIT_VERSION; 1255 #endif1256 1026 qemu_get_8s(f, &s->write_cmd); 1257 1027 qemu_get_8s(f, &s->status); … … 1269 1039 qemu_get_be32s(f, (uint32_t *)&s->mouse_dy); 1270 1040 qemu_get_be32s(f, (uint32_t *)&s->mouse_dz); 1271 #ifdef VBOX1272 1041 if (version_id > 2) 1273 1042 { … … 1275 1044 qemu_get_be32s(f, (uint32_t *)&s->mouse_flags); 1276 1045 } 1277 #endif1278 1046 qemu_get_8s(f, &s->mouse_buttons); 1279 #ifdef VBOX1280 1047 s->queue.count = 0; 1281 1048 s->queue.rptr = 0; … … 1354 1121 return VERR_SSM_DATA_UNIT_FORMAT_CHANGED; 1355 1122 } 1356 #endif /* VBOX */1357 1123 return 0; 1358 1124 } 1359 1360 #ifndef VBOX1361 void kbd_init(void)1362 {1363 KBDState *s = &kbd_state;1364 1365 kbd_reset(s);1366 register_savevm("pckbd", 0, 1, kbd_save, kbd_load, s);1367 register_ioport_read(0x60, 1, 1, kbd_read_data, s);1368 register_ioport_write(0x60, 1, 1, kbd_write_data, s);1369 register_ioport_read(0x64, 1, 1, kbd_read_status, s);1370 register_ioport_write(0x64, 1, 1, kbd_write_command, s);1371 1372 qemu_add_kbd_event_handler(pc_kbd_put_keycode, s);1373 qemu_add_mouse_event_handler(pc_kbd_mouse_event, s);1374 qemu_register_reset(kbd_reset, s);1375 }1376 #endif /* !VBOX */1377 1378 1125 #endif /* IN_RING3 */ 1379 1126 1380 1127 1381 #ifdef VBOX/* VirtualBox code start */1128 /* VirtualBox code start */ 1382 1129 1383 1130 /* -=-=-=-=-=- wrappers -=-=-=-=-=- */ … … 1961 1708 1962 1709 #endif /* IN_RING3 */ 1963 #endif /* VBOX */1964 1710 #endif /* !VBOX_DEVICE_STRUCT_TESTCASE */ 1965 1711
Note:
See TracChangeset
for help on using the changeset viewer.