VRB2 BBDEV PMD introduction
cover VRB2 BBDEV PMD introduction
This serie includes includes changes to the VRB BBDEV PMD for 23.11. This relies on the previous serie that Maxime is about to apply
(https://patches.dpdk.org/project/dpdk/list/?series=28544).
I did not include documentationa just yet but I will in next revision.
This allows the VRB unified driver to support the new VRB2 implementation variant on GNR-D.
This also include minor change to the dev_info to expose FFT version flexibility to expose information to the application on what is configured dynamically on the device.
Nicolas Chautru (7):
bbdev: add FFT version member in driver info baseband/acc: add FFT version in the VRM PMD baseband/acc: remove the 4G SO capability for VRB1 baseband/acc: allocate FCW memory separately baseband/acc: add support for MLD operation baseband/acc: introduce the new VRB2 variant baseband/acc: add configure helper for VRB2
drivers/baseband/acc/acc100_pmd.h | 2 + drivers/baseband/acc/acc_common.h | 97 +- drivers/baseband/acc/rte_acc100_pmd.c | 10 +- drivers/baseband/acc/rte_vrb_pmd.c | 1967 ++++++++++++++++++++++--- drivers/baseband/acc/vrb1_pf_enum.h | 17 +- drivers/baseband/acc/vrb2_pf_enum.h | 124 ++ drivers/baseband/acc/vrb2_vf_enum.h | 121 ++ drivers/baseband/acc/vrb_cfg.h | 16 + drivers/baseband/acc/vrb_pmd.h | 173 ++- lib/bbdev/rte_bbdev.h | 2 + 10 files changed, 2297 insertions(+), 232 deletions(-) create mode 100644 drivers/baseband/acc/vrb2_pf_enum.h create mode 100644 drivers/baseband/acc/vrb2_vf_enum.h
Signature · 1 line
2.34.1
PATCH 1/7 bbdev: add FFT version member in driver info
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)
lib/bbdev/rte_bbdev.h +2 -0
@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
Signature · 1 line
2.34.1
Re: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Quoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
RE: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide more context.
The SRS processing chain (https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operation) includes a pointwise multiplication by time window.
The generic API include some control of these windowing function but still the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or outside of Intel control). As an illustration for VRB device pf_bb_config provides to user an option to include such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor.
What is required here is for the user application to have knowledge of what version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act accordingly.
The content itself is not specified, for VRB we just use the md5sum of that binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application assumption.
It is also important to under that the user/vendor may use any array or shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application enumerates.
I can add more details in the documentation indeed but above should arguably make sense. The name FFT_version naming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.
Let me know if unclear or if any other thought,
Thanks
Nic
Quoted 36 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
Re: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Hi Nicolas,
Quoted 5 lines · Nicolas
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide more context.
The SRS processing chain (https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operation) includes a pointwise multiplication by time window.
The generic API include some control of these windowing function but still the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or outside of Intel control).
Thanks for the explanations. I also did my homework as my FFT knowledge was buried quite deep in my memory. :)
So this is a vendor-specific way to express generic paramaters.
Regarding VRB device, is this table per device or per VF? Could it be configured by the application directly, or has it to be done through the PF?
Quoted 8 lines
As an illustration for VRB device
pf_bb_configprovides to user an option to include such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor. What is required here is for the user application to have knowledge of what version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act accordingly. The content itself is not specified, for VRB we just use the md5sum of that binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application assumption.
It is also important to under that the user/vendor may use any array or shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application enumerates.I can add more details in the documentation indeed but above should arguably make sense. The name
FFT_versionnaming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.Let me know if unclear or if any other thought,
I think this is clear now to me.
In my opinion, this is not good to have this part of the BBDEV API, as every vendor will have their own way to represent this.
Other alternative is to have a vendor specific API. This is far from ideal and should be avoided as much as possible, but in this case the application has to know anyways which device it is driving. It would be at least clear the field has to be interpreted in a vendor-specific way.
@Hemant, I would be interested in your opinion. (I don't know if NXP has or plans to have FFT accelerator IP)
Regards,
Maxime
Quoted 40 lines
Thanks
NicQuoted 36 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
RE: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Hi Maxime,
Quoted 26 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Friday, September 22, 2023 1:15 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 3 lines · Nicolas
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide
more context.
Quoted 1 line
The SRS processing chain
(https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operation)
includes a pointwise multiplication by time window.Quoted 1 line
The generic API include some control of these windowing function but still
the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or outside of Intel control).
Quoted 4 lines
Thanks for the explanations. I also did my homework as my FFT knowledge was buried quite deep in my memory. :)
So this is a vendor-specific way to express generic paramaters.
Unsure this is that vendor specific. At least the interface allows to know a hash of the table being loaded (which is just pointwise data really, non-proprietary format). I did not state the content is a simple md5sum of the bin file being loaded from linux.
Quoted 3 lines
Regarding VRB device, is this table per device or per VF?
Could it be configured by the application directly, or has it to be done through the PF?
This is configured for the device at platform level, ie. through operator. Common to all application/devices. This captures the windows shape assumptions.
Quoted 35 lines
Quoted 2 lines
As an illustration for VRB device
pf_bb_configprovides to user an option toinclude such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor.
Quoted 1 line
What is required here is for the user application to have knowledge of what
version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act accordingly.
Quoted 1 line
The content itself is not specified, for VRB we just use the md5sum of that
binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application assumption.
Quoted 1 line
It is also important to under that the user/vendor may use any array or
shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application enumerates.
Quoted 2 lines
I can add more details in the documentation indeed but above should
arguably make sense. The name
FFT_versionnaming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.Quoted 2 lines
Let me know if unclear or if any other thought,
I think this is clear now to me.
In my opinion, this is not good to have this part of the BBDEV API, as every vendor will have their own way to represent this.
Quoted 7 lines
Other alternative is to have a vendor specific API. This is far from ideal and should be avoided as much as possible, but in this case the application has to know anyways which device it is driving. It would be at least clear the field has to be interpreted in a vendor-specific way.
@Hemant, I would be interested in your opinion. (I don't know if NXP has or plans to have FFT accelerator IP)
Yes looking forward to it.
Quoted 46 lines
Regards,
MaximeQuoted 8 lines
Thanks
NicQuoted 5 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas,Hernan
Quoted 33 lines
Quoted 32 lines
<[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
Re: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Quoted 28 lines · Nicolas
Hi Maxime,
Quoted 26 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Friday, September 22, 2023 1:15 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 3 lines · Nicolas
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide
more context.
Quoted 1 line
The SRS processing chain
(https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operation)
includes a pointwise multiplication by time window.Quoted 1 line
The generic API include some control of these windowing function but still
the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or outside of Intel control).
Quoted 6 lines
Quoted 4 lines
Thanks for the explanations. I also did my homework as my FFT knowledge was buried quite deep in my memory. :)
So this is a vendor-specific way to express generic paramaters.
Unsure this is that vendor specific. At least the interface allows to know a hash of the table being loaded (which is just pointwise data really, non-proprietary format). I did not state the content is a simple md5sum of the bin file being loaded from linux.
Ok, I think it would be better to provide an API to get the table directly, and have the format being described in the documentation.
With that, we can also provide the hash as you'd like, but the method to calculate the hash should also be provided. Or the application can perform the hash itself if it needs it.
The fact that it is several KB is not an issue, as this information would only be queried once at init time if really needed.
An non-DPDK alternative could be to pass such information to the pod via the device plugin (as a mounted file for instance, or variable).
Quoted 5 lines
Quoted 3 lines
Regarding VRB device, is this table per device or per VF?
Could it be configured by the application directly, or has it to be done through the PF?This is configured for the device at platform level, ie. through operator. Common to all application/devices. This captures the windows shape assumptions.
Thanks for the information!
Quoted 40 lines
Quoted 40 lines
Quoted 2 lines
As an illustration for VRB device
pf_bb_configprovides to user an option toinclude such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor.
Quoted 1 line
What is required here is for the user application to have knowledge of what
version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act accordingly.
Quoted 1 line
The content itself is not specified, for VRB we just use the md5sum of that
binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application assumption.
Quoted 1 line
It is also important to under that the user/vendor may use any array or
shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application enumerates.
Quoted 2 lines
I can add more details in the documentation indeed but above should
arguably make sense. The name
FFT_versionnaming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.Quoted 2 lines
Let me know if unclear or if any other thought,
I think this is clear now to me.
In my opinion, this is not good to have this part of the BBDEV API, as every vendor will have their own way to represent this.
Other alternative is to have a vendor specific API. This is far from ideal and should be avoided as much as possible, but in this case the application has to know anyways which device it is driving. It would be at least clear the field has to be interpreted in a vendor-specific way.
Quoted 4 lines
Quoted 2 lines
@Hemant, I would be interested in your opinion. (I don't know if NXP has or plans to have FFT accelerator IP)
Yes looking forward to it.
Thanks,
Maxime
Quoted 48 lines
Quoted 47 lines
Regards,
MaximeQuoted 8 lines
Thanks
NicQuoted 5 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas,Hernan
Quoted 33 lines
Quoted 32 lines
<[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
RE: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Hi Maxime, Hemant,
I wanted initially to keep it fairly open hence a hash table for the windows profiles, but it is also possible to expose something more descriptive, that would work as well actually. Ie.
+ /** FFT windowing width for 2048 FFT. */
+ uint16_t fft_window_width[RTE_BBDEV_MAX_FFT_WIN];
The provides the width of each windows shape which is enough to distinguish major variants and to estimate noise factor.
Let me know of opinion.
Thanks
Nic
Quoted 180 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 26, 2023 3:00 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 30 lines · Nicolas
Hi Maxime,
Quoted 28 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Friday, September 22, 2023 1:15 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 4 lines · Nicolas
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide
more context.
Quoted 1 line
The SRS processing chain
(https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operatio
n) includes a pointwise multiplication by time window.Quoted 2 lines
The generic API include some control of these windowing function but still
the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or
outside of Intel control).
Quoted 7 lines
Quoted 5 lines
Thanks for the explanations. I also did my homework as my FFT knowledge was buried quite deep in my memory. :)
So this is a vendor-specific way to express generic paramaters.
Unsure this is that vendor specific. At least the interface allows to know a
hash of the table being loaded (which is just pointwise data really, non- proprietary format). I did not state the content is a simple md5sum of the bin file being loaded from linux.
Ok, I think it would be better to provide an API to get the table directly, and have the format being described in the documentation.
With that, we can also provide the hash as you'd like, but the method to calculate the hash should also be provided. Or the application can perform the hash itself if it needs it.
The fact that it is several KB is not an issue, as this information would only be queried once at init time if really needed.
An non-DPDK alternative could be to pass such information to the pod via the device plugin (as a mounted file for instance, or variable).
Quoted 5 lines
Quoted 3 lines
Regarding VRB device, is this table per device or per VF? Could it be configured by the application directly, or has it to be done through the PF?
This is configured for the device at platform level, ie. through operator.
Common to all application/devices. This captures the windows shape assumptions.
Thanks for the information!
Quoted 7 lines
Quoted 7 lines
Quoted 3 lines
As an illustration for VRB device
pf_bb_configprovides to user an option toinclude such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor.
Quoted 6 lines
Quoted 6 lines
Quoted 2 lines
What is required here is for the user application to have knowledge of what
version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act
accordingly.
Quoted 5 lines
Quoted 5 lines
Quoted 2 lines
The content itself is not specified, for VRB we just use the md5sum of that
binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application
assumption.
Quoted 5 lines
Quoted 5 lines
Quoted 2 lines
It is also important to under that the user/vendor may use any array or
shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application
enumerates.
Quoted 21 lines
Quoted 21 lines
Quoted 2 lines
I can add more details in the documentation indeed but above should
arguably make sense. The name
FFT_versionnaming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.Quoted 2 lines
Let me know if unclear or if any other thought,
I think this is clear now to me.
In my opinion, this is not good to have this part of the BBDEV API, as every vendor will have their own way to represent this.
Other alternative is to have a vendor specific API. This is far from ideal and should be avoided as much as possible, but in this case the application has to know anyways which device it is driving. It would be at least clear the field has to be interpreted in a vendor-specific way.
Quoted 4 lines
Quoted 2 lines
@Hemant, I would be interested in your opinion. (I don't know if NXP has or plans to have FFT accelerator IP)
Yes looking forward to it.
Thanks,
MaximeQuoted 48 lines
Quoted 47 lines
Regards,
MaximeQuoted 8 lines
Thanks
NicQuoted 5 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas,Hernan
Quoted 33 lines
Quoted 32 lines
<[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
Re: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Hi Nicolas,
Quoted 9 lines · Nicolas
Hi Maxime, Hemant,
I wanted initially to keep it fairly open hence a hash table for the windows profiles, but it is also possible to expose something more descriptive, that would work as well actually. Ie.
(quoted diff) +2
-0+ /** FFT windowing width for 2048 FFT. */ + uint16_t fft_window_width[RTE_BBDEV_MAX_FFT_WIN];The provides the width of each windows shape which is enough to distinguish major variants and to estimate noise factor.
That sounds much better IMHO.
Regarding the array and values sizes:
1. Should it only covers 2048 points FFT? I see some references about 4096 FFT for 5G and satellites communications
2. Is uint16_t enough for all the usecases?
Since this array is quite big, could it be exposed to the application via dedicated APIs instead of a field? An API to query the length of the array so that the application can allocate required meory, and an API to copy the data in the allocated mem?
Maybe overkill, but I feel different FFT size could be supported in the future, so that would be both future proof and more memory efficient for apps that don't need this.
Quoted 1 line
Let me know of opinion.
Thanks for suggesting this,
Maxime
Quoted 184 lines
Thanks
NicQuoted 180 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 26, 2023 3:00 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 30 lines · Nicolas
Hi Maxime,
Quoted 28 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Friday, September 22, 2023 1:15 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 4 lines · Nicolas
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide
more context.
Quoted 1 line
The SRS processing chain
(https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operatio
n) includes a pointwise multiplication by time window.Quoted 2 lines
The generic API include some control of these windowing function but still
the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or
outside of Intel control).
Quoted 7 lines
Quoted 5 lines
Thanks for the explanations. I also did my homework as my FFT knowledge was buried quite deep in my memory. :)
So this is a vendor-specific way to express generic paramaters.
Unsure this is that vendor specific. At least the interface allows to know a
hash of the table being loaded (which is just pointwise data really, non- proprietary format). I did not state the content is a simple md5sum of the bin file being loaded from linux.
Ok, I think it would be better to provide an API to get the table directly, and have the format being described in the documentation.
With that, we can also provide the hash as you'd like, but the method to calculate the hash should also be provided. Or the application can perform the hash itself if it needs it.
The fact that it is several KB is not an issue, as this information would only be queried once at init time if really needed.
An non-DPDK alternative could be to pass such information to the pod via the device plugin (as a mounted file for instance, or variable).
Quoted 5 lines
Quoted 3 lines
Regarding VRB device, is this table per device or per VF? Could it be configured by the application directly, or has it to be done through the PF?
This is configured for the device at platform level, ie. through operator.
Common to all application/devices. This captures the windows shape assumptions.
Thanks for the information!
Quoted 7 lines
Quoted 7 lines
Quoted 3 lines
As an illustration for VRB device
pf_bb_configprovides to user an option toinclude such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor.
Quoted 6 lines
Quoted 6 lines
Quoted 2 lines
What is required here is for the user application to have knowledge of what
version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act
accordingly.
Quoted 5 lines
Quoted 5 lines
Quoted 2 lines
The content itself is not specified, for VRB we just use the md5sum of that
binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application
assumption.
Quoted 5 lines
Quoted 5 lines
Quoted 2 lines
It is also important to under that the user/vendor may use any array or
shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application
enumerates.
Quoted 21 lines
Quoted 21 lines
Quoted 2 lines
I can add more details in the documentation indeed but above should
arguably make sense. The name
FFT_versionnaming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.Quoted 2 lines
Let me know if unclear or if any other thought,
I think this is clear now to me.
In my opinion, this is not good to have this part of the BBDEV API, as every vendor will have their own way to represent this.
Other alternative is to have a vendor specific API. This is far from ideal and should be avoided as much as possible, but in this case the application has to know anyways which device it is driving. It would be at least clear the field has to be interpreted in a vendor-specific way.
Quoted 4 lines
Quoted 2 lines
@Hemant, I would be interested in your opinion. (I don't know if NXP has or plans to have FFT accelerator IP)
Yes looking forward to it.
Thanks,
MaximeQuoted 48 lines
Quoted 47 lines
Regards,
MaximeQuoted 8 lines
Thanks
NicQuoted 5 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas,Hernan
Quoted 33 lines
Quoted 32 lines
<[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
RE: [PATCH v1 1/7] bbdev: add FFT version member in driver info
HI Maxime,
Quoted 24 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Thursday, September 28, 2023 1:27 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 3 lines · Nicolas
Hi Maxime, Hemant,
I wanted initially to keep it fairly open hence a hash table for the windows
profiles, but it is also possible to expose something more descriptive, that would work as well actually.
Quoted 6 lines
Ie.
(quoted diff) +2
-0+ /** FFT windowing width for 2048 FFT. */ + uint16_t fft_window_width[RTE_BBDEV_MAX_FFT_WIN];The provides the width of each windows shape which is enough to
distinguish major variants and to estimate noise factor.
Quoted 6 lines
That sounds much better IMHO.
Regarding the array and values sizes:
1. Should it only covers 2048 points FFT? I see some references about 4096 FFT for 5G and satellites communications 2. Isuint16_tenough for all the usecases?
That is a misunderstanding, probably because I did not include the definition and value of RTE_BBDEV_MAX_FFT_WIN on the snippet above.
The dimension of the array is purely the number of windows to choose from, ie. 16.
That is NOT an array matching the size of the FFT. In effect that width value is for the reference for 2048 FFT, but the actual width would be scaled down when a lower FFT is being set or higher for bigger FFT, so this doesn’t make assumption on the max FFT size, just a given portion using a reference resolution for 2048 FFT. Uint16_t is more than enough, that width cannot be more than 1024 based on reference above.
Quoted 9 lines
Since this array is quite big, could it be exposed to the application via dedicated APIs instead of a field? An API to query the length of the array so that the application can allocate required meory, and an API to copy the data in the allocated mem?
Maybe overkill, but I feel different FFT size could be supported in the future, so that would be both future proof and more memory efficient for apps that don't need this.
Note above, let me know if unclear.
Quoted 198 lines
Quoted 2 lines
Let me know of opinion.
Thanks for suggesting this,
MaximeQuoted 133 lines
Thanks
NicQuoted 130 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 26, 2023 3:00 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 32 lines · Nicolas
Hi Maxime,
Quoted 30 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Friday, September 22, 2023 1:15 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 4 lines · Nicolas
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide
more context.
Quoted 1 line
The SRS processing chain
(https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operat
io
n) includes a pointwise multiplication by time window.Quoted 2 lines
The generic API include some control of these windowing function but still
the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or
outside of Intel control).
Quoted 8 lines
Quoted 5 lines
Thanks for the explanations. I also did my homework as my FFT knowledge was buried quite deep in my memory. :)
So this is a vendor-specific way to express generic paramaters.
Unsure this is that vendor specific. At least the interface allows to know a
hash of the table being loaded (which is just pointwise data really, non- proprietary format). I did not state the content is a simple md5sum of the bin file being loaded from linux.
Ok, I think it would be better to provide an API to get the table directly, and have the format being described in the documentation.
With that, we can also provide the hash as you'd like, but the method to calculate the hash should also be provided. Or the application can perform the hash itself if it needs it.
The fact that it is several KB is not an issue, as this information would only be queried once at init time if really needed.
An non-DPDK alternative could be to pass such information to the pod via the device plugin (as a mounted file for instance, or variable).
Quoted 5 lines
Quoted 3 lines
Regarding VRB device, is this table per device or per VF? Could it be configured by the application directly, or has it to be done through the PF?
This is configured for the device at platform level, ie. through operator.
Common to all application/devices. This captures the windows shape assumptions.
Thanks for the information!
Quoted 7 lines
Quoted 7 lines
Quoted 3 lines
As an illustration for VRB device
pf_bb_configprovides to user an option toinclude such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor.
Quoted 7 lines
Quoted 7 lines
Quoted 2 lines
What is required here is for the user application to have knowledge of what
version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act
accordingly.
Quoted 5 lines
Quoted 5 lines
Quoted 2 lines
The content itself is not specified, for VRB we just use the md5sum of that
binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application
assumption.
Quoted 6 lines
Quoted 6 lines
Quoted 2 lines
It is also important to under that the user/vendor may use any array or
shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application
enumerates.
Quoted 21 lines
Quoted 21 lines
Quoted 3 lines
I can add more details in the documentation indeed but above should
arguably make sense. The name
FFT_versionnaming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.Quoted 2 lines
Let me know if unclear or if any other thought,
I think this is clear now to me.
In my opinion, this is not good to have this part of the BBDEV API, as every vendor will have their own way to represent this.
Other alternative is to have a vendor specific API. This is far from ideal and should be avoided as much as possible, but in this case the application has to know anyways which device it is driving. It would be at least clear the field has to be interpreted in a
vendor-specific way.
Quoted 58 lines
Quoted 57 lines
Quoted 5 lines
Quoted 3 lines
@Hemant, I would be interested in your opinion. (I don't know if NXP has or plans to have FFT accelerator IP)
Yes looking forward to it.
Thanks,
MaximeQuoted 48 lines
Quoted 47 lines
Regards,
MaximeQuoted 8 lines
Thanks
NicQuoted 5 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas,Hernan
Quoted 33 lines
Quoted 32 lines
<[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
Re: [PATCH v1 1/7] bbdev: add FFT version member in driver info
Quoted 29 lines · Nicolas
HI Maxime,
Quoted 26 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Thursday, September 28, 2023 1:27 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 3 lines · Nicolas
Hi Maxime, Hemant,
I wanted initially to keep it fairly open hence a hash table for the windows
profiles, but it is also possible to expose something more descriptive, that would work as well actually.
Quoted 6 lines
Ie.
(quoted diff) +2
-0+ /** FFT windowing width for 2048 FFT. */ + uint16_t fft_window_width[RTE_BBDEV_MAX_FFT_WIN];The provides the width of each windows shape which is enough to
distinguish major variants and to estimate noise factor.
That sounds much better IMHO.
Quoted 7 lines
Quoted 4 lines
Regarding the array and values sizes:
1. Should it only covers 2048 points FFT? I see some references about 4096 FFT for 5G and satellites communications 2. Isuint16_tenough for all the usecases?That is a misunderstanding, probably because I did not include the definition and value of
RTE_BBDEV_MAX_FFT_WINon the snippet above. The dimension of the array is purely the number of windows to choose from, ie. 16.
Ok, where is the number of windows made available?
Quoted 1 line
That is NOT an array matching the size of the FFT. In effect that width value is for the reference for 2048 FFT, but the actual width would be scaled down when a lower FFT is being set or higher for bigger FFT, so this doesn’t make assumption on the max FFT size, just a given portion using a reference resolution for 2048 FFT.
Ok, if you could document this with example that would be great. Maybe you have some existing links explaining that?
Quoted 8 lines
Uint16_tis more than enough, that width cannot be more than 1024 based on reference above.Quoted 6 lines
Since this array is quite big, could it be exposed to the application via dedicated APIs instead of a field? An API to query the length of the array so that the application can allocate required meory, and an API to copy the data in the allocated mem?
Quoted 5 lines
Quoted 3 lines
Maybe overkill, but I feel different FFT size could be supported in the future, so that would be both future proof and more memory efficient for apps that don't need this.
Note above, let me know if unclear.
It is not clear to me how this representation is generic or specific to your device.
Thanks,
Maxime
Quoted 200 lines
Quoted 199 lines
Quoted 3 lines
Let me know of opinion.
Thanks for suggesting this,
MaximeQuoted 133 lines
Thanks
NicQuoted 130 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 26, 2023 3:00 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 32 lines · Nicolas
Hi Maxime,
Quoted 30 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Friday, September 22, 2023 1:15 AM
To: Chautru, Nicolas <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoHi Nicolas,
Quoted 4 lines · Nicolas
Hi Maxime,
This is neither part of 3GPP per se, nor specific to VRB device. Let me provide
more context.
Quoted 1 line
The SRS processing chain
(https://doc.dpdk.org/guides/prog_guide/bbdev.html#bbdev-fft-operat
io
n) includes a pointwise multiplication by time window.Quoted 2 lines
The generic API include some control of these windowing function but still
the actual shape need to be programmed onto any device (ie. rectangular, taped, sinc, different width or offset, any abritraty shape defined as an array of scalars). These degrees of liberties cannot be exposed through a generic API (information is multi-kB, ie the data itself) and can be user specific (external to the HW IP itself or
outside of Intel control).
Quoted 8 lines
Quoted 5 lines
Thanks for the explanations. I also did my homework as my FFT knowledge was buried quite deep in my memory. :)
So this is a vendor-specific way to express generic paramaters.
Unsure this is that vendor specific. At least the interface allows to know a
hash of the table being loaded (which is just pointwise data really, non- proprietary format). I did not state the content is a simple md5sum of the bin file being loaded from linux.
Ok, I think it would be better to provide an API to get the table directly, and have the format being described in the documentation.
With that, we can also provide the hash as you'd like, but the method to calculate the hash should also be provided. Or the application can perform the hash itself if it needs it.
The fact that it is several KB is not an issue, as this information would only be queried once at init time if really needed.
An non-DPDK alternative could be to pass such information to the pod via the device plugin (as a mounted file for instance, or variable).
Quoted 5 lines
Quoted 3 lines
Regarding VRB device, is this table per device or per VF? Could it be configured by the application directly, or has it to be done through the PF?
This is configured for the device at platform level, ie. through operator.
Common to all application/devices. This captures the windows shape assumptions.
Thanks for the information!
Quoted 7 lines
Quoted 7 lines
Quoted 3 lines
As an illustration for VRB device
pf_bb_configprovides to user an option toinclude such windowing data as an input ("FFT LUT bin file"), but more generally at platform level for any bb device this big Look-Up Table or big array can be configured on the host during platform initialization for a given deployment or vendor.
Quoted 7 lines
Quoted 7 lines
Quoted 2 lines
What is required here is for the user application to have knowledge of what
version of such array is being used on the given platform, as this information would be relevant to processing done outside of bbdev (notably for noise estimate). Through that mechanism, the user can now map through that API which possible file was being used, and act
accordingly.
Quoted 5 lines
Quoted 5 lines
Quoted 2 lines
The content itself is not specified, for VRB we just use the md5sum of that
binary file (which is just a big array of int16 for point wise multiplication) so that this can be used to share knowledge between initialized platform configuration and at run-time user application
assumption.
Quoted 6 lines
Quoted 6 lines
Quoted 2 lines
It is also important to under that the user/vendor may use any array or
shape (based on their algorithm) regardless of Intel or IP, and still be able to share information mapping between what is configured on the platform (multiple versions possible) and what the application
enumerates.
Quoted 21 lines
Quoted 21 lines
Quoted 3 lines
I can add more details in the documentation indeed but above should
arguably make sense. The name
FFT_versionnaming may be quite vague, this is more related to the FFT pointwise windowing array variant assumed on the platform. I did not want to impose for it to be an md5sum necessarily, hence the vagueness, as it could be any hash shared between the device programming and the user application related to the semi-static FFT processing programming.Quoted 2 lines
Let me know if unclear or if any other thought,
I think this is clear now to me.
In my opinion, this is not good to have this part of the BBDEV API, as every vendor will have their own way to represent this.
Other alternative is to have a vendor specific API. This is far from ideal and should be avoided as much as possible, but in this case the application has to know anyways which device it is driving. It would be at least clear the field has to be interpreted in a
vendor-specific way.
Quoted 58 lines
Quoted 57 lines
Quoted 5 lines
Quoted 3 lines
@Hemant, I would be interested in your opinion. (I don't know if NXP has or plans to have FFT accelerator IP)
Yes looking forward to it.
Thanks,
MaximeQuoted 48 lines
Quoted 47 lines
Regards,
MaximeQuoted 8 lines
Thanks
NicQuoted 5 lines
-----Original Message-----
From: Maxime Coquelin <[email protected]>
Sent: Tuesday, September 19, 2023 2:56 AM
To: Chautru, Nicolas <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; Vargas,Hernan
Quoted 33 lines
Quoted 32 lines
<[email protected]>
Subject: Re: [PATCH v1 1/7] bbdev: add FFT version member in driver infoQuoted 3 lines · Nicolas Chautru
This can be used to distinguish different version of the flexible pointwise windowing applied to the FFT and expose this to the application.
Does this version relates to a standard, or is this specific to the implementation of your VRB devices?
Quoted 18 lines
Signed-off-by Nicolas Chautru <[email protected]>--- lib/bbdev/rte_bbdev.h | 2 ++ 1 file changed, 2 insertions(+)lib/bbdev/rte_bbdev.h index renamed from lib/bbdev/rte_bbdev.h +0
-0
a5bcc09f10..d6e54ee9a4100644lib/bbdev/rte_bbdev.h +2
-0@@ -349,6 +349,8 @@ struct rte_bbdev_driver_info {const struct rte_bbdev_op_cap *capabilities;/** Device cpu_flag requirements */ const enum rte_cpu_flag_t *cpu_flag_reqs; +/** Versioning number for the FFT operation type. */ +uint16_t fft_version; };/** Macro used at end of bbdev PMD list */
PATCH 2/7 baseband/acc: add FFT version in the VRM PMD
In reply to Nicolas ChautruThis allows to exposes the flexible version of the poitwise flexible operation being dynamically configured on the device.
--- drivers/baseband/acc/acc_common.h | 1 + drivers/baseband/acc/rte_vrb_pmd.c | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+)
drivers/baseband/acc/acc_common.h +1 -0
@@ -512,6 +512,7 @@ struct acc_deq_intr_details {enum {ACC_VF2PF_STATUS_REQUEST =1 ,ACC_VF2PF_USING_VF =2 , +ACC_VF2PF_LUT_VER_REQUEST =3 , };
drivers/baseband/acc/rte_vrb_pmd.c +22 -0
@@ -298,6 +298,27 @@ vrb_device_status(struct rte_bbdev *dev)return reg; } +/* Request device FFT related version information. */ +static inline uint32_t +vrb_device_fft_ver (struct rte_bbdev *dev) +{ +struct acc_device *d = dev->data->dev_private; +uint32_t reg, time_out =0 ; + +if (d->pf_device) +return 0 ; + +vrb_vf2pf (d,ACC_VF2PF_LUT_VER_REQUEST ); + reg =acc_reg_read (d, d->reg_addr->pf2vf_doorbell); +while ((time_out <ACC_STATUS_TO ) && (reg ==RTE_BBDEV_DEV_NOSTATUS )) { +usleep (ACC_STATUS_WAIT );/*< Wait or VF->PF->VF Comms */ + reg =acc_reg_read (d, d->reg_addr->pf2vf_doorbell); + time_out++; + } + +return reg; +} +/* Checks PF Info Ring to find the interrupt cause and handles it accordingly. */ static inline void vrb_check_ir (struct acc_device *acc_dev)
@@ -1100,6 +1121,7 @@ vrb_dev_info_get(struct rte_bbdev *dev, struct rte_bbdev_driver_info *dev_info)fetch_acc_config (dev);/* Check the status of device. */ dev_info->device_status =vrb_device_status (dev); + dev_info->fft_version =vrb_device_fft_ver (dev);/* Exposed number of queues. */ dev_info->num_queues[RTE_BBDEV_OP_NONE ] =0 ;
Signature · 1 line
2.34.1
PATCH 3/7 baseband/acc: remove the 4G SO capability for VRB1
In reply to Nicolas ChautruThis removes the specific capability and support of LTE Decoder Soft Output option on the VRB1 PMD.
--- drivers/baseband/acc/rte_vrb_pmd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/baseband/acc/rte_vrb_pmd.c +3 -3
@@ -1019,14 +1019,11 @@ vrb_dev_info_get(struct rte_bbdev *dev, struct rte_bbdev_driver_info *dev_info)RTE_BBDEV_TURBO_CRC_TYPE_24B |RTE_BBDEV_TURBO_DEC_CRC_24B_DROP |RTE_BBDEV_TURBO_EQUALIZER | -RTE_BBDEV_TURBO_SOFT_OUT_SATURATE |RTE_BBDEV_TURBO_HALF_ITERATION_EVEN |RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH | -RTE_BBDEV_TURBO_SOFT_OUTPUT |RTE_BBDEV_TURBO_EARLY_TERMINATION |RTE_BBDEV_TURBO_DEC_INTERRUPTS |RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN | -RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT |RTE_BBDEV_TURBO_MAP_DEC |RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP | RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,
@@ -1975,6 +1972,9 @@ enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op,struct rte_mbuf *input, *h_output_head, *h_output, *s_output_head, *s_output; +/* Disable explictly SO for VRB 1. */ + op->turbo_dec.op_flags &= ~RTE_BBDEV_TURBO_SOFT_OUTPUT ; + desc =acc_desc (q, total_enqueued_cbs);vrb_fcw_td_fill (op, &desc->req.fcw_td);
Signature · 1 line
2.34.1
Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1
Quoted 3 lines · Nicolas Chautru
This removes the specific capability and support of LTE Decoder Soft Output option on the VRB1 PMD.
Please explain why such support is removed for this hw.
Quoted 26 lines
Signed-off-by Nicolas Chautru <[email protected]>--- drivers/baseband/acc/rte_vrb_pmd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)drivers/baseband/acc/rte_vrb_pmd.c +0
-3@@ -1019,14 +1019,11 @@ vrb_dev_info_get(struct rte_bbdev *dev, struct rte_bbdev_driver_info *dev_info)RTE_BBDEV_TURBO_CRC_TYPE_24B |RTE_BBDEV_TURBO_DEC_CRC_24B_DROP |RTE_BBDEV_TURBO_EQUALIZER | -RTE_BBDEV_TURBO_SOFT_OUT_SATURATE |RTE_BBDEV_TURBO_HALF_ITERATION_EVEN |RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH | -RTE_BBDEV_TURBO_SOFT_OUTPUT |RTE_BBDEV_TURBO_EARLY_TERMINATION |RTE_BBDEV_TURBO_DEC_INTERRUPTS |RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN | -RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT |RTE_BBDEV_TURBO_MAP_DEC |RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP | RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,
drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op, · line 1976
Quoted 5 lines
drivers/baseband/acc/rte_vrb_pmd.c +2
-0@@ -1975,6 +1972,9 @@ enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op,struct rte_mbuf *input, *h_output_head, *h_output, *s_output_head, *s_output; +/* Disable explictly SO for VRB 1. */ + op->turbo_dec.op_flags &= ~RTE_BBDEV_TURBO_SOFT_OUTPUT ;
Can you explain why it is needed to filter this out?
I did not find a clear description in the bbdev API.
It would help if there were explicits references in doxygen of which capability is necessary for using flags/API.
I was expecting that asking for RTE_BBDEV_TURBO_SOFT_OUTPUT to a driver is only allowed if rte_bbdev_op_cap contains it. With this assumption, it would be invalid for an application to request RTE_BBDEV_TURBO_SOFT_OUTPUT through rte_bbdev_enqueue_dec_ops.
Quoted 7 lines
drivers/baseband/acc/rte_vrb_pmd.c +1
-1+ desc =acc_desc (q, total_enqueued_cbs);vrb_fcw_td_fill (op, &desc->req.fcw_td); --2.34.1
At this point of the series, the documentation still references RTE_BBDEV_TURBO_SOFT_OUTPUT as something supported by the vrb1 driver.
Signature · 1 line
David Marchand
RE: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1
Hi David,
Quoted 9 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Tuesday, September 19, 2023 8:20 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1
Quoted 7 lines
Quoted 3 lines · Nicolas Chautru
This removes the specific capability and support of LTE Decoder Soft Output option on the VRB1 PMD.
Please explain why such support is removed for this hw.
The decision is made to defeature this optional capability as under certain race conditions enabling this may potentially cause reliability issues which would not be acceptable. Note that this is an optional additional output information (soft output information) independent of the actual decoding operation.
More details below next to your other comments.
Quoted 45 lines
drivers/baseband/acc/rte_vrb_pmd.c vrb_dev_info_get(struct rte_bbdev *dev, struct
Quoted 14 lines
Signed-off-by Nicolas Chautru <[email protected]>--- drivers/baseband/acc/rte_vrb_pmd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1019,14 +1019,11 @@ vrb_dev_info_get(struct rte_bbdev *dev, struct
rte_bbdev_driver_info*dev_info)drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q,
Quoted 16 lines
drivers/baseband/acc/rte_vrb_pmd.c +0
-3RTE_BBDEV_TURBO_CRC_TYPE_24B |RTE_BBDEV_TURBO_DEC_CRC_24B_DROP |RTE_BBDEV_TURBO_EQUALIZER | -RTE_BBDEV_TURBO_SOFT_OUT_SATURATE |RTE_BBDEV_TURBO_HALF_ITERATION_EVEN |RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH | -RTE_BBDEV_TURBO_SOFT_OUTPUT |RTE_BBDEV_TURBO_EARLY_TERMINATION |RTE_BBDEV_TURBO_DEC_INTERRUPTS |RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN | -RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT |RTE_BBDEV_TURBO_MAP_DEC | RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP |
RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1975,6 +1972,9 @@ enqueue_dec_one_op_cb(struct acc_queue *q,struct
rte_bbdev_dec_op*op,drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op, · line 1976
Quoted 5 lines
drivers/baseband/acc/rte_vrb_pmd.c +2
-0struct rte_mbuf *input, *h_output_head, *h_output, *s_output_head, *s_output; +/* Disable explictly SO for VRB 1. */ + op->turbo_dec.op_flags &= ~RTE_BBDEV_TURBO_SOFT_OUTPUT ;Can you explain why it is needed to filter this out?
I did not find a clear description in the bbdev API.
It would help if there were explicits references in doxygen of which capability is necessary for using flags/API.
Quoted 4 lines
I was expecting that asking for
RTE_BBDEV_TURBO_SOFT_OUTPUTto a driver is only allowed ifrte_bbdev_op_capcontains it.
With this assumption, it would be invalid for an application to requestRTE_BBDEV_TURBO_SOFT_OUTPUTthroughrte_bbdev_enqueue_dec_ops.
You may arguably expect this from a well behaved user application but still there is nothing that enforces it explicitly, ie. notably under negative scenario conditions which we still need to manage gracefully. Here we want to make sure that in case the optional operational flag is included, we fall back to default mode when using the VRB1 variant.
Keep in mind that the unified driver can support multiple HW variant (see rest of the serie) and may support this option for other variants using same code.
In term of documentation, I believe that capability/flag (ie. note that the enum maps to a capability when retrieved from info_get, and to an operation flag when provided to the bbdev api) is already captured explicitly for many generations. Basically this an optional output of the LTE decoding processing, to provide APP LLR which can be potentially be useful for the user application (separate optional mbuf). It may or may not be supported by a bb device, and it may or may not be requested to be provided through the API. Typically this is not enabled.
In that commit we are defeaturing this optional capability for VRB1, we no longer expose it to the application, and in case the application was requesting it, we would ignore it (as we do for any other flags that is not supported, they become don't care flags which are ignored).
Kindly let me know if still unclear.
Thanks
Nic
Quoted 17 lines
Quoted 9 lines
drivers/baseband/acc/rte_vrb_pmd.c +1
-1+ desc =acc_desc (q, total_enqueued_cbs);vrb_fcw_td_fill (op, &desc->req.fcw_td); --2.34.1
At this point of the series, the documentation still references
RTE_BBDEV_TURBO_SOFT_OUTPUTas something supported by the vrb1 driver.--
David Marchand
Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1
Quoted 15 lines · Nicolas
Hi David,
Quoted 12 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Tuesday, September 19, 2023 8:20 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1Quoted 1 line · Nicolas Chautru
Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
This removes the specific capability and support of LTE Decoder Soft Output option on the VRB1 PMD.
Please explain why such support is removed for this hw.
The decision is made to defeature this optional capability as under certain race conditions enabling this may potentially cause reliability issues which would not be acceptable. Note that this is an optional additional output information (soft output information) independent of the actual decoding operation.
More details below next to your other comments.
This must be explained in the commitlog.
Quoted 46 lines
Quoted 46 lines
drivers/baseband/acc/rte_vrb_pmd.c vrb_dev_info_get(struct rte_bbdev *dev, struct
Quoted 15 lines
Signed-off-by Nicolas Chautru <[email protected]>--- drivers/baseband/acc/rte_vrb_pmd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1019,14 +1019,11 @@ vrb_dev_info_get(struct rte_bbdev *dev, struct
rte_bbdev_driver_info*dev_info)drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q,
Quoted 16 lines
drivers/baseband/acc/rte_vrb_pmd.c +0
-3RTE_BBDEV_TURBO_CRC_TYPE_24B |RTE_BBDEV_TURBO_DEC_CRC_24B_DROP |RTE_BBDEV_TURBO_EQUALIZER | -RTE_BBDEV_TURBO_SOFT_OUT_SATURATE |RTE_BBDEV_TURBO_HALF_ITERATION_EVEN |RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH | -RTE_BBDEV_TURBO_SOFT_OUTPUT |RTE_BBDEV_TURBO_EARLY_TERMINATION |RTE_BBDEV_TURBO_DEC_INTERRUPTS |RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN | -RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT |RTE_BBDEV_TURBO_MAP_DEC | RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP |
RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1975,6 +1972,9 @@ enqueue_dec_one_op_cb(struct acc_queue *q,struct
rte_bbdev_dec_op*op,drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op, · line 1976
Quoted 5 lines
drivers/baseband/acc/rte_vrb_pmd.c +2
-0struct rte_mbuf *input, *h_output_head, *h_output, *s_output_head, *s_output; +/* Disable explictly SO for VRB 1. */ + op->turbo_dec.op_flags &= ~RTE_BBDEV_TURBO_SOFT_OUTPUT ;Can you explain why it is needed to filter this out?
I did not find a clear description in the bbdev API.
It would help if there were explicits references in doxygen of which capability is necessary for using flags/API.
Quoted 6 lines
Quoted 4 lines
I was expecting that asking for
RTE_BBDEV_TURBO_SOFT_OUTPUTto a driver is only allowed ifrte_bbdev_op_capcontains it.
With this assumption, it would be invalid for an application to requestRTE_BBDEV_TURBO_SOFT_OUTPUTthroughrte_bbdev_enqueue_dec_ops.You may arguably expect this from a well behaved user application but still there is nothing that enforces it explicitly, ie. notably under negative scenario conditions which we still need to manage gracefully.
If your application is buggy (not reading / complying with the device capabilities), fix it.
Quoted 2 lines
Here we want to make sure that in case the optional operational flag is included, we fall back to default mode when using the VRB1 variant. Keep in mind that the unified driver can support multiple HW variant (see rest of the serie) and may support this option for other variants using same code.
Whatever the HW variant, the API should be respected: exposing capabilities is done on a per device basis.
Quoted 2 lines
In term of documentation, I believe that capability/flag (ie. note that the enum maps to a capability when retrieved from
info_get, and to an operation flag when provided to the bbdev api) is already captured explicitly for many generations. Basically this an optional output of the LTE decoding processing, to provide APP LLR which can be potentially be useful for the user application (separate optional mbuf). It may or may not be supported by a bb device, and it may or may not be requested to be provided through the API. Typically this is not enabled.
Being optional does not mean that a driver can ignore it. Otherwise, there is no point in exposing a capability.
Thanks.
Signature · 1 line
David Marchand
RE: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1
Hi David,
Quoted 33 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Thursday, September 21, 2023 12:13 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>; Thomas Monjalon <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1Quoted 21 lines · Nicolas
Hi David,
Quoted 17 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Tuesday, September 19, 2023 8:20 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for
VRB1Quoted 3 lines · Nicolas Chautru
This removes the specific capability and support of LTE Decoder Soft Output option on the VRB1 PMD.
Please explain why such support is removed for this hw.
Quoted 8 lines
Quoted 1 line
The decision is made to defeature this optional capability as under certain
race conditions enabling this may potentially cause reliability issues which would not be acceptable.
Quoted 1 line
Note that this is an optional additional output information (soft output
information) independent of the actual decoding operation.
Quoted 1 line
More details below next to your other comments.
This must be explained in the commitlog.
OK will add now.
Quoted 54 lines
Quoted 31 lines
Quoted 31 lines
Quoted 16 lines
Signed-off-by Nicolas Chautru <[email protected]>--- drivers/baseband/acc/rte_vrb_pmd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1019,14 +1019,11 @@ vrb_dev_info_get(struct rte_bbdev *dev,Quoted 1 line
struct
rte_bbdev_driver_info*dev_info)Quoted 13 lines
RTE_BBDEV_TURBO_CRC_TYPE_24B | RTE_BBDEV_TURBO_DEC_CRC_24B_DROP | RTE_BBDEV_TURBO_EQUALIZER |drivers/baseband/acc/rte_vrb_pmd.c +0
-3-RTE_BBDEV_TURBO_SOFT_OUT_SATURATE |RTE_BBDEV_TURBO_HALF_ITERATION_EVEN |RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH | -RTE_BBDEV_TURBO_SOFT_OUTPUT |RTE_BBDEV_TURBO_EARLY_TERMINATION |RTE_BBDEV_TURBO_DEC_INTERRUPTS |RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN | -RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT | RTE_BBDEV_TURBO_MAP_DEC |Quoted 4 lines
Quoted 4 lines
drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue
Quoted 4 lines
RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP|
RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1975,6 +1972,9 @@ enqueue_dec_one_op_cb(struct acc_queue*q,
Quoted 14 lines
Quoted 14 lines
struct
rte_bbdev_dec_op*op,drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op, · line 1976
Quoted 5 lines
drivers/baseband/acc/rte_vrb_pmd.c +2
-0struct rte_mbuf *input, *h_output_head, *h_output, *s_output_head, *s_output; +/* Disable explictly SO for VRB 1. */ + op->turbo_dec.op_flags &= ~RTE_BBDEV_TURBO_SOFT_OUTPUT ;Can you explain why it is needed to filter this out?
I did not find a clear description in the bbdev API.
It would help if there were explicits references in doxygen of which capability is necessary for using flags/API.Quoted 4 lines
Quoted 4 lines
I was expecting that asking for
RTE_BBDEV_TURBO_SOFT_OUTPUTto a driver is only allowed ifrte_bbdev_op_capcontains it. With this assumption, it would be invalid for an application to requestRTE_BBDEV_TURBO_SOFT_OUTPUTthrough
Quoted 8 lines
rte_bbdev_enqueue_dec_ops.Quoted 2 lines
You may arguably expect this from a well behaved user application but still
there is nothing that enforces it explicitly, ie. notably under negative scenario conditions which we still need to manage gracefully.
If your application is buggy (not reading / complying with the device capabilities), fix it.
Supporting negative scenario is within the scope of the PMD, whatever the application throws at us in cannot cause any HW issue. Fixing application issues is outside of DPDK control obviously.
Quoted 11 lines
Quoted 3 lines
Here we want to make sure that in case the optional operational flag is
included, we fall back to default mode when using the VRB1 variant.
Quoted 1 line
Keep in mind that the unified driver can support multiple HW variant (see
rest of the serie) and may support this option for other variants using same code.
Whatever the HW variant, the API should be respected: exposing capabilities is done on a per device basis.
It should be ideally, but in practice in case this is not done for whatever reason (negative scenario, bug in user application) then we want the PMD to still avoid misbehaving.
Quoted 11 lines
Quoted 3 lines
In term of documentation, I believe that capability/flag (ie. note that the
enum maps to a capability when retrieved from
info_get, and to an operation flag when provided to the bbdev api) is already captured explicitly for many generations. Basically this an optional output of the LTE decoding processing, to provide APP LLR which can be potentially be useful for the user application (separate optional mbuf). It may or may not be supported by a bb device, and it may or may not be requested to be provided through the API. Typically this is not enabled.
Quoted 2 lines
Being optional does not mean that a driver can ignore it. Otherwise, there is no point in exposing a capability.
I am not sure I follow your concern. Capability are critical for application to enumerate what the underlying device can do.
Here we are only stating that this is valuable to harden the PMD so that it can operate even if an unexpected API is provided, notably to guarantee the unified code is not used in an unintended manner. Note that no PMD to my knowledge enforces checking explicitly the op_flag matches with the capability (like a bitmask check),
and I don’t really think we have to, these other flags are just meant to have effect since not supported.
Quoted 7 lines
Thanks.
--
David Marchand
Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1
Quoted 103 lines · Nicolas
Hi David,
Quoted 33 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Thursday, September 21, 2023 12:13 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>; Thomas Monjalon <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1Quoted 21 lines · Nicolas
Hi David,
Quoted 17 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Tuesday, September 19, 2023 8:20 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for
VRB1Quoted 3 lines · Nicolas Chautru
This removes the specific capability and support of LTE Decoder Soft Output option on the VRB1 PMD.
Please explain why such support is removed for this hw.
Quoted 8 lines
Quoted 1 line
The decision is made to defeature this optional capability as under certain
race conditions enabling this may potentially cause reliability issues which would not be acceptable.
Quoted 1 line
Note that this is an optional additional output information (soft output
information) independent of the actual decoding operation.
Quoted 1 line
More details below next to your other comments.
This must be explained in the commitlog.
OK will add now.
Quoted 57 lines
Quoted 31 lines
Quoted 31 lines
Quoted 16 lines
Signed-off-by Nicolas Chautru <[email protected]>--- drivers/baseband/acc/rte_vrb_pmd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1019,14 +1019,11 @@ vrb_dev_info_get(struct rte_bbdev *dev,Quoted 1 line
struct
rte_bbdev_driver_info*dev_info)Quoted 13 lines
RTE_BBDEV_TURBO_CRC_TYPE_24B | RTE_BBDEV_TURBO_DEC_CRC_24B_DROP | RTE_BBDEV_TURBO_EQUALIZER |drivers/baseband/acc/rte_vrb_pmd.c +0
-3-RTE_BBDEV_TURBO_SOFT_OUT_SATURATE |RTE_BBDEV_TURBO_HALF_ITERATION_EVEN |RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH | -RTE_BBDEV_TURBO_SOFT_OUTPUT |RTE_BBDEV_TURBO_EARLY_TERMINATION |RTE_BBDEV_TURBO_DEC_INTERRUPTS |RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN | -RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT | RTE_BBDEV_TURBO_MAP_DEC |Quoted 4 lines
Quoted 4 lines
drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue
Quoted 4 lines
RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP|
RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1975,6 +1972,9 @@ enqueue_dec_one_op_cb(struct acc_queue*q,
Quoted 14 lines
Quoted 14 lines
struct
rte_bbdev_dec_op*op,drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op, · line 1976
Quoted 5 lines
drivers/baseband/acc/rte_vrb_pmd.c +2
-0struct rte_mbuf *input, *h_output_head, *h_output, *s_output_head, *s_output; +/* Disable explictly SO for VRB 1. */ + op->turbo_dec.op_flags &= ~RTE_BBDEV_TURBO_SOFT_OUTPUT ;Can you explain why it is needed to filter this out?
I did not find a clear description in the bbdev API.
It would help if there were explicits references in doxygen of which capability is necessary for using flags/API.Quoted 4 lines
Quoted 4 lines
I was expecting that asking for
RTE_BBDEV_TURBO_SOFT_OUTPUTto a driver is only allowed ifrte_bbdev_op_capcontains it. With this assumption, it would be invalid for an application to requestRTE_BBDEV_TURBO_SOFT_OUTPUTthrough
rte_bbdev_enqueue_dec_ops.Quoted 2 lines
You may arguably expect this from a well behaved user application but still
Quoted 8 lines
Quoted 5 lines
there is nothing that enforces it explicitly, ie. notably under negative scenario conditions which we still need to manage gracefully.
If your application is buggy (not reading / complying with the device capabilities), fix it.
Supporting negative scenario is within the scope of the PMD, whatever the application throws at us in cannot cause any HW issue. Fixing application issues is outside of DPDK control obviously.
I don't think it is not the role of the PMD to workaround application bugs.
The PMD driver reports capabilities for a given device variant. The application ignores that and forces the capability, the PMD driver should fail. It is better for the application the PMD driver let it know it is misbehaving than trying to hide it.
Quoted 43 lines
Quoted 12 lines
Quoted 4 lines
Here we want to make sure that in case the optional operational flag is
included, we fall back to default mode when using the VRB1 variant.
Quoted 1 line
Keep in mind that the unified driver can support multiple HW variant (see
rest of the serie) and may support this option for other variants using same code.
Whatever the HW variant, the API should be respected: exposing capabilities is done on a per device basis.
It should be ideally, but in practice in case this is not done for whatever reason (negative scenario, bug in user application) then we want the PMD to still avoid misbehaving.
Quoted 11 lines
Quoted 3 lines
In term of documentation, I believe that capability/flag (ie. note that the
enum maps to a capability when retrieved from
info_get, and to an operation flag when provided to the bbdev api) is already captured explicitly for many generations. Basically this an optional output of the LTE decoding processing, to provide APP LLR which can be potentially be useful for the user application (separate optional mbuf). It may or may not be supported by a bb device, and it may or may not be requested to be provided through the API. Typically this is not enabled.Quoted 2 lines
Being optional does not mean that a driver can ignore it. Otherwise, there is no point in exposing a capability.
I am not sure I follow your concern. Capability are critical for application to enumerate what the underlying device can do.
Here we are only stating that this is valuable to harden the PMD so that it can operate even if an unexpected API is provided, notably to guarantee the unified code is not used in an unintended manner. Note that no PMD to my knowledge enforces checking explicitly theop_flagmatches with the capability (like a bitmask check),
and I don’t really think we have to, these other flags are just meant to have effect since not supported.Quoted 7 lines
Thanks.
--
David Marchand
Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1
Quoted 118 lines · Maxime Coquelin
Quoted 115 lines · Nicolas
Hi David,
Quoted 33 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Thursday, September 21, 2023 12:13 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>; Thomas Monjalon <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for VRB1Quoted 21 lines · Nicolas
Hi David,
Quoted 17 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Tuesday, September 19, 2023 8:20 AM
To: Chautru, Nicolas <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; Vargas, Hernan <[email protected]>
Subject: Re: [PATCH v1 3/7] baseband/acc: remove the 4G SO capability for
VRB1Quoted 3 lines · Nicolas Chautru
This removes the specific capability and support of LTE Decoder Soft Output option on the VRB1 PMD.
Please explain why such support is removed for this hw.
Quoted 8 lines
Quoted 1 line
The decision is made to defeature this optional capability as under certain
race conditions enabling this may potentially cause reliability issues which would not be acceptable.
Quoted 1 line
Note that this is an optional additional output information (soft output
information) independent of the actual decoding operation.
Quoted 1 line
More details below next to your other comments.
This must be explained in the commitlog.
OK will add now.
Quoted 69 lines
Quoted 40 lines
Quoted 40 lines
Quoted 16 lines
Signed-off-by Nicolas Chautru <[email protected]>---
drivers/baseband/acc/rte_vrb_pmd.c| 6 +++---1 file changed, 3 insertions(+), 3 deletions(-)drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1019,14 +1019,11 @@ vrb_dev_info_get(struct rte_bbdev *dev,Quoted 1 line
struct
rte_bbdev_driver_info*dev_info)Quoted 22 lines
RTE_BBDEV_TURBO_CRC_TYPE_24B|
RTE_BBDEV_TURBO_DEC_CRC_24B_DROP|RTE_BBDEV_TURBO_EQUALIZER| -RTE_BBDEV_TURBO_SOFT_OUT_SATURATE|
RTE_BBDEV_TURBO_HALF_ITERATION_EVEN|
RTE_BBDEV_TURBO_CONTINUE_CRC_MATCH|
-RTE_BBDEV_TURBO_SOFT_OUTPUT|
RTE_BBDEV_TURBO_EARLY_TERMINATION|
RTE_BBDEV_TURBO_DEC_INTERRUPTS|
RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN|
-RTE_BBDEV_TURBO_NEG_LLR_1_BIT_SOFT_OUT|RTE_BBDEV_TURBO_MAP_DEC|Quoted 4 lines
Quoted 4 lines
drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue
Quoted 4 lines
RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP|
RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,drivers/baseband/acc/rte_vrb_pmd.c +0
-0@@ -1975,6 +1972,9 @@ enqueue_dec_one_op_cb(struct acc_queue*q,
Quoted 14 lines
Quoted 14 lines
struct
rte_bbdev_dec_op*op,drivers/baseband/acc/rte_vrb_pmd.c enqueue_dec_one_op_cb(struct acc_queue *q, struct rte_bbdev_dec_op *op, · line 1976
Quoted 5 lines
drivers/baseband/acc/rte_vrb_pmd.c +2
-0struct rte_mbuf *input, *h_output_head, *h_output, *s_output_head, *s_output; + /* Disable explictly SO for VRB 1. */ + op->turbo_dec.op_flags &= ~RTE_BBDEV_TURBO_SOFT_OUTPUT;Can you explain why it is needed to filter this out?
I did not find a clear description in the bbdev API.
It would help if there were explicits references in doxygen of which capability is necessary for using flags/API.Quoted 4 lines
Quoted 4 lines
I was expecting that asking for
RTE_BBDEV_TURBO_SOFT_OUTPUTto a driver is only allowed ifrte_bbdev_op_capcontains it. With this assumption, it would be invalid for an application to requestRTE_BBDEV_TURBO_SOFT_OUTPUTthrough
rte_bbdev_enqueue_dec_ops.Quoted 2 lines
You may arguably expect this from a well behaved user application but still
there is nothing that enforces it explicitly, ie. notably under negative scenario conditions which we still need to manage gracefully.
Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
If your application is buggy (not reading / complying with the device capabilities), fix it.
Supporting negative scenario is within the scope of the PMD, whatever the application throws at us in cannot cause any HW issue. Fixing application issues is outside of DPDK control obviously.
I don't think it is not the role of the PMD to workaround application bugs.
Of course I meant:
I don't think it is the role of the PMD to workaround application bugs.
Quoted 49 lines
The PMD driver reports capabilities for a given device variant. The application ignores that and forces the capability, the PMD driver should fail. It is better for the application the PMD driver let it know it is misbehaving than trying to hide it.
Quoted 43 lines
Quoted 12 lines
Quoted 4 lines
Here we want to make sure that in case the optional operational flag is
included, we fall back to default mode when using the VRB1 variant.
Quoted 1 line
Keep in mind that the unified driver can support multiple HW variant (see
rest of the serie) and may support this option for other variants using same code.
Whatever the HW variant, the API should be respected: exposing capabilities is done on a per device basis.
It should be ideally, but in practice in case this is not done for whatever reason (negative scenario, bug in user application) then we want the PMD to still avoid misbehaving.
Quoted 11 lines
Quoted 3 lines
In term of documentation, I believe that capability/flag (ie. note that the
enum maps to a capability when retrieved from
info_get, and to an operation flag when provided to the bbdev api) is already captured explicitly for many generations. Basically this an optional output of the LTE decoding processing, to provide APP LLR which can be potentially be useful for the user application (separate optional mbuf). It may or may not be supported by a bb device, and it may or may not be requested to be provided through the API. Typically this is not enabled.Quoted 2 lines
Being optional does not mean that a driver can ignore it. Otherwise, there is no point in exposing a capability.
I am not sure I follow your concern. Capability are critical for application to enumerate what the underlying device can do.
Here we are only stating that this is valuable to harden the PMD so that it can operate even if an unexpected API is provided, notably to guarantee the unified code is not used in an unintended manner. Note that no PMD to my knowledge enforces checking explicitly theop_flagmatches with the capability (like a bitmask check),
and I don’t really think we have to, these other flags are just meant to have effect since not supported.Quoted 7 lines
Thanks.
Signature · 1 line
David Marchand
PATCH 4/7 baseband/acc: allocate FCW memory separately
In reply to Nicolas ChautruThis allows more flexibility to the FCW size for the unified driver. No actual functional change.
--- drivers/baseband/acc/acc_common.h | 4 +++- drivers/baseband/acc/rte_vrb_pmd.c | 25 ++++++++++++++++++++++++- 2 files changed, 27 insertions(+), 2 deletions(-)
drivers/baseband/acc/acc_common.h +3 -1
@@ -101,6 +101,7 @@#define ACC_NUM_QGRPS_PER_WORD 8#define ACC_MAX_NUM_QGRPS 32#define ACC_RING_SIZE_GRANULARITY 64 +#define ACC_MAX_FCW_SIZE 128/* Constants from K0 computation from 3GPP 38.212 Table 5.4.2.1-2 */ #define ACC_N_ZC_1 66/* N = 66 Zc for BG 1 */
@@ -582,13 +583,14 @@ struct __rte_cache_aligned acc_queue {uint32_t aq_enqueued;/* Count how many "batches" have been enqueued */ uint32_t aq_dequeued;/* Count how many "batches" have been dequeued */ uint32_t irq_enable;/* Enable ops dequeue interrupts if set to 1 */ -struct rte_mempool *fcw_mempool;/* FCW mempool */ enum rte_bbdev_op_type op_type;/* Type of this Queue: TE or TD */ /* Internal Buffers for loopback input */ uint8_t *lb_in;uint8_t *lb_out; +uint8_t *fcw_ring;rte_iova_t lb_in_addr_iova;rte_iova_t lb_out_addr_iova; +rte_iova_t fcw_ring_addr_iova;int8_t *derm_buffer;/* interim buffer for de-rm in SDK */ struct acc_device *d; };
drivers/baseband/acc/rte_vrb_pmd.c +24 -1
@@ -883,6 +883,25 @@ vrb_queue_setup(struct rte_bbdev *dev, uint16_t queue_id, goto free_companion_ring_addr; } + q->fcw_ring =rte_zmalloc_socket (dev->device->driver->name, +ACC_MAX_FCW_SIZE * d->sw_ring_max_depth, +RTE_CACHE_LINE_SIZE , conf->socket); +if (q->fcw_ring ==NULL ) { +rte_bbdev_log (ERR ,"Failed to allocate fcw_ring memory" ); + ret = -ENOMEM ; + goto free_companion_ring_addr; + } + q->fcw_ring_addr_iova =rte_malloc_virt2iova (q->fcw_ring); + +/* For FFT we need to store the FCW separately */ +if (conf->op_type ==RTE_BBDEV_OP_FFT ) { +for (desc_idx =0 ; desc_idx < d->sw_ring_max_depth; desc_idx++) { + desc = q->ring_addr + desc_idx; + desc->req.data_ptrs[0 ].address = q->fcw_ring_addr_iova + + desc_idx *ACC_MAX_FCW_SIZE ; + } + } + q->qgrp_id = (q_idx >>VRB1_GRP_ID_SHIFT ) &0xF ; q->vf_id = (q_idx >>VRB1_VF_ID_SHIFT ) &0x3F ; q->aq_id = q_idx &0xF ;
@@ -994,6 +1013,7 @@ vrb_queue_release(struct rte_bbdev *dev, uint16_t q_id)if (q !=NULL ) {/* Mark the Queue as un-assigned. */ d->q_assigned_bit_map[q->qgrp_id] &= (~0ULL - (1 << (uint64_t ) q->aq_id)); +rte_free (q->fcw_ring);rte_free (q->companion_ring_addr);rte_free (q->lb_in);rte_free (q->lb_out);
@@ -3225,7 +3245,10 @@ vrb_enqueue_fft_one_op(struct acc_queue *q, struct rte_bbdev_fft_op *op, output = op->fft.base_output.data; in_offset = op->fft.base_input.offset; out_offset = op->fft.base_output.offset; - fcw = &desc->req.fcw_fft; + + fcw = (struct acc_fcw_fft *) (q->fcw_ring + + ((q->sw_ring_head + total_enqueued_cbs) & q->sw_ring_wrap_mask) + *ACC_MAX_FCW_SIZE );vrb1_fcw_fft_fill (op, fcw);vrb1_dma_desc_fft_fill (op, &desc->req, input, output, &in_offset, &out_offset);
Signature · 1 line
2.34.1
PATCH 5/7 baseband/acc: add support for MLD operation
In reply to Nicolas ChautruThere is no functionality related to the MLD operation but allows the unified PMD to support the operation being added moving forward.
--- drivers/baseband/acc/acc_common.h | 1 + drivers/baseband/acc/rte_vrb_pmd.c | 39 ++++++++++++++++++++++++------ drivers/baseband/acc/vrb_pmd.h | 12 +++++++++ 3 files changed, 45 insertions(+), 7 deletions(-)
drivers/baseband/acc/acc_common.h +1 -0
@@ -87,6 +87,7 @@#define ACC_FCW_LE_BLEN 32#define ACC_FCW_LD_BLEN 36#define ACC_FCW_FFT_BLEN 28 +#define ACC_FCW_MLDTS_BLEN 32#define ACC_5GUL_SIZE_0 16#define ACC_5GUL_SIZE_1 40#define ACC_5GUL_OFFSET_0 36
drivers/baseband/acc/rte_vrb_pmd.c +32 -7
@@ -37,7 +37,7 @@ vrb1_queue_offset(bool pf_device, uint8_t vf_id, uint8_t qgrp_id, uint16_t aq_idreturn ((qgrp_id <<7 ) + (aq_id <<3 ) + VRB1_VfQmgrIngressAq); } -enum {UL_4G =0 ,UL_5G ,DL_4G ,DL_5G ,FFT ,NUM_ACC }; +enum {UL_4G =0 ,UL_5G ,DL_4G ,DL_5G ,FFT ,MLD ,NUM_ACC };/* Return the accelerator enum for a Queue Group Index. */ static inline int
@@ -53,6 +53,7 @@ accFromQgid(int qg_idx, const struct rte_acc_conf *acc_conf) NumQGroupsPerFn[DL_4G ] = acc_conf->q_dl_4g.num_qgroups; NumQGroupsPerFn[DL_5G ] = acc_conf->q_dl_5g.num_qgroups; NumQGroupsPerFn[FFT ] = acc_conf->q_fft.num_qgroups; + NumQGroupsPerFn[MLD ] = acc_conf->q_mld.num_qgroups;for (acc =UL_4G ; acc <NUM_ACC ; acc++)for (qgIdx =0 ; qgIdx < NumQGroupsPerFn[acc]; qgIdx++) accQg[qgIndex++] = acc;
@@ -83,6 +84,9 @@ qtopFromAcc(struct rte_acc_queue_topology **qtop, int acc_enum, struct rte_acc_ccase FFT : p_qtop = &(acc_conf->q_fft);break ; +case MLD : + p_qtop = &(acc_conf->q_mld); +break ;default :/* NOTREACHED. */ rte_bbdev_log (ERR ,"Unexpected error evaluating %s using %d" , __func__, acc_enum);
@@ -139,6 +143,9 @@ initQTop(struct rte_acc_conf *acc_conf) acc_conf->q_fft.num_aqs_per_groups =0 ; acc_conf->q_fft.num_qgroups =0 ; acc_conf->q_fft.first_qgroup_index =-1 ; + acc_conf->q_mld.num_aqs_per_groups =0 ; + acc_conf->q_mld.num_qgroups =0 ; + acc_conf->q_mld.first_qgroup_index =-1 ; } static inline void
@@ -250,7 +257,7 @@ fetch_acc_config(struct rte_bbdev *dev) } rte_bbdev_log_debug( - "%s Config LLR SIGN IN/OUT %s %s QG %u %u %u %u %u AQ %u %u %u %u %u Len %u %u %u %u %u\n", + "%s Config LLR SIGN IN/OUT %s %s QG %u %u %u %u %u %u AQ %u %u %u %u %u %u Len %u %u %u %u %u %u\n", (d->pf_device) ? "PF" : "VF", (acc_conf->input_pos_llr_1_bit) ? "POS" : "NEG", (acc_conf->output_pos_llr_1_bit) ? "POS" : "NEG",
@@ -259,16 +266,19 @@ fetch_acc_config(struct rte_bbdev *dev) acc_conf->q_ul_5g.num_qgroups, acc_conf->q_dl_5g.num_qgroups, acc_conf->q_fft.num_qgroups, + acc_conf->q_mld.num_qgroups, acc_conf->q_ul_4g.num_aqs_per_groups, acc_conf->q_dl_4g.num_aqs_per_groups, acc_conf->q_ul_5g.num_aqs_per_groups, acc_conf->q_dl_5g.num_aqs_per_groups, acc_conf->q_fft.num_aqs_per_groups, + acc_conf->q_mld.num_aqs_per_groups, acc_conf->q_ul_4g.aq_depth_log2, acc_conf->q_dl_4g.aq_depth_log2, acc_conf->q_ul_5g.aq_depth_log2, acc_conf->q_dl_5g.aq_depth_log2, - acc_conf->q_fft.aq_depth_log2); + acc_conf->q_fft.aq_depth_log2, + acc_conf->q_mld.aq_depth_log2); } static inline void
@@ -332,7 +342,7 @@ vrb_check_ir(struct acc_device *acc_dev)while (ring_data->valid) {if ((ring_data->int_nb <ACC_PF_INT_DMA_DL_DESC_IRQ ) || ( - ring_data->int_nb >ACC_PF_INT_DMA_DL5G_DESC_IRQ )) { + ring_data->int_nb >ACC_PF_INT_DMA_MLD_DESC_IRQ )) {rte_bbdev_log (WARNING ,"InfoRing: ITR:%d Info:0x%x" , ring_data->int_nb, ring_data->detailed_info);/* Initialize Info Ring entry and move forward. */
@@ -366,6 +376,7 @@ vrb_dev_interrupt_handler(void *cb_arg)case ACC_PF_INT_DMA_FFT_DESC_IRQ :case ACC_PF_INT_DMA_UL5G_DESC_IRQ :case ACC_PF_INT_DMA_DL5G_DESC_IRQ : +case ACC_PF_INT_DMA_MLD_DESC_IRQ : deq_intr_det.queue_id =get_queue_id_from_ring_info ( dev->data, *ring_data);if (deq_intr_det.queue_id ==UINT16_MAX ) {
@@ -393,6 +404,7 @@ vrb_dev_interrupt_handler(void *cb_arg)case ACC_VF_INT_DMA_FFT_DESC_IRQ :case ACC_VF_INT_DMA_UL5G_DESC_IRQ :case ACC_VF_INT_DMA_DL5G_DESC_IRQ : +case ACC_VF_INT_DMA_MLD_DESC_IRQ :/* VFs are not aware of their vf_id - it's set to 0. */ ring_data->vf_id =0 ; deq_intr_det.queue_id = get_queue_id_from_ring_info(
@@ -741,7 +753,7 @@ vrb_find_free_queue_idx(struct rte_bbdev *dev, const struct rte_bbdev_queue_conf *conf) {struct acc_device *d = dev->data->dev_private; -int op_2_acc[6 ] = {0 ,UL_4G ,DL_4G ,UL_5G ,DL_5G ,FFT }; +int op_2_acc[7 ] = {0 ,UL_4G ,DL_4G ,UL_5G ,DL_5G ,FFT ,MLD };int acc = op_2_acc[conf->op_type];struct rte_acc_queue_topology *qtop =NULL ;uint16_t group_idx;
@@ -804,7 +816,8 @@ vrb_queue_setup(struct rte_bbdev *dev, uint16_t queue_id,int fcw_len = (conf->op_type ==RTE_BBDEV_OP_LDPC_ENC ?ACC_FCW_LE_BLEN : (conf->op_type ==RTE_BBDEV_OP_TURBO_DEC ?ACC_FCW_TD_BLEN : (conf->op_type ==RTE_BBDEV_OP_LDPC_DEC ? -ACC_FCW_LD_BLEN :ACC_FCW_FFT_BLEN ))); +ACC_FCW_LD_BLEN : (conf->op_type ==RTE_BBDEV_OP_FFT ? +ACC_FCW_FFT_BLEN :ACC_FCW_MLDTS_BLEN ))));for (desc_idx =0 ; desc_idx < d->sw_ring_max_depth; desc_idx++) { desc = q->ring_addr + desc_idx;
@@ -916,6 +929,8 @@ vrb_queue_setup(struct rte_bbdev *dev, uint16_t queue_id, q->aq_depth = (1 << d->acc_conf.q_dl_5g.aq_depth_log2); else if (conf->op_type == RTE_BBDEV_OP_FFT) q->aq_depth = (1 << d->acc_conf.q_fft.aq_depth_log2); + else if (conf->op_type == RTE_BBDEV_OP_MLDTS) + q->aq_depth = (1 << d->acc_conf.q_mld.aq_depth_log2); q->mmio_reg_enqueue =RTE_PTR_ADD (d->mmio_base, d->queue_offset (d->pf_device, q->vf_id, q->qgrp_id, q->aq_id));
@@ -972,6 +987,13 @@ vrb_print_op(struct rte_bbdev_dec_op *op, enum rte_bbdev_op_type op_type, op_dl->ldpc_enc.n_filler, op_dl->ldpc_enc.cb_params.e, op_dl->ldpc_enc.op_flags, op_dl->ldpc_enc.rv_index ); + }else if (op_type ==RTE_BBDEV_OP_MLDTS ) { +struct rte_bbdev_mldts_op *op_mldts = (struct rte_bbdev_mldts_op *) op; +rte_bbdev_log (INFO ," Op MLD %d RBs %d NL %d Rp %d %d %x\n" , + index, + op_mldts->mldts.num_rbs, op_mldts->mldts.num_layers, + op_mldts->mldts.r_rep, + op_mldts->mldts.c_rep, op_mldts->mldts.op_flags); } }
@@ -1152,13 +1174,16 @@ vrb_dev_info_get(struct rte_bbdev *dev, struct rte_bbdev_driver_info *dev_info) d->acc_conf.q_dl_5g.num_qgroups; dev_info->num_queues[RTE_BBDEV_OP_FFT ] = d->acc_conf.q_fft.num_aqs_per_groups * d->acc_conf.q_fft.num_qgroups; + dev_info->num_queues[RTE_BBDEV_OP_MLDTS ] = d->acc_conf.q_mld.num_aqs_per_groups * + d->acc_conf.q_mld.num_qgroups; dev_info->queue_priority[RTE_BBDEV_OP_TURBO_DEC ] = d->acc_conf.q_ul_4g.num_qgroups; dev_info->queue_priority[RTE_BBDEV_OP_TURBO_ENC ] = d->acc_conf.q_dl_4g.num_qgroups; dev_info->queue_priority[RTE_BBDEV_OP_LDPC_DEC ] = d->acc_conf.q_ul_5g.num_qgroups; dev_info->queue_priority[RTE_BBDEV_OP_LDPC_ENC ] = d->acc_conf.q_dl_5g.num_qgroups; dev_info->queue_priority[RTE_BBDEV_OP_FFT ] = d->acc_conf.q_fft.num_qgroups; + dev_info->queue_priority[RTE_BBDEV_OP_MLDTS ] = d->acc_conf.q_mld.num_qgroups; dev_info->max_num_queues =0 ; -for (i =RTE_BBDEV_OP_NONE ; i <=RTE_BBDEV_OP_FFT ; i++) +for (i =RTE_BBDEV_OP_NONE ; i <=RTE_BBDEV_OP_MLDTS ; i++) dev_info->max_num_queues += dev_info->num_queues[i]; dev_info->queue_size_lim =ACC_MAX_QUEUE_DEPTH ; dev_info->hardware_accelerated = true;
drivers/baseband/acc/vrb_pmd.h +12 -0
@@ -101,6 +101,8 @@ struct acc_registry_addr {unsigned int dma_ring_ul4g_lo;unsigned int dma_ring_fft_hi;unsigned int dma_ring_fft_lo; +unsigned int dma_ring_mld_hi; +unsigned int dma_ring_mld_lo;unsigned int ring_size;unsigned int info_ring_hi;unsigned int info_ring_lo;
@@ -116,6 +118,8 @@ struct acc_registry_addr {unsigned int tail_ptrs_ul4g_lo;unsigned int tail_ptrs_fft_hi;unsigned int tail_ptrs_fft_lo; +unsigned int tail_ptrs_mld_hi; +unsigned int tail_ptrs_mld_lo;unsigned int depth_log0_offset;unsigned int depth_log1_offset;unsigned int qman_group_func;
@@ -140,6 +144,8 @@ static const struct acc_registry_addr vrb1_pf_reg_addr = { .dma_ring_ul4g_lo = VRB1_PfDmaFec4GulDescBaseLoRegVf, .dma_ring_fft_hi = VRB1_PfDmaFftDescBaseHiRegVf, .dma_ring_fft_lo = VRB1_PfDmaFftDescBaseLoRegVf, + .dma_ring_mld_hi = 0, + .dma_ring_mld_lo = 0, .ring_size = VRB1_PfQmgrRingSizeVf, .info_ring_hi = VRB1_PfHiInfoRingBaseHiRegPf, .info_ring_lo = VRB1_PfHiInfoRingBaseLoRegPf,
@@ -155,6 +161,8 @@ static const struct acc_registry_addr vrb1_pf_reg_addr = { .tail_ptrs_ul4g_lo = VRB1_PfDmaFec4GulRespPtrLoRegVf, .tail_ptrs_fft_hi = VRB1_PfDmaFftRespPtrHiRegVf, .tail_ptrs_fft_lo = VRB1_PfDmaFftRespPtrLoRegVf, + .tail_ptrs_mld_hi = 0, + .tail_ptrs_mld_lo = 0, .depth_log0_offset = VRB1_PfQmgrGrpDepthLog20Vf, .depth_log1_offset = VRB1_PfQmgrGrpDepthLog21Vf, .qman_group_func = VRB1_PfQmgrGrpFunction0,
@@ -179,6 +187,8 @@ static const struct acc_registry_addr vrb1_vf_reg_addr = { .dma_ring_ul4g_lo = VRB1_VfDmaFec4GulDescBaseLoRegVf, .dma_ring_fft_hi = VRB1_VfDmaFftDescBaseHiRegVf, .dma_ring_fft_lo = VRB1_VfDmaFftDescBaseLoRegVf, + .dma_ring_mld_hi = 0, + .dma_ring_mld_lo = 0, .ring_size = VRB1_VfQmgrRingSizeVf, .info_ring_hi = VRB1_VfHiInfoRingBaseHiVf, .info_ring_lo = VRB1_VfHiInfoRingBaseLoVf,
@@ -194,6 +204,8 @@ static const struct acc_registry_addr vrb1_vf_reg_addr = { .tail_ptrs_ul4g_lo = VRB1_VfDmaFec4GulRespPtrLoRegVf, .tail_ptrs_fft_hi = VRB1_VfDmaFftRespPtrHiRegVf, .tail_ptrs_fft_lo = VRB1_VfDmaFftRespPtrLoRegVf, + .tail_ptrs_mld_hi = 0, + .tail_ptrs_mld_lo = 0, .depth_log0_offset = VRB1_VfQmgrGrpDepthLog20Vf, .depth_log1_offset = VRB1_VfQmgrGrpDepthLog21Vf, .qman_group_func = VRB1_VfQmgrGrpFunction0Vf,
Signature · 1 line
2.34.1
PATCH 6/7 baseband/acc: introduce the new VRB2 variant
In reply to Nicolas ChautruThis extends the unified driver to support both the VRB1 and VRB2 implentation of Intel vRAN Boost.
--- drivers/baseband/acc/acc_common.h | 84 +- drivers/baseband/acc/rte_acc100_pmd.c | 4 +- drivers/baseband/acc/rte_vrb_pmd.c | 1441 ++++++++++++++++++++++--- drivers/baseband/acc/vrb1_pf_enum.h | 17 +- drivers/baseband/acc/vrb2_pf_enum.h | 124 +++ drivers/baseband/acc/vrb2_vf_enum.h | 121 +++ drivers/baseband/acc/vrb_pmd.h | 161 ++- 7 files changed, 1789 insertions(+), 163 deletions(-) create mode 100644 drivers/baseband/acc/vrb2_pf_enum.h create mode 100644 drivers/baseband/acc/vrb2_vf_enum.h
drivers/baseband/acc/acc_common.h +70 -14
@@ -18,6 +18,7 @@#define ACC_DMA_BLKID_OUT_HARQ 3#define ACC_DMA_BLKID_IN_HARQ 3#define ACC_DMA_BLKID_IN_MLD_R 3 +#define ACC_DMA_BLKID_DEWIN_IN 3/* Values used in filling in decode FCWs */ #define ACC_FCW_TD_VER 1
@@ -103,6 +104,9 @@#define ACC_MAX_NUM_QGRPS 32#define ACC_RING_SIZE_GRANULARITY 64#define ACC_MAX_FCW_SIZE 128 +#define ACC_IQ_SIZE 4 + +#define ACC_FCW_FFT_BLEN_3 28/* Constants from K0 computation from 3GPP 38.212 Table 5.4.2.1-2 */ #define ACC_N_ZC_1 66/* N = 66 Zc for BG 1 */
@@ -132,6 +136,11 @@#define ACC_LIM_21 14/* 0.21 */ #define ACC_LIM_31 20/* 0.31 */ #define ACC_MAX_E (128 * 1024 - 2) +#define ACC_MAX_CS 12 + +#define ACC100_VARIANT 0 +#define VRB1_VARIANT 2 +#define VRB2_VARIANT 3/* Helper macro for logging */ #define rte_acc_log (level, fmt, ...) \
@@ -332,6 +341,37 @@ struct __rte_packed acc_fcw_fft { res:19 ; }; +/* FFT Frame Control Word */ +struct __rte_packed acc_fcw_fft_3 { + uint32_t in_frame_size:16, + leading_pad_size:16; + uint32_t out_frame_size:16, + leading_depad_size:16; +uint32_t cs_window_sel; + uint32_t cs_window_sel2:16, + cs_enable_bmap:16; + uint32_t num_antennas:8, + idft_size:8, + dft_size:8, + cs_offset:8; + uint32_t idft_shift:8, + dft_shift:8, + cs_multiplier:16; + uint32_t bypass:2, + fp16_in:1, /* Not supported in VRB1 */ + fp16_out:1, + exp_adj:4, + power_shift:4, + power_en:1, + enable_dewin:1, + freq_resample_mode:2, + depad_ouput_size:16; +uint16_t cs_theta_0[ACC_MAX_CS ]; +uint32_t cs_theta_d[ACC_MAX_CS ]; +int8_t cs_time_offset[ACC_MAX_CS ]; +}; + +/* MLD-TS Frame Control Word */ struct __rte_packed acc_fcw_mldts { uint32_t fcw_version:4,
@@ -473,14 +513,14 @@ union acc_info_ring_data { uint16_t valid: 1; };struct { -uint32_t aq_id_3:6 ; -uint32_t qg_id_3:5 ; -uint32_t vf_id_3:6 ; -uint32_t int_nb_3:6 ; -uint32_t msi_0_3:1 ; -uint32_t vf2pf_3:6 ; -uint32_t loop_3:1 ; -uint32_t valid_3:1 ; +uint32_t aq_id_vrb2:6 ; +uint32_t qg_id_vrb2:5 ; +uint32_t vf_id_vrb2:6 ; +uint32_t int_nb_vrb2:6 ; +uint32_t msi_0_vrb2:1 ; +uint32_t vf2pf_vrb2:6 ; +uint32_t loop_vrb2:1 ; +uint32_t valid_vrb2:1 ; }; } __rte_packed;
@@ -765,16 +805,20 @@ alloc_sw_rings_min_mem(struct rte_bbdev *dev, struct acc_device *d,*/ static inline uint16_t get_queue_id_from_ring_info (struct rte_bbdev_data *data, -const union acc_info_ring_data ring_data) +const union acc_info_ring_data ring_data,uint16_t device_variant) {uint16_t queue_id; +struct acc_queue *acc_q; +uint16_t vf_id = (device_variant ==VRB2_VARIANT ) ? ring_data.vf_id_vrb2 : ring_data.vf_id; +uint16_t aq_id = (device_variant ==VRB2_VARIANT ) ? ring_data.aq_id_vrb2 : ring_data.aq_id; +uint16_t qg_id = (device_variant ==VRB2_VARIANT ) ? ring_data.qg_id_vrb2 : ring_data.qg_id;for (queue_id =0 ; queue_id < data->num_queues; ++queue_id) { -struct acc_queue *acc_q = - data->queues[queue_id].queue_private; -if (acc_q !=NULL && acc_q->aq_id == ring_data.aq_id && - acc_q->qgrp_id == ring_data.qg_id && - acc_q->vf_id == ring_data.vf_id) + acc_q = data->queues[queue_id].queue_private; + +if (acc_q !=NULL && acc_q->aq_id == aq_id && + acc_q->qgrp_id == qg_id && + acc_q->vf_id == vf_id)return queue_id; }
@@ -1436,4 +1480,16 @@ get_num_cbs_in_tb_ldpc_enc(struct rte_bbdev_op_ldpc_enc *ldpc_enc) return cbs_in_tb; } +#ifdef RTE_LIBRTE_BBDEV_DEBUG +static inline void +acc_memdump (const char *string,void *buf,uint16_t bytes) +{ +printf ("%s\n" , string); +uint32_t *data = buf; +uint16_t i; +for (i =0 ; i < bytes /4 ; i++) +printf ("0x%08X\n" , data[i]); +} +#endif +#endif /* _ACC_COMMON_H_ */
drivers/baseband/acc/rte_acc100_pmd.c +2 -2
@@ -294,7 +294,7 @@ acc100_pf_interrupt_handler(struct rte_bbdev *dev)case ACC100_PF_INT_DMA_UL5G_DESC_IRQ :case ACC100_PF_INT_DMA_DL5G_DESC_IRQ : deq_intr_det.queue_id =get_queue_id_from_ring_info ( - dev->data, *ring_data); + dev->data, *ring_data, acc100_dev->device_variant);if (deq_intr_det.queue_id ==UINT16_MAX ) { rte_bbdev_log(ERR, "Couldn't find queue: aq_id: %u, qg_id: %u, vf_id: %u",
@@ -348,7 +348,7 @@ acc100_vf_interrupt_handler(struct rte_bbdev *dev)*/ ring_data->vf_id =0 ; deq_intr_det.queue_id =get_queue_id_from_ring_info ( - dev->data, *ring_data); + dev->data, *ring_data, acc100_dev->device_variant);if (deq_intr_det.queue_id ==UINT16_MAX ) { rte_bbdev_log(ERR, "Couldn't find queue: aq_id: %u, qg_id: %u",
drivers/baseband/acc/rte_vrb_pmd.c +1303 -138
1,804 lines not on this page · raw message
drivers/baseband/acc/vrb1_pf_enum.h +12 -5
@@ -98,11 +98,18 @@ enum {ACC_PF_INT_DMA_UL5G_DESC_IRQ =8 ,ACC_PF_INT_DMA_DL5G_DESC_IRQ =9 ,ACC_PF_INT_DMA_MLD_DESC_IRQ =10 , -ACC_PF_INT_ARAM_ECC_1BIT_ERR =11 , -ACC_PF_INT_PARITY_ERR =12 , -ACC_PF_INT_QMGR_ERR =13 , -ACC_PF_INT_INT_REQ_OVERFLOW =14 , - ACC_PF_INT_APB_TIMEOUT = 15, +ACC_PF_INT_ARAM_ACCESS_ERR =11 , +ACC_PF_INT_ARAM_ECC_1BIT_ERR =12 , +ACC_PF_INT_PARITY_ERR =13 , +ACC_PF_INT_QMGR_OVERFLOW =14 , +ACC_PF_INT_QMGR_ERR =15 , +ACC_PF_INT_ATS_ERR =22 , +ACC_PF_INT_ARAM_FUUL =23 , +ACC_PF_INT_EXTRA_READ =24 , +ACC_PF_INT_COMPLETION_TIMEOUT =25 , +ACC_PF_INT_CORE_HANG =26 , +ACC_PF_INT_DMA_HANG =28 , + ACC_PF_INT_DS_HANG = 27, };#endif /* VRB1_PF_ENUM_H */
drivers/baseband/acc/vrb2_pf_enum.h new file +124 -0
124 lines not on this page · raw message
drivers/baseband/acc/vrb2_vf_enum.h new file +121 -0
121 lines not on this page · raw message
drivers/baseband/acc/vrb_pmd.h +157 -4
192 lines not on this page · raw message
Signature · 1 line
2.34.1
PATCH 7/7 baseband/acc: add configure helper for VRB2
In reply to Nicolas ChautruThis allows to configure the VRB2 device using a
companion configuration function within the DPDK
bbdev-test environment.
--- drivers/baseband/acc/acc100_pmd.h | 2 + drivers/baseband/acc/acc_common.h | 7 + drivers/baseband/acc/rte_acc100_pmd.c | 6 +- drivers/baseband/acc/rte_vrb_pmd.c | 322 ++++++++++++++++++++++++++ drivers/baseband/acc/vrb_cfg.h | 16 ++ 5 files changed, 352 insertions(+), 1 deletion(-)
drivers/baseband/acc/acc100_pmd.h +2 -0
@@ -34,6 +34,8 @@#define ACC100_VENDOR_ID (0x8086)#define ACC100_PF_DEVICE_ID (0x0d5c)#define ACC100_VF_DEVICE_ID (0x0d5d) +#define VRB1_PF_DEVICE_ID (0x57C0) +#define VRB2_PF_DEVICE_ID (0x57C2)/* Values used in writing to the registers */ #define ACC100_REG_IRQ_EN_ALL 0x1FF83FF/* Enable all interrupts */
drivers/baseband/acc/acc_common.h +7 -0
@@ -1480,6 +1480,13 @@ get_num_cbs_in_tb_ldpc_enc(struct rte_bbdev_op_ldpc_enc *ldpc_enc)return cbs_in_tb; } +static inline void +acc_reg_fast_write (struct acc_device *d,uint32_t offset,uint32_t value) +{ +void *reg_addr =RTE_PTR_ADD (d->mmio_base, offset); +mmio_write (reg_addr, value); +} +#ifdef RTE_LIBRTE_BBDEV_DEBUG static inline void acc_memdump (const char *string,void *buf,uint16_t bytes)
drivers/baseband/acc/rte_acc100_pmd.c +5 -1
@@ -5187,6 +5187,10 @@ rte_acc_configure(const char *dev_name, struct rte_acc_conf *conf)return acc100_configure (dev_name, conf); else if (pci_dev->id.device_id == ACC101_PF_DEVICE_ID) return acc101_configure(dev_name, conf); - else + else if (pci_dev->id.device_id == VRB1_PF_DEVICE_ID) return vrb1_configure(dev_name, conf); + else if (pci_dev->id.device_id == VRB2_PF_DEVICE_ID) + return vrb2_configure(dev_name, conf); + +return -ENXIO ; }
drivers/baseband/acc/rte_vrb_pmd.c +322 -0
325 lines not on this page · raw message
drivers/baseband/acc/vrb_cfg.h +16 -0
@@ -29,4 +29,20 @@int vrb1_configure (const char *dev_name,struct rte_acc_conf *conf); +/** +* Configure a VRB2 device. +* +* @param dev_name +* The name of the device. This is the short form of PCI BDF, e.g. 00:01.0. +* It can also be retrieved for a bbdev device from the dev_name field in the +* rte_bbdev_info structure returned by rte_bbdev_info_get(). +* @param conf +* Configuration to apply to VRB2 HW. +* +* @return +* Zero on success, negative value on failure. +*/ +int +vrb2_configure (const char *dev_name,struct rte_acc_conf *conf); +#endif /* _VRB_CFG_H_ */
Signature · 1 line
2.34.1
Quoted 4 lines · Nicolas Chautru
This serie includes includes changes to the VRB BBDEV PMD for 23.11. This relies on the previous serie that Maxime is about to apply
(https://patches.dpdk.org/project/dpdk/list/?series=28544).
Fyi, the CI people started to implement series dependencies. Currently, only the ovsrobot supports it, but the UNH lab will support it soon, too (and others CI will probably follow later).
http://inbox.dpdk.org/dts/[email protected]/T/#m7e86d61319ab09aedc123defea34b6e3699d34fa
For example here, that would translate to adding the following tag to this cover letter (or the first patch of your series):
Depends-on: series-28544 ("bbdev: API extension for 23.11")
Signature · 1 line
David Marchand