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:	Mon, 6 Jun 2016 17:20:03 +0200
From:	Vlastimil Babka <vbabka@...e.cz>
To:	Joonsoo Kim <js1304@...il.com>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	Mel Gorman <mgorman@...hsingularity.net>,
	Minchan Kim <minchan@...nel.org>,
	Alexander Potapenko <glider@...gle.com>,
	Hugh Dickins <hughd@...gle.com>,
	Michal Hocko <mhocko@...nel.org>,
	LKML <linux-kernel@...r.kernel.org>,
	Linux Memory Management List <linux-mm@...ck.org>,
	Joonsoo Kim <iamjoonsoo.kim@....com>
Subject: Re: [PATCH v2 2/7] mm/page_owner: initialize page owner without
 holding the zone lock

On 06/03/2016 02:47 PM, Joonsoo Kim wrote:
[...]

>>> @@ -128,8 +127,12 @@ static void unset_migratetype_isolate(struct page
>>> *page, unsigned migratetype)
>>>         zone->nr_isolate_pageblock--;
>>>  out:
>>>         spin_unlock_irqrestore(&zone->lock, flags);
>>> -       if (isolated_page)
>>> +       if (isolated_page) {
>>> +               kernel_map_pages(page, (1 << order), 1);
>>
>>
>> So why we don't need the other stuff done by e.g. map_pages()? For example
>> arch_alloc_page() and kasan_alloc_pages(). Maybe kasan_free_pages() (called
>> below via __free_pages() I assume) now doesn't check if the allocation part
>> was done. But maybe it will start doing that?
>>
>> See how the multiple places doing similar stuff is fragile? :(
>
> I answered it in reply of comment of patch 1.

Right.

Acked-by: Vlastimil Babka <vbabka@...e.cz>

>
>>> +               set_page_refcounted(page);
>>> +               set_page_owner(page, order, __GFP_MOVABLE);
>>>                 __free_pages(isolated_page, order);
>>
>>
>> This mixing of "isolated_page" and "page" is not a bug, but quite ugly.
>> Can't isolated_page variable just be a bool?
>>
>
> Looks better. I will do it.
>
> Thanks.
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ