+ mm-apply-the-section-attribute-to-the-variable-not-its-type.patch added to -mm tree

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

 



The patch titled
     Subject: mm: Apply the section attribute to the variable, not its type
has been added to the -mm tree.  Its filename is
     mm-apply-the-section-attribute-to-the-variable-not-its-type.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/mm-apply-the-section-attribute-to-the-variable-not-its-type.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/mm-apply-the-section-attribute-to-the-variable-not-its-type.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Jan-Simon Möller <dl9pf@xxxxxx>
Subject: mm: Apply the section attribute to the variable, not its type

This fixes a compilation error in clang in that a linker section attribute
can't be added to a type.

arch/x86/mm/mmap.c:34:8: error: '__section__' attribute only applies to functions and global variables
struct __read_mostly va_alignment va_align = {
       ^
arch/x86/include/asm/cache.h:10:38: note: expanded from macro '__read_mostly'
#define __read_mostly __attribute__((__section__(".data..read_mostly")))
                                     ^
1 error generated.

By moving the section attribute to the variable declaration, the desired
effect is acheived.

Signed-off-by: Jan-Simon Möller <dl9pf@xxxxxx>
Signed-off-by: Behan Webster <behanw@xxxxxxxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 arch/x86/mm/mmap.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN arch/x86/mm/mmap.c~mm-apply-the-section-attribute-to-the-variable-not-its-type arch/x86/mm/mmap.c
--- a/arch/x86/mm/mmap.c~mm-apply-the-section-attribute-to-the-variable-not-its-type
+++ a/arch/x86/mm/mmap.c
@@ -31,7 +31,7 @@
 #include <linux/sched.h>
 #include <asm/elf.h>
 
-struct __read_mostly va_alignment va_align = {
+struct va_alignment __read_mostly va_align = {
 	.flags = -1,
 };
 
_

Patches currently in -mm which might be from dl9pf@xxxxxx are

linux-next.patch
mm-apply-the-section-attribute-to-the-variable-not-its-type.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux