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] [day] [month] [year] [list]
Date:	Wed, 29 Oct 2014 20:09:02 -0700
From:	John Fastabend <john.fastabend@...il.com>
To:	xiyou.wangcong@...il.com, wang.bo116@....com.cn
CC:	David Miller <davem@...emloft.net>, netdev@...r.kernel.org,
	john.r.fastabend@...el.com, edumazet@...gle.com, kaber@...sh.net,
	vtlam@...gle.com
Subject: Re: [Patch net 2/2] net_sched: always call ->destroy when ->init()
 fails

On 10/29/2014 11:29 AM, David Miller wrote:
> From: Cong Wang <xiyou.wangcong@...il.com>
> Date: Fri, 24 Oct 2014 16:55:59 -0700
>
>> In qdisc_create(), when ->init() exists and it fails, we should
>> call ->destroy() to clean up the potentially partially initialized
>> qdisc's. This will also make the ->init() implementation easier.
>>
>> qdisc_create_dflt() already does that. Most callers of qdisc_create_dflt()
>> simply use noop_qdisc when it fails.
>>
>> And, most of the ->destroy() implementations are already able to clean up
>> partially initialization, we don't need to worry.
>>
>> The following ->init()'s need to catch up:
>> fq_codel_init(), hhf_init(), multiq_init(),  sfq_init(), mq_init(),
>> mqprio_init().
>>
>> Reported-by: Wang Bo <wang.bo116@....com.cn>
>> Signed-off-by: Cong Wang <xiyou.wangcong@...il.com>
>
> As discussed, I really want to see ->init() clean up it's own crap.
>
> There are certain kinds of initializations that cannot be tested for,
> such as setting up a workqueue etc.
>
> Therefore, the mere idea that we can call ->destroy() to handle this
> is a pure non-starter as far as I am concerned.
>
> Thanks.
> --

Cong/Wang, anyone working on this? Otherwise I'll take a stab
at it tomorrow.

Thanks!
John

-- 
John Fastabend         Intel Corporation
--
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