17 Jul, 2019

2 commits

  • Merge more updates from Andrew Morton:
    "VM:
    - z3fold fixes and enhancements by Henry Burns and Vitaly Wool

    - more accurate reclaimed slab caches calculations by Yafang Shao

    - fix MAP_UNINITIALIZED UAPI symbol to not depend on config, by
    Christoph Hellwig

    - !CONFIG_MMU fixes by Christoph Hellwig

    - new novmcoredd parameter to omit device dumps from vmcore, by
    Kairui Song

    - new test_meminit module for testing heap and pagealloc
    initialization, by Alexander Potapenko

    - ioremap improvements for huge mappings, by Anshuman Khandual

    - generalize kprobe page fault handling, by Anshuman Khandual

    - device-dax hotplug fixes and improvements, by Pavel Tatashin

    - enable synchronous DAX fault on powerpc, by Aneesh Kumar K.V

    - add pte_devmap() support for arm64, by Robin Murphy

    - unify locked_vm accounting with a helper, by Daniel Jordan

    - several misc fixes

    core/lib:
    - new typeof_member() macro including some users, by Alexey Dobriyan

    - make BIT() and GENMASK() available in asm, by Masahiro Yamada

    - changed LIST_POISON2 on x86_64 to 0xdead000000000122 for better
    code generation, by Alexey Dobriyan

    - rbtree code size optimizations, by Michel Lespinasse

    - convert struct pid count to refcount_t, by Joel Fernandes

    get_maintainer.pl:
    - add --no-moderated switch to skip moderated ML's, by Joe Perches

    misc:
    - ptrace PTRACE_GET_SYSCALL_INFO interface

    - coda updates

    - gdb scripts, various"

    [ Using merge message suggestion from Vlastimil Babka, with some editing - Linus ]

    * emailed patches from Andrew Morton : (100 commits)
    fs/select.c: use struct_size() in kmalloc()
    mm: add account_locked_vm utility function
    arm64: mm: implement pte_devmap support
    mm: introduce ARCH_HAS_PTE_DEVMAP
    mm: clean up is_device_*_page() definitions
    mm/mmap: move common defines to mman-common.h
    mm: move MAP_SYNC to asm-generic/mman-common.h
    device-dax: "Hotremove" persistent memory that is used like normal RAM
    mm/hotplug: make remove_memory() interface usable
    device-dax: fix memory and resource leak if hotplug fails
    include/linux/lz4.h: fix spelling and copy-paste errors in documentation
    ipc/mqueue.c: only perform resource calculation if user valid
    include/asm-generic/bug.h: fix "cut here" for WARN_ON for __WARN_TAINT architectures
    scripts/gdb: add helpers to find and list devices
    scripts/gdb: add lx-genpd-summary command
    drivers/pps/pps.c: clear offset flags in PPS_SETPARAMS ioctl
    kernel/pid.c: convert struct pid count to refcount_t
    drivers/rapidio/devices/rio_mport_cdev.c: NUL terminate some strings
    select: shift restore_saved_sigmask_unless() into poll_select_copy_remaining()
    select: change do_poll() to return -ERESTARTNOHAND rather than -EINTR
    ...

    Linus Torvalds
     
  • Since commit 2724273e8fd0 ("vmcore: add API to collect hardware dump in
    second kernel"), drivers are allowed to add device related dump data to
    vmcore as they want by using the device dump API. This has a potential
    issue, the data is stored in memory, drivers may append too much data
    and use too much memory. The vmcore is typically used in a kdump kernel
    which runs in a pre-reserved small chunk of memory. So as a result it
    will make kdump unusable at all due to OOM issues.

    So introduce new 'novmcoredd' command line option. User can disable
    device dump to reduce memory usage. This is helpful if device dump is
    using too much memory, disabling device dump could make sure a regular
    vmcore without device dump data is still available.

    [akpm@linux-foundation.org: tweak documentation]
    [akpm@linux-foundation.org: vmcore.c needs moduleparam.h]
    Link: http://lkml.kernel.org/r/20190528111856.7276-1-kasong@redhat.com
    Signed-off-by: Kairui Song
    Acked-by: Dave Young
    Reviewed-by: Bhupesh Sharma
    Cc: Rahul Lakkireddy
    Cc: "David S . Miller"
    Cc: Eric Biederman
    Cc: Alexey Dobriyan
    Cc: Baoquan He
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kairui Song
     

15 Jul, 2019

1 commit


12 Jun, 2019

1 commit

  • Exposing architecture specific per process information is useful for
    various reasons. An example is the AVX512 usage on x86 which is important
    for task placement for power/performance optimizations.

    Adding this information to the existing /prcc/pid/status file would be the
    obvious choise, but it has been agreed on that a explicit arch_status file
    is better in separating the generic and architecture specific information.

    [ tglx: Massage changelog ]

    Signed-off-by: Aubrey Li
    Signed-off-by: Thomas Gleixner
    Acked-by: Andrew Morton
    Cc: peterz@infradead.org
    Cc: hpa@zytor.com
    Cc: ak@linux.intel.com
    Cc: tim.c.chen@linux.intel.com
    Cc: dave.hansen@intel.com
    Cc: arjan@linux.intel.com
    Cc: adobriyan@gmail.com
    Cc: aubrey.li@intel.com
    Cc: linux-api@vger.kernel.org
    Cc: Andy Lutomirski
    Cc: Peter Zijlstra
    Cc: Andi Kleen
    Cc: Tim Chen
    Cc: Dave Hansen
    Cc: Arjan van de Ven
    Cc: Alexey Dobriyan
    Cc: Linux API
    Link: https://lkml.kernel.org/r/20190606012236.9391-1-aubrey.li@linux.intel.com

    Aubrey Li
     

21 May, 2019

1 commit


23 Aug, 2018

1 commit

  • The vmcoreinfo information is useful for runtime debugging tools, not just
    for crash dumps. A lot of this information can be determined by other
    means, but this is much more convenient, and it only adds a page at most
    to the file.

    Link: http://lkml.kernel.org/r/fddbcd08eed76344863303878b12de1c1e2a04b6.1531953780.git.osandov@fb.com
    Signed-off-by: Omar Sandoval
    Cc: Alexey Dobriyan
    Cc: Bhupesh Sharma
    Cc: Eric Biederman
    Cc: James Morse
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Omar Sandoval
     

15 May, 2018

1 commit

  • The sequence of actions done by device drivers to append their device
    specific hardware/firmware logs to /proc/vmcore are as follows:

    1. During probe (before hardware is initialized), device drivers
    register to the vmcore module (via vmcore_add_device_dump()), with
    callback function, along with buffer size and log name needed for
    firmware/hardware log collection.

    2. vmcore module allocates the buffer with requested size. It adds
    an Elf note and invokes the device driver's registered callback
    function.

    3. Device driver collects all hardware/firmware logs into the buffer
    and returns control back to vmcore module.

    Ensure that the device dump buffer size is always aligned to page size
    so that it can be mmaped.

    Also, rename alloc_elfnotes_buf() to vmcore_alloc_buf() to make it more
    generic and reserve NT_VMCOREDD note type to indicate vmcore device
    dump.

    Suggested-by: Eric Biederman .
    Signed-off-by: Rahul Lakkireddy
    Signed-off-by: Ganesh Goudar
    Signed-off-by: David S. Miller

    Rahul Lakkireddy
     

18 Jul, 2015

1 commit

  • The purpose of the option was documented in
    Documentation/filesystems/proc.txt but the help text was missing.

    Add small help text that also points to the documentation.

    Signed-off-by: Iago López Galeiras
    Reviewed-by: Jean Delvare
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Iago López Galeiras
     

26 Jun, 2015

1 commit

  • Commit 818411616baf ("fs, proc: introduce /proc//task//children
    entry") introduced the children entry for checkpoint restore and the
    file is only available on kernels configured with CONFIG_EXPERT and
    CONFIG_CHECKPOINT_RESTORE.

    This is available in most distributions (Fedora, Debian, Ubuntu, CoreOS)
    because they usually enable CONFIG_EXPERT and CONFIG_CHECKPOINT_RESTORE.
    But Arch does not enable CONFIG_EXPERT or CONFIG_CHECKPOINT_RESTORE.

    However, the children proc file is useful outside of checkpoint restore.
    I would like to use it in rkt. The rkt process exec() another program
    it does not control, and that other program will fork()+exec() a child
    process. I would like to find the pid of the child process from an
    external tool without iterating in /proc over all processes to find
    which one has a parent pid equal to rkt.

    This commit introduces CONFIG_PROC_CHILDREN and makes
    CONFIG_CHECKPOINT_RESTORE select it. This allows enabling
    /proc//task//children without needing to enable
    CONFIG_CHECKPOINT_RESTORE and CONFIG_EXPERT.

    Alban tested that /proc//task//children is present when the
    kernel is configured with CONFIG_PROC_CHILDREN=y but without
    CONFIG_CHECKPOINT_RESTORE

    Signed-off-by: Iago López Galeiras
    Tested-by: Alban Crequy
    Reviewed-by: Cyrill Gorcunov
    Cc: Oleg Nesterov
    Cc: Kees Cook
    Cc: Pavel Emelyanov
    Cc: Serge Hallyn
    Cc: KAMEZAWA Hiroyuki
    Cc: Alexander Viro
    Cc: Andy Lutomirski
    Cc: Djalal Harouni
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Iago López Galeiras
     

13 Nov, 2013

1 commit

  • Under Pseudo filesystems, /proc/kcore support has no help.

    Fixes a portion of kernel bugzilla #52671:
    https://bugzilla.kernel.org/show_bug.cgi?id=52671

    Thanks for David Howells for the help text.

    Signed-off-by: Randy Dunlap
    Reported-by:
    Signed-off-by: David Howells
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Randy Dunlap
     

21 Jan, 2011

1 commit

  • The meaning of CONFIG_EMBEDDED has long since been obsoleted; the option
    is used to configure any non-standard kernel with a much larger scope than
    only small devices.

    This patch renames the option to CONFIG_EXPERT in init/Kconfig and fixes
    references to the option throughout the kernel. A new CONFIG_EMBEDDED
    option is added that automatically selects CONFIG_EXPERT when enabled and
    can be used in the future to isolate options that should only be
    considered for embedded systems (RISC architectures, SLOB, etc).

    Calling the option "EXPERT" more accurately represents its intention: only
    expert users who understand the impact of the configuration changes they
    are making should enable it.

    Reviewed-by: Ingo Molnar
    Acked-by: David Woodhouse
    Signed-off-by: David Rientjes
    Cc: Greg KH
    Cc: "David S. Miller"
    Cc: Jens Axboe
    Cc: Arnd Bergmann
    Cc: Robin Holt
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Rientjes
     

27 Oct, 2010

1 commit

  • We use vmcore in our production kernel for a long time, it is pretty
    stable now. So I don't think we need to mark it as experimental any more.

    Signed-off-by: WANG Cong
    Acked-by: Neil Horman
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    WANG Cong
     

10 Oct, 2008

1 commit


26 Jul, 2008

1 commit