[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 3/3] xen/init: Annotate all command line parameter infrastructure as const



>>> On 09.02.16 at 14:52, <andrew.cooper3@xxxxxxxxxx> wrote:
> On 09/02/16 12:43, Jan Beulich wrote:
>>>>> On 08.02.16 at 18:07, <andrew.cooper3@xxxxxxxxxx> wrote:
>>> --- a/xen/arch/x86/xen.lds.S
>>> +++ b/xen/arch/x86/xen.lds.S
>>> @@ -120,6 +120,12 @@ SECTIONS
>>>    .init.data : {
>>>         *(.init.rodata)
>>>         *(.init.rodata.str*)
>>> +
>>> +       . = ALIGN(32);
>> Why 32?
>>
>>> +       __setup_start = .;
>>> +       *(.init.setup)
>>> +       __setup_end = .;
>>> +
>>>         *(.init.data)
>>>         *(.init.data.rel)
>>>         *(.init.data.rel.*)
>>> @@ -146,11 +152,6 @@ SECTIONS
>>>         __ctors_end = .;
>>>    } :text
>>>    . = ALIGN(32);
>>> -  .init.setup : {
>>> -       __setup_start = .;
>>> -       *(.init.setup)
>>> -       __setup_end = .;
>>> -  } :text
>> If just because it was 32 here, I don't think that's a compelling
>> reason. With it (above, not necessarily here) reduced to 8 (which
>> of course could also be done while committing, if you agree and
>> there are no deeper reasons),
>> Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
> 
> It was just because of the code here.  I still can't think of any
> specific reason why 32 is needed, so the ALIGN() can just be dropped.

No, dropping ALIGN() altogether would make the placement of
__setup_start dependent upon the alignment of the previous
section (and since it's a strings section which precedes it,
problems would be quite likely). (This is, btw., why it would be
better if we used __startof__ and __alignof__ instead of linker
script generated symbols. I may give that a try ...)

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.