lkml.org 
[lkml]   [2008]   [Apr]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] pop previous section in alternative.c


On Thu, 10 Apr 2008, Andy Whitcroft wrote:
> >
> > BTW it looks like the problem was added with 121d7bf5a246d282ba91234d03a4edf9ccc9c940,
> > signed off by me, sorry for not catching it in review.
> >
> > Perhaps that is something that would make sense adding to checkpatch.pl?
> > Complain for .section in inline assembler without .previous or popsection
> > (cc Andy). I think such a check would make sense.
>
> Do you have an example of such a bad thing? My only concern is this
> sounds like a check which could potentially need to see more lines than are
> available in the patch context and so the test might be rather unreliable.
>

From commit 121d7bf5a246d282ba91234d03a4edf9ccc9c940:

get them easily into strings. */
-asm("\t.data\nintelnops: "
+asm("\t.section .rodata, \"a\"\nintelnops: "
GENERIC_NOP1 GENERIC_NOP2 GENERIC_NOP3 GENERIC_NOP4 GENERIC_NOP5 GENERIC
GENERIC_NOP7 GENERIC_NOP8);
-extern unsigned char intelnops[];


I would say anytime there's a "^+.*\.section" there had better be a
"^-.*\.section" or a "+.*.previous" matching it. Off hand I can't think of
any exceptions to this rule although I may be wrong.

-- Steve




\
 
 \ /
  Last update: 2008-04-10 16:13    [W:0.063 / U:0.500 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site