LKML Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3
@ 2019-08-06  4:24 Daniel Black
  2019-08-12  8:03 ` Tao Xu
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Daniel Black @ 2019-08-06  4:24 UTC (permalink / raw)
  To: unlisted-recipients:; (no To-header on input)
  Cc: Daniel Black, Rafael J. Wysocki, Len Brown, linux-acpi, linux-kernel

ACPI-6.3 corresponds to when hmat revision was bumped from
1 to 2. In this version ACPI_HMAT_MEMORY_PD_VALID was
deprecated and made reserved.

As such in revision 2+ we shouldn't be testing this flag.

This is as per ACPI-6.3, 5.2.27.3, Table 5-145
"Memory Proximity Domain Attributes Structure"
for Flags.

Signed-off-by: Daniel Black <daniel@linux.ibm.com>
---
 drivers/acpi/hmat/hmat.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/acpi/hmat/hmat.c b/drivers/acpi/hmat/hmat.c
index 96b7d39a97c6..e938e34673d9 100644
--- a/drivers/acpi/hmat/hmat.c
+++ b/drivers/acpi/hmat/hmat.c
@@ -382,7 +382,7 @@ static int __init hmat_parse_proximity_domain(union acpi_subtable_headers *heade
 		pr_info("HMAT: Memory Flags:%04x Processor Domain:%d Memory Domain:%d\n",
 			p->flags, p->processor_PD, p->memory_PD);
 
-	if (p->flags & ACPI_HMAT_MEMORY_PD_VALID) {
+	if (p->flags & ACPI_HMAT_MEMORY_PD_VALID && hmat_revision == 1) {
 		target = find_mem_target(p->memory_PD);
 		if (!target) {
 			pr_debug("HMAT: Memory Domain missing from SRAT\n");
-- 
2.21.0


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

* Re: [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3
  2019-08-06  4:24 [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3 Daniel Black
@ 2019-08-12  8:03 ` Tao Xu
  2019-09-02 21:28 ` Rafael J. Wysocki
  2019-10-10 22:20 ` Rafael J. Wysocki
  2 siblings, 0 replies; 6+ messages in thread
From: Tao Xu @ 2019-08-12  8:03 UTC (permalink / raw)
  To: Daniel Black; +Cc: Rafael J. Wysocki, Len Brown, open list:ACPI, open list

On 8/6/2019 12:24 PM, Daniel Black wrote:
> ACPI-6.3 corresponds to when hmat revision was bumped from
> 1 to 2. In this version ACPI_HMAT_MEMORY_PD_VALID was
> deprecated and made reserved.
> 
> As such in revision 2+ we shouldn't be testing this flag.
> 
> This is as per ACPI-6.3, 5.2.27.3, Table 5-145
> "Memory Proximity Domain Attributes Structure"
> for Flags.

Looks good to me.

Reviewed-by: Tao Xu <tao3.xu@intel.com>
> 
> Signed-off-by: Daniel Black <daniel@linux.ibm.com>
> ---
>   drivers/acpi/hmat/hmat.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/acpi/hmat/hmat.c b/drivers/acpi/hmat/hmat.c
> index 96b7d39a97c6..e938e34673d9 100644
> --- a/drivers/acpi/hmat/hmat.c
> +++ b/drivers/acpi/hmat/hmat.c
> @@ -382,7 +382,7 @@ static int __init hmat_parse_proximity_domain(union acpi_subtable_headers *heade
>   		pr_info("HMAT: Memory Flags:%04x Processor Domain:%d Memory Domain:%d\n",
>   			p->flags, p->processor_PD, p->memory_PD);
>   
> -	if (p->flags & ACPI_HMAT_MEMORY_PD_VALID) {
> +	if (p->flags & ACPI_HMAT_MEMORY_PD_VALID && hmat_revision == 1) {
>   		target = find_mem_target(p->memory_PD);
>   		if (!target) {
>   			pr_debug("HMAT: Memory Domain missing from SRAT\n");
> 


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

* Re: [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3
  2019-08-06  4:24 [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3 Daniel Black
  2019-08-12  8:03 ` Tao Xu
@ 2019-09-02 21:28 ` Rafael J. Wysocki
  2019-09-03  1:03   ` Daniel Black
  2019-10-10 22:20 ` Rafael J. Wysocki
  2 siblings, 1 reply; 6+ messages in thread
From: Rafael J. Wysocki @ 2019-09-02 21:28 UTC (permalink / raw)
  To: Daniel Black, Keith Busch
  Cc: Rafael J. Wysocki, Len Brown, open list:ACPI, open list

On Tue, Aug 6, 2019 at 6:24 AM Daniel Black <daniel@linux.ibm.com> wrote:
>
> ACPI-6.3 corresponds to when hmat revision was bumped from
> 1 to 2. In this version ACPI_HMAT_MEMORY_PD_VALID was
> deprecated and made reserved.
>
> As such in revision 2+ we shouldn't be testing this flag.
>
> This is as per ACPI-6.3, 5.2.27.3, Table 5-145
> "Memory Proximity Domain Attributes Structure"
> for Flags.
>
> Signed-off-by: Daniel Black <daniel@linux.ibm.com>

Keith, any comments?

> ---
>  drivers/acpi/hmat/hmat.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/hmat/hmat.c b/drivers/acpi/hmat/hmat.c
> index 96b7d39a97c6..e938e34673d9 100644
> --- a/drivers/acpi/hmat/hmat.c
> +++ b/drivers/acpi/hmat/hmat.c
> @@ -382,7 +382,7 @@ static int __init hmat_parse_proximity_domain(union acpi_subtable_headers *heade
>                 pr_info("HMAT: Memory Flags:%04x Processor Domain:%d Memory Domain:%d\n",
>                         p->flags, p->processor_PD, p->memory_PD);
>
> -       if (p->flags & ACPI_HMAT_MEMORY_PD_VALID) {
> +       if (p->flags & ACPI_HMAT_MEMORY_PD_VALID && hmat_revision == 1) {
>                 target = find_mem_target(p->memory_PD);
>                 if (!target) {
>                         pr_debug("HMAT: Memory Domain missing from SRAT\n");
> --
> 2.21.0
>

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

* Re: [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3
  2019-09-02 21:28 ` Rafael J. Wysocki
@ 2019-09-03  1:03   ` Daniel Black
  2019-10-02  0:25     ` Daniel Black
  0 siblings, 1 reply; 6+ messages in thread
From: Daniel Black @ 2019-09-03  1:03 UTC (permalink / raw)
  To: Keith Busch
  Cc: Rafael J. Wysocki, Rafael J. Wysocki, Len Brown, open list:ACPI,
	open list, Tao Xu

On Mon, 2 Sep 2019 23:28:50 +0200
"Rafael J. Wysocki" <rafael@kernel.org> wrote:

> On Tue, Aug 6, 2019 at 6:24 AM Daniel Black <daniel@linux.ibm.com> wrote:
> >
> > ACPI-6.3 corresponds to when hmat revision was bumped from
> > 1 to 2. In this version ACPI_HMAT_MEMORY_PD_VALID was
> > deprecated and made reserved.
> >
> > As such in revision 2+ we shouldn't be testing this flag.
> >
> > This is as per ACPI-6.3, 5.2.27.3, Table 5-145
> > "Memory Proximity Domain Attributes Structure"
> > for Flags.
> >
> > Signed-off-by: Daniel Black <daniel@linux.ibm.com>  
> 
> Keith, any comments?

FYI this was found when I was testing Tao Xu's qemu implementation of HMAT ACPI-6.3 which has no implementation of  ACPI_HMAT_MEMORY_PD_VALID.

Current patch implementing Memory Proximity Domain Attributes Structure:
https://patchwork.kernel.org/patch/11125301/


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

* Re: [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3
  2019-09-03  1:03   ` Daniel Black
@ 2019-10-02  0:25     ` Daniel Black
  0 siblings, 0 replies; 6+ messages in thread
From: Daniel Black @ 2019-10-02  0:25 UTC (permalink / raw)
  To: Keith Busch
  Cc: Rafael J. Wysocki, Rafael J. Wysocki, Len Brown, open list:ACPI,
	open list, Tao Xu

On Tue, 3 Sep 2019 11:03:45 +1000
Daniel Black <daniel@linux.ibm.com> wrote:

> On Mon, 2 Sep 2019 23:28:50 +0200
> "Rafael J. Wysocki" <rafael@kernel.org> wrote:
> 
> > On Tue, Aug 6, 2019 at 6:24 AM Daniel Black <daniel@linux.ibm.com> wrote:  
> > >
> > > ACPI-6.3 corresponds to when hmat revision was bumped from
> > > 1 to 2. In this version ACPI_HMAT_MEMORY_PD_VALID was
> > > deprecated and made reserved.
> > >
> > > As such in revision 2+ we shouldn't be testing this flag.
> > >
> > > This is as per ACPI-6.3, 5.2.27.3, Table 5-145
> > > "Memory Proximity Domain Attributes Structure"
> > > for Flags.
> > >
> > > Signed-off-by: Daniel Black <daniel@linux.ibm.com>    
> > 
> > Keith, any comments?  
> 
> FYI this was found when I was testing Tao Xu's qemu implementation of HMAT ACPI-6.3 which has no implementation of  ACPI_HMAT_MEMORY_PD_VALID.
> 
> Current patch implementing Memory Proximity Domain Attributes Structure:
> https://patchwork.kernel.org/patch/11125301/


On Mon, 12 Aug 2019 16:03:15 +0800
Tao Xu <tao3.xu@intel.com> wrote:
> 
> Looks good to me.
> 
> Reviewed-by: Tao Xu <tao3.xu@intel.com>

Ping. Any comments?


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

* Re: [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3
  2019-08-06  4:24 [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3 Daniel Black
  2019-08-12  8:03 ` Tao Xu
  2019-09-02 21:28 ` Rafael J. Wysocki
@ 2019-10-10 22:20 ` Rafael J. Wysocki
  2 siblings, 0 replies; 6+ messages in thread
From: Rafael J. Wysocki @ 2019-10-10 22:20 UTC (permalink / raw)
  To: Daniel Black; +Cc: Len Brown, open list:ACPI, open list

On Tuesday, August 6, 2019 6:24:39 AM CEST Daniel Black wrote:
> ACPI-6.3 corresponds to when hmat revision was bumped from
> 1 to 2. In this version ACPI_HMAT_MEMORY_PD_VALID was
> deprecated and made reserved.
> 
> As such in revision 2+ we shouldn't be testing this flag.
> 
> This is as per ACPI-6.3, 5.2.27.3, Table 5-145
> "Memory Proximity Domain Attributes Structure"
> for Flags.
> 
> Signed-off-by: Daniel Black <daniel@linux.ibm.com>
> ---
>  drivers/acpi/hmat/hmat.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/acpi/hmat/hmat.c b/drivers/acpi/hmat/hmat.c
> index 96b7d39a97c6..e938e34673d9 100644
> --- a/drivers/acpi/hmat/hmat.c
> +++ b/drivers/acpi/hmat/hmat.c
> @@ -382,7 +382,7 @@ static int __init hmat_parse_proximity_domain(union acpi_subtable_headers *heade
>  		pr_info("HMAT: Memory Flags:%04x Processor Domain:%d Memory Domain:%d\n",
>  			p->flags, p->processor_PD, p->memory_PD);
>  
> -	if (p->flags & ACPI_HMAT_MEMORY_PD_VALID) {
> +	if (p->flags & ACPI_HMAT_MEMORY_PD_VALID && hmat_revision == 1) {
>  		target = find_mem_target(p->memory_PD);
>  		if (!target) {
>  			pr_debug("HMAT: Memory Domain missing from SRAT\n");
> 

Applied as a fix for 5.4, thanks!




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

end of thread, back to index

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-06  4:24 [PATCH] acpi/hmat: ACPI_HMAT_MEMORY_PD_VALID is deprecated in ACPI-6.3 Daniel Black
2019-08-12  8:03 ` Tao Xu
2019-09-02 21:28 ` Rafael J. Wysocki
2019-09-03  1:03   ` Daniel Black
2019-10-02  0:25     ` Daniel Black
2019-10-10 22:20 ` Rafael J. Wysocki

LKML Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/lkml/0 lkml/git/0.git
	git clone --mirror https://lore.kernel.org/lkml/1 lkml/git/1.git
	git clone --mirror https://lore.kernel.org/lkml/2 lkml/git/2.git
	git clone --mirror https://lore.kernel.org/lkml/3 lkml/git/3.git
	git clone --mirror https://lore.kernel.org/lkml/4 lkml/git/4.git
	git clone --mirror https://lore.kernel.org/lkml/5 lkml/git/5.git
	git clone --mirror https://lore.kernel.org/lkml/6 lkml/git/6.git
	git clone --mirror https://lore.kernel.org/lkml/7 lkml/git/7.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 lkml lkml/ https://lore.kernel.org/lkml \
		linux-kernel@vger.kernel.org linux-kernel@archiver.kernel.org
	public-inbox-index lkml

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-kernel


AGPL code for this site: git clone https://public-inbox.org/ public-inbox