linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Documentation/x86/boot.rst: minor improvement
@ 2020-09-01  3:41 Cao jin
  2020-09-01  5:25 ` Cao jin
  0 siblings, 1 reply; 4+ messages in thread
From: Cao jin @ 2020-09-01  3:41 UTC (permalink / raw)
  To: linux-doc, linux-kernel, x86; +Cc: tglx, ingo, p, hpa, corbet

Typo fix & file name update

Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com>
---
 Documentation/x86/boot.rst | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Documentation/x86/boot.rst b/Documentation/x86/boot.rst
index 7fafc7ac00d7..c04afec90486 100644
--- a/Documentation/x86/boot.rst
+++ b/Documentation/x86/boot.rst
@@ -1379,7 +1379,7 @@ can be calculated as follows::
 In addition to read/modify/write the setup header of the struct
 boot_params as that of 16-bit boot protocol, the boot loader should
 also fill the additional fields of the struct boot_params as described
-in zero-page.txt.
+in zero-page.rst.
 
 After setting up the struct boot_params, the boot loader can load
 64-bit kernel in the same way as that of 16-bit boot protocol, but
@@ -1391,7 +1391,7 @@ In 64-bit boot protocol, the kernel is started by jumping to the
 
 At entry, the CPU must be in 64-bit mode with paging enabled.
 The range with setup_header.init_size from start address of loaded
-kernel and zero page and command line buffer get ident mapping;
+kernel and zero page and command line buffer get identity mapping;
 a GDT must be loaded with the descriptors for selectors
 __BOOT_CS(0x10) and __BOOT_DS(0x18); both descriptors must be 4G flat
 segment; __BOOT_CS must have execute/read permission, and __BOOT_DS
-- 
2.21.0




^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] Documentation/x86/boot.rst: minor improvement
  2020-09-01  3:41 [PATCH] Documentation/x86/boot.rst: minor improvement Cao jin
@ 2020-09-01  5:25 ` Cao jin
  2020-09-01  5:35   ` H. Peter Anvin
  0 siblings, 1 reply; 4+ messages in thread
From: Cao jin @ 2020-09-01  5:25 UTC (permalink / raw)
  To: linux-doc, linux-kernel, x86; +Cc: tglx, mingo, bp, hpa, corbet

Sorry, I mis-copied 2 addresses. make sure they are CCed.

On 9/1/20 11:41 AM, Cao jin wrote:
> Typo fix & file name update
> 
> Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com>
> ---
>  Documentation/x86/boot.rst | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Documentation/x86/boot.rst b/Documentation/x86/boot.rst
> index 7fafc7ac00d7..c04afec90486 100644
> --- a/Documentation/x86/boot.rst
> +++ b/Documentation/x86/boot.rst
> @@ -1379,7 +1379,7 @@ can be calculated as follows::
>  In addition to read/modify/write the setup header of the struct
>  boot_params as that of 16-bit boot protocol, the boot loader should
>  also fill the additional fields of the struct boot_params as described
> -in zero-page.txt.
> +in zero-page.rst.
>  
>  After setting up the struct boot_params, the boot loader can load
>  64-bit kernel in the same way as that of 16-bit boot protocol, but
> @@ -1391,7 +1391,7 @@ In 64-bit boot protocol, the kernel is started by jumping to the
>  
>  At entry, the CPU must be in 64-bit mode with paging enabled.
>  The range with setup_header.init_size from start address of loaded
> -kernel and zero page and command line buffer get ident mapping;
> +kernel and zero page and command line buffer get identity mapping;
>  a GDT must be loaded with the descriptors for selectors
>  __BOOT_CS(0x10) and __BOOT_DS(0x18); both descriptors must be 4G flat
>  segment; __BOOT_CS must have execute/read permission, and __BOOT_DS
> 


-- 
Sincerely,
Cao jin



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] Documentation/x86/boot.rst: minor improvement
  2020-09-01  5:25 ` Cao jin
@ 2020-09-01  5:35   ` H. Peter Anvin
  2020-09-01  6:23     ` Cao jin
  0 siblings, 1 reply; 4+ messages in thread
From: H. Peter Anvin @ 2020-09-01  5:35 UTC (permalink / raw)
  To: Cao jin, linux-doc, linux-kernel, x86; +Cc: tglx, mingo, bp, corbet

If you are going to fix the language...

On 2020-08-31 22:25, Cao jin wrote:
> Sorry, I mis-copied 2 addresses. make sure they are CCed.
> 
> On 9/1/20 11:41 AM, Cao jin wrote:
>> Typo fix & file name update
>>
>> Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com>
>> ---
>>  Documentation/x86/boot.rst | 4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/Documentation/x86/boot.rst b/Documentation/x86/boot.rst
>> index 7fafc7ac00d7..c04afec90486 100644
>> --- a/Documentation/x86/boot.rst
>> +++ b/Documentation/x86/boot.rst
>> @@ -1379,7 +1379,7 @@ can be calculated as follows::
>>  In addition to read/modify/write the setup header of the struct
>>  boot_params as that of 16-bit boot protocol, the boot loader should
>>  also fill the additional fields of the struct boot_params as described
>> -in zero-page.txt.
>> +in zero-page.rst.
>>  
>>  After setting up the struct boot_params, the boot loader can load
>>  64-bit kernel in the same way as that of 16-bit boot protocol, but
>> @@ -1391,7 +1391,7 @@ In 64-bit boot protocol, the kernel is started by jumping to the
>>  
>>  At entry, the CPU must be in 64-bit mode with paging enabled.

(Paging enabled is redundant here.)

>>  The range with setup_header.init_size from start address of loaded
>> -kernel and zero page and command line buffer get ident mapping;
>> +kernel and zero page and command line buffer get identity mapping;

The range with setup_header.init_size from start address of the loaded kernel,
the zero page, and the command line buffer get identity-mapped, anda GDT must
be loaded with the descriptors for selectors __BOOT_CS(0x10) and
__BOOT_DS(0x18): both descriptors must be 4G flat segment with __BOOT_CS
having execute/read
permission and __BOOT_DS...

Also, it might be useful to take a look to see if other data structures, like
setup_data and the initrd also need to be in the identity map.

	-hpa


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] Documentation/x86/boot.rst: minor improvement
  2020-09-01  5:35   ` H. Peter Anvin
@ 2020-09-01  6:23     ` Cao jin
  0 siblings, 0 replies; 4+ messages in thread
From: Cao jin @ 2020-09-01  6:23 UTC (permalink / raw)
  To: H. Peter Anvin, linux-doc, linux-kernel, x86; +Cc: tglx, mingo, bp, corbet

On 9/1/20 1:35 PM, H. Peter Anvin wrote:
> If you are going to fix the language...
> 
> On 2020-08-31 22:25, Cao jin wrote:
>> Sorry, I mis-copied 2 addresses. make sure they are CCed.
>>
>> On 9/1/20 11:41 AM, Cao jin wrote:
>>> Typo fix & file name update
>>>

I did quick search in dict & google, didn't see ident = identity, my omission.

>>> Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com>
...

>>> @@ -1391,7 +1391,7 @@ In 64-bit boot protocol, the kernel is started by jumping to the
>>>  
>>>  At entry, the CPU must be in 64-bit mode with paging enabled.
> 
> (Paging enabled is redundant here.)

Yes, 64-bit defaults with paging enabled. Maybe it is a little bit helpful for
newbies.

> 
>>>  The range with setup_header.init_size from start address of loaded
>>> -kernel and zero page and command line buffer get ident mapping;
>>> +kernel and zero page and command line buffer get identity mapping;
> 
> The range with setup_header.init_size from start address of the loaded kernel,
> the zero page, and the command line buffer get identity-mapped, anda GDT must
> be loaded with the descriptors for selectors __BOOT_CS(0x10) and
> __BOOT_DS(0x18): both descriptors must be 4G flat segment with __BOOT_CS
> having execute/read
> permission and __BOOT_DS...
> 
> Also, it might be useful to take a look to see if other data structures, like
> setup_data and the initrd also need to be in the identity map.
> 

Thanks for your info. I have indistinct memory that KASLR need them identity
mapped. I will take a look.

-- 
Sincerely,
Cao jin



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-09-01  6:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-01  3:41 [PATCH] Documentation/x86/boot.rst: minor improvement Cao jin
2020-09-01  5:25 ` Cao jin
2020-09-01  5:35   ` H. Peter Anvin
2020-09-01  6:23     ` Cao jin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).