From: "Kundapura, Ganapati" <ganapati.kundapura@intel.com>
To: dpdk-dev <dev@dpdk.org>,
"gakhil@marvell.com" <gakhil@marvell.com>,
"fanzhang.oss@gmail.com" <fanzhang.oss@gmail.com>,
"Ji, Kai" <kai.ji@intel.com>,
"Power, Ciara" <ciara.power@intel.com>,
"Kusztal, ArkadiuszX" <arkadiuszx.kusztal@intel.com>,
"Gujjar, Abhinandan S" <abhinandan.gujjar@intel.com>,
"Jayatheerthan, Jay" <jay.jayatheerthan@intel.com>,
Jerin Jacob <jerinjacobk@gmail.com>
Subject: RFC: Using and renaming 8-bit reserved field of rte_crypto_op for implementation specific
Date: Tue, 5 Mar 2024 07:13:33 +0000 [thread overview]
Message-ID: <MW4PR11MB59115297140DB034BD39047187222@MW4PR11MB5911.namprd11.prod.outlook.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 2495 bytes --]
Hi dpdk-dev,
Can 'uint8_t reserved[1]' of 'struct rte_crypto_op' be renamed
to 'uint8_t impl_opaque' for implementation specific?
An implementation may use this field to hold implementation specific
value to share value between dequeue and enqueue operation and crypto library/driver
can also use this field to share implementation specfic value to event crypto adapter/application.
'struct rte_event' has 'uint8_t impl_opaque' member
struct rte_event {
...
uint8_t impl_opaque;
/**< Implementation specific opaque value.
* An implementation may use this field to hold
* implementation specific value to share between
* dequeue and enqueue operation.
* The application should not modify this field.
*/
...
};
Event crypto adapter, on dequeuing the event, enqueues rte_event::event_ptr
to cryptodev as rte_crypto_op and converts the dequeued crypto op to rte_event
without restoring the implementation specific opaque value.
By having the 'uint8_t impl_opaque' member in 'struct rte_crypto_op' as
diff --git a/lib/cryptodev/rte_crypto.h b/lib/cryptodev/rte_crypto.h
index dbc2700..af46ec9 100644
--- a/lib/cryptodev/rte_crypto.h
+++ b/lib/cryptodev/rte_crypto.h
@@ -146,10 +146,13 @@ struct rte_crypto_op {
/**< TLS record */
} param1;
/**< Additional per operation parameter 1. */
- uint8_t reserved[1];
- /**< Reserved bytes to fill 64 bits for
- * future additions
+ uint8_t impl_opaque;
+ /**< Implementation specific opaque value.
+ * An implementation may use this field to hold
+ * implementation specific value to share between
+ * dequeue and enqueue operation.
*/
+
which is untouched in library/driver and rte_event::impl_opaque field can be restored
while enqueuing the event back to eventdev.
Also crypto library/driver can use rte_crypto_op::impl_opaque field to
share implementation specific opaque value to the event crypto adapter/application.
I look forward to feedback on this proposal. Patch will be submitted
for review once the initial feedback is received.
Thank you,
Ganapati
[-- Attachment #2: Type: text/html, Size: 8113 bytes --]
next reply other threads:[~2024-03-05 7:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-05 7:13 Kundapura, Ganapati [this message]
2024-03-05 16:47 ` Akhil Goyal
2024-03-06 4:57 ` Kundapura, Ganapati
2024-03-12 7:52 ` Kundapura, Ganapati
2024-03-12 8:10 ` Akhil Goyal
2024-03-12 12:02 ` Kundapura, Ganapati
2024-03-13 18:07 ` Akhil Goyal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=MW4PR11MB59115297140DB034BD39047187222@MW4PR11MB5911.namprd11.prod.outlook.com \
--to=ganapati.kundapura@intel.com \
--cc=abhinandan.gujjar@intel.com \
--cc=arkadiuszx.kusztal@intel.com \
--cc=ciara.power@intel.com \
--cc=dev@dpdk.org \
--cc=fanzhang.oss@gmail.com \
--cc=gakhil@marvell.com \
--cc=jay.jayatheerthan@intel.com \
--cc=jerinjacobk@gmail.com \
--cc=kai.ji@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).