public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Introduce userspace interface for Firmware-provided memory map
@ 2008-06-20 15:56 Bernhard Walle
  2008-06-20 15:56 ` [PATCH 1/3] Introduce /proc/firmware_mem Bernhard Walle
                   ` (4 more replies)
  0 siblings, 5 replies; 16+ messages in thread
From: Bernhard Walle @ 2008-06-20 15:56 UTC (permalink / raw)
  To: kexec; +Cc: x86, linux-kernel, vgoyal, Bernhard Walle

This patch (as request for comments) introduces a new userspace interface
/proc/firmware_mem that provides the unfiltered view of the BIOS on
memory configuration. That's usable for two reasons:

 1) Debugging (yes, the E820 memory is printed in kernel ring buffer, but that's
    not the case for all platforms, on IA64 you have to enable some magic define
    to print the EFI memory map, for example),
 
 2) Kexec. When the user or the system uses a special command line to modify the
    memory configuration, kexec still needs a method to get the original memory
    map.  While the filtered view is useful for generating ELF core headers for
    crashdumps, the unfiltered view is necessary to boot the next kernel without
    the "limitations" the original kernel has.

We had the discussion to add iomem_used on kexec mailing list. However, I think
it's better to let /proc/iomem represent the *filtered* (i.e. "used") view of
the I/O resources and introduce a new interface for the *unfiltered* view.
There are two reasons:

 1) On i386 (the oldest architectures), /proc/iomem always represented the
    *filtered* view (i.e. "mem" parameter was also visible in /proc/iomem).
    I think we should not change the semantics of an interface without a reason.
 
 2) /proc/iomem_used would it make necessary to duplicate all registration between
    /proc/iomem and /proc/iomem_used. Because currently the resource root
    is exported and used everywhere in the kernel source, that would make
    changes of the whole resource infrastructure necessary if code duplication
    should be avoided.

Maybe you think that /proc/firmware_mem is not the right place to export that.
I don't know, I also don't care that much about the naming or the way to export
that. So, please advise me if you agree that it's ok for kexec to export an
unfiltered view of the memory map.

The patch has been tested on i386 and x86_64.



Signed-off-by: Bernhard Walle <bwalle@suse.de>




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

end of thread, other threads:[~2008-06-26  8:21 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-20 15:56 Introduce userspace interface for Firmware-provided memory map Bernhard Walle
2008-06-20 15:56 ` [PATCH 1/3] Introduce /proc/firmware_mem Bernhard Walle
2008-06-20 15:56 ` [PATCH 2/3] Use /proc/firmware_mem for x86 (e820) Bernhard Walle
2008-06-24 18:28   ` Pavel Machek
2008-06-26  8:21     ` Bernhard Walle
2008-06-20 15:57 ` [PATCH 3/3] Limit E820 map when a user-defined memory map is specified Bernhard Walle
2008-06-20 19:45   ` Vivek Goyal
2008-06-20 20:34   ` Yinghai Lu
2008-06-22 19:46     ` Bernhard Walle
2008-06-22 19:56     ` Bernhard Walle
2008-06-22 20:11       ` Yinghai Lu
2008-06-24 14:07         ` Bernhard Walle
2008-06-20 15:58 ` Introduce userspace interface for Firmware-provided memory map Bernhard Walle
2008-06-20 19:42 ` Vivek Goyal
2008-06-20 20:35   ` H. Peter Anvin
2008-06-22 19:59     ` Bernhard Walle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox