Skip to contentSkip to conversation

testpmd: use RFC2544 reserved IP addresses

RFC In review Stephen Hemminger 3 participants 5 messages Mar 21, 2018 – Jun 8, 2018

lore
Share & tools
lore
#0 lore raw

RFC 1/1 testpmd: use RFC2544 reserved IP addresses

Change the transmit only side of testpmd to use the IP addresses that are marked as reserved for benchmarking by RFC2544 192.18.0.0/27; rather than the commonly used subnet 192.168.0.0/24 which is likely to used for administrative interface.

---
 app/test-pmd/txonly.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
app/test-pmd/txonly.c +3 -2
index 1f08b6ed37a2..22785bdcbe44 100644
@@ -43,8 +43,9 @@
 #define UDP_SRC_PORT 1024
 #define UDP_DST_PORT 1024
 
-#define IP_SRC_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 1)
-#define IP_DST_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 2)
+/* RFC 2544 reserved IP addresses for benchmarking */
+#define IP_SRC_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 1)
+#define IP_DST_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 2)
 
 #define IP_DEFTTL  64   /* from RFC 1340. */
 #define IP_VERSION 0x40
Signature · 1 line
2.16.2
#1 lore raw

+Cc maintainers

21/03/2018 04:44, Stephen Hemminger:

Quoted 27 lines

Change the transmit only side of testpmd to use the IP addresses that are marked as reserved for benchmarking by RFC2544 192.18.0.0/27; rather than the commonly used subnet 192.168.0.0/24 which is likely to used for administrative interface.

---
 app/test-pmd/txonly.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
app/test-pmd/txonly.c +3 -2
index 1f08b6ed37a2..22785bdcbe44 100644
@@ -43,8 +43,9 @@
 #define UDP_SRC_PORT 1024
 #define UDP_DST_PORT 1024
 
-#define IP_SRC_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 1)
-#define IP_DST_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 2)
+/* RFC 2544 reserved IP addresses for benchmarking */
+#define IP_SRC_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 1)
+#define IP_DST_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 2)
 
 #define IP_DEFTTL  64   /* from RFC 1340. */
 #define IP_VERSION 0x40
#2 lore raw
In reply to Stephen Hemminger

Hi Stephen,

Quoted 9 lines

-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Stephen Hemminger
Sent: Wednesday, March 21, 2018 3:45 AM
To: [email protected]
Cc: Stephen Hemminger <[email protected]>
Subject: [dpdk-dev] [RFC] testpmd: use RFC2544 reserved IP addresses

Change the transmit only side of testpmd to use the IP addresses that are marked as reserved for benchmarking by RFC2544 192.18.0.0/27; rather than

RFC2544 seems to use 198.18.0.0 and 198.19.0.0 ?

Quoted 2 lines

the commonly used subnet 192.168.0.0/24 which is likely to used for administrative interface.

Typo in the commit message "to used" should be "to be used"

Quoted 25 lines
---
 app/test-pmd/txonly.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
app/test-pmd/txonly.c index renamed from app/test-pmd/txonly.c +0 -0

1f08b6ed37a2..22785bdcbe44 100644

app/test-pmd/txonly.c +3 -2
@@ -43,8 +43,9 @@
 #define UDP_SRC_PORT 1024
 #define UDP_DST_PORT 1024
 
-#define IP_SRC_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 1) -#define
 IP_DST_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 2)
+/* RFC 2544 reserved IP addresses for benchmarking */ #define
+IP_SRC_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 1) #define
+IP_DST_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 2)
 
 #define IP_DEFTTL  64   /* from RFC 1340. */
 #define IP_VERSION 0x40
--

2.16.2

Quoted 1 line

From RFC 2544:

"The single filter case should permit traffic from IP address 198.18.1.2 to IP address 198.19.65.2 and deny all other traffic."

Should the macros be as follows?

#define IP_SRC_ADDR ((198U << 24) | (18 << 16) | (0 << 8) | 1)
#define IP_DST_ADDR ((198U << 24) | (19 << 16) | (0 << 8) | 2)

Regards,

Bernard

#3 lore raw
Quoted 9 lines · Bernard

Hi Stephen,

Quoted 7 lines

-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Stephen Hemminger
Sent: Wednesday, March 21, 2018 3:45 AM
To: [email protected]
Cc: Stephen Hemminger <[email protected]>
Subject: [dpdk-dev] [RFC] testpmd: use RFC2544 reserved IP addresses

Quoted 4 lines
Quoted 2 lines

Change the transmit only side of testpmd to use the IP addresses that are marked as reserved for benchmarking by RFC2544 192.18.0.0/27; rather than

RFC2544 seems to use 198.18.0.0 and 198.19.0.0 ?

The 18 and 19 networks would be used when doing L3fwd type test. The addresses this patch addresses are those used in the default case for a transmit only type of test (on same subnet).

Quoted 5 lines
Quoted 3 lines

the commonly used subnet 192.168.0.0/24 which is likely to used for administrative interface.

Typo in the commit message "to used" should be "to be used"

yes.

Quoted 37 lines
Quoted 24 lines
---
 app/test-pmd/txonly.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
app/test-pmd/txonly.c index renamed from app/test-pmd/txonly.c +0 -0

1f08b6ed37a2..22785bdcbe44 100644

app/test-pmd/txonly.c +3 -2
@@ -43,8 +43,9 @@
 #define UDP_SRC_PORT 1024
 #define UDP_DST_PORT 1024
 
-#define IP_SRC_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 1) -#define
 IP_DST_ADDR ((192U << 24) | (168 << 16) | (0 << 8) | 2)
+/* RFC 2544 reserved IP addresses for benchmarking */ #define
+IP_SRC_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 1) #define
+IP_DST_ADDR ((192U << 24) | (18 << 16) | (0 << 8) | 2)
 
 #define IP_DEFTTL  64   /* from RFC 1340. */
 #define IP_VERSION 0x40
--
Quoted 1 line

2.16.2

From RFC 2544:
"The single filter case should permit traffic from IP address 198.18.1.2 to IP address 198.19.65.2 and deny all other traffic."

Should the macros be as follows?

#define IP_SRC_ADDR ((198U << 24) | (18 << 16) | (0 << 8) | 1)
#define IP_DST_ADDR ((198U << 24) | (19 << 16) | (0 << 8) | 2)

Regards,

Bernard

#4 lore raw

Hi Stephen,

<snip>

Quoted 11 lines
Quoted 7 lines
Quoted 5 lines

Subject: [dpdk-dev] [RFC] testpmd: use RFC2544 reserved IP addresses

Change the transmit only side of testpmd to use the IP addresses that are marked as reserved for benchmarking by RFC2544 192.18.0.0/27; rather than

RFC2544 seems to use 198.18.0.0 and 198.19.0.0 ?

The 18 and 19 networks would be used when doing L3fwd type test. The addresses this patch addresses are those used in the default case for a transmit only type of test (on same subnet).

It might be useful to add some comments clarify this use case.

Quoted 8 lines
Quoted 4 lines
Quoted 2 lines

the commonly used subnet 192.168.0.0/24 which is likely to used for administrative interface.

Typo in the commit message "to used" should be "to be used"

yes.

Quoted 1 line

<snip>

Regards,

Bernard.