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: <4A0D253A.1070705@kernel.org>
Date:	Fri, 15 May 2009 17:18:02 +0900
From:	Tejun Heo <tj@...nel.org>
To:	Jan Beulich <JBeulich@...ell.com>
CC:	mingo@...e.hu, andi@...stfloor.org, tglx@...utronix.de,
	linux-kernel@...r.kernel.org, hpa@...or.com
Subject: Re: [PATCH 3/5] x86: fix pageattr handling for remap percpu	 allocator

Hello,

Jan Beulich wrote:
>>>> Tejun Heo <tj@...nel.org> 15.05.09 06:28 >>>
>> @@ -742,6 +744,27 @@ static int cpa_process_alias(struct cpa_data *cpa)
>> 	}
>> #endif
>>
>> +	/*
>> +	 * If the PMD page was partially used for per-cpu remapping,
>> +	 * the remapped area needs to be split and modified.  Note
>> +	 * that the partial recycling only happens at the tail of a
>> +	 * partially used PMD page, so touching single PMD page is
>> +	 * always enough.
>> +	 */
>> +	remapped = pcpu_pmd_remapped((void *)vaddr);
> 
> vaddr here is the passed-in address, but in order for the lookup to
> be positive it needs to be the canonical address (i.e. the one
> pointing into the 1:1 mapping), i.e. __va(cpa->pfn << PAGE_SHIFT),
> just like temp_cpa_vaddr gets calculated earlier in the same
> function.

Hmmm... There's no need to match percpu map -> linear addr.  Okay,
right, if the recycled part has been aliased to different vmalloc
mapping than the pfn should be matched.

Thanks for spotting it.  Will posted updated patch.

-- 
tejun
--
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