lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20140824.223133.170922940598584254.davem@davemloft.net>
Date:	Sun, 24 Aug 2014 22:31:33 -0700 (PDT)
From:	David Miller <davem@...emloft.net>
To:	john.fastabend@...il.com
Cc:	xiyou.wangcong@...il.com, jhs@...atatu.com, eric.dumazet@...il.com,
	netdev@...r.kernel.org, paulmck@...ux.vnet.ibm.com,
	brouer@...hat.com
Subject: Re: [net-next PATCH v2 02/15] net: rcu-ify tcf_proto

From: John Fastabend <john.fastabend@...il.com>
Date: Sun, 24 Aug 2014 17:48:31 -0700

> @@ -722,8 +724,9 @@ static void sfq_free(void *addr)
>  static void sfq_destroy(struct Qdisc *sch)
>  {
>  	struct sfq_sched_data *q = qdisc_priv(sch);
> +	struct tcf_proto *fl = rtnl_dereference(q->filter_list);
>  
> -	tcf_destroy_chain(&q->filter_list);
> +	tcf_destroy_chain(&fl);

This will cause tcf_destroy_chain() to set the local variable
'fl' to NULL rather than q->filter_list.

I don't see how this can be correct at all.

You need to make tcf_destroy_chain() take a pointer to an __rcu
pointer, and do the proper dereferencing and RCU assignments in
that chain destroy loop.

This might be why you're getting annotation warnings.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ