* [PATCH 1/1] acpi: Add missing RISC-V acpi_table header
@ 2023-07-25 1:23 Heinrich Schuchardt
2023-07-25 2:26 ` Bin Meng
0 siblings, 1 reply; 4+ messages in thread
From: Heinrich Schuchardt @ 2023-07-25 1:23 UTC (permalink / raw)
To: Rick Chen, Leo; +Cc: u-boot, Heinrich Schuchardt
The pci_mmc.c driver can generate ACPI info and therefore includes
asm/acpi_table.h. This file does not exist for the RISC-V architecture
and thus code compilation fails when using this driver on RISC-V
Create an empty include file.
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
---
arch/riscv/include/asm/acpi_table.h | 0
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 arch/riscv/include/asm/acpi_table.h
diff --git a/arch/riscv/include/asm/acpi_table.h b/arch/riscv/include/asm/acpi_table.h
new file mode 100644
index 0000000000..e69de29bb2
--
2.40.1
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] acpi: Add missing RISC-V acpi_table header
2023-07-25 1:23 [PATCH 1/1] acpi: Add missing RISC-V acpi_table header Heinrich Schuchardt
@ 2023-07-25 2:26 ` Bin Meng
2023-07-25 7:44 ` Heinrich Schuchardt
0 siblings, 1 reply; 4+ messages in thread
From: Bin Meng @ 2023-07-25 2:26 UTC (permalink / raw)
To: Heinrich Schuchardt, Simon Glass; +Cc: Rick Chen, Leo, u-boot
+Simon,
On Tue, Jul 25, 2023 at 9:30 AM Heinrich Schuchardt
<heinrich.schuchardt@canonical.com> wrote:
>
> The pci_mmc.c driver can generate ACPI info and therefore includes
> asm/acpi_table.h. This file does not exist for the RISC-V architecture
> and thus code compilation fails when using this driver on RISC-V
Which header file includes the <asm/acpi_table.h> in pci_mmc.c?
I feel like we should fix the header file dependency of the driver,
not by adding a dummy file for random architecture.
>
> Create an empty include file.
>
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
> ---
> arch/riscv/include/asm/acpi_table.h | 0
> 1 file changed, 0 insertions(+), 0 deletions(-)
> create mode 100644 arch/riscv/include/asm/acpi_table.h
>
> diff --git a/arch/riscv/include/asm/acpi_table.h b/arch/riscv/include/asm/acpi_table.h
> new file mode 100644
> index 0000000000..e69de29bb2
> --
Regards,
Bin
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] acpi: Add missing RISC-V acpi_table header
2023-07-25 2:26 ` Bin Meng
@ 2023-07-25 7:44 ` Heinrich Schuchardt
2023-07-26 3:11 ` Leo Liang
0 siblings, 1 reply; 4+ messages in thread
From: Heinrich Schuchardt @ 2023-07-25 7:44 UTC (permalink / raw)
To: Bin Meng; +Cc: Rick Chen, Leo, u-boot, Simon Glass
On 7/25/23 04:26, Bin Meng wrote:
> +Simon,
>
> On Tue, Jul 25, 2023 at 9:30 AM Heinrich Schuchardt
> <heinrich.schuchardt@canonical.com> wrote:
>>
>> The pci_mmc.c driver can generate ACPI info and therefore includes
>> asm/acpi_table.h. This file does not exist for the RISC-V architecture
>> and thus code compilation fails when using this driver on RISC-V
>
> Which header file includes the <asm/acpi_table.h> in pci_mmc.c?
>
> I feel like we should fix the header file dependency of the driver,
> not by adding a dummy file for random architecture.
The error is:
In file included from include/acpi/acpigen.h:13,
from drivers/mmc/pci_mmc.c:15:
include/acpi/acpi_table.h:936:10: fatal error: asm/acpi_table.h: No such
file or directory
936 | #include <asm/acpi_table.h>
| ^~~~~~~~~~~~~~~~~~
Currently we have:
./arch/x86/include/asm/acpi_table.h
./arch/arm/include/asm/acpi_table.h
./arch/sandbox/include/asm/acpi_table.h
Only arch/x86/include/asm/acpi_table.h has content.
The RISC-V architecture in general supports ACPI but has some
requirements that are different to x86.
So I think we will end up with a arch/riscv/include/asm/acpi_table.h
anyway in the future.
Best regards
Heinrich
>
>>
>> Create an empty include file.
>>
>> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
>> ---
>> arch/riscv/include/asm/acpi_table.h | 0
>> 1 file changed, 0 insertions(+), 0 deletions(-)
>> create mode 100644 arch/riscv/include/asm/acpi_table.h
>>
>> diff --git a/arch/riscv/include/asm/acpi_table.h b/arch/riscv/include/asm/acpi_table.h
>> new file mode 100644
>> index 0000000000..e69de29bb2
>> --
>
> Regards,
> Bin
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] acpi: Add missing RISC-V acpi_table header
2023-07-25 7:44 ` Heinrich Schuchardt
@ 2023-07-26 3:11 ` Leo Liang
0 siblings, 0 replies; 4+ messages in thread
From: Leo Liang @ 2023-07-26 3:11 UTC (permalink / raw)
To: Heinrich Schuchardt; +Cc: Bin Meng, Rick Chen, u-boot, Simon Glass
Hi Heinrich,
On Tue, Jul 25, 2023 at 09:44:00AM +0200, Heinrich Schuchardt wrote:
> On 7/25/23 04:26, Bin Meng wrote:
> > +Simon,
> >
> > On Tue, Jul 25, 2023 at 9:30 AM Heinrich Schuchardt
> > <heinrich.schuchardt@canonical.com> wrote:
> > >
> > > The pci_mmc.c driver can generate ACPI info and therefore includes
> > > asm/acpi_table.h. This file does not exist for the RISC-V architecture
> > > and thus code compilation fails when using this driver on RISC-V
> >
> > Which header file includes the <asm/acpi_table.h> in pci_mmc.c?
> >
> > I feel like we should fix the header file dependency of the driver,
> > not by adding a dummy file for random architecture.
>
> The error is:
>
> In file included from include/acpi/acpigen.h:13,
> from drivers/mmc/pci_mmc.c:15:
> include/acpi/acpi_table.h:936:10: fatal error: asm/acpi_table.h: No such
> file or directory
> 936 | #include <asm/acpi_table.h>
> | ^~~~~~~~~~~~~~~~~~
>
> Currently we have:
>
> ./arch/x86/include/asm/acpi_table.h
> ./arch/arm/include/asm/acpi_table.h
> ./arch/sandbox/include/asm/acpi_table.h
>
> Only arch/x86/include/asm/acpi_table.h has content.
>
> The RISC-V architecture in general supports ACPI but has some requirements
> that are different to x86.
>
> So I think we will end up with a arch/riscv/include/asm/acpi_table.h anyway
> in the future.
>
LGTM!
But could we also add something like what is in ./arch/sandbox/include/asm/acpi_table.h
instead of just an empty file ?
Best regards,
Leo
> Best regards
>
> Heinrich
>
> >
> > >
> > > Create an empty include file.
> > >
> > > Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
> > > ---
> > > arch/riscv/include/asm/acpi_table.h | 0
> > > 1 file changed, 0 insertions(+), 0 deletions(-)
> > > create mode 100644 arch/riscv/include/asm/acpi_table.h
> > >
> > > diff --git a/arch/riscv/include/asm/acpi_table.h b/arch/riscv/include/asm/acpi_table.h
> > > new file mode 100644
> > > index 0000000000..e69de29bb2
> > > --
> >
> > Regards,
> > Bin
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-07-26 3:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-25 1:23 [PATCH 1/1] acpi: Add missing RISC-V acpi_table header Heinrich Schuchardt
2023-07-25 2:26 ` Bin Meng
2023-07-25 7:44 ` Heinrich Schuchardt
2023-07-26 3:11 ` Leo Liang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox