patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] [PATCH] kni: fix compilation on RHEL 8.3
@ 2020-11-26 14:23 Olivier Matz
  2020-11-26 18:04 ` David Marchand
  0 siblings, 1 reply; 4+ messages in thread
From: Olivier Matz @ 2020-11-26 14:23 UTC (permalink / raw)
  To: dev; +Cc: Ferruh Yigit, Kevin Traynor, stable, Christophe Grosse

Like what was done for mainline kernel in commit 38ad54f3bc76 ("kni: fix
build with Linux 5.6"), a new parameter 'txqueue' has to be added to
'ndo_tx_timeout' ndo on RHEL 8.3 kernel.

Cc: stable@dpdk.org

Tested-by: Christophe Grosse <christophe.grosse@6wind.com>
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
---
 kernel/linux/kni/compat.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/kernel/linux/kni/compat.h b/kernel/linux/kni/compat.h
index d515b27669..5f65640d5e 100644
--- a/kernel/linux/kni/compat.h
+++ b/kernel/linux/kni/compat.h
@@ -131,7 +131,9 @@
 #define HAVE_IOVA_TO_KVA_MAPPING_SUPPORT
 #endif
 
-#if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE
+#if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE || \
+	(defined(RHEL_RELEASE_CODE) && \
+	 RHEL_RELEASE_VERSION(8, 3) <= RHEL_RELEASE_CODE)
 #define HAVE_TX_TIMEOUT_TXQUEUE
 #endif
 
-- 
2.25.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-stable] [PATCH] kni: fix compilation on RHEL 8.3
  2020-11-26 14:23 [dpdk-stable] [PATCH] kni: fix compilation on RHEL 8.3 Olivier Matz
@ 2020-11-26 18:04 ` David Marchand
  2020-11-26 18:08   ` Ferruh Yigit
  0 siblings, 1 reply; 4+ messages in thread
From: David Marchand @ 2020-11-26 18:04 UTC (permalink / raw)
  To: Olivier Matz
  Cc: dev, Ferruh Yigit, Kevin Traynor, dpdk stable, Christophe Grosse

On Thu, Nov 26, 2020 at 3:24 PM Olivier Matz <olivier.matz@6wind.com> wrote:
>
> Like what was done for mainline kernel in commit 38ad54f3bc76 ("kni: fix
> build with Linux 5.6"), a new parameter 'txqueue' has to be added to
> 'ndo_tx_timeout' ndo on RHEL 8.3 kernel.
>
> Cc: stable@dpdk.org
>
> Tested-by: Christophe Grosse <christophe.grosse@6wind.com>
> Signed-off-by: Olivier Matz <olivier.matz@6wind.com>

Reproduced issue on a RHEL 8.3 with kernel 4.18.0-240.el8.x86_64.
FAILED: kernel/linux/kni/rte_kni.ko
make -j4 -C /lib/modules/4.18.0-240.el8.x86_64/build
M=/root/dpdk/build/kernel/linux/kni src=/root/dpdk/kernel/linux/kni
'MODULE_CFLAGS=-include /root/dpdk/config/rte_config.h
-I/root/dpdk/lib/librte_eal/include -I/root/dpdk/lib/librte_kni
-I/root/dpdk/build -I/root/dpdk/kernel/linux/kni' modules
make: Entering directory '/usr/src/kernels/4.18.0-240.el8.x86_64'
  CC [M]  /root/dpdk/build/kernel/linux/kni/kni_net.o
  CC [M]  /root/dpdk/build/kernel/linux/kni/kni_misc.o
/root/dpdk/kernel/linux/kni/kni_net.c:791:20: error: initialization of
‘void (*)(struct net_device *, unsigned int)’ from incompatible
pointer type ‘void (*)(struct net_device *)’
[-Werror=incompatible-pointer-types]
  .ndo_tx_timeout = kni_net_tx_timeout,
                    ^~~~~~~~~~~~~~~~~~
/root/dpdk/kernel/linux/kni/kni_net.c:791:20: note: (near
initialization for ‘kni_net_netdev_ops.<anonymous>.ndo_tx_timeout’)
cc1: some warnings being treated as errors
make[1]: *** [scripts/Makefile.build:315:
/root/dpdk/build/kernel/linux/kni/kni_net.o] Error 1
make: *** [Makefile:1544: _module_/root/dpdk/build/kernel/linux/kni] Error 2
make: Leaving directory '/usr/src/kernels/4.18.0-240.el8.x86_64'
ninja: build stopped: subcommand failed.



> ---
>  kernel/linux/kni/compat.h | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/kernel/linux/kni/compat.h b/kernel/linux/kni/compat.h
> index d515b27669..5f65640d5e 100644
> --- a/kernel/linux/kni/compat.h
> +++ b/kernel/linux/kni/compat.h
> @@ -131,7 +131,9 @@
>  #define HAVE_IOVA_TO_KVA_MAPPING_SUPPORT
>  #endif
>
> -#if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE
> +#if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE || \
> +       (defined(RHEL_RELEASE_CODE) && \
> +        RHEL_RELEASE_VERSION(8, 3) <= RHEL_RELEASE_CODE)
>  #define HAVE_TX_TIMEOUT_TXQUEUE
>  #endif
>
> --
> 2.25.1
>

Tested-by: David Marchand <david.marchand@redhat.com>
Thanks.


-- 
David Marchand


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-stable] [PATCH] kni: fix compilation on RHEL 8.3
  2020-11-26 18:04 ` David Marchand
@ 2020-11-26 18:08   ` Ferruh Yigit
  2020-11-27  0:41     ` [dpdk-stable] [dpdk-dev] " Thomas Monjalon
  0 siblings, 1 reply; 4+ messages in thread
From: Ferruh Yigit @ 2020-11-26 18:08 UTC (permalink / raw)
  To: David Marchand, Olivier Matz
  Cc: dev, Kevin Traynor, dpdk stable, Christophe Grosse

On 11/26/2020 6:04 PM, David Marchand wrote:
> On Thu, Nov 26, 2020 at 3:24 PM Olivier Matz <olivier.matz@6wind.com> wrote:
>>
>> Like what was done for mainline kernel in commit 38ad54f3bc76 ("kni: fix
>> build with Linux 5.6"), a new parameter 'txqueue' has to be added to
>> 'ndo_tx_timeout' ndo on RHEL 8.3 kernel.
>>
>> Cc: stable@dpdk.org
>>
>> Tested-by: Christophe Grosse <christophe.grosse@6wind.com>
>> Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
> 
> Reproduced issue on a RHEL 8.3 with kernel 4.18.0-240.el8.x86_64.
> FAILED: kernel/linux/kni/rte_kni.ko
> make -j4 -C /lib/modules/4.18.0-240.el8.x86_64/build
> M=/root/dpdk/build/kernel/linux/kni src=/root/dpdk/kernel/linux/kni
> 'MODULE_CFLAGS=-include /root/dpdk/config/rte_config.h
> -I/root/dpdk/lib/librte_eal/include -I/root/dpdk/lib/librte_kni
> -I/root/dpdk/build -I/root/dpdk/kernel/linux/kni' modules
> make: Entering directory '/usr/src/kernels/4.18.0-240.el8.x86_64'
>    CC [M]  /root/dpdk/build/kernel/linux/kni/kni_net.o
>    CC [M]  /root/dpdk/build/kernel/linux/kni/kni_misc.o
> /root/dpdk/kernel/linux/kni/kni_net.c:791:20: error: initialization of
> ‘void (*)(struct net_device *, unsigned int)’ from incompatible
> pointer type ‘void (*)(struct net_device *)’
> [-Werror=incompatible-pointer-types]
>    .ndo_tx_timeout = kni_net_tx_timeout,
>                      ^~~~~~~~~~~~~~~~~~
> /root/dpdk/kernel/linux/kni/kni_net.c:791:20: note: (near
> initialization for ‘kni_net_netdev_ops.<anonymous>.ndo_tx_timeout’)
> cc1: some warnings being treated as errors
> make[1]: *** [scripts/Makefile.build:315:
> /root/dpdk/build/kernel/linux/kni/kni_net.o] Error 1
> make: *** [Makefile:1544: _module_/root/dpdk/build/kernel/linux/kni] Error 2
> make: Leaving directory '/usr/src/kernels/4.18.0-240.el8.x86_64'
> ninja: build stopped: subcommand failed.
> 
> 
> 
>> ---
>>   kernel/linux/kni/compat.h | 4 +++-
>>   1 file changed, 3 insertions(+), 1 deletion(-)
>>
>> diff --git a/kernel/linux/kni/compat.h b/kernel/linux/kni/compat.h
>> index d515b27669..5f65640d5e 100644
>> --- a/kernel/linux/kni/compat.h
>> +++ b/kernel/linux/kni/compat.h
>> @@ -131,7 +131,9 @@
>>   #define HAVE_IOVA_TO_KVA_MAPPING_SUPPORT
>>   #endif
>>
>> -#if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE
>> +#if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE || \
>> +       (defined(RHEL_RELEASE_CODE) && \
>> +        RHEL_RELEASE_VERSION(8, 3) <= RHEL_RELEASE_CODE)
>>   #define HAVE_TX_TIMEOUT_TXQUEUE
>>   #endif
>>
>> --
>> 2.25.1
>>
> 
> Tested-by: David Marchand <david.marchand@redhat.com>
> Thanks.
> 

Thanks David for testing.

Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-stable] [dpdk-dev] [PATCH] kni: fix compilation on RHEL 8.3
  2020-11-26 18:08   ` Ferruh Yigit
@ 2020-11-27  0:41     ` Thomas Monjalon
  0 siblings, 0 replies; 4+ messages in thread
From: Thomas Monjalon @ 2020-11-27  0:41 UTC (permalink / raw)
  To: Olivier Matz
  Cc: David Marchand, dev, Kevin Traynor, dpdk stable,
	Christophe Grosse, Ferruh Yigit

26/11/2020 19:08, Ferruh Yigit:
> On 11/26/2020 6:04 PM, David Marchand wrote:
> > On Thu, Nov 26, 2020 at 3:24 PM Olivier Matz <olivier.matz@6wind.com> wrote:
> >>
> >> Like what was done for mainline kernel in commit 38ad54f3bc76 ("kni: fix
> >> build with Linux 5.6"), a new parameter 'txqueue' has to be added to
> >> 'ndo_tx_timeout' ndo on RHEL 8.3 kernel.
> >>
> >> Cc: stable@dpdk.org
> >>
> >> Tested-by: Christophe Grosse <christophe.grosse@6wind.com>
> >> Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
> > 
> > Tested-by: David Marchand <david.marchand@redhat.com>
> > Thanks.
> 
> Thanks David for testing.
> 
> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>

Applied, thanks




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-11-27  0:41 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-26 14:23 [dpdk-stable] [PATCH] kni: fix compilation on RHEL 8.3 Olivier Matz
2020-11-26 18:04 ` David Marchand
2020-11-26 18:08   ` Ferruh Yigit
2020-11-27  0:41     ` [dpdk-stable] [dpdk-dev] " Thomas Monjalon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).