DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [RFC] ethdev: use special speed for virtual Ethernet devices
@ 2020-04-01  9:33 Morten Brørup
  2020-04-01  9:53 ` Thomas Monjalon
  0 siblings, 1 reply; 23+ messages in thread
From: Morten Brørup @ 2020-04-01  9:33 UTC (permalink / raw)
  To: Thomas Monjalon, Ferruh Yigit, Andrew Rybchenko, dev
  Cc: Matan Azrad, Benoit Ganne (bganne)

Thomas, Ferruh, Andrew (Ethernet API Maintainers),

A command line option was recently added to set which speed a vNIC reports when the link is up. This makes sense for Spanning Tree and other protocols which depend on link speed.

However, I suspect that this workaround rarely reflects the physical truth, and suggest that the application should handle it instead.

In other words... Instead of faking it in the virtual Ethernet drivers, I suggest that rte_ethdev.h defines a special speed value for vNICs which really don't have a physical link speed:

#define ETH_SPEED_NUM_NONE         0 /**< Not defined */
+#define ETH_SPEED_NUM_UNKNOWN      1 /**< Unknown (virtual device) */
#define ETH_SPEED_NUM_10M         10 /**<  10 Mbps */

Alternatively, we could expand the meaning of ETH_SPEED_NUM_NONE:

-#define ETH_SPEED_NUM_NONE         0 /**< Not defined */
+#define ETH_SPEED_NUM_NONE         0 /**< Not defined or unknown (virtual device) */

The special value could also be used in cases like this:
http://inbox.dpdk.org/dev/AM0PR0502MB401907ADE7CEA27DC642DF35D2CB0@AM0PR0502MB4019.eurprd05.prod.outlook.com/T/#t


Med venlig hilsen / kind regards
- Morten Brørup



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

end of thread, other threads:[~2020-04-26 11:44 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-01  9:33 [dpdk-dev] [RFC] ethdev: use special speed for virtual Ethernet devices Morten Brørup
2020-04-01  9:53 ` Thomas Monjalon
2020-04-01 10:03   ` Benoit Ganne (bganne)
2020-04-01 10:06   ` [dpdk-dev] [RFC] ethdev: use special speed for virtual Ethernetdevices Morten Brørup
2020-04-02 12:54     ` Ivan Dyukov
2020-04-02 13:50       ` Morten Brørup
2020-04-02 15:29         ` Stephen Hemminger
2020-04-02 20:41         ` Ivan Dyukov
2020-04-02 20:58           ` Thomas Monjalon
2020-04-03  8:05             ` Ivan Dyukov
2020-04-03  9:45               ` Morten Brørup
2020-04-03 11:01                 ` Thomas Monjalon
2020-04-07 22:26                 ` [dpdk-dev] [PATCH 0/2] ethdev link speed Thomas Monjalon
2020-04-07 22:26                   ` [dpdk-dev] [PATCH 1/2] ethdev: deduplicate functions to get link infos Thomas Monjalon
2020-04-08  5:21                     ` Asaf Penso
2020-04-08 12:49                       ` Thomas Monjalon
2020-04-13 14:14                     ` Andrew Rybchenko
2020-04-07 22:26                   ` [dpdk-dev] [PATCH 2/2] ethdev: allow unknown link speed Thomas Monjalon
2020-04-08  5:39                     ` Jerin Jacob
2020-04-10 10:53                     ` Morten Brørup
2020-04-13 14:26                     ` Andrew Rybchenko
2020-04-16 13:42                       ` Ferruh Yigit
2020-04-26 11:44                     ` Matan Azrad

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).