From: Colin Ian King <[email protected]>
The assignment dev = dev is redundant and should be removed.
Detected by CoverityScan, CID#1469486 ("Evaluation order violation")
Signed-off-by: Colin Ian King <[email protected]>
---
kernel/bpf/devmap.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/bpf/devmap.c b/kernel/bpf/devmap.c
index ae16d0c373ef..1fe3fe60508a 100644
--- a/kernel/bpf/devmap.c
+++ b/kernel/bpf/devmap.c
@@ -352,7 +352,7 @@ int dev_map_enqueue(struct bpf_dtab_netdev *dst, struct xdp_buff *xdp,
static void *dev_map_lookup_elem(struct bpf_map *map, void *key)
{
struct bpf_dtab_netdev *obj = __dev_map_lookup_elem(map, *(u32 *)key);
- struct net_device *dev = dev = obj ? obj->dev : NULL;
+ struct net_device *dev = obj ? obj->dev : NULL;
return dev ? &dev->ifindex : NULL;
}
--
2.17.0
On Wed, May 30, 2018 at 8:09 AM, Colin King <[email protected]> wrote:
> From: Colin Ian King <[email protected]>
>
> The assignment dev = dev is redundant and should be removed.
>
> Detected by CoverityScan, CID#1469486 ("Evaluation order violation")
>
> Signed-off-by: Colin Ian King <[email protected]>
Acked-by: Song Liu <[email protected]>
> ---
> kernel/bpf/devmap.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/bpf/devmap.c b/kernel/bpf/devmap.c
> index ae16d0c373ef..1fe3fe60508a 100644
> --- a/kernel/bpf/devmap.c
> +++ b/kernel/bpf/devmap.c
> @@ -352,7 +352,7 @@ int dev_map_enqueue(struct bpf_dtab_netdev *dst, struct xdp_buff *xdp,
> static void *dev_map_lookup_elem(struct bpf_map *map, void *key)
> {
> struct bpf_dtab_netdev *obj = __dev_map_lookup_elem(map, *(u32 *)key);
> - struct net_device *dev = dev = obj ? obj->dev : NULL;
> + struct net_device *dev = obj ? obj->dev : NULL;
>
> return dev ? &dev->ifindex : NULL;
> }
> --
> 2.17.0
>
On Wed, May 30, 2018 at 04:09:16PM +0100, Colin King wrote:
> From: Colin Ian King <[email protected]>
>
> The assignment dev = dev is redundant and should be removed.
>
> Detected by CoverityScan, CID#1469486 ("Evaluation order violation")
>
> Signed-off-by: Colin Ian King <[email protected]>
Applied, Thanks.
Please use [PATCH bpf-next] in the subject next time.
See Documentation/bpf/bpf_devel_QA.rst
On Wed, May 30, 2018 at 05:07:15PM -0400, Alexei Starovoitov wrote:
> On Wed, May 30, 2018 at 04:09:16PM +0100, Colin King wrote:
> > From: Colin Ian King <[email protected]>
> >
> > The assignment dev = dev is redundant and should be removed.
> >
> > Detected by CoverityScan, CID#1469486 ("Evaluation order violation")
> >
> > Signed-off-by: Colin Ian King <[email protected]>
>
> Applied, Thanks.
>
> Please use [PATCH bpf-next] in the subject next time.
> See Documentation/bpf/bpf_devel_QA.rst
Guys, be reasonable...
git log --author=Carpenter | \
grep -A1 "Signed-off-by: Dan Carpenter <[email protected]>" | \
grep -v Carpenter | grep Signed | cut -d '<' -f 1 | sort -u | wc -l
I have sent patches to 206 maintainers. It doesn't scale for everyone
to have their own special document for sending patches.
I asked this last time, and I even skimmed your document, but how are
people supposed to go from linux-next to the correct bpf-next git tree?
It's a pain for me to do this for net, but net is way larger and busier
than any other tree. I know it's a bit rude for me to say that you guys
are not as important as net, but that's how I feel. I'm only going to
report bugs instead of writing patches if you guys are going to insist
on all sorts of new rules.
regards,
dan carpenter
On Thu, 31 May 2018, Dan Carpenter wrote:
> On Wed, May 30, 2018 at 05:07:15PM -0400, Alexei Starovoitov wrote:
> > On Wed, May 30, 2018 at 04:09:16PM +0100, Colin King wrote:
> > > From: Colin Ian King <[email protected]>
> > >
> > > The assignment dev = dev is redundant and should be removed.
> > >
> > > Detected by CoverityScan, CID#1469486 ("Evaluation order violation")
> > >
> > > Signed-off-by: Colin Ian King <[email protected]>
> >
> > Applied, Thanks.
> >
> > Please use [PATCH bpf-next] in the subject next time.
> > See Documentation/bpf/bpf_devel_QA.rst
>
> Guys, be reasonable...
>
> git log --author=Carpenter | \
> grep -A1 "Signed-off-by: Dan Carpenter <[email protected]>" | \
> grep -v Carpenter | grep Signed | cut -d '<' -f 1 | sort -u | wc -l
>
> I have sent patches to 206 maintainers. It doesn't scale for everyone
> to have their own special document for sending patches.
Thanks Dan, I support this point of view completely. Special information
has to be in one place and in a machine readable manner. Maybe
get_maintainers can produce this information in some way, if it is
essential.
julia
>
> I asked this last time, and I even skimmed your document, but how are
> people supposed to go from linux-next to the correct bpf-next git tree?
> It's a pain for me to do this for net, but net is way larger and busier
> than any other tree. I know it's a bit rude for me to say that you guys
> are not as important as net, but that's how I feel. I'm only going to
> report bugs instead of writing patches if you guys are going to insist
> on all sorts of new rules.
>
> regards,
> dan carpenter
> --
> To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>