From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Zijlstra Subject: Re: [PATCH] KVM: x86: Fix build breakage due to anonymous field initialization Date: Thu, 15 Dec 2011 13:08:54 +0100 Message-ID: <1323950934.18942.37.camel@twins> References: <1319993624-20247-1-git-send-email-gleb@redhat.com> <1319993624-20247-3-git-send-email-gleb@redhat.com> <4EE9E234.6050702@siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT Cc: avi@redhat.com, mtosatti@redhat.com, Gleb Natapov , kvm@vger.kernel.org, linux-kernel@redhat.com, mingo@elte.hu, acme@ghostprotocols.net To: Jan Kiszka Return-path: Received: from casper.infradead.org ([85.118.1.10]:39187 "EHLO casper.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751089Ab1LOMJz convert rfc822-to-8bit (ORCPT ); Thu, 15 Dec 2011 07:09:55 -0500 In-Reply-To: <4EE9E234.6050702@siemens.com> Sender: kvm-owner@vger.kernel.org List-ID: On Thu, 2011-12-15 at 13:04 +0100, Jan Kiszka wrote: > Not all compilers accept anonymous field initialization, e.g. gcc > 4.5.1. > > Signed-off-by: Jan Kiszka > --- > arch/x86/kvm/pmu.c | 3 ++- > 1 files changed, 2 insertions(+), 1 deletions(-) > > diff --git a/arch/x86/kvm/pmu.c b/arch/x86/kvm/pmu.c > index 061a03f..7aad544 100644 > --- a/arch/x86/kvm/pmu.c > +++ b/arch/x86/kvm/pmu.c > @@ -170,10 +170,11 @@ static void reprogram_counter(struct kvm_pmc *pmc, u32 type, > .exclude_host = 1, > .exclude_user = exclude_user, > .exclude_kernel = exclude_kernel, > - .sample_period = (-pmc->counter) & pmc_bitmask(pmc), + { .sample_period = ... }, Does that work? > .config = config, > };