[dpdk-dev] [PATCH v2 2/3] net/ice: build on Windows

Kadam, Pallavi pallavi.kadam at intel.com
Sun Mar 28 04:00:27 CEST 2021


On 3/26/2021 4:51 AM, Ferruh Yigit wrote:
> On 3/11/2021 1:58 AM, Pallavi Kadam wrote:
>> - Add Intel ice PMD support on Windows.
>> - Remove #include sys/ioctl header file as it is not needed.
>> - Replace x86intrin.h with rte_vect.h to avoid __m_prefetchw conflicting
>> types.
>> - Replace POSIX usleep() API with rte API.
>> - Add a new macro for the access() API as the original function
>> has been deprecated on Windows.
>> - Add extra cflags '-fno-asynchronous-unwind-tables'
>> to avoid MinGW build error:
>>     Error: invalid register for .seh_savexmm
>> - Add documentation to support ice PMD on Windows.
>> Update the release notes and features list for the same.
>>
>> Signed-off-by: Pallavi Kadam <pallavi.kadam at intel.com>
>> Reviewed-by: Ranjit Menon <ranjit.menon at intel.com>
>
> <...>
>
>> --- a/drivers/net/ice/base/ice_switch.c
>> +++ b/drivers/net/ice/base/ice_switch.c
>> @@ -6684,7 +6684,7 @@ ice_fill_valid_words(struct ice_adv_lkup_elem 
>> *rule,
>>         for (j = 0; j < sizeof(rule->m_u) / sizeof(u16); j++)
>>           if (((u16 *)&rule->m_u)[j] &&
>> -            rule->type < ARRAY_SIZE(ice_prot_ext)) {
>> +            (unsigned long long)rule->type < 
>> ARRAY_SIZE(ice_prot_ext)) {
>
> isn't 'ARRAY_SIZE' return type is 'size_t', if 'size_t' is supported 
> in Windows why not cast to it, instead of "unsigned long long".

Ok. Yes, size_t works on Windows. Will replace it in v3.

>
> <...>
>
>> index b82d05fe7..01f8f409d 100644
>> --- a/drivers/net/ice/base/meson.build
>> +++ b/drivers/net/ice/base/meson.build
>> @@ -29,6 +29,10 @@ foreach flag: error_cflags
>>       endif
>>   endforeach
>>   +if is_windows and cc.get_id() != 'clang'
>> +    cflags += ['-fno-asynchronous-unwind-tables']
>> +endif
>> +
>
> This seems not having affect [1], may be because 'cflags' is not used 
> for build but 'c_args', moving the block above "c_args = cflags" 
> assignment may work.
>
> [1]
> http://mails.dpdk.org/archives/test-report/2021-March/182218.html

Thanks, Ferrruh. Ok, will move this cflag above the assignment and give 
it a try.

Either way I am not able to reproduce this error. Let's see if UNH lab 
still reports it.



More information about the dev mailing list