# Re: \[PATCH\] net/sched: reset block pointer in tcf\_block\_put()

- From: Florian Westphal \<fw@strlen.de\>
- Date: 2017-08-11 20:35:06 
- List: netdev
- Page: https://ratatoskr.run/netdev/2017/08/11062352
- Thread: https://ratatoskr.run/netdev/2017/08/11062195/t.md

```text
Cong Wang [ref] wrote:
> On Thu, Aug 10, 2017 at 2:31 AM, Konstantin Khlebnikov
> [ref] wrote:
> > In previous API tcf_destroy_chain() could be called several times and
> > some schedulers like hfsc and atm use that. In new API tcf_block_put()
> > frees block but leaves stale pointer, second call will free it once again.
> 
> Which call path do we call tcf_block_put() for multiple times on
> the same block? Please be specific, it is not obvious.

you can use tools/testing/selftests/net/rtnetlink.sh to reproduce this
(kernel panics on delete of root qdisc).
```
