Previous 15994 Revisions Next

r11724 Monday 30th May, 2011 at 14:26:32 UTC by Miodrag Milanović
idectrl - implemented verify no retry command [Carl]
i86 - Fixed imul instruction [Carl]

Credited in MAME
[src/emu/cpu/i86]instr186.c instr286.c
[src/emu/machine]idectrl.c

src/emu/cpu/i86/instr186.c
r11723r11724
6868{
6969   DEF_r16w(dst,src);
7070   unsigned src2=FETCH;
71   src+=(FETCH<<8);
71   src2+=(FETCH<<8);
7272
7373   ICOUNT -= (ModRM >= 0xc0) ? timing.imul_rri16 : timing.imul_rmi16;
7474
src/emu/cpu/i86/instr286.c
r11723r11724
510510            desc[2] = ReadWord(addr+4);
511511            r = RIGHTS(desc);
512512            if (SEGDESC(r) || (GATE(r) != LDTDESC)) throw TRAP(GENERAL_PROTECTION_FAULT,IDXTBL(sel));
513            if (!PRES(r)) TRAP(SEG_NOT_PRESENT,IDXTBL(sel));
513            if (!PRES(r)) throw TRAP(SEG_NOT_PRESENT,IDXTBL(sel));
514514         } else {
515515            desc[0] = 0;
516516            desc[1] = 0;
r11723r11724
530530         desc[2] = ReadWord(addr+4);
531531         r = RIGHTS(desc);
532532         if (SEGDESC(r) || (GATE(r) != TSSDESCIDLE)) throw TRAP(GENERAL_PROTECTION_FAULT,IDXTBL(sel));
533         if (!PRES(r)) TRAP(SEG_NOT_PRESENT,IDXTBL(sel));
533         if (!PRES(r)) throw TRAP(SEG_NOT_PRESENT,IDXTBL(sel));
534534         desc[2] |= 0x200; // mark busy
535535         WriteWord(addr+4, desc[2]);
536536         cpustate->tr.sel=sel;
src/emu/machine/idectrl.c
r11723r11724
7979#define IDE_COMMAND_SECURITY_UNLOCK      0xf2
8080#define IDE_COMMAND_UNKNOWN_F9         0xf9
8181#define IDE_COMMAND_VERIFY_MULTIPLE      0x40
82#define IDE_COMMAND_VERIFY_NORETRY      0x41
8283#define IDE_COMMAND_ATAPI_IDENTIFY      0xa1
8384#define IDE_COMMAND_RECALIBRATE         0x10
8485#define IDE_COMMAND_IDLE_IMMEDIATE      0xe1
r11723r11724
10401041         break;
10411042
10421043      case IDE_COMMAND_VERIFY_MULTIPLE:
1043         LOGPRINT(("IDE Read verify multiple with retries: C=%d H=%d S=%d LBA=%d count=%d\n",
1044      case IDE_COMMAND_VERIFY_NORETRY:
1045         LOGPRINT(("IDE Read verify multiple with/without retries: C=%d H=%d S=%d LBA=%d count=%d\n",
10441046            ide->cur_cylinder, ide->cur_head, ide->cur_sector, lba_address(ide), ide->sector_count));
10451047
10461048         /* reset the buffer */

Previous 15994 Revisions Next


© 1998-2018 The MESS Team