Previous 15994 Revisions Next

r6448 Monday 23rd November, 2009 at 23:27:53 UTC by Harmony
[N64] A couple of core SCSI and WD33C93 controller-related fixes; allows IP22 to begin running its diagnostics and begin installing IRIX 6.5 [Harmony]
[src/emu/machine]scsihd.c wd33c93.c

src/emu/machine/scsihd.c
r6447r6448
222222   switch ( command[0] )
223223   {
224224      case 0x0a: // WRITE(6)
225      case 0x2a: // WRITE(10)
225226         if ((our_this->disk) && (our_this->blocks))
226227         {
228            printf("We have a disc and we have %d blocks, with a data length of %d, time to write\n", our_this->blocks, dataLength);
227229            while (dataLength > 0)
228230            {
231               printf("Attempting to write some data at LBA %08x\n", our_this->lba);
229232               if (!hard_disk_write(our_this->disk, our_this->lba, data))
230233               {
231234                  logerror("SCSIHD: HD write error!\n");
r6447r6448
306309         return 0;
307310
308311      case SCSIOP_WRITE_DATA:
312         printf("intparm = %08x%08x\n", (UINT32)(intparm >> 32), (UINT32)(intparm & 0x00000000ffffffff));
309313         scsihd_write_data( (SCSIInstance *)file, (UINT8 *)ptrparm, intparm );
310314         return 0;
311315
src/emu/machine/wd33c93.c
r6447r6448
172172typedef void (*cmd_handler)(running_machine *machine);
173173#define CMD_HANDLER(name) void name(running_machine *machine)
174174
175#define TEMP_INPUT_LEN   65536
175#define TEMP_INPUT_LEN   262144
176176#define FIFO_SIZE      12
177177
178178/* internal controller data definition */
r6447r6448
815815
816816void wd33c93_get_dma_data( int bytes, UINT8 *pData )
817817{
818   int      len = bytes;
818   int   len = bytes;
819819
820820   if ( len >= wd33c93_get_xfer_count() )
821821      len = wd33c93_get_xfer_count();
r6447r6448
829829      len = TEMP_INPUT_LEN - len;
830830   }
831831
832   assert(len);
833
832834   memcpy( pData, &scsi_data.temp_input[scsi_data.temp_input_pos], len );
833835
834836   scsi_data.temp_input_pos += len;

Previous 15994 Revisions Next


© 1998-2018 The MESS Team