Enable ACPI_ADR_SPACE_PCI_CONFIG in acpi_gbl_default_address_spaces only when ACPI_PCI_CONFIGURED is defined
Subsystems (2)
PATCH 1/1 Enable ACPI_ADR_SPACE_PCI_CONFIG in acpi_gbl_default_address_spaces only when ACPI_PCI_CONFIGURED is defined
--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)
drivers/acpi/acpica/evhandler.c +2 -0
@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };
include/acpi/acconfig.h +4 -0
@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */
Signature · 1 line
2.24.3 (Apple Git-128)
Rafael J. Wysocki
maintainerQuoted 3 lines · Weidong Cui
Signed-off-by Weidong Cui <weidongcui(a)gmail.com>Signed-off-by Xinyang Ge <aegiryy(a)gmail.com>
ACPICA material, left to Erik & Bob, thanks!
Quoted 38 lines
--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h +4
-1@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
A message that is not in the archive (sent off-list or not yet received): CADFYyO63S4xZHJh9Cw1NYa7W=D8h=ZtUG1qPeLxfQ88kvW7MRQ@mail.gmail.com
A message that is not in the archive (sent off-list or not yet received): MWHPR11MB159925DE73F89A71D5E67113F0859@MWHPR11MB1599.namprd11.prod.outlook.com
Quoted 1 line
Hi, I’ll take a look next week.. Sorry about the delay
Hi Erik,
I would like to gently ping you about this patch. Please let us know if you have any questions.
Thanks!
Weidong
Quoted 66 lines
From: Weidong Cui <[email protected]>
Sent: Wednesday, February 17, 2021 6:55 PM
To: Rafael J. Wysocki <[email protected]>
Cc: Moore, Robert <[email protected]>; Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Len Brown <[email protected]>; Xinyang Ge <[email protected]>; ACPI Devel Maling List <[email protected]>; open list:ACPI COMPONENT ARCHITECTURE (ACPICA) <[email protected]>; Linux Kernel Mailing List <[email protected]>
Subject: Re: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedErik and Bob, please let us know if you have any questions or comments.
Thanks,
Weidong
On Tue, Feb 9, 2021 at 6:35 AM Rafael J. Wysocki <[email protected]> wrote:
Quoted 3 lines · Weidong Cui
Signed-off-by Weidong Cui <[email protected]>Signed-off-by Xinyang Ge <[email protected]>ACPICA material, left to Erik & Bob, thanks!
Quoted 38 lines
--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h +4
-1@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
This looks good to me. Bob, do you have any comments?
Erik
Quoted 52 lines
-----Original Message-----
From: Weidong Cui <[email protected]>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <[email protected]>; Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Len Brown <[email protected]>
Cc: Weidong Cui <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; linux- [email protected]
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <[email protected]>Signed-off-by Xinyang Ge <[email protected]>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h +4
-1@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
Well, I don't like the fact that PCI_CONFIGURED would have to be defined by each current host:
Quoted 1 line
+#ifdef
ACPI_PCI_CONFIGURED
I would rather the logic be reversed:
Quoted 1 line
+#ifdef
ACPI_PCI_NOT_CONFIGURED
-----Original Message-----
From: Kaneda, Erik <erik.kaneda(a)intel.com>
Sent: Wednesday, March 03, 2021 10:29 AM
To: Weidong Cui <weidongcui(a)gmail.com>; Moore, Robert <robert.moore(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>
Cc: Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux-kernel(a)vger.kernel.org; Len Brown <lenb(a)kernel.org>
Subject: RE: [PATCH] Enable ACPI_ADR_SPACE_PCI_CONFIG in acpi_gbl_default_address_spaces only when ACPI_PCI_CONFIGURED is defined
This looks good to me. Bob, do you have any comments?
Erik
Quoted 52 lines
-----Original Message-----
From: Weidong Cui <weidongcui(a)gmail.com>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <robert.moore(a)intel.com>; Kaneda, Erik <erik.kaneda(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>; Len Brown <lenb(a)kernel.org>
Cc: Weidong Cui <weidongcui(a)gmail.com>; Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux- kernel(a)vger.kernel.org
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <weidongcui(a)gmail.com>Signed-off-by Xinyang Ge <aegiryy(a)gmail.com>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)(quoted diff) +0
-0
b/drivers/acpi/acpica/evhandler.cindex5884eba04..4c25ad433100644drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h index renamed from include/acpi/acconfig.h +0
-0a225eff49..790999028 100644
include/acpi/acconfig.h +4
-1@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
Quoted 7 lines
Well, I don't like the fact that
PCI_CONFIGUREDwould have to be defined by each current host:Quoted 1 line
+#ifdef
ACPI_PCI_CONFIGUREDI would rather the logic be reversed:
Quoted 1 line
+#ifdef
ACPI_PCI_NOT_CONFIGURED
Thank you for the comments, Erik and Bob!
ACPI_PCI_CONFIGURED is defined in aclinux.h (see below) and used in several places in evhandler.c and exregion.c.
I'm not sure why we want to introduce ACPI_PCI_NOT_CONFIGURED. Bob, I don't understand your concerns
about "have to be defined by each current host". Can you please shed some light on it?
#ifdef CONFIG_PCI
#define ACPI_PCI_CONFIGURED
#endif
Quoted 64 lines
-----Original Message-----
From: Kaneda, Erik <[email protected]>
Sent: Wednesday, March 03, 2021 10:29 AM
To: Weidong Cui <[email protected]>; Moore, Robert <[email protected]>; Wysocki, Rafael J <[email protected]>
Cc: Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]; Len Brown <[email protected]>
Subject: RE: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedThis looks good to me. Bob, do you have any comments?
Erik
Quoted 52 lines
-----Original Message-----
From: Weidong Cui <[email protected]>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <[email protected]>; Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Len Brown <[email protected]>
Cc: Weidong Cui <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; linux- [email protected]
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <[email protected]>Signed-off-by Xinyang Ge <[email protected]>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)(quoted diff) +0
-0
b/drivers/acpi/acpica/evhandler.cindex5884eba04..4c25ad433100644drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h index renamed from include/acpi/acconfig.h +0
-0a225eff49..790999028 100644
include/acpi/acconfig.h +4
-1@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
-----Original Message-----
From: Weidong Cui <weidongcui(a)gmail.com>
Sent: Thursday, March 04, 2021 9:06 AM
To: Moore, Robert <robert.moore(a)intel.com>
Cc: Kaneda, Erik <erik.kaneda(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>; Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux-kernel(a)vger.kernel.org; Len Brown <lenb(a)kernel.org>
Subject: Re: [PATCH] Enable ACPI_ADR_SPACE_PCI_CONFIG in acpi_gbl_default_address_spaces only when ACPI_PCI_CONFIGURED is defined
Quoted 7 lines
Well, I don't like the fact that
PCI_CONFIGUREDwould have to be defined by each current host:Quoted 1 line
+#ifdef
ACPI_PCI_CONFIGUREDI would rather the logic be reversed:
Quoted 1 line
+#ifdef
ACPI_PCI_NOT_CONFIGURED
Thank you for the comments, Erik and Bob!
ACPI_PCI_CONFIGURED is defined in aclinux.h (see below) and used in several places in evhandler.c and exregion.c.
I'm not sure why we want to introduce ACPI_PCI_NOT_CONFIGURED. Bob, I don't understand your concerns about "have to be defined by each current host". Can you please shed some light on it?
It is required in aclinux.h, and thus it is required in every host-dependent configuration file (acfreebsd.h, acmacosx.h, acnetbsd.h, achaiku.h, etc.) I would rather not force these host-specific header files to change. Bob
#ifdef CONFIG_PCI
#define ACPI_PCI_CONFIGURED
#endif
Quoted 70 lines
-----Original Message-----
From: Kaneda, Erik <erik.kaneda(a)intel.com>
Sent: Wednesday, March 03, 2021 10:29 AM
To: Weidong Cui <weidongcui(a)gmail.com>; Moore, Robert <robert.moore(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>
Cc: Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux-kernel(a)vger.kernel.org; Len Brown <lenb(a)kernel.org>
Subject: RE: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedThis looks good to me. Bob, do you have any comments?
Erik
Quoted 52 lines
-----Original Message-----
From: Weidong Cui <weidongcui(a)gmail.com>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <robert.moore(a)intel.com>; Kaneda, Erik <erik.kaneda(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>; Len Brown <lenb(a)kernel.org>
Cc: Weidong Cui <weidongcui(a)gmail.com>; Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux- kernel(a)vger.kernel.org
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <weidongcui(a)gmail.com>Signed-off-by Xinyang Ge <aegiryy(a)gmail.com>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)(quoted diff) +0
-0
b/drivers/acpi/acpica/evhandler.cindex5884eba04..4c25ad433100644drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h index renamed from include/acpi/acconfig.h +0
-0a225eff49..790999028 100644
include/acpi/acconfig.h +4
-1@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
Quoted 2 lines · Robert
It is required in
aclinux.h, and thus it is required in every host-dependent configuration file (acfreebsd.h,acmacosx.h,acnetbsd.h,achaiku.h, etc.) I would rather not force these host-specific header files to change. Bob
Hi Bob,
I don't know the reason for ACPI_PCI_CONFIGURED to be introduced into aclinux.h. That patch introduced the bug I'm trying to fix: if CONFIG_PCI is not enabled, the kernel will crash. Would it be okay to accept this patch first to fix this kernel crash bug? We can come up a plan to fix this host-dependent configuration issue in a separate patch. What do you think?
@Erik, I would love to hear your thoughts on this.
Thank you!
Weidong
Quoted 70 lines
Quoted 70 lines
-----Original Message-----
From: Kaneda, Erik <[email protected]>
Sent: Wednesday, March 03, 2021 10:29 AM
To: Weidong Cui <[email protected]>; Moore, Robert <[email protected]>; Wysocki, Rafael J <[email protected]>
Cc: Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]; Len Brown <[email protected]>
Subject: RE: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedThis looks good to me. Bob, do you have any comments?
Erik
Quoted 52 lines
-----Original Message-----
From: Weidong Cui <[email protected]>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <[email protected]>; Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Len Brown <[email protected]>
Cc: Weidong Cui <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; linux- [email protected]
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <[email protected]>Signed-off-by Xinyang Ge <[email protected]>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)(quoted diff) +0
-0
b/drivers/acpi/acpica/evhandler.cindex5884eba04..4c25ad433100644drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h index renamed from include/acpi/acconfig.h +0
-0a225eff49..790999028 100644
include/acpi/acconfig.h +4
-1@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif /* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
After giving this some thought, I think we can #define ACPI_PCI_CONFIGURED in the global configuration file (I think it is acconfig.h) - and document why and when it should be removed. Bob
-----Original Message-----
From: Moore, Robert <robert.moore(a)intel.com>
Sent: Thursday, March 04, 2021 9:37 AM
To: weidongcui(a)gmail.com
Cc: Kaneda, Erik <erik.kaneda(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>; Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux-kernel(a)vger.kernel.org
Subject: [Devel] Re: [PATCH] Enable ACPI_ADR_SPACE_PCI_CONFIG in acpi_gbl_default_address_spaces only when ACPI_PCI_CONFIGURED is defined
-----Original Message-----
From: Weidong Cui <weidongcui(a)gmail.com>
Sent: Thursday, March 04, 2021 9:06 AM
To: Moore, Robert <robert.moore(a)intel.com>
Cc: Kaneda, Erik <erik.kaneda(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>; Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux-kernel(a)vger.kernel.org; Len Brown <lenb(a)kernel.org>
Subject: Re: [PATCH] Enable ACPI_ADR_SPACE_PCI_CONFIG in acpi_gbl_default_address_spaces only when ACPI_PCI_CONFIGURED is defined
Quoted 7 lines
Well, I don't like the fact that
PCI_CONFIGUREDwould have to be defined by each current host:Quoted 1 line
+#ifdef
ACPI_PCI_CONFIGUREDI would rather the logic be reversed:
Quoted 1 line
+#ifdef
ACPI_PCI_NOT_CONFIGURED
Thank you for the comments, Erik and Bob!
ACPI_PCI_CONFIGURED is defined in aclinux.h (see below) and used in several places in evhandler.c and exregion.c.
I'm not sure why we want to introduce ACPI_PCI_NOT_CONFIGURED. Bob, I don't understand your concerns about "have to be defined by each current host". Can you please shed some light on it?
It is required in aclinux.h, and thus it is required in every host-dependent configuration file (acfreebsd.h, acmacosx.h, acnetbsd.h, achaiku.h, etc.) I would rather not force these host-specific header files to change. Bob
#ifdef CONFIG_PCI
#define ACPI_PCI_CONFIGURED
#endif
Quoted 65 lines
-----Original Message-----
From: Kaneda, Erik <erik.kaneda(a)intel.com>
Sent: Wednesday, March 03, 2021 10:29 AM
To: Weidong Cui <weidongcui(a)gmail.com>; Moore, Robert <robert.moore(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>
Cc: Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux-kernel(a)vger.kernel.org; Len Brown <lenb(a)kernel.org>
Subject: RE: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedThis looks good to me. Bob, do you have any comments?
Erik
Quoted 48 lines
-----Original Message-----
From: Weidong Cui <weidongcui(a)gmail.com>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <robert.moore(a)intel.com>; Kaneda, Erik <erik.kaneda(a)intel.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>; Len Brown <lenb(a)kernel.org>
Cc: Weidong Cui <weidongcui(a)gmail.com>; Xinyang Ge <aegiryy(a)gmail.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org; linux- kernel(a)vger.kernel.org
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <weidongcui(a)gmail.com>Signed-off-by Xinyang Ge <aegiryy(a)gmail.com>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)(quoted diff) +0
-0
b/drivers/acpi/acpica/evhandler.cindex5884eba04..4c25ad433100644drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h index renamed from include/acpi/acconfig.h +0
-0a225eff49..790999028 100644
include/acpi/acconfig.h +4
-0@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif
Quoted 5 lines
Quoted 4 lines
include/acpi/acconfig.h +0
-1/* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
_______________________________________________
Devel mailing list -- devel(a)acpica.org
To unsubscribe send an email to devel-leave(a)acpica.org %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
Quoted 3 lines · Robert
After giving this some thought, I think we can #define
ACPI_PCI_CONFIGUREDin the global configuration file (I think it isacconfig.h) - and document why and when it should be removed. Bob
Hi Bob,
Thank you very much for your new suggestion! Let me make sure I understand it.
1. We should move the following define from aclinux.h to acconfig.h.
#ifdef CONFIG_PCI
#define ACPI_PCI_CONFIGURED
#endif
2. We should add a comment there to "document why and when it should be removed".
I don't really know "why and when" since I'm not an expert on ACPI (we were just trying
to fix a bug :-)).
Thanks!
Weidong
Quoted 110 lines
-----Original Message-----
From: Moore, Robert <[email protected]>
Sent: Thursday, March 04, 2021 9:37 AM
To: [email protected]
Cc: Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]
Subject: [Devel] Re: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis defined-----Original Message-----
From: Weidong Cui <[email protected]>
Sent: Thursday, March 04, 2021 9:06 AM
To: Moore, Robert <[email protected]>
Cc: Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]; Len Brown <[email protected]>
Subject: Re: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedQuoted 7 lines
Well, I don't like the fact that
PCI_CONFIGUREDwould have to be defined by each current host:Quoted 1 line
+#ifdef
ACPI_PCI_CONFIGUREDI would rather the logic be reversed:
Quoted 1 line
+#ifdef
ACPI_PCI_NOT_CONFIGUREDThank you for the comments, Erik and Bob!
ACPI_PCI_CONFIGUREDis defined inaclinux.h(see below) and used in several places inevhandler.candexregion.c.
I'm not sure why we want to introduceACPI_PCI_NOT_CONFIGURED. Bob, I don't understand your concerns about "have to be defined by each current host". Can you please shed some light on it?It is required in
aclinux.h, and thus it is required in every host-dependent configuration file (acfreebsd.h,acmacosx.h,acnetbsd.h,achaiku.h, etc.) I would rather not force these host-specific header files to change. Bob#ifdef
CONFIG_PCI
#defineACPI_PCI_CONFIGURED
#endifQuoted 65 lines
-----Original Message-----
From: Kaneda, Erik <[email protected]>
Sent: Wednesday, March 03, 2021 10:29 AM
To: Weidong Cui <[email protected]>; Moore, Robert <[email protected]>; Wysocki, Rafael J <[email protected]>
Cc: Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]; Len Brown <[email protected]>
Subject: RE: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedThis looks good to me. Bob, do you have any comments?
Erik
Quoted 48 lines
-----Original Message-----
From: Weidong Cui <[email protected]>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <[email protected]>; Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Len Brown <[email protected]>
Cc: Weidong Cui <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; linux- [email protected]
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <[email protected]>Signed-off-by Xinyang Ge <[email protected]>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)(quoted diff) +0
-0
b/drivers/acpi/acpica/evhandler.cindex5884eba04..4c25ad433100644drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h index renamed from include/acpi/acconfig.h +0
-0a225eff49..790999028 100644
include/acpi/acconfig.h +4
-0@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif Quoted 5 lines
Quoted 4 lines
include/acpi/acconfig.h +0
-1/* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
_______________________________________________
Devel mailing list -- [email protected]
To unsubscribe send an email to [email protected] %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
Hi Bob and Erik,
Quoted 10 lines
Hi Bob,
Thank you very much for your new suggestion! Let me make sure I understand it.
1. We should move the following define from
aclinux.htoacconfig.h.#ifdef
CONFIG_PCI
#defineACPI_PCI_CONFIGURED
#endif
Quoted 8 lines
2. We should add a comment there to "document why and when it should be removed".
I don't really know "why and when" since I'm not an expert on ACPI (we were just trying
to fix a bug :-)).Thanks!
Weidong
Hi Bob and Erik,
I would like to ping you about my two questions above. Can you please advise on how I should proceed?
Thanks!
Weidong
Quoted 111 lines
Quoted 111 lines
-----Original Message-----
From: Moore, Robert <[email protected]>
Sent: Thursday, March 04, 2021 9:37 AM
To: [email protected]
Cc: Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]
Subject: [Devel] Re: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis defined-----Original Message-----
From: Weidong Cui <[email protected]>
Sent: Thursday, March 04, 2021 9:06 AM
To: Moore, Robert <[email protected]>
Cc: Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]; Len Brown <[email protected]>
Subject: Re: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedQuoted 7 lines
Well, I don't like the fact that
PCI_CONFIGUREDwould have to be defined by each current host:Quoted 1 line
+#ifdef
ACPI_PCI_CONFIGUREDI would rather the logic be reversed:
Quoted 1 line
+#ifdef
ACPI_PCI_NOT_CONFIGUREDThank you for the comments, Erik and Bob!
ACPI_PCI_CONFIGUREDis defined inaclinux.h(see below) and used in several places inevhandler.candexregion.c.
I'm not sure why we want to introduceACPI_PCI_NOT_CONFIGURED. Bob, I don't understand your concerns about "have to be defined by each current host". Can you please shed some light on it?It is required in
aclinux.h, and thus it is required in every host-dependent configuration file (acfreebsd.h,acmacosx.h,acnetbsd.h,achaiku.h, etc.) I would rather not force these host-specific header files to change. Bob#ifdef
CONFIG_PCI
#defineACPI_PCI_CONFIGURED
#endifQuoted 65 lines
-----Original Message-----
From: Kaneda, Erik <[email protected]>
Sent: Wednesday, March 03, 2021 10:29 AM
To: Weidong Cui <[email protected]>; Moore, Robert <[email protected]>; Wysocki, Rafael J <[email protected]>
Cc: Xinyang Ge <[email protected]>; [email protected]; [email protected]; [email protected]; Len Brown <[email protected]>
Subject: RE: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedThis looks good to me. Bob, do you have any comments?
Erik
Quoted 48 lines
-----Original Message-----
From: Weidong Cui <[email protected]>
Sent: Monday, February 8, 2021 7:18 PM
To: Moore, Robert <[email protected]>; Kaneda, Erik <[email protected]>; Wysocki, Rafael J <[email protected]>; Len Brown <[email protected]>
Cc: Weidong Cui <[email protected]>; Xinyang Ge <[email protected]>; [email protected]; [email protected]; linux- [email protected]
Subject: [PATCH] EnableACPI_ADR_SPACE_PCI_CONFIGinacpi_gbl_default_address_spacesonly whenACPI_PCI_CONFIGUREDis definedSigned-off-by Weidong Cui <[email protected]>Signed-off-by Xinyang Ge <[email protected]>--- drivers/acpi/acpica/evhandler.c | 2 ++ include/acpi/acconfig.h | 4 ++++ 2 files changed, 6 insertions(+)(quoted diff) +0
-0
b/drivers/acpi/acpica/evhandler.cindex5884eba04..4c25ad433100644drivers/acpi/acpica/evhandler.c +2
-0@@ -26,7 +26,9 @@ acpi_ev_install_handler(acpi_handle obj_handle,u8 acpi_gbl_default_address_spaces[ACPI_NUM_DEFAULT_SPACES ] = {ACPI_ADR_SPACE_SYSTEM_MEMORY ,ACPI_ADR_SPACE_SYSTEM_IO , +#ifdef ACPI_PCI_CONFIGUREDACPI_ADR_SPACE_PCI_CONFIG , +#endifACPI_ADR_SPACE_DATA_TABLE };include/acpi/acconfig.h index renamed from include/acpi/acconfig.h +0
-0a225eff49..790999028 100644
include/acpi/acconfig.h +4
-0@@ -162,7 +162,11 @@/* Maximum space_ids for Operation Regions */ #define ACPI_MAX_ADDRESS_SPACE 255 +#ifdef ACPI_PCI_CONFIGURED #define ACPI_NUM_DEFAULT_SPACES 4 +#else +#define ACPI_NUM_DEFAULT_SPACES 3 +#endif Quoted 5 lines
Quoted 4 lines
include/acpi/acconfig.h +0
-1/* Array sizes. Used for range checking also */ --2.24.3 (Apple Git-128)
_______________________________________________
Devel mailing list -- [email protected]
To unsubscribe send an email to [email protected] %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s