[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201002083144.39af89e8@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date: Fri, 2 Oct 2020 08:31:44 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Johannes Berg <johannes@...solutions.net>
Cc: netdev@...r.kernel.org, Johannes Berg <johannes.berg@...el.com>
Subject: Re: [PATCH 1/5] netlink: simplify netlink_policy_dump_start()
prototype
On Fri, 2 Oct 2020 11:09:40 +0200 Johannes Berg wrote:
> From: Johannes Berg <johannes.berg@...el.com>
>
> Since moving the call to this to a dump start() handler we no
> longer need this to deal with being called after having been
> called already. Since that is the preferred way of doing things
> anyway, remove the code necessary for that and simply return
> the pointer (or an ERR_PTR()).
>
> Signed-off-by: Johannes Berg <johannes.berg@...el.com>
Reviewed-by: Jakub Kicinski <kuba@...nel.org>
> - return netlink_policy_dump_start(op.policy, op.maxattr, &ctx->state);
> + ctx->state = netlink_policy_dump_start(op.policy, op.maxattr);
> + if (IS_ERR(ctx->state))
> + return PTR_ERR(ctx->state);
> + return 0;
PTR_ERR_OR_ZERO()?
Powered by blists - more mailing lists