|
@@ -20,6 +20,7 @@
|
20
|
20
|
#include <memory>
|
21
|
21
|
|
22
|
22
|
#include "resetable.h"
|
|
23
|
+#include "traceable.h"
|
23
|
24
|
#include "resource_access_if.h"
|
24
|
25
|
#include "util/delegate.h"
|
25
|
26
|
#include "utilities.h"
|
|
@@ -234,7 +235,7 @@ public:
|
234
|
235
|
*
|
235
|
236
|
* @param write_cb
|
236
|
237
|
*/
|
237
|
|
- void set_write_cb(std::function<bool(this_type &, DATATYPE &)> write_cb) {
|
|
238
|
+ void set_write_cb(std::function<bool(this_type &, const DATATYPE &)> write_cb) {
|
238
|
239
|
wr_cb = [write_cb](this_type ®, DATATYPE &data, sc_core::sc_time delay) { return write_cb(reg, data); };
|
239
|
240
|
}
|
240
|
241
|
/**
|
|
@@ -242,7 +243,7 @@ public:
|
242
|
243
|
*
|
243
|
244
|
* @param write_cb
|
244
|
245
|
*/
|
245
|
|
- void set_write_cb(std::function<bool(this_type &, DATATYPE &, sc_core::sc_time)> write_cb) { wr_cb = write_cb; }
|
|
246
|
+ void set_write_cb(std::function<bool(this_type &, const DATATYPE &, sc_core::sc_time)> write_cb) { wr_cb = write_cb; }
|
246
|
247
|
/**
|
247
|
248
|
* trace the register value to the given trace file
|
248
|
249
|
*
|