summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/cpu/sh4/sh4comn.c
diff options
context:
space:
mode:
author Aaron Giles <aaron@aarongiles.com>2010-07-01 00:34:46 +0000
committer Aaron Giles <aaron@aarongiles.com>2010-07-01 00:34:46 +0000
commitde771cbfeb7c38387972208e5c731c6074e89318 (patch)
treec54ebeb9f02a82e39f81e2f3aaa3d291f06d7c15 /src/emu/cpu/sh4/sh4comn.c
parentdfc04871c447c7fe041d15023b472a641454ffc7 (diff)
Remove the following functions:
cpu_get_total_cycles() == cpudevice->total_cycles() cpu_clocks_to_attotime() == cpudevice->cycles_to_attotime() cpu_attotime_to_clocks() == cpudevice->attotime_to_cycles() In some cases, I updated existing code that fetched and cached devices to fetch them as cpu_device so that these can be called without casting. In other cases, I did the quick & dirty thing which was to downcast a generic device to a cpu_device and then call the function. Note that cpu_clocks_to_attotime() and cpu_attotime_to_clocks() were previously mapping to the device-level functions clocks_to_attotime() and attotime_to_clocks(). This was different behavior than before the big devices change, so with this update I have fixed it to match the previous behavior (i.e., map cycles not clocks). This may impact timing of drivers that used these functions on CPUs that have clock dividers or multipliers.
Diffstat (limited to 'src/emu/cpu/sh4/sh4comn.c')
-rw-r--r--src/emu/cpu/sh4/sh4comn.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/emu/cpu/sh4/sh4comn.c b/src/emu/cpu/sh4/sh4comn.c
index 5c7856de7ce..c5079e51a41 100644
--- a/src/emu/cpu/sh4/sh4comn.c
+++ b/src/emu/cpu/sh4/sh4comn.c
@@ -461,7 +461,7 @@ static int sh4_dma_transfer(SH4 *sh4, int channel, int timermode, UINT32 chcr, U
if (timermode == 1)
{
sh4->dma_timer_active[channel] = 1;
- timer_adjust_oneshot(sh4->dma_timer[channel], cpu_clocks_to_attotime(sh4->device, 2*count+1), channel);
+ timer_adjust_oneshot(sh4->dma_timer[channel], sh4->device->cycles_to_attotime(2*count+1), channel);
}
else if (timermode == 2)
{