All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [RESEND PATCH for-1.5] acpi: add dummy write function for acpi timer
@ 2013-05-14 12:29 Gerd Hoffmann
  2013-05-14 12:45 ` Laszlo Ersek
  2013-05-14 16:10 ` Anthony Liguori
  0 siblings, 2 replies; 3+ messages in thread
From: Gerd Hoffmann @ 2013-05-14 12:29 UTC (permalink / raw)
  To: qemu-devel; +Cc: Gerd Hoffmann, Michael S. Tsirkin

Otherwise the guest can crash qemu (NULL pointer dereference).

https://bugzilla.redhat.com/show_bug.cgi?id=947691

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 hw/acpi/core.c |    7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/hw/acpi/core.c b/hw/acpi/core.c
index 64b8718..42eeace 100644
--- a/hw/acpi/core.c
+++ b/hw/acpi/core.c
@@ -462,8 +462,15 @@ static uint64_t acpi_pm_tmr_read(void *opaque, hwaddr addr, unsigned width)
     return acpi_pm_tmr_get(opaque);
 }
 
+static void acpi_pm_tmr_write(void *opaque, hwaddr addr, uint64_t val,
+                              unsigned width)
+{
+    /* nothing */
+}
+
 static const MemoryRegionOps acpi_pm_tmr_ops = {
     .read = acpi_pm_tmr_read,
+    .write = acpi_pm_tmr_write,
     .valid.min_access_size = 4,
     .valid.max_access_size = 4,
     .endianness = DEVICE_LITTLE_ENDIAN,
-- 
1.7.9.7

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] [RESEND PATCH for-1.5] acpi: add dummy write function for acpi timer
  2013-05-14 12:29 [Qemu-devel] [RESEND PATCH for-1.5] acpi: add dummy write function for acpi timer Gerd Hoffmann
@ 2013-05-14 12:45 ` Laszlo Ersek
  2013-05-14 16:10 ` Anthony Liguori
  1 sibling, 0 replies; 3+ messages in thread
From: Laszlo Ersek @ 2013-05-14 12:45 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: qemu-devel, Michael S. Tsirkin

On 05/14/13 14:29, Gerd Hoffmann wrote:
> Otherwise the guest can crash qemu (NULL pointer dereference).
> 
> https://bugzilla.redhat.com/show_bug.cgi?id=947691
> 
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> ---
>  hw/acpi/core.c |    7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/hw/acpi/core.c b/hw/acpi/core.c
> index 64b8718..42eeace 100644
> --- a/hw/acpi/core.c
> +++ b/hw/acpi/core.c
> @@ -462,8 +462,15 @@ static uint64_t acpi_pm_tmr_read(void *opaque, hwaddr addr, unsigned width)
>      return acpi_pm_tmr_get(opaque);
>  }
>  
> +static void acpi_pm_tmr_write(void *opaque, hwaddr addr, uint64_t val,
> +                              unsigned width)
> +{
> +    /* nothing */
> +}
> +
>  static const MemoryRegionOps acpi_pm_tmr_ops = {
>      .read = acpi_pm_tmr_read,
> +    .write = acpi_pm_tmr_write,
>      .valid.min_access_size = 4,
>      .valid.max_access_size = 4,
>      .endianness = DEVICE_LITTLE_ENDIAN,
> 

(Hopefully the low-hanging fruit impression it makes is not a trap!)

Reviewed-by: Laszlo Ersek <lersek@redhat.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] [RESEND PATCH for-1.5] acpi: add dummy write function for acpi timer
  2013-05-14 12:29 [Qemu-devel] [RESEND PATCH for-1.5] acpi: add dummy write function for acpi timer Gerd Hoffmann
  2013-05-14 12:45 ` Laszlo Ersek
@ 2013-05-14 16:10 ` Anthony Liguori
  1 sibling, 0 replies; 3+ messages in thread
From: Anthony Liguori @ 2013-05-14 16:10 UTC (permalink / raw)
  To: Gerd Hoffmann, qemu-devel; +Cc: Michael S. Tsirkin

Applied.  Thanks.

Regards,

Anthony Liguori

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-05-14 16:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-14 12:29 [Qemu-devel] [RESEND PATCH for-1.5] acpi: add dummy write function for acpi timer Gerd Hoffmann
2013-05-14 12:45 ` Laszlo Ersek
2013-05-14 16:10 ` Anthony Liguori

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.