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: <924EFEDD5F540B4284297C4DC59F3DEE5E8AB4@orsmsx423.amr.corp.intel.com>
Date:	Wed, 16 Jan 2008 10:17:56 -0800
From:	"Pallipadi, Venkatesh" <venkatesh.pallipadi@...el.com>
To:	Mika Penttilä <mika.penttila@...umbus.fi>
Cc:	<ak@....de>, <ebiederm@...ssion.com>, <rdreier@...co.com>,
	<torvalds@...ux-foundation.org>, <gregkh@...e.de>,
	<airlied@...net.ie>, <davej@...hat.com>, <mingo@...e.hu>,
	<tglx@...utronix.de>, <hpa@...or.com>, <akpm@...ux-foundation.org>,
	<arjan@...radead.org>, "Barnes, Jesse" <jesse.barnes@...el.com>,
	<davem@...emloft.net>, <linux-kernel@...r.kernel.org>,
	"Siddha, Suresh B" <suresh.b.siddha@...el.com>
Subject: RE: [patch 2/4] x86: PAT followup - Remove KERNPG_TABLE from pte entry

>-----Original Message-----
>From: Mika Penttilä [mailto:mika.penttila@...umbus.fi] 
>Sent: Wednesday, January 16, 2008 12:14 AM
>To: Pallipadi, Venkatesh
>Cc: ak@....de; ebiederm@...ssion.com; rdreier@...co.com; 
>torvalds@...ux-foundation.org; gregkh@...e.de; 
>airlied@...net.ie; davej@...hat.com; mingo@...e.hu; 
>tglx@...utronix.de; hpa@...or.com; akpm@...ux-foundation.org; 
>arjan@...radead.org; Barnes, Jesse; davem@...emloft.net; 
>linux-kernel@...r.kernel.org; Siddha, Suresh B
>Subject: Re: [patch 2/4] x86: PAT followup - Remove 
>KERNPG_TABLE from pte entry
>
>venkatesh.pallipadi@...el.com kirjoitti:
>> KERNPG_TABLE was a bug in earlier patch. Remove it from pte.
>> pte_val() check is redundant as this routine is called 
>immediately after a
>> ptepage is allocated afresh.
>>
>> Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@...el.com>
>> Signed-off-by: Suresh Siddha <suresh.b.siddha@...el.com>
>>
>> Index: linux-2.6.git/arch/x86/mm/init_64.c
>> ===================================================================
>> --- linux-2.6.git.orig/arch/x86/mm/init_64.c	2008-01-15 
>11:02:23.000000000 -0800
>> +++ linux-2.6.git/arch/x86/mm/init_64.c	2008-01-15 
>11:06:37.000000000 -0800
>> @@ -541,9 +541,6 @@
>>  		if (address >= end)
>>  			break;
>>  
>> -		if (pte_val(*pte))
>> -			continue;
>> -
>>  		/* Nothing to map. Map the null page */
>>  		if (!(address & (~PAGE_MASK)) &&
>>  		    (address + PAGE_SIZE <= end) &&
>> @@ -561,9 +558,9 @@
>>  		}
>>  
>>  		if (exec)
>> -			entry = 
>_PAGE_NX|_KERNPG_TABLE|_PAGE_GLOBAL|address;
>> +			entry = _PAGE_NX|_PAGE_GLOBAL|address;
>>  		else
>> -			entry = _KERNPG_TABLE|_PAGE_GLOBAL|address;
>> +			entry = _PAGE_GLOBAL|address;
>>  		entry &= __supported_pte_mask;
>>  		set_pte(pte, __pte(entry));
>>  	}
>>
>>   
>
>Hmm then what's the point of mapping not present 4k pages for 
>valid mem 
>here?
>

My bad... Thanks for the catch.
I had to replace KERNPG_TABLE by PAGE_KERNEL here.

Thanks,
Venki
--
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