31 Mar, 2020

1 commit

  • Pull locking updates from Ingo Molnar:
    "The main changes in this cycle were:

    - Continued user-access cleanups in the futex code.

    - percpu-rwsem rewrite that uses its own waitqueue and atomic_t
    instead of an embedded rwsem. This addresses a couple of
    weaknesses, but the primary motivation was complications on the -rt
    kernel.

    - Introduce raw lock nesting detection on lockdep
    (CONFIG_PROVE_RAW_LOCK_NESTING=y), document the raw_lock vs. normal
    lock differences. This too originates from -rt.

    - Reuse lockdep zapped chain_hlocks entries, to conserve RAM
    footprint on distro-ish kernels running into the "BUG:
    MAX_LOCKDEP_CHAIN_HLOCKS too low!" depletion of the lockdep
    chain-entries pool.

    - Misc cleanups, smaller fixes and enhancements - see the changelog
    for details"

    * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (55 commits)
    fs/buffer: Make BH_Uptodate_Lock bit_spin_lock a regular spinlock_t
    thermal/x86_pkg_temp: Make pkg_temp_lock a raw_spinlock_t
    Documentation/locking/locktypes: Minor copy editor fixes
    Documentation/locking/locktypes: Further clarifications and wordsmithing
    m68knommu: Remove mm.h include from uaccess_no.h
    x86: get rid of user_atomic_cmpxchg_inatomic()
    generic arch_futex_atomic_op_inuser() doesn't need access_ok()
    x86: don't reload after cmpxchg in unsafe_atomic_op2() loop
    x86: convert arch_futex_atomic_op_inuser() to user_access_begin/user_access_end()
    objtool: whitelist __sanitizer_cov_trace_switch()
    [parisc, s390, sparc64] no need for access_ok() in futex handling
    sh: no need of access_ok() in arch_futex_atomic_op_inuser()
    futex: arch_futex_atomic_op_inuser() calling conventions change
    completion: Use lockdep_assert_RT_in_threaded_ctx() in complete_all()
    lockdep: Add posixtimer context tracing bits
    lockdep: Annotate irq_work
    lockdep: Add hrtimer context tracing bits
    lockdep: Introduce wait-type checks
    completion: Use simple wait queues
    sched/swait: Prepare usage in completions
    ...

    Linus Torvalds
     

28 Mar, 2020

1 commit

  • Move access_ok() in and pagefault_enable()/pagefault_disable() out.
    Mechanical conversion only - some instances don't really need
    a separate access_ok() at all (e.g. the ones only using
    get_user()/put_user(), or architectures where access_ok()
    is always true); we'll deal with that in followups.

    Signed-off-by: Al Viro

    Al Viro
     

12 Mar, 2020

2 commits

  • The default defintions use fill pattern 0x90 for padding which for ARC
    generates unintended "ldh_s r12,[r0,0x20]" corresponding to opcode 0x9090

    So use ".align 4" which insert a "nop_s" instruction instead.

    Cc: stable@vger.kernel.org
    Acked-by: Vineet Gupta
    Signed-off-by: Eugeniy Paltsev
    Signed-off-by: Vineet Gupta

    Eugeniy Paltsev
     
  • Before
    ------

    | CPU: 1 PID: 29061 Comm: tst-dynarray-at Not tainted 5.6.0-rc1-00002-g941fcc018ca6-dirty #12
    |
    | [ECR ]: 0x00090000 =>
    | [EFA ]: 0x00000000
    | [ERET ]: 0x2004aa6c
    | @off 0x2aa6c in [/lib/libc-2.31.9000.so]
    VMA: 0x20020000 to 0x20122000
    | [STAT32]: 0x80080a82 [IE U ]
    | BTA: 0x2004aa18 SP: 0x5ffff8a8 FP: 0x5ffff8fc
    | LPS: 0x2008788e LPE: 0x20087896 LPC: 0x00000000
    | r00: 0x00000000 r01: 0x5ffff8a8 r02: 0x00000000
    | r03: 0x00000008 r04: 0xffffffff r05: 0x00000000
    | r06: 0x00000000 r07: 0x00000000 r08: 0x00000087
    | r09: 0x00000000 r10: 0x2010691c r11: 0x00000020
    | r12: 0x2003b214 r13: 0x5ffff8a8 r14: 0x20126e68
    | r15: 0x2001f26c r16: 0x2012a000 r17: 0x00000001
    | r18: 0x5ffff8fc r19: 0x00000000 r20: 0x5ffff948
    | r21: 0x00000001 r22: 0xffffffff r23: 0x5fffff8c
    | r24: 0x4008c2a8 r25: 0x2001f6e0

    After
    -----

    | CPU: 1 PID: 29061 Comm: tst-dynarray-at Not tainted 5.6.0-rc1-00002-g941fcc018ca6-dirty #12
    | @off 0x2aa6c in [/lib/libc-2.31.9000.so] VMA: 0x20020000 to 0x20122000
    | ECR: 0x00090000 EFA: 0x00000000 ERET: 0x2004aa6c
    | STAT32: 0x80080a82 [IE U ] BTA: 0x2004aa18
    | BLK: 0x2003b214 SP: 0x5ffff8a8 FP: 0x5ffff8fc
    | LPS: 0x2008788e LPE: 0x20087896 LPC: 0x00000000
    | r00: 0x00000000 r01: 0x5ffff8a8 r02: 0x00000000
    | r03: 0x00000008 r04: 0xffffffff r05: 0x00000000
    | r06: 0x00000000 r07: 0x00000000 r08: 0x00000087
    | r09: 0x00000000 r10: 0x2010691c r11: 0x00000020
    | r12: 0x2003b214 r13: 0x5ffff8a8 r14: 0x20126e68
    | r15: 0x2001f26c r16: 0x2012a000 r17: 0x00000001
    | r18: 0x5ffff8fc r19: 0x00000000 r20: 0x5ffff948
    | r21: 0x00000001 r22: 0xffffffff r23: 0x5fffff8c
    | r24: 0x4008c2a8 r25: 0x2001f6e0 BTA: 0x2004aa18

    Signed-off-by: Vineet Gupta

    Vineet Gupta
     

13 Feb, 2020

1 commit


10 Feb, 2020

3 commits


04 Feb, 2020

1 commit

  • walk_page_range() is going to be allowed to walk page tables other than
    those of user space. For this it needs to know when it has reached a
    'leaf' entry in the page tables. This information will be provided by the
    p?d_leaf() functions/macros.

    For arc, we only have two levels, so only pmd_leaf() is needed.

    Link: http://lkml.kernel.org/r/20191218162402.45610-3-steven.price@arm.com
    Signed-off-by: Steven Price
    Acked-by: Vineet Gupta
    Cc: Albert Ou
    Cc: Alexandre Ghiti
    Cc: Andy Lutomirski
    Cc: Ard Biesheuvel
    Cc: Arnd Bergmann
    Cc: Benjamin Herrenschmidt
    Cc: Borislav Petkov
    Cc: Catalin Marinas
    Cc: Christian Borntraeger
    Cc: Dave Hansen
    Cc: David S. Miller
    Cc: Heiko Carstens
    Cc: "H. Peter Anvin"
    Cc: Ingo Molnar
    Cc: James Hogan
    Cc: James Morse
    Cc: Jerome Glisse
    Cc: "Liang, Kan"
    Cc: Mark Rutland
    Cc: Michael Ellerman
    Cc: Paul Burton
    Cc: Paul Mackerras
    Cc: Paul Walmsley
    Cc: Peter Zijlstra
    Cc: Ralf Baechle
    Cc: Russell King
    Cc: Thomas Gleixner
    Cc: Vasily Gorbik
    Cc: Will Deacon
    Cc: Zong Li
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Steven Price
     

01 Feb, 2020

1 commit

  • Pull ARC updates from Vineet Gupta:

    - Wire up clone3 syscall

    - ARCv2 FPU state save/restore across context switch

    - AXS10x platform and misc fixes

    * tag 'arc-5.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc:
    ARCv2: fpu: preserve userspace fpu state
    ARC: fpu: declutter code, move bits out into fpu.h
    ARC: wireup clone3 syscall
    ARC: [plat-axs10x]: Add missing multicast filter number to GMAC node
    ARC: update feature support for jump-labels

    Linus Torvalds
     

30 Jan, 2020

1 commit

  • Pull tty/serial driver updates from Greg KH:
    "Here are the big set of tty and serial driver updates for 5.6-rc1

    Included in here are:
    - dummy_con cleanups (touches lots of arch code)
    - sysrq logic cleanups (touches lots of serial drivers)
    - samsung driver fixes (wasn't really being built)
    - conmakeshash move to tty subdir out of scripts
    - lots of small tty/serial driver updates

    All of these have been in linux-next for a while with no reported
    issues"

    * tag 'tty-5.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: (140 commits)
    tty: n_hdlc: Use flexible-array member and struct_size() helper
    tty: baudrate: SPARC supports few more baud rates
    tty: baudrate: Synchronise baud_table[] and baud_bits[]
    tty: serial: meson_uart: Add support for kernel debugger
    serial: imx: fix a race condition in receive path
    serial: 8250_bcm2835aux: Document struct bcm2835aux_data
    serial: 8250_bcm2835aux: Use generic remapping code
    serial: 8250_bcm2835aux: Allocate uart_8250_port on stack
    serial: 8250_bcm2835aux: Suppress register_port error on -EPROBE_DEFER
    serial: 8250_bcm2835aux: Suppress clk_get error on -EPROBE_DEFER
    serial: 8250_bcm2835aux: Fix line mismatch on driver unbind
    serial_core: Remove unused member in uart_port
    vt: Correct comment documenting do_take_over_console()
    vt: Delete comment referencing non-existent unbind_con_driver()
    arch/xtensa/setup: Drop dummy_con initialization
    arch/x86/setup: Drop dummy_con initialization
    arch/unicore32/setup: Drop dummy_con initialization
    arch/sparc/setup: Drop dummy_con initialization
    arch/sh/setup: Drop dummy_con initialization
    arch/s390/setup: Drop dummy_con initialization
    ...

    Linus Torvalds
     

29 Jan, 2020

3 commits

  • Pull scheduler updates from Ingo Molnar:
    "These were the main changes in this cycle:

    - More -rt motivated separation of CONFIG_PREEMPT and
    CONFIG_PREEMPTION.

    - Add more low level scheduling topology sanity checks and warnings
    to filter out nonsensical topologies that break scheduling.

    - Extend uclamp constraints to influence wakeup CPU placement

    - Make the RT scheduler more aware of asymmetric topologies and CPU
    capacities, via uclamp metrics, if CONFIG_UCLAMP_TASK=y

    - Make idle CPU selection more consistent

    - Various fixes, smaller cleanups, updates and enhancements - please
    see the git log for details"

    * 'sched-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (58 commits)
    sched/fair: Define sched_idle_cpu() only for SMP configurations
    sched/topology: Assert non-NUMA topology masks don't (partially) overlap
    idle: fix spelling mistake "iterrupts" -> "interrupts"
    sched/fair: Remove redundant call to cpufreq_update_util()
    sched/psi: create /proc/pressure and /proc/pressure/{io|memory|cpu} only when psi enabled
    sched/fair: Fix sgc->{min,max}_capacity calculation for SD_OVERLAP
    sched/fair: calculate delta runnable load only when it's needed
    sched/cputime: move rq parameter in irqtime_account_process_tick
    stop_machine: Make stop_cpus() static
    sched/debug: Reset watchdog on all CPUs while processing sysrq-t
    sched/core: Fix size of rq::uclamp initialization
    sched/uclamp: Fix a bug in propagating uclamp value in new cgroups
    sched/fair: Load balance aggressively for SCHED_IDLE CPUs
    sched/fair : Improve update_sd_pick_busiest for spare capacity case
    watchdog: Remove soft_lockup_hrtimer_cnt and related code
    sched/rt: Make RT capacity-aware
    sched/fair: Make EAS wakeup placement consider uclamp restrictions
    sched/fair: Make task_fits_capacity() consider uclamp restrictions
    sched/uclamp: Rename uclamp_util_with() into uclamp_rq_util_with()
    sched/uclamp: Make uclamp util helpers use and return UL values
    ...

    Linus Torvalds
     
  • Pull EFI updates from Ingo Molnar:
    "The main changes in this cycle were:

    - Cleanup of the GOP [graphics output] handling code in the EFI stub

    - Complete refactoring of the mixed mode handling in the x86 EFI stub

    - Overhaul of the x86 EFI boot/runtime code

    - Increase robustness for mixed mode code

    - Add the ability to disable DMA at the root port level in the EFI
    stub

    - Get rid of RWX mappings in the EFI memory map and page tables,
    where possible

    - Move the support code for the old EFI memory mapping style into its
    only user, the SGI UV1+ support code.

    - plus misc fixes, updates, smaller cleanups.

    ... and due to interactions with the RWX changes, another round of PAT
    cleanups make a guest appearance via the EFI tree - with no side
    effects intended"

    * 'efi-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (75 commits)
    efi/x86: Disable instrumentation in the EFI runtime handling code
    efi/libstub/x86: Fix EFI server boot failure
    efi/x86: Disallow efi=old_map in mixed mode
    x86/boot/compressed: Relax sed symbol type regex for LLVM ld.lld
    efi/x86: avoid KASAN false positives when accessing the 1: 1 mapping
    efi: Fix handling of multiple efi_fake_mem= entries
    efi: Fix efi_memmap_alloc() leaks
    efi: Add tracking for dynamically allocated memmaps
    efi: Add a flags parameter to efi_memory_map
    efi: Fix comment for efi_mem_type() wrt absent physical addresses
    efi/arm: Defer probe of PCIe backed efifb on DT systems
    efi/x86: Limit EFI old memory map to SGI UV machines
    efi/x86: Avoid RWX mappings for all of DRAM
    efi/x86: Don't map the entire kernel text RW for mixed mode
    x86/mm: Fix NX bit clearing issue in kernel_map_pages_in_pgd
    efi/libstub/x86: Fix unused-variable warning
    efi/libstub/x86: Use mandatory 16-byte stack alignment in mixed mode
    efi/libstub/x86: Use const attribute for efi_is_64bit()
    efi: Allow disabling PCI busmastering on bridges during boot
    efi/x86: Allow translating 64-bit arguments for mixed mode calls
    ...

    Linus Torvalds
     
  • Pull objtool updates from Ingo Molnar:
    "The main changes are to move the ORC unwind table sorting from early
    init to build-time - this speeds up booting.

    No change in functionality intended"

    * 'core-objtool-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    x86/unwind/orc: Fix !CONFIG_MODULES build warning
    x86/unwind/orc: Remove boot-time ORC unwind tables sorting
    scripts/sorttable: Implement build-time ORC unwind table sorting
    scripts/sorttable: Rename 'sortextable' to 'sorttable'
    scripts/sortextable: Refactor the do_func() function
    scripts/sortextable: Remove dead code
    scripts/sortextable: Clean up the code to meet the kernel coding style better
    scripts/sortextable: Rewrite error/success handling

    Linus Torvalds
     

18 Jan, 2020

2 commits


16 Jan, 2020

1 commit


15 Jan, 2020

1 commit


14 Jan, 2020

1 commit


11 Jan, 2020

1 commit


07 Jan, 2020

1 commit


29 Dec, 2019

1 commit


25 Dec, 2019

1 commit


19 Dec, 2019

1 commit


13 Dec, 2019

1 commit

  • Use a more generic name for additional table sorting usecases,
    such as the upcoming ORC table sorting feature. This tool is
    not tied to exception table sorting anymore.

    No functional changes intended.

    [ mingo: Rewrote the changelog. ]

    Signed-off-by: Shile Zhang
    Acked-by: Peter Zijlstra (Intel)
    Cc: Josh Poimboeuf
    Cc: Masahiro Yamada
    Cc: Michal Marek
    Cc: linux-kbuild@vger.kernel.org
    Link: https://lkml.kernel.org/r/20191204004633.88660-6-shile.zhang@linux.alibaba.com
    Signed-off-by: Ingo Molnar

    Shile Zhang
     

10 Dec, 2019

4 commits

  • In the x86 MM code we'd like to untangle various types of historic
    header dependency spaghetti, but for this we'd need to pass to
    the generic vmalloc code various vmalloc related defines that
    customarily come via the low level arch header.

    Signed-off-by: Ingo Molnar

    Ingo Molnar
     
  • Commit 6aae3425aa9c ("ARC: mm: remove __ARCH_USE_5LEVEL_HACK") make ARC
    paging code 5-level compliant but left behind a stale define of
    __ARCH_USE_5LEVEL_HACK in arch/arc/include/asm/hugepage.h.

    Remove it.

    Signed-off-by: Mike Rapoport
    Signed-off-by: Vineet Gupta

    Mike Rapoport
     
  • Fix kconfig warning for arch/arc/plat-eznps/Kconfig allmodconfig:

    WARNING: unmet direct dependencies detected for CLKSRC_NPS
    Depends on [n]: GENERIC_CLOCKEVENTS [=y] && !PHYS_ADDR_T_64BIT [=y]
    Selected by [y]:
    - ARC_PLAT_EZNPS [=y]

    Signed-off-by: Randy Dunlap
    Cc: Vineet Gupta
    Cc: Ofer Levi
    Cc: linux-snps-arc@lists.infradead.org
    Signed-off-by: Vineet Gupta

    Randy Dunlap
     
  • Replace all the occurrences of FIELD_SIZEOF() with sizeof_field() except
    at places where these are defined. Later patches will remove the unused
    definition of FIELD_SIZEOF().

    This patch is generated using following script:

    EXCLUDE_FILES="include/linux/stddef.h|include/linux/kernel.h"

    git grep -l -e "\bFIELD_SIZEOF\b" | while read file;
    do

    if [[ "$file" =~ $EXCLUDE_FILES ]]; then
    continue
    fi
    sed -i -e 's/\bFIELD_SIZEOF\b/sizeof_field/g' $file;
    done

    Signed-off-by: Pankaj Bharadiya
    Link: https://lore.kernel.org/r/20190924105839.110713-3-pankaj.laxminarayan.bharadiya@intel.com
    Co-developed-by: Kees Cook
    Signed-off-by: Kees Cook
    Acked-by: David Miller # for net

    Pankaj Bharadiya
     

08 Dec, 2019

1 commit

  • CONFIG_PREEMPTION is selected by CONFIG_PREEMPT and by CONFIG_PREEMPT_RT.
    Both PREEMPT and PREEMPT_RT require the same functionality which today
    depends on CONFIG_PREEMPT.

    Switch the entry code over to use CONFIG_PREEMPTION.

    Signed-off-by: Thomas Gleixner
    Signed-off-by: Sebastian Andrzej Siewior
    Signed-off-by: Thomas Gleixner
    Cc: Linus Torvalds
    Cc: Peter Zijlstra
    Cc: Vineet Gupta
    Cc: linux-snps-arc@lists.infradead.org
    Link: https://lore.kernel.org/r/20191015191821.11479-5-bigeasy@linutronix.de
    Signed-off-by: Ingo Molnar

    Thomas Gleixner
     

05 Dec, 2019

1 commit

  • Pull ARC updates from Vineet Gupta

    - Jump Label support for ARC

    - kmemleak enabled

    - arc mm backend TLB Miss / flush optimizations

    - nSIM platform switching to dwuart (vs. arcuart) and ensuing defconfig
    updates and cleanups

    - axs platform pll / video-mode updates

    * tag 'arc-5.5-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc:
    ARC: add kmemleak support
    ARC: [plat-axs10x]: remove hardcoded video mode from bootargs
    ARC: [plat-axs10x]: use pgu pll instead of fixed clock
    ARC: ARCv2: jump label: implement jump label patching
    ARC: mm: tlb flush optim: elide redundant uTLB invalidates for MMUv3
    ARC: mm: tlb flush optim: elide repeated uTLB invalidate in loop
    ARC: mm: tlb flush optim: Make TLBWriteNI fallback to TLBWrite if not available
    ARC: mm: TLB Miss optim: avoid re-reading ECR
    ARCv2: mm: TLB Miss optim: Use double world load/stores LDD/STD
    ARCv2: mm: TLB Miss optim: SMP builds can cache pgd pointer in mmu scratch reg
    ARC: nSIM_700: remove unused network options
    ARC: nSIM_700: switch to DW UART usage
    ARC: merge HAPS-HS with nSIM-HS configs
    ARC: HAPS: cleanup defconfigs from unused ETH drivers
    ARC: HAPS: add HIGHMEM memory zone to DTS
    ARC: HAPS: use same UART configuration everywhere
    ARC: HAPS: cleanup defconfigs from unused IO-related options
    ARC: regenerate nSIM and HAPS defconfigs

    Linus Torvalds
     

04 Dec, 2019

1 commit

  • Pull PCI updates from Bjorn Helgaas:
    "Enumeration:

    - Warn if a host bridge has no NUMA info (Yunsheng Lin)

    - Add PCI_STD_NUM_BARS for the number of standard BARs (Denis
    Efremov)

    Resource management:

    - Fix boot-time Embedded Controller GPE storm caused by incorrect
    resource assignment after ACPI Bus Check Notification (Mika
    Westerberg)

    - Protect pci_reassign_bridge_resources() against concurrent
    addition/removal (Benjamin Herrenschmidt)

    - Fix bridge dma_ranges resource list cleanup (Rob Herring)

    - Add "pci=hpmmiosize" and "pci=hpmmioprefsize" parameters to control
    the MMIO and prefetchable MMIO window sizes of hotplug bridges
    independently (Nicholas Johnson)

    - Fix MMIO/MMIO_PREF window assignment that assigned more space than
    desired (Nicholas Johnson)

    - Only enforce bus numbers from bridge EA if the bridge has EA
    devices downstream (Subbaraya Sundeep)

    - Consolidate DT "dma-ranges" parsing and convert all host drivers to
    use shared parsing (Rob Herring)

    Error reporting:

    - Restore AER capability after resume (Mayurkumar Patel)

    - Add PoisonTLPBlocked AER counter (Rajat Jain)

    - Use for_each_set_bit() to simplify AER code (Andy Shevchenko)

    - Fix AER kernel-doc (Andy Shevchenko)

    - Add "pcie_ports=dpc-native" parameter to allow native use of DPC
    even if platform didn't grant control over AER (Olof Johansson)

    Hotplug:

    - Avoid returning prematurely from sysfs requests to enable or
    disable a PCIe hotplug slot (Lukas Wunner)

    - Don't disable interrupts twice when suspending hotplug ports (Mika
    Westerberg)

    - Fix deadlocks when PCIe ports are hot-removed while suspended (Mika
    Westerberg)

    Power management:

    - Remove unnecessary ASPM locking (Bjorn Helgaas)

    - Add support for disabling L1 PM Substates (Heiner Kallweit)

    - Allow re-enabling Clock PM after it has been disabled (Heiner
    Kallweit)

    - Add sysfs attributes for controlling ASPM link states (Heiner
    Kallweit)

    - Remove CONFIG_PCIEASPM_DEBUG, including "link_state" and "clk_ctl"
    sysfs files (Heiner Kallweit)

    - Avoid AMD FCH XHCI USB PME# from D0 defect that prevents wakeup on
    USB 2.0 or 1.1 connect events (Kai-Heng Feng)

    - Move power state check out of pci_msi_supported() (Bjorn Helgaas)

    - Fix incorrect MSI-X masking on resume and revert related nvme quirk
    for Kingston NVME SSD running FW E8FK11.T (Jian-Hong Pan)

    - Always return devices to D0 when thawing to fix hibernation with
    drivers like mlx4 that used legacy power management (previously we
    only did it for drivers with new power management ops) (Dexuan Cui)

    - Clear PCIe PME Status even for legacy power management (Bjorn
    Helgaas)

    - Fix PCI PM documentation errors (Bjorn Helgaas)

    - Use dev_printk() for more power management messages (Bjorn Helgaas)

    - Apply D2 delay as milliseconds, not microseconds (Bjorn Helgaas)

    - Convert xen-platform from legacy to generic power management (Bjorn
    Helgaas)

    - Removed unused .resume_early() and .suspend_late() legacy power
    management hooks (Bjorn Helgaas)

    - Rearrange power management code for clarity (Rafael J. Wysocki)

    - Decode power states more clearly ("4" or "D4" really refers to
    "D3cold") (Bjorn Helgaas)

    - Notice when reading PM Control register returns an error (~0)
    instead of interpreting it as being in D3hot (Bjorn Helgaas)

    - Add missing link delays required by the PCIe spec (Mika Westerberg)

    Virtualization:

    - Move pci_prg_resp_pasid_required() to CONFIG_PCI_PRI (Bjorn
    Helgaas)

    - Allow VFs to use PRI (the PF PRI is shared by the VFs, but the code
    previously didn't recognize that) (Kuppuswamy Sathyanarayanan)

    - Allow VFs to use PASID (the PF PASID capability is shared by the
    VFs, but the code previously didn't recognize that) (Kuppuswamy
    Sathyanarayanan)

    - Disconnect PF and VF ATS enablement, since ATS in PFs and
    associated VFs can be enabled independently (Kuppuswamy
    Sathyanarayanan)

    - Cache PRI and PASID capability offsets (Kuppuswamy Sathyanarayanan)

    - Cache the PRI PRG Response PASID Required bit (Bjorn Helgaas)

    - Consolidate ATS declarations in linux/pci-ats.h (Krzysztof
    Wilczynski)

    - Remove unused PRI and PASID stubs (Bjorn Helgaas)

    - Removed unnecessary EXPORT_SYMBOL_GPL() from ATS, PRI, and PASID
    interfaces that are only used by built-in IOMMU drivers (Bjorn
    Helgaas)

    - Hide PRI and PASID state restoration functions used only inside the
    PCI core (Bjorn Helgaas)

    - Add a DMA alias quirk for the Intel VCA NTB (Slawomir Pawlowski)

    - Serialize sysfs sriov_numvfs reads vs writes (Pierre Crégut)

    - Update Cavium ACS quirk for ThunderX2 and ThunderX3 (George
    Cherian)

    - Fix the UPDCR register address in the Intel ACS quirk (Steffen
    Liebergeld)

    - Unify ACS quirk implementations (Bjorn Helgaas)

    Amlogic Meson host bridge driver:

    - Fix meson PERST# GPIO polarity problem (Remi Pommarel)

    - Add DT bindings for Amlogic Meson G12A (Neil Armstrong)

    - Fix meson clock names to match DT bindings (Neil Armstrong)

    - Add meson support for Amlogic G12A SoC with separate shared PHY
    (Neil Armstrong)

    - Add meson extended PCIe PHY functions for Amlogic G12A USB3+PCIe
    combo PHY (Neil Armstrong)

    - Add arm64 DT for Amlogic G12A PCIe controller node (Neil Armstrong)

    - Add commented-out description of VIM3 USB3/PCIe mux in arm64 DT
    (Neil Armstrong)

    Broadcom iProc host bridge driver:

    - Invalidate iProc PAXB address mapping before programming it
    (Abhishek Shah)

    - Fix iproc-msi and mvebu __iomem annotations (Ben Dooks)

    Cadence host bridge driver:

    - Refactor Cadence PCIe host controller to use as a library for both
    host and endpoint (Tom Joseph)

    Freescale Layerscape host bridge driver:

    - Add layerscape LS1028a support (Xiaowei Bao)

    Intel VMD host bridge driver:

    - Add VMD bus 224-255 restriction decode (Jon Derrick)

    - Add VMD 8086:9A0B device ID (Jon Derrick)

    - Remove Keith from VMD maintainer list (Keith Busch)

    Marvell ARMADA 3700 / Aardvark host bridge driver:

    - Use LTSSM state to build link training flag since Aardvark doesn't
    implement the Link Training bit (Remi Pommarel)

    - Delay before training Aardvark link in case PERST# was asserted
    before the driver probe (Remi Pommarel)

    - Fix Aardvark issues with Root Control reads and writes (Remi
    Pommarel)

    - Don't rely on jiffies in Aardvark config access path since
    interrupts may be disabled (Remi Pommarel)

    - Fix Aardvark big-endian support (Grzegorz Jaszczyk)

    Marvell ARMADA 370 / XP host bridge driver:

    - Make mvebu_pci_bridge_emul_ops static (Ben Dooks)

    Microsoft Hyper-V host bridge driver:

    - Add hibernation support for Hyper-V virtual PCI devices (Dexuan
    Cui)

    - Track Hyper-V pci_protocol_version per-hbus, not globally (Dexuan
    Cui)

    - Avoid kmemleak false positive on hv hbus buffer (Dexuan Cui)

    Mobiveil host bridge driver:

    - Change mobiveil csr_read()/write() function names that conflict
    with riscv arch functions (Kefeng Wang)

    NVIDIA Tegra host bridge driver:

    - Fix Tegra CLKREQ dependency programming (Vidya Sagar)

    Renesas R-Car host bridge driver:

    - Remove unnecessary header include from rcar (Andrew Murray)

    - Tighten register index checking for rcar inbound range programming
    (Marek Vasut)

    - Fix rcar inbound range alignment calculation to improve packing of
    multiple entries (Marek Vasut)

    - Update rcar MACCTLR setting to match documentation (Yoshihiro
    Shimoda)

    - Clear bit 0 of MACCTLR before PCIETCTLR.CFINIT per manual
    (Yoshihiro Shimoda)

    - Add Marek Vasut and Yoshihiro Shimoda as R-Car maintainers (Simon
    Horman)

    Rockchip host bridge driver:

    - Make rockchip 0V9 and 1V8 power regulators non-optional (Robin
    Murphy)

    Socionext UniPhier host bridge driver:

    - Set uniphier to host (RC) mode always (Kunihiko Hayashi)

    Endpoint drivers:

    - Fix endpoint driver sign extension problem when shifting page
    number to phys_addr_t (Alan Mikhak)

    Misc:

    - Add NumaChip SPDX header (Krzysztof Wilczynski)

    - Replace EXTRA_CFLAGS with ccflags-y (Krzysztof Wilczynski)

    - Remove unused includes (Krzysztof Wilczynski)

    - Removed unused sysfs attribute groups (Ben Dooks)

    - Remove PTM and ASPM dependencies on PCIEPORTBUS (Bjorn Helgaas)

    - Add PCIe Link Control 2 register field definitions to replace magic
    numbers in AMDGPU and Radeon CIK/SI (Bjorn Helgaas)

    - Fix incorrect Link Control 2 Transmit Margin usage in AMDGPU and
    Radeon CIK/SI PCIe Gen3 link training (Bjorn Helgaas)

    - Use pcie_capability_read_word() instead of pci_read_config_word()
    in AMDGPU and Radeon CIK/SI (Frederick Lawler)

    - Remove unused pci_irq_get_node() Greg Kroah-Hartman)

    - Make asm/msi.h mandatory and simplify PCI_MSI_IRQ_DOMAIN Kconfig
    (Palmer Dabbelt, Michal Simek)

    - Read all 64 bits of Switchtec part_event_bitmap (Logan Gunthorpe)

    - Fix erroneous intel-iommu dependency on CONFIG_AMD_IOMMU (Bjorn
    Helgaas)

    - Fix bridge emulation big-endian support (Grzegorz Jaszczyk)

    - Fix dwc find_next_bit() usage (Niklas Cassel)

    - Fix pcitest.c fd leak (Hewenliang)

    - Fix typos and comments (Bjorn Helgaas)

    - Fix Kconfig whitespace errors (Krzysztof Kozlowski)"

    * tag 'pci-v5.5-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: (160 commits)
    PCI: Remove PCI_MSI_IRQ_DOMAIN architecture whitelist
    asm-generic: Make msi.h a mandatory include/asm header
    Revert "nvme: Add quirk for Kingston NVME SSD running FW E8FK11.T"
    PCI/MSI: Fix incorrect MSI-X masking on resume
    PCI/MSI: Move power state check out of pci_msi_supported()
    PCI/MSI: Remove unused pci_irq_get_node()
    PCI: hv: Avoid a kmemleak false positive caused by the hbus buffer
    PCI: hv: Change pci_protocol_version to per-hbus
    PCI: hv: Add hibernation support
    PCI: hv: Reorganize the code in preparation of hibernation
    MAINTAINERS: Remove Keith from VMD maintainer
    PCI/ASPM: Remove PCIEASPM_DEBUG Kconfig option and related code
    PCI/ASPM: Add sysfs attributes for controlling ASPM link states
    PCI: Fix indentation
    drm/radeon: Prefer pcie_capability_read_word()
    drm/radeon: Replace numbers with PCI_EXP_LNKCTL2 definitions
    drm/radeon: Correct Transmit Margin masks
    drm/amdgpu: Prefer pcie_capability_read_word()
    PCI: uniphier: Set mode register to host mode
    drm/amdgpu: Replace numbers with PCI_EXP_LNKCTL2 definitions
    ...

    Linus Torvalds
     

02 Dec, 2019

2 commits

  • Merge updates from Andrew Morton:
    "Incoming:

    - a small number of updates to scripts/, ocfs2 and fs/buffer.c

    - most of MM

    I still have quite a lot of material (mostly not MM) staged after
    linux-next due to -next dependencies. I'll send those across next week
    as the preprequisites get merged up"

    * emailed patches from Andrew Morton : (135 commits)
    mm/page_io.c: annotate refault stalls from swap_readpage
    mm/Kconfig: fix trivial help text punctuation
    mm/Kconfig: fix indentation
    mm/memory_hotplug.c: remove __online_page_set_limits()
    mm: fix typos in comments when calling __SetPageUptodate()
    mm: fix struct member name in function comments
    mm/shmem.c: cast the type of unmap_start to u64
    mm: shmem: use proper gfp flags for shmem_writepage()
    mm/shmem.c: make array 'values' static const, makes object smaller
    userfaultfd: require CAP_SYS_PTRACE for UFFD_FEATURE_EVENT_FORK
    fs/userfaultfd.c: wp: clear VM_UFFD_MISSING or VM_UFFD_WP during userfaultfd_register()
    userfaultfd: wrap the common dst_vma check into an inlined function
    userfaultfd: remove unnecessary WARN_ON() in __mcopy_atomic_hugetlb()
    userfaultfd: use vma_pagesize for all huge page size calculation
    mm/madvise.c: use PAGE_ALIGN[ED] for range checking
    mm/madvise.c: replace with page_size() in madvise_inject_error()
    mm/mmap.c: make vma_merge() comment more easy to understand
    mm/hwpoison-inject: use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs fops
    autonuma: reduce cache footprint when scanning page tables
    autonuma: fix watermark checking in migrate_balanced_pgdat()
    ...

    Linus Torvalds
     
  • Pull sysctl system call removal from Eric Biederman:
    "As far as I can tell we have reached the point where no one enables
    the sysctl system call anymore. It still is enabled in a few
    defconfigs but they are mostly the rarely used one and in asking
    people about that it was more cut & paste enabled than anything else.

    This is single commit that just deletes code. Leaving just enough code
    so that the deprecated sysctl warning continues to be printed. If my
    analysis turns out to be wrong and someone actually cares it will be
    easy to revert this commit and have the system call again.

    There was one new xtensa defconfig in linux-next that enabled the
    system call this cycle and when asked about it the maintainer of the
    code replied that it was not enabled on purpose. As of today's
    linux-next tree that defconfig no longer enables the system call.

    What we saw in the review discussion was that if we go a step farther
    than my patch and mess with uapi headers there are pieces of code that
    won't compile, but nothing minds the system call actually disappearing
    from the kernel"

    Link: https://lore.kernel.org/lkml/201910011140.EA0181F13@keescook/

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace:
    sysctl: Remove the sysctl system call

    Linus Torvalds
     

01 Dec, 2019

1 commit

  • Patch series "elide extraneous generated code for folded p4d/pud/pmd", v3.

    This series came out of seemingly benign excursion into
    understanding/removing __ARCH_USE_5LEVEL_HACK from ARC port showing some
    extraneous code being generated despite folded p4d/pud/pmd

    | bloat-o-meter2 vmlinux-[AB]*
    | add/remove: 0/0 grow/shrink: 3/0 up/down: 130/0 (130)
    | function old new delta
    | free_pgd_range 548 660 +112
    | p4d_clear_bad 2 20 +18

    The patches here address that

    | bloat-o-meter2 vmlinux-[BF]*
    | add/remove: 0/2 grow/shrink: 0/1 up/down: 0/-386 (-386)
    | function old new delta
    | pud_clear_bad 20 - -20
    | p4d_clear_bad 20 - -20
    | free_pgd_range 660 314 -346

    The code savings are not a whole lot, but still worthwhile IMHO.

    This patch (of 5):

    With paging code made 5-level compliant, this is no longer needed. ARC
    has software page walker with 2 lookup levels (pgd -> pte)

    This was expected to be non functional change but ended with slight
    code bloat due to needless inclusions of p*d_free_tlb() macros which
    will be addressed in further patches.

    | bloat-o-meter2 vmlinux-[AB]*
    | add/remove: 0/0 grow/shrink: 2/0 up/down: 128/0 (128)
    | function old new delta
    | free_pgd_range 546 656 +110
    | p4d_clear_bad 2 20 +18
    | Total: Before=4137148, After=4137276, chg 0.000000%

    Link: http://lkml.kernel.org/r/20191016162400.14796-2-vgupta@synopsys.com
    Signed-off-by: Vineet Gupta
    Acked-by: Kirill A. Shutemov
    Cc: "Aneesh Kumar K . V"
    Cc: Arnd Bergmann
    Cc: Nick Piggin
    Cc: Peter Zijlstra
    Cc: Will Deacon
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Vineet Gupta
     

29 Nov, 2019

2 commits

  • …linux; tag 'dma-mapping-5.5' of git://git.infradead.org/users/hch/dma-mapping

    Pull dma-mapping updates from Christoph Hellwig:

    - improve dma-debug scalability (Eric Dumazet)

    - tiny dma-debug cleanup (Dan Carpenter)

    - check for vmap memory in dma_map_single (Kees Cook)

    - check for dma_addr_t overflows in dma-direct when using DMA offsets
    (Nicolas Saenz Julienne)

    - switch the x86 sta2x11 SOC to use more generic DMA code (Nicolas
    Saenz Julienne)

    - fix arm-nommu dma-ranges handling (Vladimir Murzin)

    - use __initdata in CMA (Shyam Saini)

    - replace the bus dma mask with a limit (Nicolas Saenz Julienne)

    - merge the remapping helpers into the main dma-direct flow (me)

    - switch xtensa to the generic dma remap handling (me)

    - various cleanups around dma_capable (me)

    - remove unused dev arguments to various dma-noncoherent helpers (me)

    * 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux:

    * tag 'dma-mapping-5.5' of git://git.infradead.org/users/hch/dma-mapping: (22 commits)
    dma-mapping: treat dev->bus_dma_mask as a DMA limit
    dma-direct: exclude dma_direct_map_resource from the min_low_pfn check
    dma-direct: don't check swiotlb=force in dma_direct_map_resource
    dma-debug: clean up put_hash_bucket()
    powerpc: remove support for NULL dev in __phys_to_dma / __dma_to_phys
    dma-direct: avoid a forward declaration for phys_to_dma
    dma-direct: unify the dma_capable definitions
    dma-mapping: drop the dev argument to arch_sync_dma_for_*
    x86/PCI: sta2x11: use default DMA address translation
    dma-direct: check for overflows on 32 bit DMA addresses
    dma-debug: increase HASH_SIZE
    dma-debug: reorder struct dma_debug_entry fields
    xtensa: use the generic uncached segment support
    dma-mapping: merge the generic remapping helpers into dma-direct
    dma-direct: provide mmap and get_sgtable method overrides
    dma-direct: remove the dma_handle argument to __dma_direct_alloc_pages
    dma-direct: remove __dma_direct_free_pages
    usb: core: Remove redundant vmap checks
    kernel: dma-contiguous: mark CMA parameters __initdata/__initconst
    dma-debug: add a schedule point in debug_dma_dump_mappings()
    ...

    Linus Torvalds
     
  • Pull generic ioremap support from Christoph Hellwig:
    "This adds the remaining bits for an entirely generic ioremap and
    iounmap to lib/ioremap.c. To facilitate that, it cleans up the giant
    mess of weird ioremap variants we had with no users outside the arch
    code.

    For now just the three newest ports use the code, but there is more
    than a handful others that can be converted without too much work.

    Summary:

    - clean up various obsolete ioremap and iounmap variants

    - add a new generic ioremap implementation and switch csky, nds32 and
    riscv over to it"

    * tag 'ioremap-5.5' of git://git.infradead.org/users/hch/ioremap: (21 commits)
    nds32: use generic ioremap
    csky: use generic ioremap
    csky: remove ioremap_cache
    riscv: use the generic ioremap code
    lib: provide a simple generic ioremap implementation
    sh: remove __iounmap
    nios2: remove __iounmap
    hexagon: remove __iounmap
    m68k: rename __iounmap and mark it static
    arch: rely on asm-generic/io.h for default ioremap_* definitions
    asm-generic: don't provide ioremap for CONFIG_MMU
    asm-generic: ioremap_uc should behave the same with and without MMU
    xtensa: clean up ioremap
    x86: Clean up ioremap()
    parisc: remove __ioremap
    nios2: remove __ioremap
    alpha: remove the unused __ioremap wrapper
    hexagon: clean up ioremap
    ia64: rename ioremap_nocache to ioremap_uc
    unicore32: remove ioremap_cached
    ...

    Linus Torvalds
     

27 Nov, 2019

3 commits

  • msi.h is generic for all architectures except x86, which has its own
    version. Enabling MSI by adding msi.h to every architecture's Kbuild is
    just an additional step which doesn't need to be done.

    Make msi.h mandatory in the asm-generic/Kbuild so we don't have to do it
    for each architecture.

    Suggested-by: Christoph Hellwig
    Link: https://lore.kernel.org/r/c991669e29a79b1a8e28c3b4b3a125801a693de8.1571983829.git.michal.simek@xilinx.com
    Tested-by: Paul Walmsley # build only, rv32/rv64
    Signed-off-by: Michal Simek
    Signed-off-by: Bjorn Helgaas
    Reviewed-by: Masahiro Yamada
    Acked-by: Waiman Long
    Acked-by: Paul Walmsley # arch/riscv

    Michal Simek
     
  • This system call has been deprecated almost since it was introduced, and
    in a survey of the linux distributions I can no longer find any of them
    that enable CONFIG_SYSCTL_SYSCALL. The only indication that I can find
    that anyone might care is that a few of the defconfigs in the kernel
    enable CONFIG_SYSCTL_SYSCALL. However this appears in only 31 of 414
    defconfigs in the kernel, so I suspect this symbols presence is simply
    because it is harmless to include rather than because it is necessary.

    As there appear to be no users of the sysctl system call, remove the
    code. As this removes one of the few uses of the internal kernel mount
    of proc I hope this allows for even more simplifications of the proc
    filesystem.

    Cc: Alex Smith
    Cc: Anders Berg
    Cc: Apelete Seketeli
    Cc: Arnd Bergmann
    Cc: Chee Nouk Phoon
    Cc: Chris Zankel
    Cc: Christian Ruppert
    Cc: Greg Ungerer
    Cc: Harvey Hunt
    Cc: Helge Deller
    Cc: Hongliang Tao
    Cc: Hua Yan
    Cc: Huacai Chen
    Cc: John Crispin
    Cc: Jonas Jensen
    Cc: Josh Boyer
    Cc: Jun Nie
    Cc: Kevin Hilman
    Cc: Kevin Wells
    Cc: Kumar Gala
    Cc: Lars-Peter Clausen
    Cc: Ley Foon Tan
    Cc: Linus Walleij
    Cc: Markos Chandras
    Cc: Max Filippov
    Cc: Noam Camus
    Cc: Olof Johansson
    Cc: Paul Burton
    Cc: Paul Mundt
    Cc: Phil Edworthy
    Cc: Pierrick Hascoet
    Cc: Ralf Baechle
    Cc: Roland Stigge
    Cc: Santosh Shilimkar
    Cc: Scott Telford
    Cc: Stephen Boyd
    Cc: Steven J. Hill
    Cc: Tanmay Inamdar
    Cc: Vineet Gupta
    Cc: Wolfram Sang
    Acked-by: Andi Kleen
    Reviewed-by: Kees Cook
    Signed-off-by: "Eric W. Biederman"

    Eric W. Biederman
     
  • Pull x86 asm updates from Ingo Molnar:
    "The main changes in this cycle were:

    - Cross-arch changes to move the linker sections for NOTES and
    EXCEPTION_TABLE into the RO_DATA area, where they belong on most
    architectures. (Kees Cook)

    - Switch the x86 linker fill byte from x90 (NOP) to 0xcc (INT3), to
    trap jumps into the middle of those padding areas instead of
    sliding execution. (Kees Cook)

    - A thorough cleanup of symbol definitions within x86 assembler code.
    The rather randomly named macros got streamlined around a
    (hopefully) straightforward naming scheme:

    SYM_START(name, linkage, align...)
    SYM_END(name, sym_type)

    SYM_FUNC_START(name)
    SYM_FUNC_END(name)

    SYM_CODE_START(name)
    SYM_CODE_END(name)

    SYM_DATA_START(name)
    SYM_DATA_END(name)

    etc - with about three times of these basic primitives with some
    label, local symbol or attribute variant, expressed via postfixes.

    No change in functionality intended. (Jiri Slaby)

    - Misc other changes, cleanups and smaller fixes"

    * 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (67 commits)
    x86/entry/64: Remove pointless jump in paranoid_exit
    x86/entry/32: Remove unused resume_userspace label
    x86/build/vdso: Remove meaningless CFLAGS_REMOVE_*.o
    m68k: Convert missed RODATA to RO_DATA
    x86/vmlinux: Use INT3 instead of NOP for linker fill bytes
    x86/mm: Report actual image regions in /proc/iomem
    x86/mm: Report which part of kernel image is freed
    x86/mm: Remove redundant address-of operators on addresses
    xtensa: Move EXCEPTION_TABLE to RO_DATA segment
    powerpc: Move EXCEPTION_TABLE to RO_DATA segment
    parisc: Move EXCEPTION_TABLE to RO_DATA segment
    microblaze: Move EXCEPTION_TABLE to RO_DATA segment
    ia64: Move EXCEPTION_TABLE to RO_DATA segment
    h8300: Move EXCEPTION_TABLE to RO_DATA segment
    c6x: Move EXCEPTION_TABLE to RO_DATA segment
    arm64: Move EXCEPTION_TABLE to RO_DATA segment
    alpha: Move EXCEPTION_TABLE to RO_DATA segment
    x86/vmlinux: Move EXCEPTION_TABLE to RO_DATA segment
    x86/vmlinux: Actually use _etext for the end of the text segment
    vmlinux.lds.h: Allow EXCEPTION_TABLE to live in RO_DATA
    ...

    Linus Torvalds