All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Henderson <rth@twiddle.net>
To: Tobias Markus <tobias@markus-regensburg.de>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [qemu-devel] [PATCH v2] target-i386: Fix segment cache dump
Date: Fri, 23 Aug 2013 13:01:31 -0700	[thread overview]
Message-ID: <5217BF9B.9040503@twiddle.net> (raw)
In-Reply-To: <5217B34F.4090508@markus-regensburg.de>

On 08/23/2013 12:09 PM, Tobias Markus wrote:
> When in Long Mode, cpu_x86_seg_cache() logs "DS16" because the Default operation size bit (D/B bit) is not set for Long Mode Data Segments since there are only Data Segments in Long Mode and no explicit 16/32/64-bit Descriptors.
> This patch fixes this by checking the Long Mode Active bit of the hidden flags variable and logging "DS" if it is set. (I.e. in Long Mode all Data Segments are logged as "DS")
> 
> Signed-off-by: Tobias Markus <tobias@markus-regensburg.de>

Reviewed-by: Richard Henderson <rth@twiddle.net>

> +            cpu_fprintf(f, (sc->flags & DESC_B_MASK ||
> +                        env->hflags & HF_LMA_MASK)
> +                        ? "DS  " : "DS16");

Though we don't have anything in CODING_STYLE that mandates this,
IMO expressions shouldn't "unindent" in the middle like this.

Better as

           cpu_fprintf(f, (sc->flags & DESC_B_MASK
                           || env->hflags & HF_LMA_MASK
                           ? "DS  " : "DS16"));

but that's just me and emacs...


r~

  reply	other threads:[~2013-08-23 20:01 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-23 19:09 [Qemu-devel] [qemu-devel] [PATCH v2] target-i386: Fix segment cache dump Tobias Markus
2013-08-23 20:01 ` Richard Henderson [this message]
2013-08-23 21:39   ` [Qemu-devel] " Tobias Markus
2013-08-23 21:48     ` Eric Blake
2013-08-24 10:40 ` [Qemu-devel] [qemu-devel] " Peter Maydell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5217BF9B.9040503@twiddle.net \
    --to=rth@twiddle.net \
    --cc=qemu-devel@nongnu.org \
    --cc=tobias@markus-regensburg.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.