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: <4d4f5830-dcf9-1904-9cc2-4e50860ff571@arm.com>
Date:   Fri, 22 Oct 2021 19:30:10 +0100
From:   James Morse <james.morse@....com>
To:     Reinette Chatre <reinette.chatre@...el.com>, x86@...nel.org,
        linux-kernel@...r.kernel.org
Cc:     Fenghua Yu <fenghua.yu@...el.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
        H Peter Anvin <hpa@...or.com>,
        Babu Moger <Babu.Moger@....com>,
        shameerali.kolothum.thodi@...wei.com,
        Jamie Iles <jamie@...iainc.com>,
        D Scott Phillips OS <scott@...amperecomputing.com>,
        lcherian@...vell.com, bobo.shaobowang@...wei.com,
        tan.shaopeng@...itsu.com
Subject: Re: [PATCH v2 05/23] x86/resctrl: Add domain online callback for
 resctrl work

Hi Reinette,

On 15/10/2021 23:19, Reinette Chatre wrote:
> On 10/1/2021 9:02 AM, James Morse wrote:
> 
>> @@ -527,21 +492,15 @@ static void domain_add_cpu(int cpu, struct rdt_resource *r)
>>           return;
>>       }
>>   -    if (r->mon_capable && domain_setup_mon_state(r, d)) {
>> -        kfree(hw_dom->ctrl_val);
>> -        kfree(hw_dom->mbps_val);
>> -        kfree(hw_dom);
>> -        return;
>> -    }
>> -
>>       list_add_tail(&d->list, add_pos);
>>   -    /*
>> -     * If resctrl is mounted, add
>> -     * per domain monitor data directories.
>> -     */
>> -    if (static_branch_unlikely(&rdt_mon_enable_key))
>> -        mkdir_mondata_subdir_allrdtgrp(r, d);
>> +    err = resctrl_online_domain(r, d);
>> +    if (err) {
>> +        list_del(&d->list);
>> +        kfree(hw_dom->ctrl_val);
>> +        kfree(hw_dom->mbps_val);
>> +        kfree(d);
> 
> Even though this goes away in next patch I think this should rather be kfree(hw_dom).


Whoops, that's a rebase artefact from patch 2. Fixed.


Thanks!

James

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ