diff options
author | Andrew Waterman <andrew@sifive.com> | 2022-01-09 17:04:17 -0800 |
---|---|---|
committer | Andrew Waterman <andrew@sifive.com> | 2022-01-09 17:05:07 -0800 |
commit | d1a3a4255295b742728b8c851a222cfbf06e8116 (patch) | |
tree | 22b1f5d3175faff032308b4f4cc1bb187cc9498d /riscv/debug_module.cc | |
parent | 39fc8c3921e8c9ffd9996a7d59df239b2488a206 (diff) | |
download | spike-d1a3a4255295b742728b8c851a222cfbf06e8116.zip spike-d1a3a4255295b742728b8c851a222cfbf06e8116.tar.gz spike-d1a3a4255295b742728b8c851a222cfbf06e8116.tar.bz2 |
Changes to be cleaner wrt. -Wextra
h/t @jerinjoy
See #901
Diffstat (limited to 'riscv/debug_module.cc')
-rw-r--r-- | riscv/debug_module.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/riscv/debug_module.cc b/riscv/debug_module.cc index ef25b4d..10ff9bb 100644 --- a/riscv/debug_module.cc +++ b/riscv/debug_module.cc @@ -87,20 +87,20 @@ void debug_module_t::reset() proc->halt_request = proc->HR_NONE; } - dmcontrol = {0}; + memset(&dmcontrol, 0, sizeof(dmcontrol)); - dmstatus = {0}; + memset(&dmstatus, 0, sizeof(dmstatus)); dmstatus.impebreak = config.support_impebreak; dmstatus.authenticated = !config.require_authentication; dmstatus.version = 2; - abstractcs = {0}; + memset(&abstractcs, 0, sizeof(abstractcs)); abstractcs.datacount = sizeof(dmdata) / 4; abstractcs.progbufsize = config.progbufsize; - abstractauto = {0}; + memset(&abstractauto, 0, sizeof(abstractauto)); - sbcs = {0}; + memset(&sbcs, 0, sizeof(sbcs)); if (config.max_sba_data_width > 0) { sbcs.version = 1; sbcs.asize = sizeof(reg_t) * 8; |