lkml.org 
[lkml]   [2017]   [Dec]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 2/3] x86/acpi: take rsdp address for boot params if available

* Juergen Gross <jgross@suse.com> wrote:

> On 08/12/17 08:05, Ingo Molnar wrote:
> >
> > * Juergen Gross <jgross@suse.com> wrote:
>
> ...
>
> > acpi_physical_address acpi_arch_get_root_pointer(void)
> > {
> > return boot_params.hdr.acpi_rsdp_addr;
> > }
> >
> > 4)
> >
> > Add this to arch/x86/include/asm/acpi.h:
> >
> > extern acpi_physical_address acpi_arch_get_root_pointer(void);
>
> Uuh, this leads to problems for files including <asm/acpi.h> directly:
> acpi_physical_address won't be defined, and including <acpi/actypes.h>
> from arch/x86/include/asm/acpi.h will lead to:
>
> #error unknown ACPI_MACHINE_WIDTH
>
> This can only be avoided by including <linux/acpi.h> from <asm/acpi.h>
> which seems to be the wrong layering.
>
> So I could:
>
> a) modify the sources including <asm/acpi.h> to use <linux/acpi.h>
> instead
> b) don't use acpi_physical_address but either u64 or unsigned long.
> c) ?
>
> What would be your preference?

Would it help if you put the prototype into linux/acpi.h perhaps? It's a generic
facility in principle, even if only used by x86 at the moment.

Thanks,

Ingo

\
 
 \ /
  Last update: 2017-12-08 12:27    [W:0.267 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site