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:	Fri, 17 Apr 2015 10:14:18 -0700
From:	Mike Kravetz <mike.kravetz@...cle.com>
To:	Hillf Danton <hillf.zj@...baba-inc.com>,
	Dave Hansen <dave.hansen@...ux.intel.com>
CC:	linux-kernel <linux-kernel@...r.kernel.org>, linux-mm@...ck.org
Subject: Re: [RFC PATCH 3/4] hugetlbfs: add hugetlbfs_fallocate()

On 04/17/2015 01:00 AM, Hillf Danton wrote:
>> +		clear_huge_page(page, addr, pages_per_huge_page(h));
>> +		__SetPageUptodate(page);
>> +		error = huge_add_to_page_cache(page, mapping, index);
>> +		if (error) {
>> +			put_page(page);
>> +			/* Keep going if we see an -EEXIST */
>> +			if (error != -EEXIST)
>> +				goto out;  /* FIXME, need to free? */
>> +		}
>> +
>> +		/*
>> +		 * page_put due to reference from alloc_huge_page()
>> +		 * unlock_page because locked by add_to_page_cache()
>> +		 */
>> +		put_page(page);
>
> Still needed if EEXIST?

Nope.  Good catch.

I'll fix this in the next version.
-- 
Mike Kravetz
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ