Skip to content

Commit

Permalink
ARM: KVM: Work around older compiler bug
Browse files Browse the repository at this point in the history
Compilers before 4.6 do not behave well with unnamed fields in structure
initializers and therefore produces build errors:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10676

By refering to the unnamed union using braces, both older and newer
compilers produce the same result.

Acked-by: Marc Zyngier <marc.zyngier@arm.com>
Reported-by: Russell King <linux@arm.linux.org.uk>
Tested-by: Russell King <linux@arm.linux.org.uk>
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
  • Loading branch information
Christoffer Dall committed Aug 30, 2013
1 parent 6e72cc5 commit 6833d83
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/arm/kvm/reset.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ static struct kvm_regs a15_regs_reset = {
};

static const struct kvm_irq_level a15_vtimer_irq = {
.irq = 27,
{ .irq = 27 },
.level = 1,
};

Expand Down

0 comments on commit 6833d83

Please sign in to comment.