~ubuntu-branches/debian/wheezy/mame/wheezy

« back to all changes in this revision

Viewing changes to src/emu/machine/am53cf96.c

  • Committer: Bazaar Package Importer
  • Author(s): Jordi Mallach, Emmanuel Kasper, Félix Arreola Rodríguez, Jordi Mallach
  • Date: 2011-05-11 21:06:50 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20110511210650-jizvh8a6x117y9hr
Tags: 0.142-1
[ Emmanuel Kasper ]
* New upstream release
* Set NOWERROR=1 to allow compiling with gcc-4.6
* Remove fix_powerpc_build.patch, as upstream has taken it in this release
* Add gnome-video-arcade front end as a suggested package

[ Félix Arreola Rodríguez ]
* Add kfreebsd-build.patch to quilt series, to fix build on kfreebsd

[ Jordi Mallach ]
* Remove unneeded and bogus addition of --with-quilt to the dh invocation.
* Add Cesare Falco (long time Ubuntu maintainer) to Uploaders, and wrap
  them into multiple lines.

Show diffs side-by-side

added added

removed removed

Lines of Context:
69
69
 
70
70
        if (reg == REG_FIFO)
71
71
        {
72
 
//      mame_printf_debug("53cf96: read FIFO PC=%x\n", cpu_get_pc(space->cpu));
 
72
//      mame_printf_debug("53cf96: read FIFO PC=%x\n", cpu_get_pc(&space->device()));
73
73
                return 0;
74
74
        }
75
75
 
76
 
//  logerror("53cf96: read reg %d = %x (PC=%x)\n", reg, rv>>shift, cpu_get_pc(space->cpu));
 
76
//  logerror("53cf96: read reg %d = %x (PC=%x)\n", reg, rv>>shift, cpu_get_pc(&space->device()));
77
77
 
78
78
        if (reg == REG_IRQSTATE)
79
79
        {
106
106
        }
107
107
        val &= 0xff;
108
108
 
109
 
//  logerror("53cf96: w %x to reg %d (ofs %02x data %08x mask %08x PC=%x)\n", val, reg, offset, data, mem_mask, cpu_get_pc(space->cpu));
 
109
//  logerror("53cf96: w %x to reg %d (ofs %02x data %08x mask %08x PC=%x)\n", val, reg, offset, data, mem_mask, cpu_get_pc(&space->device()));
110
110
 
111
111
        // if writing to the target ID, cache it off for later
112
112
        if (reg == REG_STATUS)
144
144
                        case 2: // reset device
145
145
                                scsi_regs[REG_IRQSTATE] = 8;    // indicate success
146
146
 
147
 
                                logerror("53cf96: reset  target ID = %d (PC = %x)\n", last_id, cpu_get_pc(space->cpu));
 
147
                                logerror("53cf96: reset  target ID = %d (PC = %x)\n", last_id, cpu_get_pc(&space->device()));
148
148
                                if (devices[last_id])
149
149
                                {
150
150
                                        SCSIReset( devices[last_id] );
159
159
                        case 3: // reset SCSI bus
160
160
                                scsi_regs[REG_INTSTATE] = 4;    // command sent OK
161
161
                                xfer_state = 0;
162
 
                                timer_set( space->machine, ATTOTIME_IN_HZ( 16384 ), NULL, 0, am53cf96_irq );
 
162
                                space->machine().scheduler().timer_set( attotime::from_hz( 16384 ), FUNC(am53cf96_irq ));
163
163
                                break;
164
164
                        case 0x42:      // select with ATN steps
165
 
                                timer_set( space->machine, ATTOTIME_IN_HZ( 16384 ), NULL, 0, am53cf96_irq );
 
165
                                space->machine().scheduler().timer_set( attotime::from_hz( 16384 ), FUNC(am53cf96_irq ));
166
166
                                if ((fifo[1] == 0) || (fifo[1] == 0x48) || (fifo[1] == 0x4b))
167
167
                                {
168
168
                                        scsi_regs[REG_INTSTATE] = 6;
172
172
                                        scsi_regs[REG_INTSTATE] = 4;
173
173
                                }
174
174
 
175
 
                                logerror("53cf96: command %x exec.  target ID = %d (PC = %x)\n", fifo[1], last_id, cpu_get_pc(space->cpu));
 
175
                                logerror("53cf96: command %x exec.  target ID = %d (PC = %x)\n", fifo[1], last_id, cpu_get_pc(&space->device()));
176
176
                                if (devices[last_id])
177
177
                                {
178
178
                                        int length;
192
192
                        case 0x10:      // information transfer (must not change xfer_state)
193
193
                        case 0x11:      // second phase of information transfer
194
194
                        case 0x12:      // message accepted
195
 
                                timer_set( space->machine, ATTOTIME_IN_HZ( 16384 ), NULL, 0, am53cf96_irq );
 
195
                                space->machine().scheduler().timer_set( attotime::from_hz( 16384 ), FUNC(am53cf96_irq ));
196
196
                                scsi_regs[REG_INTSTATE] = 6;    // command sent OK
197
197
                                break;
198
198
                        default:
208
208
        }
209
209
}
210
210
 
211
 
void am53cf96_init( running_machine *machine, const struct AM53CF96interface *interface )
 
211
void am53cf96_init( running_machine &machine, const struct AM53CF96interface *interface )
212
212
{
213
213
        int i;
214
214