• Andrew Morton's avatar
    drivers/block/nvme-core.c: fix build with gcc-4.4.4 · e44ac588
    Andrew Morton authored
    gcc-4.4.4 (and possibly other versions) fail the compile when initializers
    are used with anonymous unions.  Work around this.
    
    drivers/block/nvme-core.c: In function 'nvme_identify_ctrl':
    drivers/block/nvme-core.c:1163: error: unknown field 'identify' specified in initializer
    drivers/block/nvme-core.c:1163: warning: missing braces around initializer
    drivers/block/nvme-core.c:1163: warning: (near initialization for 'c.<anonymous>')
    drivers/block/nvme-core.c:1164: error: unknown field 'identify' specified in initializer
    drivers/block/nvme-core.c:1164: warning: excess elements in struct initializer
    drivers/block/nvme-core.c:1164: warning: (near initialization for 'c')
    ...
    
    This patch has no effect on text size with gcc-4.8.2.
    
    Fixes: d29ec824 ("nvme: submit internal commands through the block layer")
    Cc: Christoph Hellwig <hch@lst.de>
    Cc: Jens Axboe <axboe@fb.com>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarJens Axboe <axboe@fb.com>
    e44ac588
nvme-core.c 80.5 KB