lkml.org 
[lkml]   [2021]   [May]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 01/15] mm: add setup_initial_init_mm() helper
From
Date

On 2021/5/31 15:45, Geert Uytterhoeven wrote:
> Hi Kefeng,
>
> On Sat, May 29, 2021 at 12:47 PM Kefeng Wang <wangkefeng.wang@huawei.com> wrote:
>> Add setup_initial_init_mm() helper to setup kernel text,
>> data and brk.
>>
>> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
> Thanks for your patch!
>
>> --- a/include/linux/mm_types.h
>> +++ b/include/linux/mm_types.h
>> @@ -564,6 +564,16 @@ struct mm_struct {
>> };
>>
>> extern struct mm_struct init_mm;
>> +static inline void setup_initial_init_mm(char *start_code,
>> + char *end_code,
>> + char *end_data,
>> + char *brk)
> "void *" (for all four)?
The original users are all "char*",  so same here ;)
>
>> +{
>> + init_mm.start_code = (unsigned long)start_code;
>> + init_mm.end_code = (unsigned long)end_code;
>> + init_mm.end_data = (unsigned long)end_data;
>> + init_mm.brk = (unsigned long)brk;
>> +}
> Gr{oetje,eeting}s,
>
> Geert
>

\
 
 \ /
  Last update: 2021-05-31 16:09    [W:0.099 / U:1.148 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site