@@ -247,7 +247,7 @@ static int get_auto_discovery_string(acl_kernel_if *kern, char *config_str) {
247
247
kern->io .printf (" HAL Kern: Version ID incorrect\n " );
248
248
return -1 ;
249
249
}
250
- ACL_KERNEL_IF_DEBUG_MSG (kern, " Read %d bytes from kernel auto discovery" , r);
250
+ ACL_KERNEL_IF_DEBUG_MSG (kern, " Read %zu bytes from kernel auto discovery" , r);
251
251
252
252
return (r == rom_size) ? 0 : -1 ;
253
253
}
@@ -288,7 +288,7 @@ static int acl_kernel_if_read_32b(acl_kernel_if *kern, unsigned int addr,
288
288
r = kern->io .read (&kern->io , (dev_addr_t )addr, (char *)val, (size_t )size);
289
289
if (r < size) {
290
290
kern->io .printf (
291
- " HAL Kern Error: Read failed from addr %x, read %d expected %d \n " , addr,
291
+ " HAL Kern Error: Read failed from addr %x, read %zu expected %zu \n " , addr,
292
292
r, size);
293
293
return -1 ;
294
294
}
@@ -334,7 +334,7 @@ static int acl_kernel_rom_read_block(acl_kernel_if *kern, unsigned int addr,
334
334
r = kern->io .read (&kern->io , (dev_addr_t )addr, config_rom, (size_t )size);
335
335
if (r < size) {
336
336
kern->io .printf (
337
- " HAL Kern Error: Read failed from addr %x, read %d expected %d \n " , addr,
337
+ " HAL Kern Error: Read failed from addr %x, read %zu expected %zu \n " , addr,
338
338
r, size);
339
339
return -1 ;
340
340
}
@@ -381,7 +381,7 @@ static int acl_kernel_if_write_64b(acl_kernel_if *kern, unsigned int addr,
381
381
r = (int )kern->io .write (&kern->io , (dev_addr_t )addr, (char *)&val,
382
382
(size_t )size);
383
383
if (r < size) {
384
- kern->io .printf (" HAL Kern Error: Write failed to addr %x with value %x , "
384
+ kern->io .printf (" HAL Kern Error: Write failed to addr %x with value %zu , "
385
385
" wrote %d, expected %d\n " ,
386
386
addr, val, r, size);
387
387
return -1 ;
@@ -423,8 +423,8 @@ static int acl_kernel_if_write_block(acl_kernel_if *kern, unsigned int addr,
423
423
424
424
if (r < aligned_size) {
425
425
kern->io .printf (" HAL Kern Error: Write failed to addr %x with value %x, "
426
- " wrote %d expected %d \n " ,
427
- addr, val, r, aligned_size);
426
+ " wrote %zu expected %zu \n " ,
427
+ addr, * val, r, aligned_size);
428
428
return -1 ;
429
429
}
430
430
return 0 ;
@@ -930,7 +930,7 @@ int acl_kernel_if_update(const acl_device_def_autodiscovery_t &devdef,
930
930
OFFSET_KERNEL_CRA + devdef.hal_info [ii].csr .address ;
931
931
kern->accel_csr [ii].bytes = devdef.hal_info [ii].csr .num_bytes ;
932
932
933
- ACL_KERNEL_IF_DEBUG_MSG (kern, " Kernel_%s CSR { 0x%08x , 0x%08x }\n " ,
933
+ ACL_KERNEL_IF_DEBUG_MSG (kern, " Kernel_%s CSR { 0x%08zu , 0x%08zu }\n " ,
934
934
devdef.accel [ii].iface .name .c_str (),
935
935
kern->accel_csr [ii].address ,
936
936
kern->accel_csr [ii].bytes );
@@ -942,7 +942,7 @@ int acl_kernel_if_update(const acl_device_def_autodiscovery_t &devdef,
942
942
OFFSET_KERNEL_CRA + devdef.hal_info [ii].perf_mon .address ;
943
943
kern->accel_perf_mon [ii].bytes = devdef.hal_info [ii].perf_mon .num_bytes ;
944
944
945
- ACL_KERNEL_IF_DEBUG_MSG (kern, " Kernel_%s perf_mon { 0x%08x , 0x%08x }\n " ,
945
+ ACL_KERNEL_IF_DEBUG_MSG (kern, " Kernel_%s perf_mon { 0x%08zu , 0x%08zu }\n " ,
946
946
devdef.accel [ii].iface .name .c_str (),
947
947
kern->accel_perf_mon [ii].address ,
948
948
kern->accel_perf_mon [ii].bytes );
@@ -1056,7 +1056,7 @@ int acl_kernel_if_post_pll_config_init(acl_kernel_if *kern) {
1056
1056
kern->csr_version = version;
1057
1057
ACL_KERNEL_IF_DEBUG_MSG (kern,
1058
1058
" Read CSR version from kernel 0: Version = %u\n " ,
1059
- kern->csr_version );
1059
+ kern->csr_version . value () );
1060
1060
if (kern->csr_version < 5 ) {
1061
1061
// Register addresses are pushed back since previous versions
1062
1062
// doesn't have the start register
@@ -1190,7 +1190,7 @@ void acl_kernel_if_launch_kernel_on_custom_sof(
1190
1190
kern->io .printf (" currently in use, OR\n " );
1191
1191
kern->io .printf (" b) The host can not communicate properly with the "
1192
1192
" compiled kernel.\n " );
1193
- kern->io .printf (" Saw version=%u, expected=%u.\n " , kern->csr_version ,
1193
+ kern->io .printf (" Saw version=%u, expected=%u.\n " , kern->csr_version . value () ,
1194
1194
CSR_VERSION_ID);
1195
1195
assert (0 ); // Assert here because no way to pass an error up to the user.
1196
1196
// clEnqueue has already returned.
@@ -1885,7 +1885,7 @@ int acl_kernel_if_get_profile_data(acl_kernel_if *kern, cl_uint accel_id,
1885
1885
data[i] = acl_kernel_if_get_profile_data_word (kern, accel_id);
1886
1886
ACL_KERNEL_IF_DEBUG_MSG (kern,
1887
1887
" :: Read profile hardware:: Accelerator %d "
1888
- " profile_data word [%u ] is 0x%016llx.\n " ,
1888
+ " profile_data word [%zu ] is 0x%016llx.\n " ,
1889
1889
accel_id, i, data[i]);
1890
1890
}
1891
1891
0 commit comments