[dpdk-stable] patch 'net: explicit cast of multicast bit clearing' has been queued to LTS release 17.11.5

Yongseok Koh yskoh at mellanox.com
Thu Jan 3 09:13:49 CET 2019


Hi,

FYI, your patch has been queued to LTS release 17.11.5

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 01/04/19. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 45f354944bcb9e5a670d74b416f867d8e431f1f9 Mon Sep 17 00:00:00 2001
From: Andy Green <andy at warmcat.com>
Date: Thu, 17 May 2018 21:49:47 +0800
Subject: [PATCH] net: explicit cast of multicast bit clearing

[ upstream commit beb4076567441bb6f936f99f442c2a8de911bb3c ]

GCC 8.1 warned:

rte_ether.h:213:13:
warning: conversion from 'int' to 'uint8_t'
{aka 'unsigned char'} may change value [-Wconversion]
  addr[0] &= ~ETHER_GROUP_ADDR;

Fixes: 7ef007291004 ("ethdev: random MAC address")

Signed-off-by: Andy Green <andy at warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson at intel.com>
---
 lib/librte_net/rte_ether.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_net/rte_ether.h b/lib/librte_net/rte_ether.h
index 10d906e6f..f7a9a8695 100644
--- a/lib/librte_net/rte_ether.h
+++ b/lib/librte_net/rte_ether.h
@@ -239,7 +239,7 @@ static inline void eth_random_addr(uint8_t *addr)
 	uint8_t *p = (uint8_t *)&rand;
 
 	rte_memcpy(addr, p, ETHER_ADDR_LEN);
-	addr[0] &= ~ETHER_GROUP_ADDR;       /* clear multicast bit */
+	addr[0] &= (uint8_t)~ETHER_GROUP_ADDR;       /* clear multicast bit */
 	addr[0] |= ETHER_LOCAL_ADMIN_ADDR;  /* set local assignment bit */
 }
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.466990483 -0800
+++ 0026-net-explicit-cast-of-multicast-bit-clearing.patch	2019-01-02 23:59:12.083819000 -0800
@@ -1,8 +1,10 @@
-From beb4076567441bb6f936f99f442c2a8de911bb3c Mon Sep 17 00:00:00 2001
+From 45f354944bcb9e5a670d74b416f867d8e431f1f9 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy at warmcat.com>
 Date: Thu, 17 May 2018 21:49:47 +0800
 Subject: [PATCH] net: explicit cast of multicast bit clearing
 
+[ upstream commit beb4076567441bb6f936f99f442c2a8de911bb3c ]
+
 GCC 8.1 warned:
 
 rte_ether.h:213:13:
@@ -11,7 +13,6 @@
   addr[0] &= ~ETHER_GROUP_ADDR;
 
 Fixes: 7ef007291004 ("ethdev: random MAC address")
-Cc: stable at dpdk.org
 
 Signed-off-by: Andy Green <andy at warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson at intel.com>
@@ -20,10 +21,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_net/rte_ether.h b/lib/librte_net/rte_ether.h
-index 27c919594..bee2b34f0 100644
+index 10d906e6f..f7a9a8695 100644
 --- a/lib/librte_net/rte_ether.h
 +++ b/lib/librte_net/rte_ether.h
-@@ -210,7 +210,7 @@ static inline void eth_random_addr(uint8_t *addr)
+@@ -239,7 +239,7 @@ static inline void eth_random_addr(uint8_t *addr)
  	uint8_t *p = (uint8_t *)&rand;
  
  	rte_memcpy(addr, p, ETHER_ADDR_LEN);


More information about the stable mailing list