[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/3] sparc64: implement global translation tabl
From: |
Blue Swirl |
Subject: |
Re: [Qemu-devel] [PATCH 2/3] sparc64: implement global translation table entries |
Date: |
Mon, 3 May 2010 23:29:50 +0300 |
On 5/3/10, Igor Kovalenko <address@hidden> wrote:
> On Tue, May 4, 2010 at 12:06 AM, Blue Swirl <address@hidden> wrote:
> > On 5/3/10, Igor V. Kovalenko <address@hidden> wrote:
> >> From: Igor V. Kovalenko <address@hidden>
> >>
> >> - match global tte against any context
> >> - show global tte in MMU dump
> >>
> >> Signed-off-by: Igor V. Kovalenko <address@hidden>
> >
> > I get this error:
> > CC sparc64-softmmu/op_helper.o
> > cc1: warnings being treated as errors
> > /src/qemu/target-sparc/op_helper.c: In function 'demap_tlb':
> > /src/qemu/target-sparc/op_helper.c:129: error: 'context' may be used
> > uninitialized in this function
> >
>
>
> My gcc (Gentoo 4.4.3-r2 p1.2) is silent, and looking at the change all
> 4 possible cases are handled in switch statement.
I think gcc is not intelligent enough to know that x & 3 has only 4
possible cases. :-)
> It should initializes context in 3 usable cases and returns from the
> 4th which is reserved.
> How do we fix this issue?
I'd add a default case to one of the cases. Another possibility is to
initialize the context with 0 and then make one of the cases empty.
[Qemu-devel] [PATCH 3/3] sparc64: handle asi referencing nucleus and secondary MMU contexts, Igor V. Kovalenko, 2010/05/03