[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b67b75aeb43afd4812e378673151a629f1681eea.camel@intel.com>
Date: Thu, 31 May 2018 14:46:08 -0700
From: Jeff Kirsher <jeffrey.t.kirsher@...el.com>
To: Ondřej Hlavatý <ohlavaty@...hat.com>
Cc: netdev@...r.kernel.org, Andrew Bowers <andrewx.bowers@...el.com>
Subject: Re: [PATCH v2 net] ixgbe: fix parsing of TC actions for HW offload
On Thu, 2018-05-31 at 23:21 +0200, Ondřej Hlavatý wrote:
> The previous code was optimistic, accepting the offload of whole
> action
> chain when there was a single known action (drop/redirect). This
> results
> in offloading a rule which should not be offloaded, because its
> behavior
> cannot be reproduced in the hardware.
>
> For example:
>
> $ tc filter add dev eno1 parent ffff: protocol ip \
> u32 ht 800: order 1 match tcp src 42 FFFF \
> action mirred egress mirror dev enp1s16 pipe \
> drop
>
> The controller is unable to mirror the packet to a VF, but still
> offloads the rule by dropping the packet.
>
> Change the approach of the function to a pessimistic one, rejecting
> the
> chain when an unknown action is found. This is better suited for
> future
> extensions.
>
> Note that both recognized actions always return TC_ACT_SHOT,
> therefore
> it is safe to ignore actions behind them.
>
> Signed-off-by: Ondřej Hlavatý <ohlavaty@...hat.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@...el.com>
Note- I am having our validation move to testing with GCC 8.1.1 or
later so that we can catch warnings like Dave found in the future.
Dave- Please go ahead and pick this up.
Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)
Powered by blists - more mailing lists