All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Alexander Graf <agraf@suse.de>
Cc: anthony.perard@citrix.com, xen-devel@lists.xensource.com,
	qemu-devel@nongnu.org, stefano.stabellini@eu.citrix.com
Subject: Re: [Qemu-devel] [PATCH] cirrus_vga: reset lfb_addr after a pci config write if the BAR is unmapped
Date: Tue, 14 Jun 2011 18:25:45 +0200	[thread overview]
Message-ID: <4DF78B89.8030202@siemens.com> (raw)
In-Reply-To: <4DF7681F.6020104@suse.de>

On 2011-06-14 15:54, Alexander Graf wrote:
> On 06/03/2011 05:56 PM, stefano.stabellini@eu.citrix.com wrote:
>> From: Stefano Stabellini<stefano.stabellini@eu.citrix.com>
>>
>> If the cirrus_vga PCI BAR is unmapped than we should not only reset
>> map_addr but also lfb_addr, otherwise we'll keep trying to map
>> the old lfb_addr in map_linear_vram.
> 
> The patch looks good to me, but I'd love to get an ack from someone who
> knows the cirrus code before committing it.
> 

I'm not claiming to be the cirrus expert, but I've just walked through
all this vga mapping stuff: patch is correct.

Acked-by: Jan Kiszka <jan.kiszka@siemens.com>

> 
> Alex
> 
>> Signed-off-by: Stefano Stabellini<stefano.stabellini@eu.citrix.com>
>> ---
>>   hw/cirrus_vga.c |    5 ++++-
>>   1 files changed, 4 insertions(+), 1 deletions(-)
>>
>> diff --git a/hw/cirrus_vga.c b/hw/cirrus_vga.c
>> index 722cac7..3c5043e 100644
>> --- a/hw/cirrus_vga.c
>> +++ b/hw/cirrus_vga.c
>> @@ -3088,8 +3088,11 @@ static void pci_cirrus_write_config(PCIDevice *d,
>>       CirrusVGAState *s =&pvs->cirrus_vga;
>>
>>       pci_default_write_config(d, address, val, len);
>> -    if (s->vga.map_addr&&  d->io_regions[0].addr == PCI_BAR_UNMAPPED)
>> +    if (s->vga.map_addr&&  d->io_regions[0].addr == PCI_BAR_UNMAPPED) {
>>           s->vga.map_addr = 0;
>> +        s->vga.lfb_addr = 0;
>> +        s->vga.lfb_end = 0;
>> +    }
>>       cirrus_update_memory_access(s);
>>   }
>>

-- 
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux

WARNING: multiple messages have this Message-ID (diff)
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Alexander Graf <agraf@suse.de>
Cc: anthony.perard@citrix.com, xen-devel@lists.xensource.com,
	qemu-devel@nongnu.org, anthony@codemonkey.ws,
	stefano.stabellini@eu.citrix.com
Subject: Re: [PATCH] cirrus_vga: reset lfb_addr after a pci config write if the BAR is unmapped
Date: Tue, 14 Jun 2011 18:25:45 +0200	[thread overview]
Message-ID: <4DF78B89.8030202@siemens.com> (raw)
In-Reply-To: <4DF7681F.6020104@suse.de>

On 2011-06-14 15:54, Alexander Graf wrote:
> On 06/03/2011 05:56 PM, stefano.stabellini@eu.citrix.com wrote:
>> From: Stefano Stabellini<stefano.stabellini@eu.citrix.com>
>>
>> If the cirrus_vga PCI BAR is unmapped than we should not only reset
>> map_addr but also lfb_addr, otherwise we'll keep trying to map
>> the old lfb_addr in map_linear_vram.
> 
> The patch looks good to me, but I'd love to get an ack from someone who
> knows the cirrus code before committing it.
> 

I'm not claiming to be the cirrus expert, but I've just walked through
all this vga mapping stuff: patch is correct.

Acked-by: Jan Kiszka <jan.kiszka@siemens.com>

> 
> Alex
> 
>> Signed-off-by: Stefano Stabellini<stefano.stabellini@eu.citrix.com>
>> ---
>>   hw/cirrus_vga.c |    5 ++++-
>>   1 files changed, 4 insertions(+), 1 deletions(-)
>>
>> diff --git a/hw/cirrus_vga.c b/hw/cirrus_vga.c
>> index 722cac7..3c5043e 100644
>> --- a/hw/cirrus_vga.c
>> +++ b/hw/cirrus_vga.c
>> @@ -3088,8 +3088,11 @@ static void pci_cirrus_write_config(PCIDevice *d,
>>       CirrusVGAState *s =&pvs->cirrus_vga;
>>
>>       pci_default_write_config(d, address, val, len);
>> -    if (s->vga.map_addr&&  d->io_regions[0].addr == PCI_BAR_UNMAPPED)
>> +    if (s->vga.map_addr&&  d->io_regions[0].addr == PCI_BAR_UNMAPPED) {
>>           s->vga.map_addr = 0;
>> +        s->vga.lfb_addr = 0;
>> +        s->vga.lfb_end = 0;
>> +    }
>>       cirrus_update_memory_access(s);
>>   }
>>

-- 
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux

  reply	other threads:[~2011-06-14 16:25 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-03 15:56 [Qemu-devel] [PATCH] xen: avoid tracking the region 0xa0000 - 0xbffff stefano.stabellini
2011-06-03 15:56 ` stefano.stabellini
2011-06-03 15:56 ` [Qemu-devel] [PATCH] cirrus_vga: reset lfb_addr after a pci config write if the BAR is unmapped stefano.stabellini
2011-06-03 15:56   ` stefano.stabellini
2011-06-14 13:54   ` [Qemu-devel] " Alexander Graf
2011-06-14 13:54     ` Alexander Graf
2011-06-14 16:25     ` Jan Kiszka [this message]
2011-06-14 16:25       ` Jan Kiszka
2011-06-14 10:54 ` [PATCH] xen: avoid tracking the region 0xa0000 - 0xbffff Alexander Graf
2011-06-14 11:04   ` [Qemu-devel] " Jan Kiszka
2011-06-14 11:04     ` Jan Kiszka
2011-06-14 11:50     ` [Qemu-devel] " Stefano Stabellini
2011-06-14 11:50       ` Stefano Stabellini
2011-06-14 11:59       ` [Qemu-devel] " Jan Kiszka
2011-06-14 11:59         ` Jan Kiszka
2011-06-14 16:47     ` [Qemu-devel] [Xen-devel] " Avi Kivity
2011-06-14 16:47       ` Avi Kivity
2011-06-14 11:48   ` [Qemu-devel] " Stefano Stabellini
2011-06-14 11:48     ` Stefano Stabellini
2011-06-14 11:52     ` [Qemu-devel] " Alexander Graf
2011-06-14 11:52       ` Alexander Graf
2011-06-14 15:24       ` [Qemu-devel] " Stefano Stabellini
2011-06-14 15:24         ` Stefano Stabellini
2011-06-14 15:24         ` [Qemu-devel] " Alexander Graf
2011-06-14 15:24           ` Alexander Graf
2011-06-15  8:09         ` [Qemu-devel] " Alexander Graf
2011-06-15  8:09           ` Alexander Graf
2011-06-15 16:27           ` [Qemu-devel] " Stefano Stabellini
2011-06-15 16:27             ` Stefano Stabellini

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=4DF78B89.8030202@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=agraf@suse.de \
    --cc=anthony.perard@citrix.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    /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.