document scheduling types for eventdev drivers
cover document scheduling types for eventdev drivers
The various eventdev drivers, while fitting under a common API, do not all support all scheduling types. The eventdev API is missing some way to query the particular scheduling support for a driver, a key piece of information for application developers. This patchset adds the necessary capability flags, and documentation feature rows, then, driver-by-driver adds the necessary flags to both code and docs.
Bruce Richardson (8):
eventdev: add capability flags for supported sched types event/cnxk: add schedule-type capability flags event/dlb2: add schedule-type capability flags event/dpaa*: add schedule-type capability flags event/dsw: add schedule-type capability flags event/octeontx: add schedule-type capability flags event/opdl: add schedule-type capability flags event/sw: add schedule-type capability flags
doc/guides/eventdevs/features/cnxk.ini | 3 +++ doc/guides/eventdevs/features/default.ini | 3 +++ doc/guides/eventdevs/features/dlb2.ini | 3 +++ doc/guides/eventdevs/features/dpaa.ini | 2 ++ doc/guides/eventdevs/features/dpaa2.ini | 2 ++ doc/guides/eventdevs/features/dsw.ini | 1 + doc/guides/eventdevs/features/octeontx.ini | 3 +++ doc/guides/eventdevs/features/opdl.ini | 2 ++ doc/guides/eventdevs/features/sw.ini | 3 +++ drivers/event/cnxk/cnxk_eventdev.c | 5 ++++- drivers/event/dlb2/dlb2.c | 5 ++++- drivers/event/dpaa/dpaa_eventdev.c | 2 ++ drivers/event/dpaa2/dpaa2_eventdev.c | 2 ++ drivers/event/dsw/dsw_evdev.c | 1 + drivers/event/octeontx/ssovf_evdev.c | 3 +++ drivers/event/opdl/opdl_evdev.c | 3 +++ drivers/event/sw/sw_evdev.c | 3 +++ lib/eventdev/rte_eventdev.h | 21 +++++++++++++++++++++ 18 files changed, 65 insertions(+), 2 deletions(-)
--
2.39.2
PATCH 1/8 eventdev: add capability flags for supported sched types
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from rte_event_dev_info_get() API.
Similarly add the possible scheduling types to the capabilities table in the docs.
--- doc/guides/eventdevs/features/default.ini | 3 +++ lib/eventdev/rte_eventdev.h | 21 +++++++++++++++++++++ 2 files changed, 24 insertions(+)
doc/guides/eventdevs/features/default.ini +3 -0
@@ -6,6 +6,9 @@ ; the features table in the documentation. ; [Scheduling Features] +atomic_scheduling = +ordered_scheduling = +parallel_scheduling = queue_qos = event_qos = distributed_sched =
lib/eventdev/rte_eventdev.h +21 -0
@@ -326,6 +326,27 @@ struct rte_event;* than one. */ +#define RTE_EVENT_DEV_CAP_ATOMIC (1ULL << 13) +/**< Event device is capable of atomic scheduling. +* When this flag is set, the application can configure queues with scheduling type +* atomic on this event device. +* @see RTE_SCHED_TYPE_ATOMIC +*/ + +#define RTE_EVENT_DEV_CAP_ORDERED (1ULL << 13) +/**< Event device is capable of ordered scheduling. +* When this flag is set, the application can configure queues with scheduling type +* ordered on this event device. +* @see RTE_SCHED_TYPE_ORDERED +*/ + +#define RTE_EVENT_DEV_CAP_PARALLEL (1ULL << 13) +/**< Event device is capable of parallel scheduling. +* When this flag is set, the application can configure queues with scheduling type +* parallel on this event device. +* @see RTE_SCHED_TYPE_PARALLEL +*/ +/* Event device priority levels */ #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0/**< Highest priority expressed across eventdev subsystem
--
2.39.2
Re: [PATCH 24.03 1/8] eventdev: add capability flags for supported sched types
Quoted 48 lines · Bruce Richardson
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from
rte_event_dev_info_get()API.Similarly add the possible scheduling types to the capabilities table in the docs.
Signed-off-by Bruce Richardson <[email protected]>--- doc/guides/eventdevs/features/default.ini | 3 +++ lib/eventdev/rte_eventdev.h | 21 +++++++++++++++++++++ 2 files changed, 24 insertions(+)doc/guides/eventdevs/features/default.ini +3
-0@@ -6,6 +6,9 @@ ; the features table in the documentation. ; [Scheduling Features] +atomic_scheduling = +ordered_scheduling = +parallel_scheduling = queue_qos = event_qos = distributed_sched =lib/eventdev/rte_eventdev.h +10
-0@@ -326,6 +326,27 @@ struct rte_event;* than one. */ +#define RTE_EVENT_DEV_CAP_ATOMIC (1ULL << 13) +/**< Event device is capable of atomic scheduling. +* When this flag is set, the application can configure queues with scheduling type +* atomic on this event device. +* @see RTE_SCHED_TYPE_ATOMIC +*/ + +#define RTE_EVENT_DEV_CAP_ORDERED (1ULL << 13) +/**< Event device is capable of ordered scheduling. +* When this flag is set, the application can configure queues with scheduling type
lib/eventdev/rte_eventdev.h struct rte_event; · line 348
Quoted 10 lines
lib/eventdev/rte_eventdev.h +10
-0+* ordered on this event device. +* @see RTE_SCHED_TYPE_ORDERED +*/ + +#define RTE_EVENT_DEV_CAP_PARALLEL (1ULL << 13) +/**< Event device is capable of parallel scheduling. +* When this flag is set, the application can configure queues with scheduling type +* parallel on this event device. +* @see RTE_SCHED_TYPE_PARALLEL +*/
All the caps definition is 1ULL << 13. It should be unique per capa.
Quoted 6 lines
lib/eventdev/rte_eventdev.h +0
-1/* Event device priority levels */ #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0/**< Highest priority expressed across eventdev subsystem -- 2.39.2
Re: [PATCH 24.03 1/8] eventdev: add capability flags for supported sched types
Quoted 54 lines · Jerin Jacob
Quoted 52 lines · Bruce Richardson
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from
rte_event_dev_info_get()API.Similarly add the possible scheduling types to the capabilities table in the docs.
Signed-off-by Bruce Richardson <[email protected]>--- doc/guides/eventdevs/features/default.ini | 3 +++ lib/eventdev/rte_eventdev.h | 21 +++++++++++++++++++++ 2 files changed, 24 insertions(+)doc/guides/eventdevs/features/default.ini +3
-0@@ -6,6 +6,9 @@ ; the features table in the documentation. ; [Scheduling Features] +atomic_scheduling = +ordered_scheduling = +parallel_scheduling = queue_qos = event_qos = distributed_sched =lib/eventdev/rte_eventdev.h +14
-0@@ -326,6 +326,27 @@ struct rte_event;* than one. */ +#define RTE_EVENT_DEV_CAP_ATOMIC (1ULL << 13) +/**< Event device is capable of atomic scheduling. +* When this flag is set, the application can configure queues with scheduling type +* atomic on this event device. +* @see RTE_SCHED_TYPE_ATOMIC +*/ + +#define RTE_EVENT_DEV_CAP_ORDERED (1ULL << 13) +/**< Event device is capable of ordered scheduling. +* When this flag is set, the application can configure queues with scheduling type +* ordered on this event device. +* @see RTE_SCHED_TYPE_ORDERED +*/ +
Quoted 9 lines
lib/eventdev/rte_eventdev.h struct rte_event; · line 348
Quoted 6 lines
lib/eventdev/rte_eventdev.h +6
-0+#define RTE_EVENT_DEV_CAP_PARALLEL (1ULL << 13) +/**< Event device is capable of parallel scheduling. +* When this flag is set, the application can configure queues with scheduling type +* parallel on this event device. +* @see RTE_SCHED_TYPE_PARALLEL +*/ All the caps definition is 1ULL << 13. It should be unique per capa.
Yep, good spot! Copy-paste error, naturally. :-(
Will fix in a v2.
/Bruce
Re: [PATCH 24.03 1/8] eventdev: add capability flags for supported sched types
In reply to Bruce RichardsonQuoted 9 lines · Bruce Richardson
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from
rte_event_dev_info_get()API.Similarly add the possible scheduling types to the capabilities table in the docs.
Should we allow an event device to advertise RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES, but not all of these?
With current wording of RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES prevents that, but you should be able to allow for this without breaking backward compatibility by tweaking the text from
"Event device is capable of enqueuing events of any type to any queue."
"Event device is capable of enqueuing events of any type advertised as supported (e.g., by RTE_EVENT_DEV_CAP_ATOMIC)."
An event device that doesn't support ordered, but does support "all" types seems reasonable to me, while an event device that does support ordered on a per-event basis, but doesn't for queue-level configuration does not.
If RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES is left unchanged, the user may ask herself what "any" means (any supported in the API, or any supported by the actual event device).
Quoted 55 lines
Signed-off-by Bruce Richardson <[email protected]>--- doc/guides/eventdevs/features/default.ini | 3 +++ lib/eventdev/rte_eventdev.h | 21 +++++++++++++++++++++ 2 files changed, 24 insertions(+)doc/guides/eventdevs/features/default.ini +3
-0@@ -6,6 +6,9 @@ ; the features table in the documentation. ; [Scheduling Features] +atomic_scheduling = +ordered_scheduling = +parallel_scheduling = queue_qos = event_qos = distributed_sched =lib/eventdev/rte_eventdev.h +21
-1@@ -326,6 +326,27 @@ struct rte_event;* than one. */ +#define RTE_EVENT_DEV_CAP_ATOMIC (1ULL << 13) +/**< Event device is capable of atomic scheduling. +* When this flag is set, the application can configure queues with scheduling type +* atomic on this event device. +* @see RTE_SCHED_TYPE_ATOMIC +*/ + +#define RTE_EVENT_DEV_CAP_ORDERED (1ULL << 13) +/**< Event device is capable of ordered scheduling. +* When this flag is set, the application can configure queues with scheduling type +* ordered on this event device. +* @see RTE_SCHED_TYPE_ORDERED +*/ + +#define RTE_EVENT_DEV_CAP_PARALLEL (1ULL << 13) +/**< Event device is capable of parallel scheduling. +* When this flag is set, the application can configure queues with scheduling type +* parallel on this event device. +* @see RTE_SCHED_TYPE_PARALLEL +*/ +/* Event device priority levels */ #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0/**< Highest priority expressed across eventdev subsystem -- 2.39.2
Re: [PATCH 24.03 1/8] eventdev: add capability flags for supported sched types
Quoted 23 lines · Mattias Rönnblom
Quoted 9 lines · Bruce Richardson
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from
rte_event_dev_info_get()API.Similarly add the possible scheduling types to the capabilities table in the docs.
Should we allow an event device to advertise
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES, but not all of these?With current wording of
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESprevents that, but you should be able to allow for this without breaking backward compatibility by tweaking the text from"Event device is capable of enqueuing events of any type to any queue."
"Event device is capable of enqueuing events of any type advertised as supported (e.g., by
RTE_EVENT_DEV_CAP_ATOMIC)."
Quoted 8 lines
An event device that doesn't support ordered, but does support "all" types seems reasonable to me, while an event device that does support ordered on a per-event basis, but doesn't for queue-level configuration does not.
If
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESis left unchanged, the user may ask herself what "any" means (any supported in the API, or any supported by the actual event device).
Seems reasonable if we want to re-define this. I'm fine either way and can add such a change to a v2 patchset if there is consensus on it.
/Bruce
Re: [PATCH 24.03 1/8] eventdev: add capability flags for supported sched types
In reply to Mattias RönnblomQuoted 23 lines · Mattias Rönnblom
Quoted 9 lines · Bruce Richardson
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from
rte_event_dev_info_get()API.Similarly add the possible scheduling types to the capabilities table in the docs.
Should we allow an event device to advertise
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES, but not all of these?With current wording of
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESprevents that, but you should be able to allow for this without breaking backward compatibility by tweaking the text from"Event device is capable of enqueuing events of any type to any queue."
"Event device is capable of enqueuing events of any type advertised as supported (e.g., by
RTE_EVENT_DEV_CAP_ATOMIC)."
Quoted 8 lines
An event device that doesn't support ordered, but does support "all" types seems reasonable to me, while an event device that does support ordered on a per-event basis, but doesn't for queue-level configuration does not.
If
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESis left unchanged, the user may ask herself what "any" means (any supported in the API, or any supported by the actual event device).
Two follow-up thoughts on this:
1. The use of this ALL_TYPES flag would suggest to me that we should not have SINGLE_LINK as an explicit queue type, in the set of ATOMIC/ORDERED/PARALLEL, as it would really confuse the issue as to what exactly all-types means. Therefore, I think we should keep single-link as an auxiliary hint as now.
2. The CAP_QUEUE_ALL_TYPES seems a rather blunt instrument, and I was thinking that we would be better to convert it over to have the alternative flag that says that queues only support a single-type. However, even then, neither really covers the full gamut of support, because in some cases whether or not queues support all types will depend upon configuration. For example, for DLB2 driver, the docs point out that depending upon config, a queue can support either atomic or parallel, or atomic or ordered - with parallel "degrading" to ordered in that case. It's possible we could have other PMDs which allow the final combination of having a queue either atomic, or ordered and parallel combined.
Not sure we have an easy mechanism to express all this, so probably keeping the status quo - possibly with your suggested tweak - is good enough for now. We also need to keep things as simple as possible for app developers too, and try to avoid too many possible combinations.
/Bruce
RE: [PATCH 24.03 1/8] eventdev: add capability flags for supported sched types
Ideally, supporting ORing of schedule types during queue creation would have been best. But advertising all such possible combinations will be a nightmare. But this will allow flexibility to create an exact combination HW can support. Either support all or a subset of it.
-----Original Message-----
From: Bruce Richardson <[email protected]>
Sent: Tuesday, November 21, 2023 6:13 AM
To: Mattias Rönnblom <[email protected]>
Cc: [email protected]; Jerin Jacob <[email protected]>
Subject: Re: [PATCH 24.03 1/8] eventdev: add capability flags for supported sched types
Quoted 23 lines · Mattias Rönnblom
Quoted 9 lines · Bruce Richardson
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from
rte_event_dev_info_get()API.Similarly add the possible scheduling types to the capabilities table in the docs.
Should we allow an event device to advertise
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES, but not all of these?With current wording of
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESprevents that, but you should be able to allow for this without breaking backward compatibility by tweaking the text from"Event device is capable of enqueuing events of any type to any queue."
"Event device is capable of enqueuing events of any type advertised as supported (e.g., by
RTE_EVENT_DEV_CAP_ATOMIC)."
Quoted 8 lines
An event device that doesn't support ordered, but does support "all" types seems reasonable to me, while an event device that does support ordered on a per-event basis, but doesn't for queue-level configuration does not.
If
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESis left unchanged, the user may ask herself what "any" means (any supported in the API, or any supported by the actual event device).
Two follow-up thoughts on this:
1. The use of this ALL_TYPES flag would suggest to me that we should not have SINGLE_LINK as an explicit queue type, in the set of ATOMIC/ORDERED/PARALLEL, as it would really confuse the issue as to what exactly all-types means. Therefore, I think we should keep single-link as an auxiliary hint as now.
2. The CAP_QUEUE_ALL_TYPES seems a rather blunt instrument, and I was thinking that we would be better to convert it over to have the alternative flag that says that queues only support a single-type. However, even then, neither really covers the full gamut of support, because in some cases whether or not queues support all types will depend upon configuration. For example, for DLB2 driver, the docs point out that depending upon config, a queue can support either atomic or parallel, or atomic or ordered - with parallel "degrading" to ordered in that case. It's possible we could have other PMDs which allow the final combination of having a queue either atomic, or ordered and parallel combined.
Not sure we have an easy mechanism to express all this, so probably keeping the status quo - possibly with your suggested tweak - is good enough for now. We also need to keep things as simple as possible for app developers too, and try to avoid too many possible combinations.
/Bruce
PATCH 2/8 event/cnxk: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/cnxk.ini | 3 +++ drivers/event/cnxk/cnxk_eventdev.c | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-)
doc/guides/eventdevs/features/cnxk.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/cnxk/cnxk_eventdev.c +4 -1
@@ -22,7 +22,10 @@ cnxk_sso_info_get(struct cnxk_sso_evdev *dev, dev_info->max_event_port_dequeue_depth =1 ; dev_info->max_event_port_enqueue_depth =1 ; dev_info->max_num_events = dev->max_num_events; - dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_QUEUE_QOS | + dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_PARALLEL | +RTE_EVENT_DEV_CAP_QUEUE_QOS |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES | RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK |
--
2.39.2
PATCH 3/8 event/dlb2: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dlb2.ini | 3 +++ drivers/event/dlb2/dlb2.c | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-)
doc/guides/eventdevs/features/dlb2.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y event_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/dlb2/dlb2.c +4 -1
@@ -71,7 +71,10 @@ static struct rte_event_dev_info evdev_dlb2_default_info = { .max_num_events = DLB2_MAX_NUM_LDB_CREDITS, .max_single_link_event_port_queue_pairs = DLB2_MAX_NUM_DIR_PORTS(DLB2_HW_V2), - .event_dev_cap = (RTE_EVENT_DEV_CAP_EVENT_QOS | + .event_dev_cap = (RTE_EVENT_DEV_CAP_ATOMIC | + RTE_EVENT_DEV_CAP_ORDERED | + RTE_EVENT_DEV_CAP_PARALLEL | + RTE_EVENT_DEV_CAP_EVENT_QOS | RTE_EVENT_DEV_CAP_NONSEQ_MODE | RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED | RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES |
--
2.39.2
RE: [PATCH 24.03 3/8] event/dlb2: add schedule-type capability flags
PATCH 4/8 event/dpaa*: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by these drivers, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dpaa.ini | 2 ++ doc/guides/eventdevs/features/dpaa2.ini | 2 ++ drivers/event/dpaa/dpaa_eventdev.c | 2 ++ drivers/event/dpaa2/dpaa2_eventdev.c | 2 ++ 4 files changed, 8 insertions(+)
doc/guides/eventdevs/features/dpaa.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Y
doc/guides/eventdevs/features/dpaa2.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y queue_all_types = Y burst_mode = Y
drivers/event/dpaa/dpaa_eventdev.c +2 -0
@@ -353,6 +353,8 @@ dpaa_event_dev_info_get(struct rte_eventdev *dev, dev_info->max_num_events =DPAA_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap = +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_BURST_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT |
drivers/event/dpaa2/dpaa2_eventdev.c +2 -0
@@ -404,6 +404,8 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev,DPAA2_EVENT_MAX_PORT_ENQUEUE_DEPTH ; dev_info->max_num_events =DPAA2_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_BURST_MODE |RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT |
--
2.39.2
RE: [PATCH 24.03 4/8] event/dpaa*: add schedule-type capability flags
Quoted 79 lines
-----Original Message-----
From: Bruce Richardson <[email protected]>
Sent: Monday, November 20, 2023 10:56 PM
To: [email protected]
Cc: Bruce Richardson <[email protected]>; Hemant Agrawal <[email protected]>; Sachin Saxena <[email protected]>
Subject: [PATCH 24.03 4/8] event/dpaa*: add schedule-type capability flags
Importance: HighDocument explicitly the scheduling types supported by these drivers, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>--- doc/guides/eventdevs/features/dpaa.ini | 2 ++ doc/guides/eventdevs/features/dpaa2.ini | 2 ++ drivers/event/dpaa/dpaa_eventdev.c | 2 ++ drivers/event/dpaa2/dpaa2_eventdev.c | 2 ++ 4 files changed, 8 insertions(+)doc/guides/eventdevs/features/dpaa.ini +2
-0@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Ydoc/guides/eventdevs/features/dpaa2.ini +2
-0@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y queue_all_types = Y burst_mode = Ydrivers/event/dpaa/dpaa_eventdev.c +2
-0@@ -353,6 +353,8 @@ dpaa_event_dev_info_get(struct rte_eventdev *dev, dev_info->max_num_events =DPAA_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap = +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_BURST_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT | diff --git
a/drivers/event/dpaa2/dpaa2_eventdev.cb/drivers/event/dpaa2/dpaa2_eventdev.c
indexdd4e64395f..dd62c76c86100644drivers/event/dpaa2/dpaa2_eventdev.c +0
-0@@ -404,6 +404,8 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev,DPAA2_EVENT_MAX_PORT_ENQUEUE_DEPTH ; dev_info->max_num_events =DPAA2_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap =
RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED|drivers/event/dpaa2/dpaa2_eventdev.c +2
-1+RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_BURST_MODE |RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT | --2.39.2
PATCH 5/8 event/dsw: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dsw.ini | 1 + drivers/event/dsw/dsw_evdev.c | 1 + 2 files changed, 2 insertions(+)
doc/guides/eventdevs/features/dsw.ini +1 -0
@@ -4,6 +4,7 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Y
drivers/event/dsw/dsw_evdev.c +1 -0
@@ -220,6 +220,7 @@ dsw_info_get(struct rte_eventdev *dev __rte_unused, .max_num_events = DSW_MAX_EVENTS, .max_profiles_per_port = 1, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ATOMIC |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_NONSEQ_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT|
--
2.39.2
Re: [PATCH 24.03 5/8] event/dsw: add schedule-type capability flags
Quoted 34 lines · Bruce Richardson
Document explicitly the scheduling types supported by this driver, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>--- doc/guides/eventdevs/features/dsw.ini | 1 + drivers/event/dsw/dsw_evdev.c | 1 + 2 files changed, 2 insertions(+)doc/guides/eventdevs/features/dsw.ini +1
-0@@ -4,6 +4,7 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Ydrivers/event/dsw/dsw_evdev.c +1
-1@@ -220,6 +220,7 @@ dsw_info_get(struct rte_eventdev *dev __rte_unused, .max_num_events = DSW_MAX_EVENTS, .max_profiles_per_port = 1, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ATOMIC |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_NONSEQ_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT| --
Quoted 2 lines
2.39.2
Re: [PATCH 24.03 5/8] event/dsw: add schedule-type capability flags
Quoted 31 lines · Mattias Rönnblom
Quoted 30 lines · Bruce Richardson
Document explicitly the scheduling types supported by this driver, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>---
doc/guides/eventdevs/features/dsw.ini | 1 +
drivers/event/dsw/dsw_evdev.c | 1 +2 files changed, 2 insertions(+)doc/guides/eventdevs/features/dsw.ini +0
-0@@ -4,6 +4,7 @@; Refer to default.ini for the full list of available PMD features. ;
[Scheduling Features]
+atomic_scheduling = Y
distributed_sched = Y
burst_mode = Y
nonseq_mode = Ydrivers/event/dsw/dsw_evdev.c +0
-0@@ -220,6 +220,7 @@ dsw_info_get(struct rte_eventdev *dev __rte_unused, .max_num_events = DSW_MAX_EVENTS, .max_profiles_per_port = 1,.event_dev_cap = RTE_EVENT_DEV_CAP_BURST_MODE| +
RTE_EVENT_DEV_CAP_ATOMIC|
Quoted 8 lines
Quoted 6 lines
RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED|
RTE_EVENT_DEV_CAP_NONSEQ_MODE|
RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT|Signature · 1 line
2.39.2Acked-by Mattias Rönnblom <[email protected]>
Eh, hold on. PARALLEL is also supported.
Do we need a capability for single link as well?
Re: [PATCH 24.03 5/8] event/dsw: add schedule-type capability flags
Quoted 43 lines · Mattias Rönnblom
Quoted 33 lines · Mattias Rönnblom
Quoted 32 lines · Bruce Richardson
Document explicitly the scheduling types supported by this driver, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>---
doc/guides/eventdevs/features/dsw.ini | 1 +
drivers/event/dsw/dsw_evdev.c | 1 +2 files changed, 2 insertions(+)doc/guides/eventdevs/features/dsw.ini +0
-0@@ -4,6 +4,7 @@; Refer to default.ini for the full list of available PMD features. ;
[Scheduling Features]
+atomic_scheduling = Y
distributed_sched = Y
burst_mode = Y
nonseq_mode = Ydrivers/event/dsw/dsw_evdev.c +0
-0@@ -220,6 +220,7 @@ dsw_info_get(struct rte_eventdev *dev __rte_unused, .max_num_events = DSW_MAX_EVENTS, .max_profiles_per_port = 1,.event_dev_cap = RTE_EVENT_DEV_CAP_BURST_MODE| +
RTE_EVENT_DEV_CAP_ATOMIC|Quoted 8 lines
Quoted 6 lines
RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED|
RTE_EVENT_DEV_CAP_NONSEQ_MODE|
RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT|Signature · 1 line
2.39.2Acked-by Mattias Rönnblom <[email protected]>
Quoted 2 lines
Eh, hold on. PARALLEL is also supported.
Sorry, missed that. Will add in V2.
Quoted 1 line
Do we need a capability for single link as well?
I was wondering about that myself. For this v1 I decided against it because any ordered or atomic queue can be single link by just binding it to a single port. The actual single link flag is jut a hint allow the driver to be more efficient about resourcing.
However, if you think it's worthwhile calling out explicitly I can certainly add it.
/Bruce
Re: [PATCH 24.03 5/8] event/dsw: add schedule-type capability flags
Quoted 49 lines · Bruce Richardson
Quoted 43 lines · Mattias Rönnblom
Quoted 33 lines · Mattias Rönnblom
Quoted 32 lines · Bruce Richardson
Document explicitly the scheduling types supported by this driver, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>---
doc/guides/eventdevs/features/dsw.ini | 1 +
drivers/event/dsw/dsw_evdev.c | 1 +2 files changed, 2 insertions(+)doc/guides/eventdevs/features/dsw.ini +0
-0@@ -4,6 +4,7 @@; Refer to default.ini for the full list of available PMD features. ;
[Scheduling Features]
+atomic_scheduling = Y
distributed_sched = Y
burst_mode = Y
nonseq_mode = Ydrivers/event/dsw/dsw_evdev.c +0
-0@@ -220,6 +220,7 @@ dsw_info_get(struct rte_eventdev *dev __rte_unused, .max_num_events = DSW_MAX_EVENTS, .max_profiles_per_port = 1,.event_dev_cap = RTE_EVENT_DEV_CAP_BURST_MODE| +
RTE_EVENT_DEV_CAP_ATOMIC|Quoted 8 lines
Quoted 6 lines
RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED|
RTE_EVENT_DEV_CAP_NONSEQ_MODE|
RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT|Signature · 1 line
2.39.2Acked-by Mattias Rönnblom <[email protected]>Quoted 2 lines
Eh, hold on. PARALLEL is also supported.
Sorry, missed that. Will add in V2.
Quoted 8 lines
Quoted 1 line
Do we need a capability for single link as well?
I was wondering about that myself. For this v1 I decided against it because any ordered or atomic queue can be single link by just binding it to a single port. The actual single link flag is jut a hint allow the driver to be more efficient about resourcing.
However, if you think it's worthwhile calling out explicitly I can certainly add it.
If we have such a flag, we should look to have eventdev "emulate" single-link via ordered or atomic queues for drivers that don't directly support it. I'm concerned that the number of different capability options makes it difficult to write truly portable apps.
/Bruce
PATCH 6/8 event/octeontx: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/octeontx.ini | 3 +++ drivers/event/octeontx/ssovf_evdev.c | 3 +++ 2 files changed, 6 insertions(+)
doc/guides/eventdevs/features/octeontx.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/octeontx/ssovf_evdev.c +3 -0
@@ -151,6 +151,9 @@ ssovf_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *dev_info) dev_info->max_event_port_enqueue_depth =1 ; dev_info->max_num_events = edev->max_num_events; dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_QUEUE_QOS | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES | RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK |
--
2.39.2
PATCH 7/8 event/opdl: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
---
Maintainers, please check this patch carefully, as I'm not sure the correct way to document this.
According to the docs for this driver, it supports parallel only via ordered. Therefore, I've actually made the docs inconsistent from the flags claimed in the API. I've documented that PARALLEL is supported in the info_get() flags, so code that checks for that will run, but I've omitted it from the table in the docs, since it is not directly supported. Is this a good compromise, or an accurate reflection of the driver?
--- doc/guides/eventdevs/features/opdl.ini | 2 ++ drivers/event/opdl/opdl_evdev.c | 3 +++ 2 files changed, 5 insertions(+)
doc/guides/eventdevs/features/opdl.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y burst_mode = Y carry_flow_id = Y maintenance_free = Y
drivers/event/opdl/opdl_evdev.c +3 -0
@@ -376,6 +376,9 @@ opdl_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *info) .max_event_port_enqueue_depth = MAX_OPDL_CONS_Q_DEPTH, .max_num_events = OPDL_INFLIGHT_EVENTS_TOTAL, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_CARRY_FLOW_ID | RTE_EVENT_DEV_CAP_MAINTENANCE_FREE, .max_profiles_per_port = 1,
--
2.39.2
PATCH 8/8 event/sw: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/sw.ini | 3 +++ drivers/event/sw/sw_evdev.c | 3 +++ 2 files changed, 6 insertions(+)
doc/guides/eventdevs/features/sw.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y event_qos = Y burst_mode = Y
drivers/event/sw/sw_evdev.c +3 -0
@@ -600,6 +600,9 @@ sw_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *info) .max_event_port_enqueue_depth = MAX_SW_PROD_Q_DEPTH, .max_num_events = SW_INFLIGHT_EVENTS_TOTAL, .event_dev_cap = ( + RTE_EVENT_DEV_CAP_ATOMIC | + RTE_EVENT_DEV_CAP_ORDERED | + RTE_EVENT_DEV_CAP_PARALLEL | RTE_EVENT_DEV_CAP_QUEUE_QOS | RTE_EVENT_DEV_CAP_BURST_MODE | RTE_EVENT_DEV_CAP_EVENT_QOS |
--
2.39.2
v2 cover document scheduling types for eventdev drivers
In reply to Bruce RichardsonThe various eventdev drivers, while fitting under a common API, do not all support all scheduling types. The eventdev API is missing some way to query the particular scheduling support for a driver, a key piece of information for application developers. This patchset adds the necessary capability flags, and documentation feature rows, then, driver-by-driver adds the necessary flags to both code and docs.
V2:
* Fix flag values to be unique
* Fix missing PARALLEL flag on DSW
* Add patch adjusting definition of the ALL_TYPES flag
Bruce Richardson (9):
eventdev: add capability flags for supported sched types
eventdev: increase flexibility of all-types flag event/cnxk: add schedule-type capability flags event/dlb2: add schedule-type capability flags event/dpaa*: add schedule-type capability flags event/dsw: add schedule-type capability flags event/octeontx: add schedule-type capability flags event/opdl: add schedule-type capability flags event/sw: add schedule-type capability flags
doc/guides/eventdevs/features/cnxk.ini | 3 ++ doc/guides/eventdevs/features/default.ini | 3 ++ doc/guides/eventdevs/features/dlb2.ini | 3 ++ doc/guides/eventdevs/features/dpaa.ini | 2 ++ doc/guides/eventdevs/features/dpaa2.ini | 2 ++ doc/guides/eventdevs/features/dsw.ini | 2 ++ doc/guides/eventdevs/features/octeontx.ini | 3 ++ doc/guides/eventdevs/features/opdl.ini | 2 ++ doc/guides/eventdevs/features/sw.ini | 3 ++ drivers/event/cnxk/cnxk_eventdev.c | 5 ++- drivers/event/dlb2/dlb2.c | 5 ++- drivers/event/dpaa/dpaa_eventdev.c | 2 ++ drivers/event/dpaa2/dpaa2_eventdev.c | 2 ++ drivers/event/dsw/dsw_evdev.c | 2 ++ drivers/event/octeontx/ssovf_evdev.c | 3 ++ drivers/event/opdl/opdl_evdev.c | 3 ++ drivers/event/sw/sw_evdev.c | 3 ++ lib/eventdev/rte_eventdev.h | 36 ++++++++++++++++++++-- 18 files changed, 79 insertions(+), 5 deletions(-)
--
2.39.2
PATCH v2 1/9 eventdev: add capability flags for supported sched types
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from rte_event_dev_info_get() API.
Similarly add the possible scheduling types to the capabilities table in the docs.
--- doc/guides/eventdevs/features/default.ini | 3 +++ lib/eventdev/rte_eventdev.h | 21 +++++++++++++++++++++ 2 files changed, 24 insertions(+)
doc/guides/eventdevs/features/default.ini +3 -0
@@ -6,6 +6,9 @@ ; the features table in the documentation. ; [Scheduling Features] +atomic_scheduling = +ordered_scheduling = +parallel_scheduling = queue_qos = event_qos = distributed_sched =
lib/eventdev/rte_eventdev.h +21 -0
@@ -326,6 +326,27 @@ struct rte_event;* than one. */ +#define RTE_EVENT_DEV_CAP_ATOMIC (1ULL << 13) +/**< Event device is capable of atomic scheduling. +* When this flag is set, the application can configure queues with scheduling type +* atomic on this event device. +* @see RTE_SCHED_TYPE_ATOMIC +*/ + +#define RTE_EVENT_DEV_CAP_ORDERED (1ULL << 14) +/**< Event device is capable of ordered scheduling. +* When this flag is set, the application can configure queues with scheduling type +* ordered on this event device. +* @see RTE_SCHED_TYPE_ORDERED +*/ + +#define RTE_EVENT_DEV_CAP_PARALLEL (1ULL << 15) +/**< Event device is capable of parallel scheduling. +* When this flag is set, the application can configure queues with scheduling type +* parallel on this event device. +* @see RTE_SCHED_TYPE_PARALLEL +*/ +/* Event device priority levels */ #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0/**< Highest priority expressed across eventdev subsystem
Signature · 1 line
2.39.2
Re: [PATCH 24.03 v2 1/9] eventdev: add capability flags for supported sched types
Quoted 11 lines · Bruce Richardson
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from
rte_event_dev_info_get()API.Similarly add the possible scheduling types to the capabilities table in the docs.
Signed-off-by Bruce Richardson <[email protected]>
Sharing the finer details of device capability to application is always good .
PATCH v2 2/9 eventdev: increase flexibility of all-types flag
In reply to Bruce RichardsonRather than requiring that any device advertising the RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES flag support all of atomic, ordered and parallel scheduling, we can redefine the field so that it basically means that you don't need to specify the queue scheduling type at config time. Instead all types of supported events can be sent to all queues.
--- lib/eventdev/rte_eventdev.h | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-)
lib/eventdev/rte_eventdev.h +12 -3
@@ -250,11 +250,20 @@ struct rte_event;* @see rte_event_dequeue_burst() */ #define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3) -/**< Event device is capable of enqueuing events of any type to any queue. +/**< Event device is capable of accepting enqueued events, of any type +* advertised as supported by the device, to all destination queues. +* +* When this capability is set, the "schedule_type" field of the +* rte_event_queue_conf structure is ignored when a queue is being configured. +* * If this capability is not set, the queue only supports events of the -* *RTE_SCHED_TYPE_* type that it was created with. +* *RTE_SCHED_TYPE_* type specified in the rte_event_queue_conf structure +* at time of configuration. * -* @see RTE_SCHED_TYPE_* values +* @see RTE_SCHED_TYPE_ATOMIC +* @see RTE_SCHED_TYPE_ORDERED +* @see RTE_SCHED_TYPE_PARALLEL +* @see rte_event_queue_conf.schedule_type */ #define RTE_EVENT_DEV_CAP_BURST_MODE (1ULL << 4)/**< Event device is capable of operating in burst mode for enqueue(forward,
--
2.39.2
Re: [PATCH 24.03 v2 2/9] eventdev: increase flexibility of all-types flag
Quoted 18 lines · Bruce Richardson
Rather than requiring that any device advertising the
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESflag support all of atomic, ordered and parallel scheduling, we can redefine the field so that it basically means that you don't need to specify the queue scheduling type at config time. Instead all types of supported events can be sent to all queues.Suggested-by Mattias Rönnblom <[email protected]>Signed-off-by Bruce Richardson <[email protected]>--- lib/eventdev/rte_eventdev.h | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-)lib/eventdev/rte_eventdev.h +0
-0
lib/eventdev/rte_eventdev.h struct rte_event; · line 257
Quoted 9 lines
lib/eventdev/rte_eventdev.h +5
-1@@ -250,11 +250,20 @@ struct rte_event;* @see rte_event_dequeue_burst() */ #define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3) -/**< Event device is capable of enqueuing events of any type to any queue. +/**< Event device is capable of accepting enqueued events, of any type +* advertised as supported by the device, to all destination queues. +* +* When this capability is set, the "schedule_type" field of the +* rte_event_queue_conf structure is ignored when a queue is being configured.
can we also add something like below or so to above line
rte_event_queue_conf structure is ignored when a queue is being configured instead rte_event::sched_type
shall be used.
Also, git commit subject "eventdev: increase flexibility of all-types flag", This patch is just documentation clarification. Right? It was like this from day 1.
I would suggest the subject as "eventdev: clarify all-types flag documentation" or so.
With above changes,
Re: [PATCH 24.03 v2 2/9] eventdev: increase flexibility of all-types flag
Quoted 32 lines · Jerin Jacob
Quoted 18 lines · Bruce Richardson
Rather than requiring that any device advertising the
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESflag support all of atomic, ordered and parallel scheduling, we can redefine the field so that it basically means that you don't need to specify the queue scheduling type at config time. Instead all types of supported events can be sent to all queues.Suggested-by Mattias Rönnblom <[email protected]>Signed-off-by Bruce Richardson <[email protected]>--- lib/eventdev/rte_eventdev.h | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-)lib/eventdev/rte_eventdev.h +0
-0lib/eventdev/rte_eventdev.h struct rte_event; · line 257
Quoted 9 lines
lib/eventdev/rte_eventdev.h +5
-1@@ -250,11 +250,20 @@ struct rte_event;* @see rte_event_dequeue_burst() */ #define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3) -/**< Event device is capable of enqueuing events of any type to any queue. +/**< Event device is capable of accepting enqueued events, of any type +* advertised as supported by the device, to all destination queues. +* +* When this capability is set, the "schedule_type" field of the +* rte_event_queue_conf structure is ignored when a queue is being configured. can we also add something like below or so to above line
Quoted 4 lines
rte_event_queue_confstructure is ignored when a queue is being configured insteadrte_event::sched_type
shall be used.
Preparing v3 now and including this doc change. However, I'm also wondering about the correct behaviour when this flag is not set. When the flag is not set, the events enqueued should match the event type of the queue, but do we need to enforce this, or should we?
Couple of options:
1. Actually enforce this, and state that it is an error to enqueue events with another scheduling type.
2. Explicitly not enforce this, and just state instead that the sched_type of events will be ignored.
Personally, I'd tend very much towards #2. because:
* it's easier for the app, as they can ignore the sched_type field through the pipeline if they want, relying on each queues type to do the right thing. This could be especially useful if they have fallback mechanisms to e.g. configure a queue as atomic if reordered is not supported etc. The downside is that for portable applications the sched type should always be set anyway, but the app doesn't lose anything in this case with #2 over #1.
* It's easier and more performant for the drivers, since it's one less check that should be performed on enqueue. The driver can just blindly override the sched_type provided with the queue config version.
I actually think an extension of #2 would also be nice to have for portability, whereby an app could explicitly configure a queue to only have a scheduling type - event if it's all-types-capable - and thereafter never have to set the sched_type field on events. The drivers would always remember the queue-type and explicitly set that if necessary on enqueue
Thoughts?
/Bruce
PS: Going to send v3 now anyway, based on feedback thus far. If we get quick consensus on above, I can roll it into a v4, otherwise we can look to clarify that situation in a separate patch later.
Re: [PATCH 24.03 v2 2/9] eventdev: increase flexibility of all-types flag
Quoted 62 lines · Bruce Richardson
Quoted 32 lines · Jerin Jacob
Quoted 18 lines · Bruce Richardson
Rather than requiring that any device advertising the
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESflag support all of atomic, ordered and parallel scheduling, we can redefine the field so that it basically means that you don't need to specify the queue scheduling type at config time. Instead all types of supported events can be sent to all queues.Suggested-by Mattias Rönnblom <[email protected]>Signed-off-by Bruce Richardson <[email protected]>--- lib/eventdev/rte_eventdev.h | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-)lib/eventdev/rte_eventdev.h +0
-0lib/eventdev/rte_eventdev.h struct rte_event; · line 257
Quoted 9 lines
lib/eventdev/rte_eventdev.h +5
-1@@ -250,11 +250,20 @@ struct rte_event;* @see rte_event_dequeue_burst() */ #define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3) -/**< Event device is capable of enqueuing events of any type to any queue. +/**< Event device is capable of accepting enqueued events, of any type +* advertised as supported by the device, to all destination queues. +* +* When this capability is set, the "schedule_type" field of the +* rte_event_queue_conf structure is ignored when a queue is being configured. can we also add something like below or so to above line
Quoted 4 lines
rte_event_queue_confstructure is ignored when a queue is being configured insteadrte_event::sched_type
shall be used.Preparing v3 now and including this doc change. However, I'm also wondering about the correct behaviour when this flag is not set. When the flag is not set, the events enqueued should match the event type of the queue, but do we need to enforce this, or should we?
Couple of options:
1. Actually enforce this, and state that it is an error to enqueue events with another scheduling type.
2. Explicitly not enforce this, and just state instead that thesched_typeof events will be ignored.Personally, I'd tend very much towards #2. because:
* it's easier for the app, as they can ignore thesched_typefield through the pipeline if they want, relying on each queues type to do the right thing. This could be especially useful if they have fallback mechanisms to e.g. configure a queue as atomic if reordered is not supported etc. The downside is that for portable applications the sched type should always be set anyway, but the app doesn't lose anything in this case with #2 over #1.* It's easier and more performant for the drivers, since it's one less check that should be performed on enqueue. The driver can just blindly override the
sched_typeprovided with the queue config version.
Quoted 7 lines
I actually think an extension of #2 would also be nice to have for portability, whereby an app could explicitly configure a queue to only have a scheduling type - event if it's all-types-capable - and thereafter never have to set the
sched_typefield on events. The drivers would always remember the queue-type and explicitly set that if necessary on enqueueThoughts?
HW queues with All-type support will be costly resources, so making a portable program
we need to spare 3 queues instead of 1 queue.
Considering the difference in eventdev capabilities, I see the most reliable option is
end user focus on reusable packet processing stages. Have worker skeleton based on HW device capabilities, as there are enough HW differences across event devices.
That is the kind of theme followed in testeventdev.
Quoted 4 lines
/Bruce
PS: Going to send v3 now anyway, based on feedback thus far. If we get quick consensus on above, I can roll it into a v4, otherwise we can look to
Let's go with v3 now. Later we can discuss more on this latter.
Quoted 1 line
clarify that situation in a separate patch later.
PATCH v2 3/9 event/cnxk: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/cnxk.ini | 3 +++ drivers/event/cnxk/cnxk_eventdev.c | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-)
doc/guides/eventdevs/features/cnxk.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/cnxk/cnxk_eventdev.c +4 -1
@@ -22,7 +22,10 @@ cnxk_sso_info_get(struct cnxk_sso_evdev *dev, dev_info->max_event_port_dequeue_depth =1 ; dev_info->max_event_port_enqueue_depth =1 ; dev_info->max_num_events = dev->max_num_events; - dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_QUEUE_QOS | + dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_PARALLEL | +RTE_EVENT_DEV_CAP_QUEUE_QOS |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES | RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK |
Signature · 1 line
2.39.2
PATCH v2 4/9 event/dlb2: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dlb2.ini | 3 +++ drivers/event/dlb2/dlb2.c | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-)
doc/guides/eventdevs/features/dlb2.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y event_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/dlb2/dlb2.c +4 -1
@@ -71,7 +71,10 @@ static struct rte_event_dev_info evdev_dlb2_default_info = { .max_num_events = DLB2_MAX_NUM_LDB_CREDITS, .max_single_link_event_port_queue_pairs = DLB2_MAX_NUM_DIR_PORTS(DLB2_HW_V2), - .event_dev_cap = (RTE_EVENT_DEV_CAP_EVENT_QOS | + .event_dev_cap = (RTE_EVENT_DEV_CAP_ATOMIC | + RTE_EVENT_DEV_CAP_ORDERED | + RTE_EVENT_DEV_CAP_PARALLEL | + RTE_EVENT_DEV_CAP_EVENT_QOS | RTE_EVENT_DEV_CAP_NONSEQ_MODE | RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED | RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES |
Signature · 1 line
2.39.2
PATCH v2 5/9 event/dpaa*: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by these drivers, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dpaa.ini | 2 ++ doc/guides/eventdevs/features/dpaa2.ini | 2 ++ drivers/event/dpaa/dpaa_eventdev.c | 2 ++ drivers/event/dpaa2/dpaa2_eventdev.c | 2 ++ 4 files changed, 8 insertions(+)
doc/guides/eventdevs/features/dpaa.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Y
doc/guides/eventdevs/features/dpaa2.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y queue_all_types = Y burst_mode = Y
drivers/event/dpaa/dpaa_eventdev.c +2 -0
@@ -353,6 +353,8 @@ dpaa_event_dev_info_get(struct rte_eventdev *dev, dev_info->max_num_events =DPAA_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap = +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_BURST_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT |
drivers/event/dpaa2/dpaa2_eventdev.c +2 -0
@@ -404,6 +404,8 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev,DPAA2_EVENT_MAX_PORT_ENQUEUE_DEPTH ; dev_info->max_num_events =DPAA2_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_BURST_MODE |RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT |
Signature · 1 line
2.39.2
PATCH v2 6/9 event/dsw: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dsw.ini | 2 ++ drivers/event/dsw/dsw_evdev.c | 2 ++ 2 files changed, 4 insertions(+)
doc/guides/eventdevs/features/dsw.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Y
drivers/event/dsw/dsw_evdev.c +2 -0
@@ -220,6 +220,8 @@ dsw_info_get(struct rte_eventdev *dev __rte_unused, .max_num_events = DSW_MAX_EVENTS, .max_profiles_per_port = 1, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_NONSEQ_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT|
Signature · 1 line
2.39.2
PATCH v2 7/9 event/octeontx: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/octeontx.ini | 3 +++ drivers/event/octeontx/ssovf_evdev.c | 3 +++ 2 files changed, 6 insertions(+)
doc/guides/eventdevs/features/octeontx.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/octeontx/ssovf_evdev.c +3 -0
@@ -151,6 +151,9 @@ ssovf_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *dev_info) dev_info->max_event_port_enqueue_depth =1 ; dev_info->max_num_events = edev->max_num_events; dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_QUEUE_QOS | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES | RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK |
Signature · 1 line
2.39.2
PATCH v2 8/9 event/opdl: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
---
Maintainers, please check this patch carefully, as I'm not sure the correct way to document this.
According to the docs for this driver, it supports parallel only via ordered. Therefore, I've actually made the docs inconsistent from the flags claimed in the API. I've documented that PARALLEL is supported in the info_get() flags, so code that checks for that will run, but I've omitted it from the table in the docs, since it is not directly supported. Is this a good compromise, or an accurate reflection of the driver?
--- doc/guides/eventdevs/features/opdl.ini | 2 ++ drivers/event/opdl/opdl_evdev.c | 3 +++ 2 files changed, 5 insertions(+)
doc/guides/eventdevs/features/opdl.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y burst_mode = Y carry_flow_id = Y maintenance_free = Y
drivers/event/opdl/opdl_evdev.c +3 -0
@@ -376,6 +376,9 @@ opdl_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *info) .max_event_port_enqueue_depth = MAX_OPDL_CONS_Q_DEPTH, .max_num_events = OPDL_INFLIGHT_EVENTS_TOTAL, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_CARRY_FLOW_ID | RTE_EVENT_DEV_CAP_MAINTENANCE_FREE, .max_profiles_per_port = 1,
Signature · 1 line
2.39.2
Re: [PATCH 24.03 v2 8/9] event/opdl: add schedule-type capability flags
Quoted 27 lines · Bruce Richardson
Document explicitly the scheduling types supported by this driver, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>---
Maintainers, please check this patch carefully, as I'm not sure the correct way to document this.
According to the docs for this driver, it supports parallel only via ordered. Therefore, I've actually made the docs inconsistent from the flags claimed in the API. I've documented that PARALLEL is supported in the
info_get()flags, so code that checks for that will run, but I've omitted it from the table in the docs, since it is not directly supported. Is this a good compromise, or an accurate reflection of the driver?--- doc/guides/eventdevs/features/opdl.ini | 2 ++ drivers/event/opdl/opdl_evdev.c | 3 +++ 2 files changed, 5 insertions(+)doc/guides/eventdevs/features/opdl.ini +0
-0
doc/guides/eventdevs/features/opdl.ini line 8
Quoted 5 lines
doc/guides/eventdevs/features/opdl.ini +2
-0@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y
Missed parallel
Quoted 20 lines
doc/guides/eventdevs/features/opdl.ini +0
-0burst_mode = Y carry_flow_id = Y maintenance_free = Ydrivers/event/opdl/opdl_evdev.c +3
-1@@ -376,6 +376,9 @@ opdl_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *info) .max_event_port_enqueue_depth = MAX_OPDL_CONS_Q_DEPTH, .max_num_events = OPDL_INFLIGHT_EVENTS_TOTAL, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_CARRY_FLOW_ID | RTE_EVENT_DEV_CAP_MAINTENANCE_FREE, .max_profiles_per_port = 1, --2.39.2
Re: [PATCH 24.03 v2 8/9] event/opdl: add schedule-type capability flags
Quoted 24 lines · Jerin Jacob
Quoted 22 lines · Bruce Richardson
Document explicitly the scheduling types supported by this driver, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>---
Maintainers, please check this patch carefully, as I'm not sure the correct way to document this.
According to the docs for this driver, it supports parallel only via ordered. Therefore, I've actually made the docs inconsistent from the flags claimed in the API. I've documented that PARALLEL is supported in the
info_get()flags, so code that checks for that will run, but I've omitted it from the table in the docs, since it is not directly supported. Is this a good compromise, or an accurate reflection of the driver?--- doc/guides/eventdevs/features/opdl.ini | 2 ++ drivers/event/opdl/opdl_evdev.c | 3 +++ 2 files changed, 5 insertions(+)
Quoted 13 lines
doc/guides/eventdevs/features/opdl.ini line 8
Quoted 10 lines
doc/guides/eventdevs/features/opdl.ini +2
-0@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = YMissed parallel
Deliberate omission for now. See note above. Basically, parallel is supported through ordered, so I added the flag below to stop apps from breaking, but I wasn't sure about advertising it in the docs. Will add it if you feel its best to keep them consistent.
/Bruce
Re: [PATCH 24.03 v2 8/9] event/opdl: add schedule-type capability flags
Quoted 40 lines · Bruce Richardson
Quoted 24 lines · Jerin Jacob
Quoted 22 lines · Bruce Richardson
Document explicitly the scheduling types supported by this driver, both via
info_get()function, and via table in the documentation.Signed-off-by Bruce Richardson <[email protected]>---
Maintainers, please check this patch carefully, as I'm not sure the correct way to document this.
According to the docs for this driver, it supports parallel only via ordered. Therefore, I've actually made the docs inconsistent from the flags claimed in the API. I've documented that PARALLEL is supported in the
info_get()flags, so code that checks for that will run, but I've omitted it from the table in the docs, since it is not directly supported. Is this a good compromise, or an accurate reflection of the driver?--- doc/guides/eventdevs/features/opdl.ini | 2 ++ drivers/event/opdl/opdl_evdev.c | 3 +++ 2 files changed, 5 insertions(+)Quoted 13 lines
doc/guides/eventdevs/features/opdl.ini line 8
Quoted 10 lines
doc/guides/eventdevs/features/opdl.ini +2
-0@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = YMissed parallel
Quoted 1 line
Deliberate omission for now. See note above. Basically, parallel is
I see. I missed the note.
Quoted 3 lines
supported through ordered, so I added the flag below to stop apps from breaking, but I wasn't sure about advertising it in the docs. Will add it if you feel its best to keep them consistent.
I think, it is better to keep them consistent.
Quoted 2 lines
/Bruce
PATCH v2 9/9 event/sw: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/sw.ini | 3 +++ drivers/event/sw/sw_evdev.c | 3 +++ 2 files changed, 6 insertions(+)
doc/guides/eventdevs/features/sw.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y event_qos = Y burst_mode = Y
drivers/event/sw/sw_evdev.c +3 -0
@@ -600,6 +600,9 @@ sw_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *info) .max_event_port_enqueue_depth = MAX_SW_PROD_Q_DEPTH, .max_num_events = SW_INFLIGHT_EVENTS_TOTAL, .event_dev_cap = ( + RTE_EVENT_DEV_CAP_ATOMIC | + RTE_EVENT_DEV_CAP_ORDERED | + RTE_EVENT_DEV_CAP_PARALLEL | RTE_EVENT_DEV_CAP_QUEUE_QOS | RTE_EVENT_DEV_CAP_BURST_MODE | RTE_EVENT_DEV_CAP_EVENT_QOS |
Signature · 1 line
2.39.2
v3 cover document scheduling types for eventdev drivers
In reply to Bruce RichardsonThe various eventdev drivers, while fitting under a common API, do not all support all scheduling types. The eventdev API is missing some way to query the particular scheduling support for a driver, a key piece of information for application developers. This patchset adds the necessary capability flags, and documentation feature rows, then, driver-by-driver adds the necessary flags to both code and docs.
V3:
* Fix missing PARALLEL flag on OPDL
* Clarify further doc text on ALL_TYPES flag
V2:
* Fix flag values to be unique
* Fix missing PARALLEL flag on DSW
* Add patch adjusting definition of the ALL_TYPES flag
Bruce Richardson (9):
eventdev: add capability flags for supported sched types
eventdev: clarify all-types flag documentation event/cnxk: add schedule-type capability flags event/dlb2: add schedule-type capability flags event/dpaa*: add schedule-type capability flags event/dsw: add schedule-type capability flags event/octeontx: add schedule-type capability flags event/opdl: add schedule-type capability flags event/sw: add schedule-type capability flags
doc/guides/eventdevs/features/cnxk.ini | 3 ++ doc/guides/eventdevs/features/default.ini | 3 ++ doc/guides/eventdevs/features/dlb2.ini | 3 ++ doc/guides/eventdevs/features/dpaa.ini | 2 ++ doc/guides/eventdevs/features/dpaa2.ini | 2 ++ doc/guides/eventdevs/features/dsw.ini | 2 ++ doc/guides/eventdevs/features/octeontx.ini | 3 ++ doc/guides/eventdevs/features/opdl.ini | 3 ++ doc/guides/eventdevs/features/sw.ini | 3 ++ drivers/event/cnxk/cnxk_eventdev.c | 5 ++- drivers/event/dlb2/dlb2.c | 5 ++- drivers/event/dpaa/dpaa_eventdev.c | 2 ++ drivers/event/dpaa2/dpaa2_eventdev.c | 2 ++ drivers/event/dsw/dsw_evdev.c | 2 ++ drivers/event/octeontx/ssovf_evdev.c | 3 ++ drivers/event/opdl/opdl_evdev.c | 3 ++ drivers/event/sw/sw_evdev.c | 3 ++ lib/eventdev/rte_eventdev.h | 38 ++++++++++++++++++++-- 18 files changed, 82 insertions(+), 5 deletions(-)
--
2.40.1
PATCH v3 1/9 eventdev: add capability flags for supported sched types
Not all eventdev's support all scheduling types, for example, some may only support atomic scheduling or others only support ordered scheduling. There is currently no clear indication for each driver what sched types it supports, so add capability flags to be indicated on return from rte_event_dev_info_get() API.
Similarly add the possible scheduling types to the capabilities table in the docs.
--- doc/guides/eventdevs/features/default.ini | 3 +++ lib/eventdev/rte_eventdev.h | 21 +++++++++++++++++++++ 2 files changed, 24 insertions(+)
doc/guides/eventdevs/features/default.ini +3 -0
@@ -6,6 +6,9 @@ ; the features table in the documentation. ; [Scheduling Features] +atomic_scheduling = +ordered_scheduling = +parallel_scheduling = queue_qos = event_qos = distributed_sched =
lib/eventdev/rte_eventdev.h +21 -0
@@ -326,6 +326,27 @@ struct rte_event;* than one. */ +#define RTE_EVENT_DEV_CAP_ATOMIC (1ULL << 13) +/**< Event device is capable of atomic scheduling. +* When this flag is set, the application can configure queues with scheduling type +* atomic on this event device. +* @see RTE_SCHED_TYPE_ATOMIC +*/ + +#define RTE_EVENT_DEV_CAP_ORDERED (1ULL << 14) +/**< Event device is capable of ordered scheduling. +* When this flag is set, the application can configure queues with scheduling type +* ordered on this event device. +* @see RTE_SCHED_TYPE_ORDERED +*/ + +#define RTE_EVENT_DEV_CAP_PARALLEL (1ULL << 15) +/**< Event device is capable of parallel scheduling. +* When this flag is set, the application can configure queues with scheduling type +* parallel on this event device. +* @see RTE_SCHED_TYPE_PARALLEL +*/ +/* Event device priority levels */ #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0/**< Highest priority expressed across eventdev subsystem
Signature · 1 line
2.40.1
PATCH v3 2/9 eventdev: clarify all-types flag documentation
In reply to Bruce RichardsonRather than requiring that any device advertising the RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES flag support all of atomic, ordered and parallel scheduling, we can redefine the field so that it basically means that you don't need to specify the queue scheduling type at config time. Instead all types of supported events can be sent to all queues.
--- lib/eventdev/rte_eventdev.h | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-)
lib/eventdev/rte_eventdev.h +14 -3
@@ -250,11 +250,22 @@ struct rte_event;* @see rte_event_dequeue_burst() */ #define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3) -/**< Event device is capable of enqueuing events of any type to any queue. +/**< Event device is capable of accepting enqueued events, of any type +* advertised as supported by the device, to all destination queues. +* +* When this capability is set, the "schedule_type" field of the +* rte_event_queue_conf structure is ignored when a queue is being configured. +* Instead the the "sched_type" field of each event enqueued is used to +* select the scheduling to be performed on that event. +* * If this capability is not set, the queue only supports events of the -* *RTE_SCHED_TYPE_* type that it was created with. +* *RTE_SCHED_TYPE_* type specified in the rte_event_queue_conf structure +* at time of configuration. * -* @see RTE_SCHED_TYPE_* values +* @see RTE_SCHED_TYPE_ATOMIC +* @see RTE_SCHED_TYPE_ORDERED +* @see RTE_SCHED_TYPE_PARALLEL +* @see rte_event_queue_conf.schedule_type */ #define RTE_EVENT_DEV_CAP_BURST_MODE (1ULL << 4)/**< Event device is capable of operating in burst mode for enqueue(forward,
Signature · 1 line
2.40.1
Re: [PATCH v3 2/9] eventdev: clarify all-types flag documentation
Quoted 10 lines · Bruce Richardson
Rather than requiring that any device advertising the
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESflag support all of atomic, ordered and parallel scheduling, we can redefine the field so that it basically means that you don't need to specify the queue scheduling type at config time. Instead all types of supported events can be sent to all queues.Suggested-by Mattias Rönnblom <[email protected]>Signed-off-by Bruce Richardson <[email protected]>Acked-by Jerin Jacob <[email protected]>
Series applied to dpdk-next-net-eventdev/for-main with following fixes. Thanks
[for-main]dell[dpdk-next-eventdev] $ ./devtools/checkpatches.sh -n 9 && ./devtools/check-git-log.sh -n 9
### [PATCH] eventdev: clarify all-types flag documentation
WARNING:REPEATED_WORD: Possible repeated word: 'the'
#33: FILE: lib/eventdev/rte_eventdev.h:258:
+ * Instead the the "sched_type" field of each event enqueued is used to
total: 0 errors, 1 warnings, 25 lines checked
Contributor name/email mismatch with .mailmap:
Mattias Rönnblom <[email protected]> is not the primary
email address
Re: [PATCH v3 2/9] eventdev: clarify all-types flag documentation
In reply to Bruce RichardsonQuoted 7 lines · Bruce Richardson
Rather than requiring that any device advertising the
RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPESflag support all of atomic, ordered and parallel scheduling, we can redefine the field so that it basically means that you don't need to specify the queue scheduling type at config time. Instead all types of supported events can be sent to all queues.Suggested-by Mattias Rönnblom <[email protected]>
Please use <[email protected]>.
Quoted 11 lines
Signed-off-by Bruce Richardson <[email protected]>Acked-by Jerin Jacob <[email protected]>--- lib/eventdev/rte_eventdev.h | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-)lib/eventdev/rte_eventdev.h +0
-0
lib/eventdev/rte_eventdev.h struct rte_event; · line 258
Quoted 10 lines
lib/eventdev/rte_eventdev.h +6
-1@@ -250,11 +250,22 @@ struct rte_event;* @see rte_event_dequeue_burst() */ #define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3) -/**< Event device is capable of enqueuing events of any type to any queue. +/**< Event device is capable of accepting enqueued events, of any type +* advertised as supported by the device, to all destination queues. +* +* When this capability is set, the "schedule_type" field of the +* rte_event_queue_conf structure is ignored when a queue is being configured. +* Instead the the "sched_type" field of each event enqueued is used to
"The the" -> "the".
Quoted 15 lines
lib/eventdev/rte_eventdev.h +8
-2+* select the scheduling to be performed on that event. +* * If this capability is not set, the queue only supports events of the -* *RTE_SCHED_TYPE_* type that it was created with. +* *RTE_SCHED_TYPE_* type specified in the rte_event_queue_conf structure +* at time of configuration. * -* @see RTE_SCHED_TYPE_* values +* @see RTE_SCHED_TYPE_ATOMIC +* @see RTE_SCHED_TYPE_ORDERED +* @see RTE_SCHED_TYPE_PARALLEL +* @see rte_event_queue_conf.schedule_type */ #define RTE_EVENT_DEV_CAP_BURST_MODE (1ULL << 4)/**< Event device is capable of operating in burst mode for enqueue(forward,
PATCH v3 3/9 event/cnxk: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/cnxk.ini | 3 +++ drivers/event/cnxk/cnxk_eventdev.c | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-)
doc/guides/eventdevs/features/cnxk.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/cnxk/cnxk_eventdev.c +4 -1
@@ -22,7 +22,10 @@ cnxk_sso_info_get(struct cnxk_sso_evdev *dev, dev_info->max_event_port_dequeue_depth =1 ; dev_info->max_event_port_enqueue_depth =1 ; dev_info->max_num_events = dev->max_num_events; - dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_QUEUE_QOS | + dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_PARALLEL | +RTE_EVENT_DEV_CAP_QUEUE_QOS |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES | RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK |
Signature · 1 line
2.40.1
PATCH v3 4/9 event/dlb2: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dlb2.ini | 3 +++ drivers/event/dlb2/dlb2.c | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-)
doc/guides/eventdevs/features/dlb2.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y event_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/dlb2/dlb2.c +4 -1
@@ -71,7 +71,10 @@ static struct rte_event_dev_info evdev_dlb2_default_info = { .max_num_events = DLB2_MAX_NUM_LDB_CREDITS, .max_single_link_event_port_queue_pairs = DLB2_MAX_NUM_DIR_PORTS(DLB2_HW_V2), - .event_dev_cap = (RTE_EVENT_DEV_CAP_EVENT_QOS | + .event_dev_cap = (RTE_EVENT_DEV_CAP_ATOMIC | + RTE_EVENT_DEV_CAP_ORDERED | + RTE_EVENT_DEV_CAP_PARALLEL | + RTE_EVENT_DEV_CAP_EVENT_QOS | RTE_EVENT_DEV_CAP_NONSEQ_MODE | RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED | RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES |
Signature · 1 line
2.40.1
PATCH v3 5/9 event/dpaa*: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by these drivers, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dpaa.ini | 2 ++ doc/guides/eventdevs/features/dpaa2.ini | 2 ++ drivers/event/dpaa/dpaa_eventdev.c | 2 ++ drivers/event/dpaa2/dpaa2_eventdev.c | 2 ++ 4 files changed, 8 insertions(+)
doc/guides/eventdevs/features/dpaa.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Y
doc/guides/eventdevs/features/dpaa2.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y queue_all_types = Y burst_mode = Y
drivers/event/dpaa/dpaa_eventdev.c +2 -0
@@ -353,6 +353,8 @@ dpaa_event_dev_info_get(struct rte_eventdev *dev, dev_info->max_num_events =DPAA_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap = +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_BURST_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT |
drivers/event/dpaa2/dpaa2_eventdev.c +2 -0
@@ -404,6 +404,8 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev,DPAA2_EVENT_MAX_PORT_ENQUEUE_DEPTH ; dev_info->max_num_events =DPAA2_EVENT_MAX_NUM_EVENTS ; dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_BURST_MODE |RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT |
Signature · 1 line
2.40.1
PATCH v3 6/9 event/dsw: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/dsw.ini | 2 ++ drivers/event/dsw/dsw_evdev.c | 2 ++ 2 files changed, 4 insertions(+)
doc/guides/eventdevs/features/dsw.ini +2 -0
@@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +parallel_scheduling = Y distributed_sched = Y burst_mode = Y nonseq_mode = Y
drivers/event/dsw/dsw_evdev.c +2 -0
@@ -220,6 +220,8 @@ dsw_info_get(struct rte_eventdev *dev __rte_unused, .max_num_events = DSW_MAX_EVENTS, .max_profiles_per_port = 1, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_NONSEQ_MODE | RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT|
Signature · 1 line
2.40.1
PATCH v3 7/9 event/octeontx: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/octeontx.ini | 3 +++ drivers/event/octeontx/ssovf_evdev.c | 3 +++ 2 files changed, 6 insertions(+)
doc/guides/eventdevs/features/octeontx.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y distributed_sched = Y queue_all_types = Y
drivers/event/octeontx/ssovf_evdev.c +3 -0
@@ -151,6 +151,9 @@ ssovf_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *dev_info) dev_info->max_event_port_enqueue_depth =1 ; dev_info->max_num_events = edev->max_num_events; dev_info->event_dev_cap =RTE_EVENT_DEV_CAP_QUEUE_QOS | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED |RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES | RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK |
Signature · 1 line
2.40.1
PATCH v3 8/9 event/opdl: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/opdl.ini | 3 +++ drivers/event/opdl/opdl_evdev.c | 3 +++ 2 files changed, 6 insertions(+)
doc/guides/eventdevs/features/opdl.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y burst_mode = Y carry_flow_id = Y maintenance_free = Y
drivers/event/opdl/opdl_evdev.c +3 -0
@@ -376,6 +376,9 @@ opdl_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *info) .max_event_port_enqueue_depth = MAX_OPDL_CONS_Q_DEPTH, .max_num_events = OPDL_INFLIGHT_EVENTS_TOTAL, .event_dev_cap =RTE_EVENT_DEV_CAP_BURST_MODE | +RTE_EVENT_DEV_CAP_ORDERED | +RTE_EVENT_DEV_CAP_ATOMIC | +RTE_EVENT_DEV_CAP_PARALLEL |RTE_EVENT_DEV_CAP_CARRY_FLOW_ID | RTE_EVENT_DEV_CAP_MAINTENANCE_FREE, .max_profiles_per_port = 1,
Signature · 1 line
2.40.1
PATCH v3 9/9 event/sw: add schedule-type capability flags
In reply to Bruce RichardsonDocument explicitly the scheduling types supported by this driver, both via info_get() function, and via table in the documentation.
--- doc/guides/eventdevs/features/sw.ini | 3 +++ drivers/event/sw/sw_evdev.c | 3 +++ 2 files changed, 6 insertions(+)
doc/guides/eventdevs/features/sw.ini +3 -0
@@ -4,6 +4,9 @@ ; Refer to default.ini for the full list of available PMD features. ; [Scheduling Features] +atomic_scheduling = Y +ordered_scheduling = Y +parallel_scheduling = Y queue_qos = Y event_qos = Y burst_mode = Y
drivers/event/sw/sw_evdev.c +3 -0
@@ -600,6 +600,9 @@ sw_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *info) .max_event_port_enqueue_depth = MAX_SW_PROD_Q_DEPTH, .max_num_events = SW_INFLIGHT_EVENTS_TOTAL, .event_dev_cap = ( + RTE_EVENT_DEV_CAP_ATOMIC | + RTE_EVENT_DEV_CAP_ORDERED | + RTE_EVENT_DEV_CAP_PARALLEL | RTE_EVENT_DEV_CAP_QUEUE_QOS | RTE_EVENT_DEV_CAP_BURST_MODE | RTE_EVENT_DEV_CAP_EVENT_QOS |
Signature · 1 line
2.40.1