回复: [RFC PATCH v1 2/4] ethdev: add API for direct re-arm mode
Feifei Wang
Feifei.Wang2 at arm.com
Sun Dec 26 10:49:43 CET 2021
> -----邮件原件-----
> 发件人: Stephen Hemminger <stephen at networkplumber.org>
> 发送时间: Saturday, December 25, 2021 3:38 AM
> 收件人: Feifei Wang <Feifei.Wang2 at arm.com>
> 抄送: thomas at monjalon.net; Ferruh Yigit <ferruh.yigit at intel.com>; Andrew
> Rybchenko <andrew.rybchenko at oktetlabs.ru>; Ray Kinsella
> <mdr at ashroe.eu>; dev at dpdk.org; nd <nd at arm.com>; Honnappa
> Nagarahalli <Honnappa.Nagarahalli at arm.com>; Ruifeng Wang
> <Ruifeng.Wang at arm.com>
> 主题: Re: [RFC PATCH v1 2/4] ethdev: add API for direct re-arm mode
>
> On Sat, 25 Dec 2021 00:46:10 +0800
> Feifei Wang <feifei.wang2 at arm.com> wrote:
>
> > +rte_eth_direct_rxrearm_map(uint16_t rx_port_id, uint16_t rx_queue_id,
> > + uint16_t tx_port_id, uint16_t tx_queue_id) {
> > + struct rte_eth_dev *dev;
> > +
> > + dev = &rte_eth_devices[rx_port_id];
> > + (*dev->dev_ops->rx_queue_direct_rearm_enable)(dev,
> rx_queue_id);
> > + (*dev->dev_ops->rx_queue_direct_rearm_map)(dev, rx_queue_id,
> > + tx_port_id, tx_queue_id);
> > +
>
> Indirect calls are expensive, maybe better to combine these?
Thanks for your comment. I'm a little confused about this.
Whether 'expensive' is due to 'enable direct_rearm mode' and 'map queue' use
different api, and we should combine them into the same API.
If this, I think you are right, and just one api is enough to enable direct rearm mode and
map queue.
More information about the dev
mailing list