* [dpdk-dev] [PATCH] common/octeontx2: reduce wait time for mbox messages
@ 2019-12-16 14:55 Sunil Kumar Kori
0 siblings, 0 replies; 3+ messages in thread
From: Sunil Kumar Kori @ 2019-12-16 14:55 UTC (permalink / raw)
To: Jerin Jacob, Nithin Dabilpuram, Vamsi Attunuru; +Cc: dev, Sunil Kumar Kori
After each mbox send operation, context waits for minimum 1ms to get
corresponding response although response can come earlier.
So reducing wait time to lower granularity.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
---
drivers/common/octeontx2/otx2_mbox.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/common/octeontx2/otx2_mbox.c b/drivers/common/octeontx2/otx2_mbox.c
index c359bf42f..7e1f751f4 100644
--- a/drivers/common/octeontx2/otx2_mbox.c
+++ b/drivers/common/octeontx2/otx2_mbox.c
@@ -278,8 +278,9 @@ mbox_wait(struct otx2_mbox *mbox, int devid, uint32_t rst_timo)
volatile struct otx2_mbox_dev *mdev = &mbox->dev[devid];
uint32_t timeout = 0, sleep = 1;
+ rst_timo = rst_timo * 1000; /* Mili seconds to micro seconds */
while (mdev->num_msgs > mdev->msgs_acked) {
- rte_delay_ms(sleep);
+ rte_delay_us(sleep);
timeout += sleep;
if (timeout >= rst_timo) {
struct mbox_hdr *tx_hdr =
--
2.17.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] common/octeontx2: reduce wait time for mbox messages
2019-12-16 15:02 Sunil Kumar Kori
@ 2020-01-14 3:49 ` Jerin Jacob
0 siblings, 0 replies; 3+ messages in thread
From: Jerin Jacob @ 2020-01-14 3:49 UTC (permalink / raw)
To: Sunil Kumar Kori, Ferruh Yigit
Cc: Jerin Jacob, Nithin Dabilpuram, Vamsi Attunuru, dpdk-dev
On Mon, Dec 16, 2019 at 8:33 PM Sunil Kumar Kori <skori@marvell.com> wrote:
>
> After each mbox send operation, context waits for minimum 1ms to get
> corresponding response although response can come earlier.
> So reducing wait time to lower granularity.
>
> Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Applied to dpdk-next-net-mrvl/master. Thanks
> ---
> drivers/common/octeontx2/otx2_mbox.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/common/octeontx2/otx2_mbox.c b/drivers/common/octeontx2/otx2_mbox.c
> index c359bf42f..cc341aac3 100644
> --- a/drivers/common/octeontx2/otx2_mbox.c
> +++ b/drivers/common/octeontx2/otx2_mbox.c
> @@ -278,8 +278,9 @@ mbox_wait(struct otx2_mbox *mbox, int devid, uint32_t rst_timo)
> volatile struct otx2_mbox_dev *mdev = &mbox->dev[devid];
> uint32_t timeout = 0, sleep = 1;
>
> + rst_timo = rst_timo * 1000; /* Milli seconds to micro seconds */
> while (mdev->num_msgs > mdev->msgs_acked) {
> - rte_delay_ms(sleep);
> + rte_delay_us(sleep);
> timeout += sleep;
> if (timeout >= rst_timo) {
> struct mbox_hdr *tx_hdr =
> --
> 2.17.1
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [dpdk-dev] [PATCH] common/octeontx2: reduce wait time for mbox messages
@ 2019-12-16 15:02 Sunil Kumar Kori
2020-01-14 3:49 ` Jerin Jacob
0 siblings, 1 reply; 3+ messages in thread
From: Sunil Kumar Kori @ 2019-12-16 15:02 UTC (permalink / raw)
To: Jerin Jacob, Nithin Dabilpuram, Vamsi Attunuru; +Cc: dev, Sunil Kumar Kori
After each mbox send operation, context waits for minimum 1ms to get
corresponding response although response can come earlier.
So reducing wait time to lower granularity.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
---
drivers/common/octeontx2/otx2_mbox.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/common/octeontx2/otx2_mbox.c b/drivers/common/octeontx2/otx2_mbox.c
index c359bf42f..cc341aac3 100644
--- a/drivers/common/octeontx2/otx2_mbox.c
+++ b/drivers/common/octeontx2/otx2_mbox.c
@@ -278,8 +278,9 @@ mbox_wait(struct otx2_mbox *mbox, int devid, uint32_t rst_timo)
volatile struct otx2_mbox_dev *mdev = &mbox->dev[devid];
uint32_t timeout = 0, sleep = 1;
+ rst_timo = rst_timo * 1000; /* Milli seconds to micro seconds */
while (mdev->num_msgs > mdev->msgs_acked) {
- rte_delay_ms(sleep);
+ rte_delay_us(sleep);
timeout += sleep;
if (timeout >= rst_timo) {
struct mbox_hdr *tx_hdr =
--
2.17.1
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-01-14 3:49 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-16 14:55 [dpdk-dev] [PATCH] common/octeontx2: reduce wait time for mbox messages Sunil Kumar Kori
2019-12-16 15:02 Sunil Kumar Kori
2020-01-14 3:49 ` Jerin Jacob
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).