Thanks Florian! I'll send a v2 addressing the comments. Ahmed On Tue, 21 Aug 2018 18:13:08 +0200 Florian Westphal <[email protected]> wrote:
> Ahmed Abdelsalam <[email protected]> wrote: > > +static int seg6_check(const struct xt_tgchk_param *par) > > +{ > > + /** > > + * In the future, some new action may require using > > + * this function for doing some checks > > + */ > > Please add add a check on seg6->action and return -EOPNOSTUPP > in case it cannot be handled. > > If possible, also sanity check other target parameters. > Otherwise newer userspace version can't be sure kernel > will actually know how to act on whatever action they've requested. > > This will also allow you to remove the pr_err() call from the > evaluation function. -- Ahmed Abdelsalam <[email protected]>
