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]
Date:   Fri, 19 May 2017 16:16:58 +0300
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     Mika Westerberg <mika.westerberg@...ux.intel.com>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Andreas Noever <andreas.noever@...il.com>,
        Michael Jamet <michael.jamet@...el.com>,
        Yehezkel Bernat <yehezkel.bernat@...el.com>,
        Lukas Wunner <lukas@...ner.de>,
        Amir Levy <amir.jer.levy@...el.com>,
        Andy Lutomirski <luto@...nel.org>,
        Mario Limonciello <Mario.Limonciello@...l.com>,
        Jared.Dominguez@...l.com,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 06/24] thunderbolt: Introduce thunderbolt bus and
 connection manager

On Fri, May 19, 2017 at 11:15 AM, Mika Westerberg
<mika.westerberg@...ux.intel.com> wrote:
> On Thu, May 18, 2017 at 07:43:13PM +0300, Andy Shevchenko wrote:
>> On Thu, May 18, 2017 at 5:38 PM, Mika Westerberg
>> <mika.westerberg@...ux.intel.com> wrote:

>> One nit below.
>>
>> > +static void tb_domain_release(struct device *dev)
>> > +{
>> > +       struct tb *tb = container_of(dev, struct tb, dev);
>> > +
>> > +       if (tb->ctl)
>> > +               tb_ctl_free(tb->ctl);
>>
>> The usual pattern is to put such checks inside *_free() type of functions.
>
> tb_ctl_free() and these patterns are from the original code. I just
> moved the calls from tb.c intto here. No problem doing that change but I
> suppose that should be done first in a separate patch before this patch.

Precisely!

>> > +
>> > +       destroy_workqueue(tb->wq);
>> > +       ida_simple_remove(&tb_domain_ida, tb->index);
>> > +       kfree(tb);
>> > +}

-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ