Skip to content

Remove unused /dev/oldmem interface

Zhang Yanfei kexec lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest7 patches 9 repliesIn review
  2. v17 patches 13 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7/dev/oldmem: Remove the interfacedrivers/char/mem.c+0 -470 replies
2/7Documentation/devices.txt: Mark /dev/oldmem obsoleteDocumentation/devices.txt+1 -29 replies
3/7Documentation/kdump/kdump.txt: Remove /dev/oldmem descriptionDocumentation/kdump/kdump.txt+6 -250 replies
4/7mips: Remove savemaxmem parameter setuparch/mips/kernel/crash_dump.c+0 -100 replies
5/7powerpc: Remove savemaxmem parameter setuparch/powerpc/kernel/crash_dump.c+0 -100 replies
6/7ia64: Remove setting for saved_max_pfnarch/ia64/kernel/efi.c+0 -50 replies
7/7s390: Remove setting for saved_max_pfnarch/s390/kernel/setup.c+0 -40 replies

Reviews trailers per patch

6 of 7 patches have a Reviewed-by or Acked-by.

PatchEric W. Biederman
1/7A-b
2/7
3/7A-b
4/7A-b
5/7A-b
6/7A-b
7/7A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/7] Remove unused /dev/oldmem interface

/dev/oldmem provides the interface for us to access the "old memory" in the dump-capture kernel. Unfortunately, no one actually uses this interface.

And this interface could actually cause some real problems if used on ia64 where the cached/uncached accesses are mixed. See the discussion from the link: https://lkml.org/lkml/2013/4/12/386.

So Eric suggested that we should remove /dev/oldmem as an unused piece of code.

Besides, we used a global variable saved_max_pfn to let the capture kernel know the amount of memory that the previous kernel used. And for almost all architectures (except x86. In x86, saved_max_pfn is used by detect_calgary()), the only user of this variable is the read_oldmem interface of /dev/oldmem, so also remove the setting for saved_max_pfn in those architectures.

-v2:
Keep /dev/oldmem and its number 12 in case this number will get reused in the future. And mark it obsolete since /dev/oldmem will be removed from kernel.

Zhang Yanfei (7):
/dev/oldmem: Remove this interface Documentation/devices.txt: Mark /dev/oldmem obsolete Documentation/kdump/kdump.txt: Remove /dev/oldmem description
mips: Remove savemaxmem parameter setup
powerpc: Remove savemaxmem parameter setup
ia64: Remove setting for saved_max_pfn
s390: Remove setting for saved_max_pfn

 Documentation/devices.txt        |    3 +-
 Documentation/kdump/kdump.txt    |   31 +++++--------------------
 arch/ia64/kernel/efi.c           |    5 ----
 arch/mips/kernel/crash_dump.c    |   10 --------
 arch/powerpc/kernel/crash_dump.c |   10 --------
 arch/s390/kernel/setup.c         |    4 ---
 drivers/char/mem.c               |   47 --------------------------------------
 7 files changed, 7 insertions(+), 103 deletions(-)