@@ -36,7 +36,7 @@ TEST(auto_configure, simple) {
36
36
#define VERSIONIDSTRINGIFY (x ) #x
37
37
#define VERSIONIDTOSTR (x ) VERSIONIDSTRINGIFY(x)
38
38
#define DEVICE_FIELDS " 23"
39
- #define DEVICE_FIELDS_DEV_GLOBAL " 36 "
39
+ #define DEVICE_FIELDS_DEV_GLOBAL " 38 "
40
40
#define DEVICE_FIELDS_OLD " 18"
41
41
#define BOARDNAME " de4_gen2x4_swdimm"
42
42
#define BOARDNAME2 " pcie385_a7"
@@ -99,11 +99,11 @@ TEST(auto_configure, simple) {
99
99
100
100
// Device global autodiscovery entries
101
101
#define NUM_DEV_GLOBAL " 2"
102
- #define NUM_DEV_GLOBAL_FIELD \
103
- " 6 " // contains dev_globa_name, address, size, host_access, init_mode ,
104
- // implement_in_csr with the above format
105
- #define DEV_GLOBAL_1 " kernel15_dev_global 0x1000 2048 3 1 0"
106
- #define DEV_GLOBAL_2 " kernel15_dev_global2 0x800 1024 1 0 1"
102
+ #define NUM_DEV_GLOBAL_FIELD " 7 "
103
+ // The 7 fields are dev_globa_name, address, size, host_access,
104
+ // can_skip_programming, implement_in_csr, reset_on_reuse
105
+ #define DEV_GLOBAL_1 " kernel15_dev_global 0x1000 2048 3 0 0 0"
106
+ #define DEV_GLOBAL_2 " kernel15_dev_global2 0x800 1024 1 0 1 0 "
107
107
108
108
int parsed;
109
109
std::string err_str;
@@ -286,16 +286,16 @@ TEST(auto_configure, simple) {
286
286
CHECK_EQUAL (2048 , kernel15_dev_global->second .size );
287
287
CHECK_EQUAL (ACL_DEVICE_GLOBAL_HOST_ACCESS_NONE,
288
288
kernel15_dev_global->second .host_access );
289
- CHECK_EQUAL (ACL_DEVICE_GLOBAL_INIT_MODE_RESET,
290
- kernel15_dev_global->second .init_mode );
289
+ CHECK_EQUAL (false , kernel15_dev_global->second .can_skip_programming );
291
290
CHECK_EQUAL (false , kernel15_dev_global->second .implement_in_csr );
291
+ CHECK_EQUAL (false , kernel15_dev_global->second .reset_on_reuse );
292
292
CHECK_EQUAL (2048 , kernel15_dev_global2->second .address );
293
293
CHECK_EQUAL (1024 , kernel15_dev_global2->second .size );
294
294
CHECK_EQUAL (ACL_DEVICE_GLOBAL_HOST_ACCESS_WRITE_ONLY,
295
295
kernel15_dev_global2->second .host_access );
296
- CHECK_EQUAL (ACL_DEVICE_GLOBAL_INIT_MODE_REPROGRAM,
297
- kernel15_dev_global2->second .init_mode );
296
+ CHECK_EQUAL (false , kernel15_dev_global2->second .can_skip_programming );
298
297
CHECK_EQUAL (true , kernel15_dev_global2->second .implement_in_csr );
298
+ CHECK_EQUAL (false , kernel15_dev_global2->second .reset_on_reuse );
299
299
300
300
// Check a second parsing.
301
301
// It should allocate a new string for the name.
@@ -493,12 +493,14 @@ TEST(auto_configure, many_ok_forward_compatibility) {
493
493
// sections and subsections to check forward compatibility
494
494
495
495
std::string str (VERSIONIDTOSTR (
496
- ACL_AUTO_CONFIGURE_VERSIONID) " 49 "
496
+ ACL_AUTO_CONFIGURE_VERSIONID) " 51 "
497
497
" sample40byterandomhash000000000000000000 "
498
498
" a10gx 0 1 17 DDR 2 1 6 0 2147483648 100 "
499
499
" 100 100 100 0 - 0 200 200 200 200 0 0 0 "
500
- " 2 9 ms_dev_global1 0x800 1024 3 0 0 300 "
500
+ " 2 10 ms_dev_global1 0x800 1024 3 0 0 0 "
501
+ " 300 "
501
502
" 300 300 ms_dev_global2 0x1000 1024 1 1 1 "
503
+ " 0 "
502
504
" 300 300 300 0 0 400 400 47 "
503
505
" 40 external_sort_stage_0 0 128 1 0 0 1 0 "
504
506
" 1 0 1 10 0 0 4 1 0 0 0 500 500 500 0 0 "
@@ -1206,14 +1208,15 @@ TEST(auto_configure, kernel_arg_info) {
1206
1208
1207
1209
TEST (auto_configure, hostpipe) {
1208
1210
std::string str (VERSIONIDTOSTR (
1209
- ACL_AUTO_CONFIGURE_VERSIONID) " 49 "
1211
+ ACL_AUTO_CONFIGURE_VERSIONID) " 50 "
1210
1212
" sample40byterandomhash000000000000000000 "
1211
1213
" a10gx_hostpipe 0 1 15 DDR 2 1 6 0 "
1212
1214
" 2147483648 0 100 100 100 100 200 200 200 "
1213
1215
" 200 "
1214
1216
" 2 9 host_to_dev 1 0 32 32768 300 300 300 "
1215
1217
" 300 dev_to_host 0 1 32 32768 300 300 300 "
1216
- " 300 400 1 6 dev_global_3 0x400 2048 0 0 0 "
1218
+ " 300 400 1 7 dev_global_3 0x400 2048 0 0 0 "
1219
+ " 0 "
1217
1220
" 1 29 foo 0 128 1 0 0 1 0 1 0 0 0 0 0 0 1 "
1218
1221
" 1 1 3 1 1 1 3 1 0 0 800 800 800 900 "
1219
1222
" 900"
@@ -1243,9 +1246,10 @@ TEST(auto_configure, hostpipe) {
1243
1246
1244
1247
TEST (auto_configure, streaming) {
1245
1248
const std::string config_str{
1246
- " 23 29 " RANDOM_HASH
1249
+ " 23 30 " RANDOM_HASH
1247
1250
" pac_a10 0 1 13 DDR 2 2 24 1 2 0 4294967296 4294967296 8589934592 0 - 0 "
1248
- " 0 0 0 1 6 device_global_name 0x100 128 0 0 0 1 105 _ZTS3CRCILi0EE 0 256 "
1251
+ " 0 0 0 1 7 device_global_name 0x100 128 0 0 0 0 1 105 _ZTS3CRCILi0EE 0 "
1252
+ " 256 "
1249
1253
" 1 0 0 1 0 1 0 9 8 0 0 8 1 0 0 1 k0_ZTS3CRCILi0EE_arg0 8 2 1 8 1024 0 3 "
1250
1254
" 1 k0_ZTS3CRCILi0EE_arg1 8 0 0 8 1 0 0 1 k0_ZTS3CRCILi0EE_arg2 7 0 0 8 1 "
1251
1255
" 0 0 0 7 0 0 8 1 0 0 0 7 2 1 8 1024 0 2 0 7 0 0 8 1 0 0 0 7 0 0 8 1 0 0 "
0 commit comments