lkml.org 
[lkml]   [2015]   [Sep]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Subject[PATCH 03/15] frv: fix compiler warning from definition of __pmd()
    From
    Date
    Take into account that the pmd_t type is a array inside a struct, so it
    needs two levels of brackets to initialize. Otherwise, a usage of __pmd
    generates a warning:

    include/linux/mm.h:986:2: warning: missing braces around initializer [-Wmissing-braces]

    Signed-off-by: Dan Williams <dan.j.williams@intel.com>
    ---
    arch/frv/include/asm/page.h | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    diff --git a/arch/frv/include/asm/page.h b/arch/frv/include/asm/page.h
    index 8c97068ac8fc..688d8076a43a 100644
    --- a/arch/frv/include/asm/page.h
    +++ b/arch/frv/include/asm/page.h
    @@ -34,7 +34,7 @@ typedef struct page *pgtable_t;
    #define pgprot_val(x) ((x).pgprot)

    #define __pte(x) ((pte_t) { (x) } )
    -#define __pmd(x) ((pmd_t) { (x) } )
    +#define __pmd(x) ((pmd_t) { { (x) } } )
    #define __pud(x) ((pud_t) { (x) } )
    #define __pgd(x) ((pgd_t) { (x) } )
    #define __pgprot(x) ((pgprot_t) { (x) } )


    \
     
     \ /
      Last update: 2015-09-23 07:21    [W:4.525 / U:0.436 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site