--- np2/bios/sxsibios.c 2004/03/12 18:19:57 1.14 +++ np2/bios/sxsibios.c 2005/03/05 06:02:28 1.17 @@ -51,7 +51,7 @@ static REG8 sxsibios_write(UINT type, SX long pos; UINT32 addr; UINT r; - BYTE work[1024]; + UINT8 work[1024]; size = CPU_BX; if (!size) { @@ -82,7 +82,7 @@ static REG8 sxsibios_read(UINT type, SXS long pos; UINT32 addr; UINT r; - BYTE work[1024]; + UINT8 work[1024]; size = CPU_BX; if (!size) { @@ -174,7 +174,7 @@ static REG8 sasibios_init(UINT type, SXS diskequip &= 0xf0ff; for (i=0x00, bit=0x0100; i<0x02; i++, bit<<=1) { sxsi = sxsi_getptr(i); - if ((sxsi) && (sxsi->fname[0])) { + if ((sxsi) && (sxsi->flag & SXSIFLAG_READY)) { diskequip |= bit; } } @@ -187,7 +187,7 @@ static REG8 sasibios_init(UINT type, SXS static REG8 sasibios_sense(UINT type, SXSIDEV sxsi) { if (type == SXSIBIOS_SASI) { - return((REG8)((sxsi->type >> 8) & 7)); + return((REG8)(sxsi->mediatype & 7)); } else { if (CPU_AH == 0x84) { @@ -249,7 +249,7 @@ REG8 sasibios_operate(void) { static void scsibios_set(REG8 drv, REG8 sectors, REG8 surfaces, REG16 cylinders, REG16 size, BOOL hwsec) { - BYTE *scsiinf; + UINT8 *scsiinf; UINT16 inf; scsiinf = mem + 0x00460 + ((drv & 7) * 4); @@ -283,7 +283,7 @@ static REG8 scsibios_init(UINT type, SXS ZeroMemory(&mem[0x00460], 0x20); for (i=0, bit=1; i<4; i++, bit<<=1) { sxsi = sxsi_getptr((REG8)(0x20 + i)); - if ((sxsi) && (sxsi->fname[0])) { + if ((sxsi) && (sxsi->flag & SXSIFLAG_READY)) { mem[MEMB_DISK_EQUIPS] |= bit; scsibios_set(i, sxsi->sectors, sxsi->surfaces, sxsi->cylinders, sxsi->size, TRUE); @@ -295,7 +295,7 @@ static REG8 scsibios_init(UINT type, SXS static REG8 scsibios_sense(UINT type, SXSIDEV sxsi) { - BYTE *scsiinf; + UINT8 *scsiinf; scsiinf = mem + 0x00460 + ((CPU_AL & 7) * 4); if (CPU_AH == 0x24) { @@ -374,7 +374,7 @@ REG8 scsibios_operate(void) { // ---- np2sysp -#if defined(SUPPORT_SASI) || defined(SUPPORT_SCSI) +#if defined(SUPPORT_IDEIO) || defined(SUPPORT_SASI) || defined(SUPPORT_SCSI) typedef struct { UINT16 ax; UINT16 cx; @@ -417,15 +417,15 @@ static void reg_pop(const REGBAK *r) { } typedef struct { - BYTE r_ax[2]; - BYTE r_bx[2]; - BYTE r_cx[2]; - BYTE r_dx[2]; - BYTE r_bp[2]; - BYTE r_es[2]; - BYTE r_di[2]; - BYTE r_si[2]; - BYTE r_ds[2]; + UINT8 r_ax[2]; + UINT8 r_bx[2]; + UINT8 r_cx[2]; + UINT8 r_dx[2]; + UINT8 r_bp[2]; + UINT8 r_es[2]; + UINT8 r_di[2]; + UINT8 r_si[2]; + UINT8 r_ds[2]; } B1BREG; static void reg_load(UINT seg, UINT off) { @@ -463,7 +463,7 @@ static void reg_store(UINT seg, UINT off } #endif -#if defined(SUPPORT_SASI) +#if defined(SUPPORT_IDEIO) || defined(SUPPORT_SASI) void np2sysp_sasi(const void *arg1, long arg2) { UINT seg;