DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ravi Kerur <rkerur@gmail.com>
To: dpdk-dev <dev@dpdk.org>
Subject: [dpdk-dev] Q on l3fwd-acl and acl library
Date: Tue, 2 Mar 2021 11:33:15 -0800	[thread overview]
Message-ID: <CAFb4SLAes4Qj4g56OL9vfCEa6yxGPBgYy-fZeksrdSh_ucssgw@mail.gmail.com> (raw)

Hello,

I am using l3fwd-acl example code and would like to know the intention of
ACL_DENY_SIGNATURE in the code.

Is ACL rules programmed to drop packets and not for any other
functionality? I see that userdata is ignored for ACL and programmed with
ACL_DENY_SIGNATURE + count. After classification, results are checked and
packets forwarded or dropped as in send_one_packet

static inline void
send_one_packet(struct rte_mbuf *m, uint32_t res)
{
        if (likely((res & ACL_DENY_SIGNATURE) == 0 && res != 0)) {
                /* forward packets */
                send_single_packet(m,
                        (uint8_t)(res - FWD_PORT_SHIFT));
...
}

In the ACL case, "res" is always (ACL_DENY_SIGNATURE + acl_cnt) and packets
are dropped.

Is this correct?

Looking at the acl library I did not see statistics associated with the
rules so the library doesn't provide anything related to statistics?

Finally, I see the acl library has api 'rte_acl_add_rules' but nothing on
modifying/deleting existing rules?

Thanks,
Ravi

                 reply	other threads:[~2021-03-02 19:33 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=CAFb4SLAes4Qj4g56OL9vfCEa6yxGPBgYy-fZeksrdSh_ucssgw@mail.gmail.com \
    --to=rkerur@gmail.com \
    --cc=dev@dpdk.org \
    /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).