qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope.
@ 2015-04-21  8:26 Gal Hammer
  2015-04-21  9:38 ` Igor Mammedov
  2015-04-21 10:09 ` Michael S. Tsirkin
  0 siblings, 2 replies; 6+ messages in thread
From: Gal Hammer @ 2015-04-21  8:26 UTC (permalink / raw)
  To: qemu-devel; +Cc: Gal Hammer, imammedo, mst

A predefined scope in the ACPI specs is precede with a backslash.

Signed-off-by: Gal Hammer <ghammer@redhat.com>
---
 hw/i386/acpi-build.c        | 2 +-
 include/hw/acpi/aml-build.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 8d1a761..05c1d34 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -856,7 +856,7 @@ build_ssdt(GArray *table_data, GArray *linker,
         aml_append(ssdt, scope);
     }
 
-    sb_scope = aml_scope("_SB");
+    sb_scope = aml_scope("\\_SB");
     {
         /* create PCI0.PRES device and its _CRS to reserve CPU hotplug MMIO */
         dev = aml_device("PCI0." stringify(CPU_HOTPLUG_RESOURCE_DEVICE));
diff --git a/include/hw/acpi/aml-build.h b/include/hw/acpi/aml-build.h
index 48afb72..cb80f2a 100644
--- a/include/hw/acpi/aml-build.h
+++ b/include/hw/acpi/aml-build.h
@@ -120,7 +120,7 @@ void free_aml_allocator(void);
  * Joins Aml elements together and helps to construct AML tables
  * Examle of usage:
  *   Aml *table = aml_def_block("SSDT", ...);
- *   Aml *sb = aml_scope("\_SB");
+ *   Aml *sb = aml_scope("\\_SB");
  *   Aml *dev = aml_device("PCI0");
  *
  *   aml_append(dev, aml_name_decl("HID", aml_eisaid("PNP0A03")));
-- 
2.1.0

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

* Re: [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope.
  2015-04-21  8:26 [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope Gal Hammer
@ 2015-04-21  9:38 ` Igor Mammedov
  2015-04-21 10:09 ` Michael S. Tsirkin
  1 sibling, 0 replies; 6+ messages in thread
From: Igor Mammedov @ 2015-04-21  9:38 UTC (permalink / raw)
  To: Gal Hammer; +Cc: qemu-devel, mst

On Tue, 21 Apr 2015 11:26:12 +0300
Gal Hammer <ghammer@redhat.com> wrote:

> A predefined scope in the ACPI specs is precede with a backslash.
> 
> Signed-off-by: Gal Hammer <ghammer@redhat.com>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>

> ---
>  hw/i386/acpi-build.c        | 2 +-
>  include/hw/acpi/aml-build.h | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> index 8d1a761..05c1d34 100644
> --- a/hw/i386/acpi-build.c
> +++ b/hw/i386/acpi-build.c
> @@ -856,7 +856,7 @@ build_ssdt(GArray *table_data, GArray *linker,
>          aml_append(ssdt, scope);
>      }
>  
> -    sb_scope = aml_scope("_SB");
> +    sb_scope = aml_scope("\\_SB");
>      {
>          /* create PCI0.PRES device and its _CRS to reserve CPU hotplug MMIO */
>          dev = aml_device("PCI0." stringify(CPU_HOTPLUG_RESOURCE_DEVICE));
> diff --git a/include/hw/acpi/aml-build.h b/include/hw/acpi/aml-build.h
> index 48afb72..cb80f2a 100644
> --- a/include/hw/acpi/aml-build.h
> +++ b/include/hw/acpi/aml-build.h
> @@ -120,7 +120,7 @@ void free_aml_allocator(void);
>   * Joins Aml elements together and helps to construct AML tables
>   * Examle of usage:
>   *   Aml *table = aml_def_block("SSDT", ...);
> - *   Aml *sb = aml_scope("\_SB");
> + *   Aml *sb = aml_scope("\\_SB");
>   *   Aml *dev = aml_device("PCI0");
>   *
>   *   aml_append(dev, aml_name_decl("HID", aml_eisaid("PNP0A03")));

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

* Re: [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope.
  2015-04-21  8:26 [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope Gal Hammer
  2015-04-21  9:38 ` Igor Mammedov
@ 2015-04-21 10:09 ` Michael S. Tsirkin
  2015-04-21 11:33   ` Peter Maydell
  1 sibling, 1 reply; 6+ messages in thread
From: Michael S. Tsirkin @ 2015-04-21 10:09 UTC (permalink / raw)
  To: Gal Hammer; +Cc: imammedo, qemu-devel

On Tue, Apr 21, 2015 at 11:26:12AM +0300, Gal Hammer wrote:
> A predefined scope in the ACPI specs is precede with a backslash.
> 
> Signed-off-by: Gal Hammer <ghammer@redhat.com>

s/precede/preceded/

This is correct, but do we need this in 2.3?
I'm split on this. Thoughts?
If yes, commit log needs better explanation on what
the effect on guests is.


> ---
>  hw/i386/acpi-build.c        | 2 +-
>  include/hw/acpi/aml-build.h | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> index 8d1a761..05c1d34 100644
> --- a/hw/i386/acpi-build.c
> +++ b/hw/i386/acpi-build.c
> @@ -856,7 +856,7 @@ build_ssdt(GArray *table_data, GArray *linker,
>          aml_append(ssdt, scope);
>      }
>  
> -    sb_scope = aml_scope("_SB");
> +    sb_scope = aml_scope("\\_SB");
>      {
>          /* create PCI0.PRES device and its _CRS to reserve CPU hotplug MMIO */
>          dev = aml_device("PCI0." stringify(CPU_HOTPLUG_RESOURCE_DEVICE));
> diff --git a/include/hw/acpi/aml-build.h b/include/hw/acpi/aml-build.h
> index 48afb72..cb80f2a 100644
> --- a/include/hw/acpi/aml-build.h
> +++ b/include/hw/acpi/aml-build.h
> @@ -120,7 +120,7 @@ void free_aml_allocator(void);
>   * Joins Aml elements together and helps to construct AML tables
>   * Examle of usage:
>   *   Aml *table = aml_def_block("SSDT", ...);
> - *   Aml *sb = aml_scope("\_SB");
> + *   Aml *sb = aml_scope("\\_SB");
>   *   Aml *dev = aml_device("PCI0");
>   *
>   *   aml_append(dev, aml_name_decl("HID", aml_eisaid("PNP0A03")));
> -- 
> 2.1.0

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

* Re: [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope.
  2015-04-21 10:09 ` Michael S. Tsirkin
@ 2015-04-21 11:33   ` Peter Maydell
  2015-04-21 12:53     ` Michael S. Tsirkin
  0 siblings, 1 reply; 6+ messages in thread
From: Peter Maydell @ 2015-04-21 11:33 UTC (permalink / raw)
  To: Michael S. Tsirkin; +Cc: Gal Hammer, Igor Mammedov, QEMU Developers

On 21 April 2015 at 11:09, Michael S. Tsirkin <mst@redhat.com> wrote:
> On Tue, Apr 21, 2015 at 11:26:12AM +0300, Gal Hammer wrote:
>> A predefined scope in the ACPI specs is precede with a backslash.
>>
>> Signed-off-by: Gal Hammer <ghammer@redhat.com>
>
> s/precede/preceded/
>
> This is correct, but do we need this in 2.3?
> I'm split on this. Thoughts?
> If yes, commit log needs better explanation on what
> the effect on guests is.

Unless the effect is absolutely catastrophic you've missed
the boat for 2.3, and should settle for 2.4 + cc:stable.

thanks
-- PMM

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

* Re: [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope.
  2015-04-21 11:33   ` Peter Maydell
@ 2015-04-21 12:53     ` Michael S. Tsirkin
  2015-04-22  6:13       ` Igor Mammedov
  0 siblings, 1 reply; 6+ messages in thread
From: Michael S. Tsirkin @ 2015-04-21 12:53 UTC (permalink / raw)
  To: Peter Maydell; +Cc: Gal Hammer, Igor Mammedov, QEMU Developers

On Tue, Apr 21, 2015 at 12:33:36PM +0100, Peter Maydell wrote:
> On 21 April 2015 at 11:09, Michael S. Tsirkin <mst@redhat.com> wrote:
> > On Tue, Apr 21, 2015 at 11:26:12AM +0300, Gal Hammer wrote:
> >> A predefined scope in the ACPI specs is precede with a backslash.
> >>
> >> Signed-off-by: Gal Hammer <ghammer@redhat.com>
> >
> > s/precede/preceded/
> >
> > This is correct, but do we need this in 2.3?
> > I'm split on this. Thoughts?
> > If yes, commit log needs better explanation on what
> > the effect on guests is.
> 
> Unless the effect is absolutely catastrophic you've missed
> the boat for 2.3, and should settle for 2.4 + cc:stable.
> 
> thanks
> -- PMM

I rechecked a bunch of guests and they all seem to behave identically
with and without the patch.
2.4 it is.

Thanks.

-- 
MST

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

* Re: [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope.
  2015-04-21 12:53     ` Michael S. Tsirkin
@ 2015-04-22  6:13       ` Igor Mammedov
  0 siblings, 0 replies; 6+ messages in thread
From: Igor Mammedov @ 2015-04-22  6:13 UTC (permalink / raw)
  To: Michael S. Tsirkin; +Cc: Gal Hammer, Peter Maydell, QEMU Developers

On Tue, 21 Apr 2015 14:53:54 +0200
"Michael S. Tsirkin" <mst@redhat.com> wrote:

> On Tue, Apr 21, 2015 at 12:33:36PM +0100, Peter Maydell wrote:
> > On 21 April 2015 at 11:09, Michael S. Tsirkin <mst@redhat.com> wrote:
> > > On Tue, Apr 21, 2015 at 11:26:12AM +0300, Gal Hammer wrote:
> > >> A predefined scope in the ACPI specs is precede with a backslash.
> > >>
> > >> Signed-off-by: Gal Hammer <ghammer@redhat.com>
> > >
> > > s/precede/preceded/
> > >
> > > This is correct, but do we need this in 2.3?
> > > I'm split on this. Thoughts?
> > > If yes, commit log needs better explanation on what
> > > the effect on guests is.
> > 
> > Unless the effect is absolutely catastrophic you've missed
> > the boat for 2.3, and should settle for 2.4 + cc:stable.
> > 
> > thanks
> > -- PMM
> 
> I rechecked a bunch of guests and they all seem to behave identically
> with and without the patch.
> 2.4 it is.
Yep, it's cosmetic change, since that _SB was at the top level it's automatically
attributed to root scope. Having explicit root in name doesn't hurt though
and makes it consistent with other _SB declarations in the code.

> 
> Thanks.
> 

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

end of thread, other threads:[~2015-04-22  6:13 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-21  8:26 [Qemu-devel] [PATCH] acpi: add a missing backslash to the \_SB scope Gal Hammer
2015-04-21  9:38 ` Igor Mammedov
2015-04-21 10:09 ` Michael S. Tsirkin
2015-04-21 11:33   ` Peter Maydell
2015-04-21 12:53     ` Michael S. Tsirkin
2015-04-22  6:13       ` Igor Mammedov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).