06 Feb, 2020

1 commit

  • [ Upstream commit 4f80b70e1953cb846dbdd1ce72cb17333d4c8d11 ]

    resource_size_t should be printed with its own size-independent format
    to fix warnings when compiling on 64-bit platform (e.g. with
    COMPILE_TEST):

    arch/parisc/kernel/drivers.c: In function 'print_parisc_device':
    arch/parisc/kernel/drivers.c:892:9: warning:
    format '%p' expects argument of type 'void *',
    but argument 4 has type 'resource_size_t {aka unsigned int}' [-Wformat=]

    Signed-off-by: Krzysztof Kozlowski
    Signed-off-by: Helge Deller
    Signed-off-by: Sasha Levin

    Krzysztof Kozlowski
     

15 Jan, 2020

1 commit

  • commit d2f36c787b2181561d8b95814f8cdad64b348ad7 upstream.

    This is required for clone3 which passes the TLS value through a
    struct rather than a register.

    Signed-off-by: Amanieu d'Antras
    Cc: linux-parisc@vger.kernel.org
    Cc: # 5.3.x
    Link: https://lore.kernel.org/r/20200102172413.654385-5-amanieu@gmail.com
    Signed-off-by: Christian Brauner
    Signed-off-by: Greg Kroah-Hartman

    Amanieu d'Antras
     

12 Jan, 2020

3 commits

  • [ Upstream commit 75cf9797006a3a9f29a3a25c1febd6842a4a9eb2 ]

    Fix this compiler warning:
    kernel/debug/debug_core.c: In function ‘kgdb_cpu_enter’:
    arch/parisc/include/asm/cmpxchg.h:48:3: warning: value computed is not used [-Wunused-value]
    48 | ((__typeof__(*(ptr)))__xchg((unsigned long)(x), (ptr), sizeof(*(ptr))))
    arch/parisc/include/asm/atomic.h:78:30: note: in expansion of macro ‘xchg’
    78 | #define atomic_xchg(v, new) (xchg(&((v)->counter), new))
    | ^~~~
    kernel/debug/debug_core.c:596:4: note: in expansion of macro ‘atomic_xchg’
    596 | atomic_xchg(&kgdb_active, cpu);
    | ^~~~~~~~~~~

    Signed-off-by: Helge Deller
    Signed-off-by: Sasha Levin

    Helge Deller
     
  • [ Upstream commit aeea5eae4fd54e94d820ed17ea3b238160be723e ]

    compilation failed with:

    MODPOST vmlinux.o
    WARNING: vmlinux.o(.text.unlikely+0xa0c): Section mismatch in reference from the function walk_lower_bus() to the function .init.text:walk_native_bus()
    The function walk_lower_bus() references
    the function __init walk_native_bus().
    This is often because walk_lower_bus lacks a __init
    annotation or the annotation of walk_native_bus is wrong.

    FATAL: modpost: Section mismatches detected.
    Set CONFIG_SECTION_MISMATCH_WARN_ONLY=y to allow them.
    make[2]: *** [/home/svens/linux/parisc-linux/src/scripts/Makefile.modpost:64: __modpost] Error 1
    make[1]: *** [/home/svens/linux/parisc-linux/src/Makefile:1077: vmlinux] Error 2
    make[1]: Leaving directory '/home/svens/linux/parisc-linux/build'
    make: *** [Makefile:179: sub-make] Error 2

    Signed-off-by: Sven Schnelle
    Signed-off-by: Helge Deller
    Signed-off-by: Sasha Levin

    Sven Schnelle
     
  • [ Upstream commit e16260c21f87b16a33ae8ecac9e8c79f3a8b89bd ]

    Fix compilation when the CONFIG_KEXEC_FILE=y and
    CONFIG_KEXEC=n.

    Reported-by: kbuild test robot
    Signed-off-by: Sven Schnelle
    Signed-off-by: Helge Deller
    Signed-off-by: Sasha Levin

    Sven Schnelle
     

31 Oct, 2019

1 commit

  • The current code in ftrace_regs_caller() doesn't assign
    %r3 to contain the address of the current frame. This
    is hidden if the kernel is compiled with FRAME_POINTER,
    but without it just crashes because it tries to dereference
    an arbitrary address. Fix this by always setting %r3 to the
    current stack frame.

    Signed-off-by: Sven Schnelle
    Signed-off-by: Helge Deller

    Sven Schnelle
     

15 Oct, 2019

2 commits


26 Sep, 2019

2 commits

  • When a process expects no accesses to a certain memory range for a long
    time, it could hint kernel that the pages can be reclaimed instantly but
    data should be preserved for future use. This could reduce workingset
    eviction so it ends up increasing performance.

    This patch introduces the new MADV_PAGEOUT hint to madvise(2) syscall.
    MADV_PAGEOUT can be used by a process to mark a memory range as not
    expected to be used for a long time so that kernel reclaims *any LRU*
    pages instantly. The hint can help kernel in deciding which pages to
    evict proactively.

    A note: It doesn't apply SWAP_CLUSTER_MAX LRU page isolation limit
    intentionally because it's automatically bounded by PMD size. If PMD
    size(e.g., 256) makes some trouble, we could fix it later by limit it to
    SWAP_CLUSTER_MAX[1].

    - man-page material

    MADV_PAGEOUT (since Linux x.x)

    Do not expect access in the near future so pages in the specified
    regions could be reclaimed instantly regardless of memory pressure.
    Thus, access in the range after successful operation could cause
    major page fault but never lose the up-to-date contents unlike
    MADV_DONTNEED. Pages belonging to a shared mapping are only processed
    if a write access is allowed for the calling process.

    MADV_PAGEOUT cannot be applied to locked pages, Huge TLB pages, or
    VM_PFNMAP pages.

    [1] https://lore.kernel.org/lkml/20190710194719.GS29695@dhcp22.suse.cz/

    [minchan@kernel.org: clear PG_active on MADV_PAGEOUT]
    Link: http://lkml.kernel.org/r/20190802200643.GA181880@google.com
    [akpm@linux-foundation.org: resolve conflicts with hmm.git]
    Link: http://lkml.kernel.org/r/20190726023435.214162-5-minchan@kernel.org
    Signed-off-by: Minchan Kim
    Reported-by: kbuild test robot
    Acked-by: Michal Hocko
    Cc: James E.J. Bottomley
    Cc: Richard Henderson
    Cc: Ralf Baechle
    Cc: Chris Zankel
    Cc: Daniel Colascione
    Cc: Dave Hansen
    Cc: Hillf Danton
    Cc: Joel Fernandes (Google)
    Cc: Johannes Weiner
    Cc: Kirill A. Shutemov
    Cc: Oleksandr Natalenko
    Cc: Shakeel Butt
    Cc: Sonny Rao
    Cc: Suren Baghdasaryan
    Cc: Tim Murray
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Minchan Kim
     
  • Patch series "Introduce MADV_COLD and MADV_PAGEOUT", v7.

    - Background

    The Android terminology used for forking a new process and starting an app
    from scratch is a cold start, while resuming an existing app is a hot
    start. While we continually try to improve the performance of cold
    starts, hot starts will always be significantly less power hungry as well
    as faster so we are trying to make hot start more likely than cold start.

    To increase hot start, Android userspace manages the order that apps
    should be killed in a process called ActivityManagerService.
    ActivityManagerService tracks every Android app or service that the user
    could be interacting with at any time and translates that into a ranked
    list for lmkd(low memory killer daemon). They are likely to be killed by
    lmkd if the system has to reclaim memory. In that sense they are similar
    to entries in any other cache. Those apps are kept alive for
    opportunistic performance improvements but those performance improvements
    will vary based on the memory requirements of individual workloads.

    - Problem

    Naturally, cached apps were dominant consumers of memory on the system.
    However, they were not significant consumers of swap even though they are
    good candidate for swap. Under investigation, swapping out only begins
    once the low zone watermark is hit and kswapd wakes up, but the overall
    allocation rate in the system might trip lmkd thresholds and cause a
    cached process to be killed(we measured performance swapping out vs.
    zapping the memory by killing a process. Unsurprisingly, zapping is 10x
    times faster even though we use zram which is much faster than real
    storage) so kill from lmkd will often satisfy the high zone watermark,
    resulting in very few pages actually being moved to swap.

    - Approach

    The approach we chose was to use a new interface to allow userspace to
    proactively reclaim entire processes by leveraging platform information.
    This allowed us to bypass the inaccuracy of the kernel’s LRUs for pages
    that are known to be cold from userspace and to avoid races with lmkd by
    reclaiming apps as soon as they entered the cached state. Additionally,
    it could provide many chances for platform to use much information to
    optimize memory efficiency.

    To achieve the goal, the patchset introduce two new options for madvise.
    One is MADV_COLD which will deactivate activated pages and the other is
    MADV_PAGEOUT which will reclaim private pages instantly. These new
    options complement MADV_DONTNEED and MADV_FREE by adding non-destructive
    ways to gain some free memory space. MADV_PAGEOUT is similar to
    MADV_DONTNEED in a way that it hints the kernel that memory region is not
    currently needed and should be reclaimed immediately; MADV_COLD is similar
    to MADV_FREE in a way that it hints the kernel that memory region is not
    currently needed and should be reclaimed when memory pressure rises.

    This patch (of 5):

    When a process expects no accesses to a certain memory range, it could
    give a hint to kernel that the pages can be reclaimed when memory pressure
    happens but data should be preserved for future use. This could reduce
    workingset eviction so it ends up increasing performance.

    This patch introduces the new MADV_COLD hint to madvise(2) syscall.
    MADV_COLD can be used by a process to mark a memory range as not expected
    to be used in the near future. The hint can help kernel in deciding which
    pages to evict early during memory pressure.

    It works for every LRU pages like MADV_[DONTNEED|FREE]. IOW, It moves

    active file page -> inactive file LRU
    active anon page -> inacdtive anon LRU

    Unlike MADV_FREE, it doesn't move active anonymous pages to inactive file
    LRU's head because MADV_COLD is a little bit different symantic.
    MADV_FREE means it's okay to discard when the memory pressure because the
    content of the page is *garbage* so freeing such pages is almost zero
    overhead since we don't need to swap out and access afterward causes just
    minor fault. Thus, it would make sense to put those freeable pages in
    inactive file LRU to compete other used-once pages. It makes sense for
    implmentaion point of view, too because it's not swapbacked memory any
    longer until it would be re-dirtied. Even, it could give a bonus to make
    them be reclaimed on swapless system. However, MADV_COLD doesn't mean
    garbage so reclaiming them requires swap-out/in in the end so it's bigger
    cost. Since we have designed VM LRU aging based on cost-model, anonymous
    cold pages would be better to position inactive anon's LRU list, not file
    LRU. Furthermore, it would help to avoid unnecessary scanning if system
    doesn't have a swap device. Let's start simpler way without adding
    complexity at this moment. However, keep in mind, too that it's a caveat
    that workloads with a lot of pages cache are likely to ignore MADV_COLD on
    anonymous memory because we rarely age anonymous LRU lists.

    * man-page material

    MADV_COLD (since Linux x.x)

    Pages in the specified regions will be treated as less-recently-accessed
    compared to pages in the system with similar access frequencies. In
    contrast to MADV_FREE, the contents of the region are preserved regardless
    of subsequent writes to pages.

    MADV_COLD cannot be applied to locked pages, Huge TLB pages, or VM_PFNMAP
    pages.

    [akpm@linux-foundation.org: resolve conflicts with hmm.git]
    Link: http://lkml.kernel.org/r/20190726023435.214162-2-minchan@kernel.org
    Signed-off-by: Minchan Kim
    Reported-by: kbuild test robot
    Acked-by: Michal Hocko
    Acked-by: Johannes Weiner
    Cc: James E.J. Bottomley
    Cc: Richard Henderson
    Cc: Ralf Baechle
    Cc: Chris Zankel
    Cc: Johannes Weiner
    Cc: Daniel Colascione
    Cc: Dave Hansen
    Cc: Hillf Danton
    Cc: Joel Fernandes (Google)
    Cc: Kirill A. Shutemov
    Cc: Oleksandr Natalenko
    Cc: Shakeel Butt
    Cc: Sonny Rao
    Cc: Suren Baghdasaryan
    Cc: Tim Murray
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Minchan Kim
     

25 Sep, 2019

2 commits

  • Both pgtable_cache_init() and pgd_cache_init() are used to initialize kmem
    cache for page table allocations on several architectures that do not use
    PAGE_SIZE tables for one or more levels of the page table hierarchy.

    Most architectures do not implement these functions and use __weak default
    NOP implementation of pgd_cache_init(). Since there is no such default
    for pgtable_cache_init(), its empty stub is duplicated among most
    architectures.

    Rename the definitions of pgd_cache_init() to pgtable_cache_init() and
    drop empty stubs of pgtable_cache_init().

    Link: http://lkml.kernel.org/r/1566457046-22637-1-git-send-email-rppt@linux.ibm.com
    Signed-off-by: Mike Rapoport
    Acked-by: Will Deacon [arm64]
    Acked-by: Thomas Gleixner [x86]
    Cc: Catalin Marinas
    Cc: Ingo Molnar
    Cc: Borislav Petkov
    Cc: Matthew Wilcox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mike Rapoport
     
  • Patch series "mm: remove quicklist page table caches".

    A while ago Nicholas proposed to remove quicklist page table caches [1].

    I've rebased his patch on the curren upstream and switched ia64 and sh to
    use generic versions of PTE allocation.

    [1] https://lore.kernel.org/linux-mm/20190711030339.20892-1-npiggin@gmail.com

    This patch (of 3):

    Remove page table allocator "quicklists". These have been around for a
    long time, but have not got much traction in the last decade and are only
    used on ia64 and sh architectures.

    The numbers in the initial commit look interesting but probably don't
    apply anymore. If anybody wants to resurrect this it's in the git
    history, but it's unhelpful to have this code and divergent allocator
    behaviour for minor archs.

    Also it might be better to instead make more general improvements to page
    allocator if this is still so slow.

    Link: http://lkml.kernel.org/r/1565250728-21721-2-git-send-email-rppt@linux.ibm.com
    Signed-off-by: Nicholas Piggin
    Signed-off-by: Mike Rapoport
    Cc: Tony Luck
    Cc: Yoshinori Sato
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Nicholas Piggin
     

20 Sep, 2019

2 commits

  • Pull Kbuild updates from Masahiro Yamada:

    - add modpost warn exported symbols marked as 'static' because 'static'
    and EXPORT_SYMBOL is an odd combination

    - break the build early if gold linker is used

    - optimize the Bison rule to produce .c and .h files by a single
    pattern rule

    - handle PREEMPT_RT in the module vermagic and UTS_VERSION

    - warn CONFIG options leaked to the user-space except existing ones

    - make single targets work properly

    - rebuild modules when module linker scripts are updated

    - split the module final link stage into scripts/Makefile.modfinal

    - fix the missed error code in merge_config.sh

    - improve the error message displayed on the attempt of the O= build in
    unclean source tree

    - remove 'clean-dirs' syntax

    - disable -Wimplicit-fallthrough warning for Clang

    - add CONFIG_CC_OPTIMIZE_FOR_SIZE_O3 for ARC

    - remove ARCH_{CPP,A,C}FLAGS variables

    - add $(BASH) to run bash scripts

    - change *CFLAGS_.o to take the relative path to $(obj)
    instead of the basename

    - stop suppressing Clang's -Wunused-function warnings when W=1

    - fix linux/export.h to avoid genksyms calculating CRC of trimmed
    exported symbols

    - misc cleanups

    * tag 'kbuild-v5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: (63 commits)
    genksyms: convert to SPDX License Identifier for lex.l and parse.y
    modpost: use __section in the output to *.mod.c
    modpost: use MODULE_INFO() for __module_depends
    export.h, genksyms: do not make genksyms calculate CRC of trimmed symbols
    export.h: remove defined(__KERNEL__), which is no longer needed
    kbuild: allow Clang to find unused static inline functions for W=1 build
    kbuild: rename KBUILD_ENABLE_EXTRA_GCC_CHECKS to KBUILD_EXTRA_WARN
    kbuild: refactor scripts/Makefile.extrawarn
    merge_config.sh: ignore unwanted grep errors
    kbuild: change *FLAGS_.o to take the path relative to $(obj)
    modpost: add NOFAIL to strndup
    modpost: add guid_t type definition
    kbuild: add $(BASH) to run scripts with bash-extension
    kbuild: remove ARCH_{CPP,A,C}FLAGS
    kbuild,arc: add CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE_O3 for ARC
    kbuild: Do not enable -Wimplicit-fallthrough for clang for now
    kbuild: clean up subdir-ymn calculation in Makefile.clean
    kbuild: remove unneeded '+' marker from cmd_clean
    kbuild: remove clean-dirs syntax
    kbuild: check clean srctree even earlier
    ...

    Linus Torvalds
     
  • Pull dma-mapping updates from Christoph Hellwig:

    - add dma-mapping and block layer helpers to take care of IOMMU merging
    for mmc plus subsequent fixups (Yoshihiro Shimoda)

    - rework handling of the pgprot bits for remapping (me)

    - take care of the dma direct infrastructure for swiotlb-xen (me)

    - improve the dma noncoherent remapping infrastructure (me)

    - better defaults for ->mmap, ->get_sgtable and ->get_required_mask
    (me)

    - cleanup mmaping of coherent DMA allocations (me)

    - various misc cleanups (Andy Shevchenko, me)

    * tag 'dma-mapping-5.4' of git://git.infradead.org/users/hch/dma-mapping: (41 commits)
    mmc: renesas_sdhi_internal_dmac: Add MMC_CAP2_MERGE_CAPABLE
    mmc: queue: Fix bigger segments usage
    arm64: use asm-generic/dma-mapping.h
    swiotlb-xen: merge xen_unmap_single into xen_swiotlb_unmap_page
    swiotlb-xen: simplify cache maintainance
    swiotlb-xen: use the same foreign page check everywhere
    swiotlb-xen: remove xen_swiotlb_dma_mmap and xen_swiotlb_dma_get_sgtable
    xen: remove the exports for xen_{create,destroy}_contiguous_region
    xen/arm: remove xen_dma_ops
    xen/arm: simplify dma_cache_maint
    xen/arm: use dev_is_dma_coherent
    xen/arm: consolidate page-coherent.h
    xen/arm: use dma-noncoherent.h calls for xen-swiotlb cache maintainance
    arm: remove wrappers for the generic dma remap helpers
    dma-mapping: introduce a dma_common_find_pages helper
    dma-mapping: always use VM_DMA_COHERENT for generic DMA remap
    vmalloc: lift the arm flag for coherent mappings to common code
    dma-mapping: provide a better default ->get_required_mask
    dma-mapping: remove the dma_declare_coherent_memory export
    remoteproc: don't allow modular build
    ...

    Linus Torvalds
     

17 Sep, 2019

1 commit

  • Pull parisc updates from Helge Deller:

    - Make the powerpc implementation to read elf files available as a
    public kexec interface so it can be re-used on other architectures
    (Sven)

    - Implement kexec on parisc (Sven)

    - Add kprobes on ftrace on parisc (Sven)

    - Fix kernel crash with HSC-PCI cards based on card-mode Dino

    - Add assembly implementations for memset, strlen, strcpy, strncpy and
    strcat

    - Some cleanups, documentation updates, warning fixes, ...

    * 'parisc-5.4-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux: (25 commits)
    parisc: Have git ignore generated real2.S and firmware.c
    parisc: Disable HP HSC-PCI Cards to prevent kernel crash
    parisc: add support for kexec_file_load() syscall
    parisc: wire up kexec_file_load syscall
    parisc: add kexec syscall support
    parisc: add __pdc_cpu_rendezvous()
    kprobes/parisc: remove arch_kprobe_on_func_entry()
    kexec_elf: support 32 bit ELF files
    kexec_elf: remove unused variable in kexec_elf_load()
    kexec_elf: remove Elf_Rel macro
    kexec_elf: remove PURGATORY_STACK_SIZE
    kexec_elf: remove parsing of section headers
    kexec_elf: change order of elf_*_to_cpu() functions
    kexec: add KEXEC_ELF
    parisc: Save some bytes in dino driver
    parisc: Drop comments which are already in pci.h
    parisc: Convert eisa_enumerator to use pr_cont()
    parisc: Avoid warning when loading hppb driver
    parisc: speed up flush_tlb_all_local with qemu
    parisc: Add ALTERNATIVE_CODE() and ALT_COND_RUN_ON_QEMU
    ...

    Linus Torvalds
     

12 Sep, 2019

1 commit


08 Sep, 2019

4 commits


07 Sep, 2019

1 commit


05 Sep, 2019

1 commit


04 Sep, 2019

1 commit

  • parisc is the only architecture that sets ARCH_NO_COHERENT_DMA_MMAP
    when an MMU is enabled. AFAIK this is because parisc CPUs use VIVT
    caches, which means exporting normally cachable memory to userspace is
    relatively dangrous due to cache aliasing.

    But normally cachable memory is only allocated by dma_alloc_coherent
    on parisc when using the sba_iommu or ccio_iommu drivers, so just
    remove the .mmap implementation for them so that we don't have to set
    ARCH_NO_COHERENT_DMA_MMAP, which I plan to get rid of.

    Signed-off-by: Christoph Hellwig

    Christoph Hellwig
     

25 Aug, 2019

1 commit

  • Commit 0cfaee2af3a0 ("include/asm-generic/5level-fixup.h: fix variable
    'p4d' set but not used") converted a few functions from macros to static
    inline, which causes parisc to complain,

    In file included from include/asm-generic/4level-fixup.h:38:0,
    from arch/parisc/include/asm/pgtable.h:5,
    from arch/parisc/include/asm/io.h:6,
    from include/linux/io.h:13,
    from sound/core/memory.c:9:
    include/asm-generic/5level-fixup.h:14:18: error: unknown type name 'pgd_t'; did you mean 'pid_t'?
    #define p4d_t pgd_t
    ^
    include/asm-generic/5level-fixup.h:24:28: note: in expansion of macro 'p4d_t'
    static inline int p4d_none(p4d_t p4d)
    ^~~~~

    It is because "4level-fixup.h" is included before "asm/page.h" where
    "pgd_t" is defined.

    Link: http://lkml.kernel.org/r/20190815205305.1382-1-cai@lca.pw
    Fixes: 0cfaee2af3a0 ("include/asm-generic/5level-fixup.h: fix variable 'p4d' set but not used")
    Signed-off-by: Qian Cai
    Reported-by: Guenter Roeck
    Tested-by: Guenter Roeck
    Cc: Stephen Rothwell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Qian Cai
     

21 Aug, 2019

1 commit


13 Aug, 2019

2 commits


11 Aug, 2019

1 commit

  • A compilation -Wimplicit-fallthrough warning was enabled by commit
    a035d552a93b ("Makefile: Globally enable fall-through warning")

    Even though clang 10.0.0 does not currently support this warning without
    a patch, clang currently does not support a value for this option.

    Link: https://bugs.llvm.org/show_bug.cgi?id=39382

    The gcc default for this warning is 3 so removing the =3 has no effect
    for gcc and enables the warning for patched versions of clang.

    Also remove the =3 from an existing use in a parisc Makefile:
    arch/parisc/math-emu/Makefile

    Signed-off-by: Joe Perches
    Reviewed-and-tested-by: Nathan Chancellor
    Cc: Gustavo A. R. Silva
    Signed-off-by: Linus Torvalds

    Joe Perches
     

03 Aug, 2019

4 commits


01 Aug, 2019

3 commits

  • Apparently we don't have an archclean target in our
    arch/parisc/Makefile, so files in there never get cleaned out by make
    mrproper. This, in turn means that the sizes.h file in
    arch/parisc/boot/compressed never gets removed and worse, when you
    transition to an O=build/parisc[64] build model it overrides the
    generated file. The upshot being my bzImage was building with a SZ_end
    that was too small.

    I fixed it by making mrproper clean everything.

    Signed-off-by: James Bottomley
    Cc: stable@vger.kernel.org # v4.20+
    Signed-off-by: Helge Deller

    James Bottomley
     
  • Same as on x86-64, strip the .comment, .note and debug sections from the
    Linux kernel before creating the compressed image for the boot loader.

    Reported-by: James Bottomley
    Reported-by: Sven Schnelle
    Cc: stable@vger.kernel.org # v4.20+
    Signed-off-by: Helge Deller

    Helge Deller
     
  • With debug info enabled (CONFIG_DEBUG_INFO=y) the resulting vmlinux may get
    that huge that we need to increase the start addresss for the decompression
    text section otherwise one will face a linker error.

    Reported-by: Sven Schnelle
    Tested-by: Sven Schnelle
    Cc: stable@vger.kernel.org # v4.14+
    Signed-off-by: Helge Deller

    Helge Deller
     

31 Jul, 2019

4 commits

  • Assume the following ftrace code sequence that was patched in earlier by
    ftrace_make_call():

    PAGE A:
    ffc: addr of ftrace_caller()
    PAGE B:
    000: 0x6fc10080 /* stw,ma r1,40(sp) */
    004: 0x48213fd1 /* ldw -18(r1),r1 */
    008: 0xe820c002 /* bv,n r0(r1) */
    00c: 0xe83f1fdf /* b,l,n .-c,r1 */

    When a Code sequences that is to be patched spans a page break, we might
    have already cleared the part on the PAGE A. If an interrupt is coming in
    during the remap of the fixed mapping to PAGE B, it might execute the
    patched function with only parts of the FTRACE code cleared. To prevent
    this, clear the jump to our mini trampoline first, and clear the remaining
    parts after this. This might also happen when patch_text() patches a
    function that it calls during remap.

    Signed-off-by: Sven Schnelle
    Cc: # 5.2+
    Signed-off-by: Helge Deller

    Sven Schnelle
     
  • 'default_defconfig' is an awkward name since 'defconfig' is the default.
    Let's simply say 'defconfig' like other architectures. You can drop the
    KBUILD_DEFCONFIG define by following the standard naming.

    Signed-off-by: Masahiro Yamada
    Signed-off-by: Helge Deller

    Masahiro Yamada
     
  • In fpudispatch.c we see a lot of fall-through warnings, but for this file we
    prefer to not mark the switches and instead keep it in it's original state as
    it's copied from HP-UX.

    Fixes: a035d552a93b ("Makefile: Globally enable fall-through warning")
    Signed-off-by: Helge Deller

    Helge Deller
     
  • Fix a fall-through warning in fault.c.

    Fixes: a035d552a93b ("Makefile: Globally enable fall-through warning")
    Signed-off-by: Helge Deller

    Helge Deller
     

21 Jul, 2019

1 commit