[dpdk-dev] i40e: compile fix on ICC 13.0.0

Message ID 1431957127-21395-1-git-send-email-helin.zhang@intel.com (mailing list archive)
State Superseded, archived
Headers

Commit Message

Zhang, Helin May 18, 2015, 1:52 p.m. UTC
  Below compile error can be found on ICC 13.0.0, which is a warning
treated as error. Forcedly disabling the warning can fix it.

Error log:
lib/librte_pmd_i40e/i40e/i40e_nvm.c(1022): error #188: enumerated
type mixed with another type
hw->aq.asq_last_status = old_asq_status;
                       ^

Signed-off-by: Helin Zhang <helin.zhang@intel.com>
---
 lib/librte_pmd_i40e/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Zhang, Helin May 18, 2015, 3:03 p.m. UTC | #1
Compile warnings on ICC and clang can be found, and treated as errors.
Disabling those warnings forcedly can fix them.

v2 changes:
Added the fix for the compile error on clang.

Helin Zhang (2):
  i40e: compile fix on ICC 13.0.0
  i40e: compile fix on clang 3.3

 lib/librte_pmd_i40e/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
  
Zhang, Helin May 18, 2015, 3:40 p.m. UTC | #2
Compile warnings on ICC and clang can be found, and treated as errors.
Disabling those warnings forcedly can fix them.

v2 changes:
Added the fix for the compile error on clang.

v3 changes:
Reworded the commit titles.

Helin Zhang (2):
  i40e: compile fix on ICC 13.0.0
  i40e: compile fix on clang 3.3

 lib/librte_pmd_i40e/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
  
Bruce Richardson May 18, 2015, 3:43 p.m. UTC | #3
On Mon, May 18, 2015 at 11:40:54PM +0800, Helin Zhang wrote:
> Compile warnings on ICC and clang can be found, and treated as errors.
> Disabling those warnings forcedly can fix them.
> 
> v2 changes:
> Added the fix for the compile error on clang.
> 
> v3 changes:
> Reworded the commit titles.
> 
> Helin Zhang (2):
>   i40e: compile fix on ICC 13.0.0
>   i40e: compile fix on clang 3.3
> 
>  lib/librte_pmd_i40e/Makefile | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> -- 
> 1.8.1.4
> 
Series Acked-by: Bruce Richardson <bruce.richardson@intel.com>
  
Tetsuya Mukawa May 19, 2015, 1:25 a.m. UTC | #4
On 2015/05/19 0:03, Helin Zhang wrote:
> Compile warnings on ICC and clang can be found, and treated as errors.
> Disabling those warnings forcedly can fix them.
>
> v2 changes:
> Added the fix for the compile error on clang.
>
> Helin Zhang (2):
>   i40e: compile fix on ICC 13.0.0
>   i40e: compile fix on clang 3.3
>
>  lib/librte_pmd_i40e/Makefile | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
Acked-by: Tetsuya Mukawa <mukawa@igel.co.jp>
  
Thomas Monjalon May 19, 2015, 10:32 a.m. UTC | #5
2015-05-18 16:43, Bruce Richardson:
> On Mon, May 18, 2015 at 11:40:54PM +0800, Helin Zhang wrote:
> > Compile warnings on ICC and clang can be found, and treated as errors.
> > Disabling those warnings forcedly can fix them.
> > 
> > v2 changes:
> > Added the fix for the compile error on clang.
> > 
> > v3 changes:
> > Reworded the commit titles.
> 
> Series Acked-by: Bruce Richardson <bruce.richardson@intel.com>

Applied, thanks
I reworded the commit message and added reference to the breaking commit:
	http://dpdk.org/browse/dpdk/commit/?id=ff5c3960017cf
Please consider giving this kind of explanation when fixing things,
especially for special handling of base drivers.
  
Zhang, Helin May 19, 2015, 2:12 p.m. UTC | #6
Thomas, thank you!

- Helin

> -----Original Message-----
> From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]
> Sent: Tuesday, May 19, 2015 6:33 PM
> To: Zhang, Helin
> Cc: dev@dpdk.org; Richardson, Bruce
> Subject: Re: [dpdk-dev] [PATCH v3 0/2] fix compile with ICC and clang
> 
> 2015-05-18 16:43, Bruce Richardson:
> > On Mon, May 18, 2015 at 11:40:54PM +0800, Helin Zhang wrote:
> > > Compile warnings on ICC and clang can be found, and treated as
> errors.
> > > Disabling those warnings forcedly can fix them.
> > >
> > > v2 changes:
> > > Added the fix for the compile error on clang.
> > >
> > > v3 changes:
> > > Reworded the commit titles.
> >
> > Series Acked-by: Bruce Richardson <bruce.richardson@intel.com>
> 
> Applied, thanks
> I reworded the commit message and added reference to the breaking
> commit:
> 	http://dpdk.org/browse/dpdk/commit/?id=ff5c3960017cf
> Please consider giving this kind of explanation when fixing things,
> especially for special handling of base drivers.
  

Patch

diff --git a/lib/librte_pmd_i40e/Makefile b/lib/librte_pmd_i40e/Makefile
index 22f0716..911e4f5 100644
--- a/lib/librte_pmd_i40e/Makefile
+++ b/lib/librte_pmd_i40e/Makefile
@@ -48,7 +48,7 @@  LIBABIVER := 1
 # to disable warnings
 #
 ifeq ($(CC), icc)
-CFLAGS_BASE_DRIVER = -wd593
+CFLAGS_BASE_DRIVER = -wd593 -wd188
 else ifeq ($(CC), clang)
 CFLAGS_BASE_DRIVER += -Wno-sign-compare
 CFLAGS_BASE_DRIVER += -Wno-unused-value