diff options
Diffstat (limited to 'src/devices/cpu/h8')
| -rw-r--r-- | src/devices/cpu/h8/h8.cpp | 6 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_dma.cpp | 6 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_dma.h | 2 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_dtc.cpp | 7 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_sci.cpp | 30 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_timer16.cpp | 14 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_timer8.cpp | 6 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_watchdog.cpp | 8 | ||||
| -rw-r--r-- | src/devices/cpu/h8/h8_watchdog.h | 2 |
9 files changed, 40 insertions, 41 deletions
diff --git a/src/devices/cpu/h8/h8.cpp b/src/devices/cpu/h8/h8.cpp index a92143e5680..bd53761bb6a 100644 --- a/src/devices/cpu/h8/h8.cpp +++ b/src/devices/cpu/h8/h8.cpp @@ -146,9 +146,9 @@ void h8_device::set_current_dma(h8_dma_state *state) logerror("DMA done\n"); else logerror("New current dma s=%x d=%x is=%d id=%d count=%x m=%d\n", - state->source, state->dest, state->incs, state->incd, - state->count, state->mode_16 ? 16 : 8); - + state->source, state->dest, state->incs, state->incd, + state->count, state->mode_16 ? 16 : 8); + } void h8_device::set_current_dtc(h8_dtc_state *state) diff --git a/src/devices/cpu/h8/h8_dma.cpp b/src/devices/cpu/h8/h8_dma.cpp index 637e1a98b5c..fb907ffcef1 100644 --- a/src/devices/cpu/h8/h8_dma.cpp +++ b/src/devices/cpu/h8/h8_dma.cpp @@ -277,7 +277,7 @@ bool h8_dma_channel_device::start_test(int vector) if(dte == 0) return false; - throw emu_fatalerror("%s: DMA startup test in short address mode unimplemented.\n", tag()); + throw emu_fatalerror("%s: DMA startup test in short address mode unimplemented.\n", tag()); } } @@ -297,7 +297,7 @@ void h8_dma_channel_device::start(int submodule) cpu->set_current_dma(state + submodule); } } else { - throw emu_fatalerror("%s: DMA start in short address mode unimplemented.\n", tag()); + throw emu_fatalerror("%s: DMA start in short address mode unimplemented.\n", tag()); } } @@ -315,6 +315,6 @@ void h8_dma_channel_device::count_done(int submodule) throw emu_fatalerror("%s: DMA end-of-transfer interrupt in full address/normal mode unimplemented.\n", tag()); } } else { - throw emu_fatalerror("%s: DMA count done in short address mode unimplemented.\n", tag()); + throw emu_fatalerror("%s: DMA count done in short address mode unimplemented.\n", tag()); } } diff --git a/src/devices/cpu/h8/h8_dma.h b/src/devices/cpu/h8/h8_dma.h index e241fb5653e..c561f15aea8 100644 --- a/src/devices/cpu/h8/h8_dma.h +++ b/src/devices/cpu/h8/h8_dma.h @@ -25,7 +25,7 @@ struct h8_dma_state { #define MCFG_H8_DMA_ADD( _tag ) \ MCFG_DEVICE_ADD( _tag, H8_DMA, 0 ) -#define MCFG_H8_DMA_CHANNEL_ADD( _tag, intc, irq_base, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9, va, vb, vc, vd, ve, vf ) \ +#define MCFG_H8_DMA_CHANNEL_ADD( _tag, intc, irq_base, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9, va, vb, vc, vd, ve, vf ) \ MCFG_DEVICE_ADD( _tag, H8_DMA_CHANNEL, 0 ) \ downcast<h8_dma_channel_device *>(device)->set_info(intc, irq_base, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9, va, vb, vc, vd, ve, vf); diff --git a/src/devices/cpu/h8/h8_dtc.cpp b/src/devices/cpu/h8/h8_dtc.cpp index 0efb6200a54..12cd8155773 100644 --- a/src/devices/cpu/h8/h8_dtc.cpp +++ b/src/devices/cpu/h8/h8_dtc.cpp @@ -131,7 +131,7 @@ void h8_dtc_device::vector_done(int vector) UINT32 mode = sra & 0x0c000000; if(V>=1) logerror("regs at %08x sra=%08x dar=%08x cr=%08x %s mode\n", state->base, sra, dar, cr, - mode == 0x00000000 || mode == 0x0c000000 ? "normal" : mode == 0x04000000 ? "repeat" : "block"); + mode == 0x00000000 || mode == 0x0c000000 ? "normal" : mode == 0x04000000 ? "repeat" : "block"); state->incs = sra & 0x80000000 ? sra & 0x40000000 ? sra & 0x01000000 ? -2 : -1 : sra & 0x01000000 ? 2 : 1 : @@ -140,7 +140,7 @@ void h8_dtc_device::vector_done(int vector) sra & 0x10000000 ? sra & 0x01000000 ? -2 : -1 : sra & 0x01000000 ? 2 : 1 : 0; - + switch(mode) { case 0x00000000: case 0x0c0000000: state->count = 1; @@ -215,7 +215,7 @@ bool h8_dtc_device::trigger_dtc(int vector) { int slot = vector_to_enable[vector]; if(slot == -1) - return false; + return false; if(dtcer[slot >> 3] & (0x01 << (7-(slot & 7)))) { edge(vector); return true; @@ -266,4 +266,3 @@ void h8_dtc_device::count_done(int id) cpu->request_state(h8_device::STATE_DTC_WRITEBACK); waiting_writeback.push_back(id); } - diff --git a/src/devices/cpu/h8/h8_sci.cpp b/src/devices/cpu/h8/h8_sci.cpp index e4806fa4138..e07cca2722b 100644 --- a/src/devices/cpu/h8/h8_sci.cpp +++ b/src/devices/cpu/h8/h8_sci.cpp @@ -44,13 +44,13 @@ WRITE8_MEMBER(h8_sci_device::smr_w) { smr = data; if(V>=2) logerror("smr_w %02x %s %c%c%c%s /%d (%06x)\n", data, - data & SMR_CA ? "sync" : "async", - data & SMR_CHR ? '7' : '8', - data & SMR_PE ? data & SMR_OE ? 'o' : 'e' : 'n', - data & SMR_STOP ? '2' : '1', - data & SMR_MP ? " mp" : "", - 1 << 2*(data & SMR_CKS), - cpu->pc()); + data & SMR_CA ? "sync" : "async", + data & SMR_CHR ? '7' : '8', + data & SMR_PE ? data & SMR_OE ? 'o' : 'e' : 'n', + data & SMR_STOP ? '2' : '1', + data & SMR_MP ? " mp" : "", + 1 << 2*(data & SMR_CKS), + cpu->pc()); clock_update(); } @@ -86,14 +86,14 @@ bool h8_sci_device::has_recv_error() const WRITE8_MEMBER(h8_sci_device::scr_w) { if(V>=2) logerror("scr_w %02x%s%s%s%s%s%s clk=%d (%06x)\n", data, - data & SCR_TIE ? " txi" : "", - data & SCR_RIE ? " rxi" : "", - data & SCR_TE ? " tx" : "", - data & SCR_RE ? " rx" : "", - data & SCR_MPIE ? " mpi" : "", - data & SCR_TEIE ? " tei" : "", - data & SCR_CKE, - cpu->pc()); + data & SCR_TIE ? " txi" : "", + data & SCR_RIE ? " rxi" : "", + data & SCR_TE ? " tx" : "", + data & SCR_RE ? " rx" : "", + data & SCR_MPIE ? " mpi" : "", + data & SCR_TEIE ? " tei" : "", + data & SCR_CKE, + cpu->pc()); UINT8 delta = scr ^ data; scr = data; diff --git a/src/devices/cpu/h8/h8_timer16.cpp b/src/devices/cpu/h8/h8_timer16.cpp index 4c7bec631a5..796a26c0fef 100644 --- a/src/devices/cpu/h8/h8_timer16.cpp +++ b/src/devices/cpu/h8/h8_timer16.cpp @@ -103,13 +103,13 @@ WRITE8_MEMBER(h8_timer16_channel_device::tier_w) tier = data; tier_update(); if(V>=1) logerror("irq %c%c%c%c%c%c trigger=%d\n", - ier & IRQ_A ? 'a' : '.', - ier & IRQ_B ? 'b' : '.', - ier & IRQ_C ? 'c' : '.', - ier & IRQ_D ? 'd' : '.', - ier & IRQ_V ? 'v' : '.', - ier & IRQ_U ? 'u' : '.', - ier & IRQ_TRIG ? 1 : 0); + ier & IRQ_A ? 'a' : '.', + ier & IRQ_B ? 'b' : '.', + ier & IRQ_C ? 'c' : '.', + ier & IRQ_D ? 'd' : '.', + ier & IRQ_V ? 'v' : '.', + ier & IRQ_U ? 'u' : '.', + ier & IRQ_TRIG ? 1 : 0); recalc_event(); } diff --git a/src/devices/cpu/h8/h8_timer8.cpp b/src/devices/cpu/h8/h8_timer8.cpp index 0b9d5da933c..671170e1cab 100644 --- a/src/devices/cpu/h8/h8_timer8.cpp +++ b/src/devices/cpu/h8/h8_timer8.cpp @@ -130,9 +130,9 @@ void h8_timer8_channel_device::update_tcr() } if(V>=1) p += sprintf(p, ", irq=%c%c%c\n", - tcr & TCR_CMIEB ? 'b' : '-', - tcr & TCR_CMIEA ? 'a' : '-', - tcr & TCR_OVIE ? 'o' : '-'); + tcr & TCR_CMIEB ? 'b' : '-', + tcr & TCR_CMIEA ? 'a' : '-', + tcr & TCR_OVIE ? 'o' : '-'); logerror(buf); } diff --git a/src/devices/cpu/h8/h8_watchdog.cpp b/src/devices/cpu/h8/h8_watchdog.cpp index 91c097b8db1..19d9131819a 100644 --- a/src/devices/cpu/h8/h8_watchdog.cpp +++ b/src/devices/cpu/h8/h8_watchdog.cpp @@ -27,7 +27,7 @@ UINT64 h8_watchdog_device::internal_update(UINT64 current_time) int shift = (type == S ? div_s : div_bh)[tcsr & TCSR_CKS]; UINT64 spos = tcnt_cycle_base >> shift; return (spos + 0x100 - tcnt) << shift; - + } else return 0; } @@ -44,7 +44,7 @@ void h8_watchdog_device::tcnt_update(UINT64 cur_time) int next_tcnt = tcnt + int(epos - spos); tcnt = next_tcnt; tcnt_cycle_base = cur_time; - // logerror("%10lld tcnt %02x -> %03x shift=%d\n", cur_time, tcnt, next_tcnt, shift); + // logerror("%10lld tcnt %02x -> %03x shift=%d\n", cur_time, tcnt, next_tcnt, shift); if(next_tcnt >= 0x100) { logerror("watchdog triggered\n"); @@ -57,7 +57,7 @@ void h8_watchdog_device::tcnt_update(UINT64 cur_time) if(!(tcsr & TCSR_OVF)) { tcsr |= TCSR_OVF; intc->internal_interrupt(irq); - } + } } } } else @@ -91,7 +91,7 @@ WRITE16_MEMBER(h8_watchdog_device::wd_w) if(tcsr & TCSR_TME) { tcnt = data & 0xff; tcnt_cycle_base = cpu->total_cycles(); - // logerror("%10lld tcnt = %02x\n", tcnt_cycle_base, tcnt); + // logerror("%10lld tcnt = %02x\n", tcnt_cycle_base, tcnt); } cpu->internal_update(); } diff --git a/src/devices/cpu/h8/h8_watchdog.h b/src/devices/cpu/h8/h8_watchdog.h index d5c0d5d21a1..efb77b29c05 100644 --- a/src/devices/cpu/h8/h8_watchdog.h +++ b/src/devices/cpu/h8/h8_watchdog.h @@ -43,7 +43,7 @@ #include "h8.h" #include "h8_intc.h" -#define MCFG_H8_WATCHDOG_ADD( _tag, intc, irq, type ) \ +#define MCFG_H8_WATCHDOG_ADD( _tag, intc, irq, type ) \ MCFG_DEVICE_ADD( _tag, H8_WATCHDOG, 0 ) \ downcast<h8_watchdog_device *>(device)->set_info(intc, irq, type); |
