06 Dec, 2018

1 commit

  • commit 9c4bf5e0db164f330a2d3e128e9832661f69f0e9 upstream.

    The function_graph_enter() function does the work of calling the function
    graph hook function and the management of the shadow stack, simplifying the
    work done in the architecture dependent prepare_ftrace_return().

    Have sparc use the new code, and remove the shadow stack management as well as
    having to set up the trace structure.

    This is needed to prepare for a fix of a design bug on how the curr_ret_stack
    is used.

    Cc: "David S. Miller"
    Cc: sparclinux@vger.kernel.org
    Cc: stable@kernel.org
    Fixes: 03274a3ffb449 ("tracing/fgraph: Adjust fgraph depth before calling trace return callback")
    Reviewed-by: Masami Hiramatsu
    Signed-off-by: Steven Rostedt (VMware)
    Signed-off-by: Greg Kroah-Hartman

    Steven Rostedt (VMware)
     

04 Nov, 2018

3 commits

  • [ Upstream commit 1f2b5b8e2df4591fbca430aff9c5a072dcc0f408 ]

    Fixes: 8b30ca73b7cc ("sparc: Add all necessary direct socket system calls.")
    Reported-by: Joseph Myers
    Signed-off-by: David S. Miller
    Signed-off-by: Greg Kroah-Hartman

    David S. Miller
     
  • [ Upstream commit 5b4fc3882a649c9411dd0dcad2ddb78e911d340e ]

    Right now if we get a corrupted user stack frame we do a
    do_exit(SIGILL) which is not helpful.

    If under a debugger, this behavior causes the inferior process to
    exit. So the register and other state cannot be examined at the time
    of the event.

    Instead, conditionally log a rate limited kernel log message and then
    force a SIGSEGV.

    With bits and ideas borrowed (as usual) from powerpc.

    Signed-off-by: David S. Miller
    Signed-off-by: Greg Kroah-Hartman

    David Miller
     
  • [ Upstream commit 2b4792eaa9f553764047d157365ed8b7787751a3 ]

    Some drivers reference it via node_distance(), for example the
    NVME host driver core.

    ERROR: "__node_distance" [drivers/nvme/host/nvme-core.ko] undefined!
    make[1]: *** [scripts/Makefile.modpost:92: __modpost] Error 1

    Signed-off-by: David S. Miller
    Signed-off-by: Greg Kroah-Hartman

    David S. Miller
     

18 Oct, 2018

2 commits


16 Oct, 2018

1 commit


15 Oct, 2018

2 commits


13 Oct, 2018

2 commits

  • Like x86 and arm, call perf_sample_event_took() in perf event
    NMI interrupt handler.

    Signed-off-by: David S. Miller

    David S. Miller
     
  • It is important to clear the hw->state value for non-stopped events
    when they are added into the PMU. Otherwise when the event is
    scheduled out, we won't read the counter because HES_UPTODATE is still
    set. This breaks 'perf stat' and similar use cases, causing all the
    events to show zero.

    This worked for multi-pcr because we make explicit sparc_pmu_start()
    calls in calculate_multiple_pcrs(). calculate_single_pcr() doesn't do
    this because the idea there is to accumulate all of the counter
    settings into the single pcr value. So we have to add explicit
    hw->state handling there.

    Like x86, we use the PERF_HES_ARCH bit to track truly stopped events
    so that we don't accidently start them on a reload.

    Related to all of this, sparc_pmu_start() is missing a userpage update
    so add it.

    Signed-off-by: David S. Miller

    David S. Miller
     

10 Oct, 2018

1 commit


08 Oct, 2018

5 commits

  • Replace "fallthru" with a proper "fall through" annotation.

    This fix is part of the ongoing efforts to enabling
    -Wimplicit-fallthrough

    Signed-off-by: Gustavo A. R. Silva
    Signed-off-by: David S. Miller

    Gustavo A. R. Silva
     
  • Replace "fallthru" with a proper "fall through" annotation.

    This fix is part of the ongoing efforts to enabling
    -Wimplicit-fallthrough

    Signed-off-by: Gustavo A. R. Silva
    Signed-off-by: David S. Miller

    Gustavo A. R. Silva
     
  • arch/sparc/vdso/Makefile is a replica of arch/x86/entry/vdso/Makefile.

    Clean-up the Makefile in the same way as I did for x86:

    - Remove unnecessary export
    - Put the generated linker script to $(obj)/ instead of $(src)/
    - Simplify cmd_vdso2c

    The corresponding x86 commits are:

    - 61615faf0a89 ("x86/build/vdso: Remove unnecessary export in Makefile")
    - 1742ed2088cc ("x86/build/vdso: Put generated linker scripts to $(obj)/")
    - c5fcdbf15523 ("x86/build/vdso: Simplify 'cmd_vdso2c'")

    Signed-off-by: Masahiro Yamada
    Signed-off-by: David S. Miller

    Masahiro Yamada
     
  • In the quest to remove all stack VLA usage from the kernel[1], this
    allocates a fixed size array for the maximum number of cookies and
    adds a runtime sanity check.

    [1] https://lkml.kernel.org/r/CA+55aFzCG-zNmZwX4A2FQpadafLfEzK6CC=qPXydAacU1
    RqZWA@mail.gmail.com

    Signed-off-by: Kees Cook
    Signed-off-by: David S. Miller

    Kees Cook
     
  • In preparation to remove the node name pointer from struct device_node,
    convert printf users to use the %pOFn format specifier.

    Cc: "David S. Miller"
    Cc: sparclinux@vger.kernel.org
    Signed-off-by: Rob Herring
    Signed-off-by: David S. Miller

    Rob Herring
     

02 Sep, 2018

1 commit


26 Aug, 2018

1 commit

  • Pull more Kbuild updates from Masahiro Yamada:

    - add build_{menu,n,g,x}config targets for compile-testing Kconfig

    - fix and improve recursive dependency detection in Kconfig

    - fix parallel building of menuconfig/nconfig

    - fix syntax error in clang-version.sh

    - suppress distracting log from syncconfig

    - remove obsolete "rpm" target

    - remove VMLINUX_SYMBOL(_STR) macro entirely

    - fix microblaze build with CONFIG_DYNAMIC_FTRACE

    - move compiler test for dead code/data elimination to Kconfig

    - rename well-known LDFLAGS variable to KBUILD_LDFLAGS

    - misc fixes and cleanups

    * tag 'kbuild-v4.19-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
    kbuild: rename LDFLAGS to KBUILD_LDFLAGS
    kbuild: pass LDFLAGS to recordmcount.pl
    kbuild: test dead code/data elimination support in Kconfig
    initramfs: move gen_initramfs_list.sh from scripts/ to usr/
    vmlinux.lds.h: remove stale include
    export.h: remove VMLINUX_SYMBOL() and VMLINUX_SYMBOL_STR()
    Coccinelle: remove pci_alloc_consistent semantic to detect in zalloc-simple.cocci
    kbuild: make sorting initramfs contents independent of locale
    kbuild: remove "rpm" target, which is alias of "rpm-pkg"
    kbuild: Fix LOADLIBES rename in Documentation/kbuild/makefiles.txt
    kconfig: suppress "configuration written to .config" for syncconfig
    kconfig: fix "Can't open ..." in parallel build
    kbuild: Add a space after `!` to prevent parsing as file pattern
    scripts: modpost: check memory allocation results
    kconfig: improve the recursive dependency report
    kconfig: report recursive dependency involving 'imply'
    kconfig: error out when seeing recursive dependency
    kconfig: add build-only configurator targets
    scripts/dtc: consolidate include path options in Makefile

    Linus Torvalds
     

25 Aug, 2018

1 commit

  • Pull namespace fixes from Eric Biederman:
    "This is a set of four fairly obvious bug fixes:

    - a switch from d_find_alias to d_find_any_alias because the xattr
    code perversely takes a dentry

    - two mutex vs copy_to_user fixes from Jann Horn

    - a fix to use a sanitized size not the size userspace passed in from
    Christian Brauner"

    * 'userns-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace:
    getxattr: use correct xattr length
    sys: don't hold uts_sem while accessing userspace memory
    userns: move user access out of the mutex
    cap_inode_getsecurity: use d_find_any_alias() instead of d_find_alias()

    Linus Torvalds
     

24 Aug, 2018

1 commit

  • Commit a0f97e06a43c ("kbuild: enable 'make CFLAGS=...' to add
    additional options to CC") renamed CFLAGS to KBUILD_CFLAGS.

    Commit 222d394d30e7 ("kbuild: enable 'make AFLAGS=...' to add
    additional options to AS") renamed AFLAGS to KBUILD_AFLAGS.

    Commit 06c5040cdb13 ("kbuild: enable 'make CPPFLAGS=...' to add
    additional options to CPP") renamed CPPFLAGS to KBUILD_CPPFLAGS.

    For some reason, LDFLAGS was not renamed.

    Using a well-known variable like LDFLAGS may result in accidental
    override of the variable.

    Kbuild generally uses KBUILD_ prefixed variables for the internally
    appended options, so here is one more conversion to sanitize the
    naming convention.

    I did not touch Makefiles under tools/ since the tools build system
    is a different world.

    Signed-off-by: Masahiro Yamada
    Acked-by: Kirill A. Shutemov
    Reviewed-by: Palmer Dabbelt

    Masahiro Yamada
     

22 Aug, 2018

5 commits

  • As commit 5ba800962a80 ("kbuild: update ARCH alias info for sparc")
    addressed, SPARC accepts ARCH=sparc32 as an alias.

    However, arch/sparc/Makefile wrongly sets KBUILD_DEFCONFIG, then
    sparc64_defconfig is chosen as the base configuration for ARCH=sparc32.

    $ make ARCH=sparc32 defconfig
    *** Default configuration is based on 'sparc64_defconfig'
    #
    # configuration written to .config
    #

    Fix the logic to choose sparc64_defconfig only when ARCH=sparc64.

    Signed-off-by: Masahiro Yamada
    Signed-off-by: David S. Miller

    Masahiro Yamada
     
  • The detection and reservation of ramdisk memory were separated to allow
    bootmem bitmap initialization after the ramdisk boundaries are detected.
    Since the bootmem initialization is removed, the reservation of ramdisk
    memory is done immediately after its boundaries are found.

    Split the entire block into a separate helper function.

    Signed-off-by: Mike Rapoport
    Suggested-by: Sam Ravnborg
    Reviewed-by: Sam Ravnborg
    Signed-off-by: David S. Miller

    Mike Rapoport
     
  • Each populated sparc_phys_bank is added to memblock.memory. The
    reserve_bootmem() calls are replaced with memblock_reserve(), and the
    bootmem bitmap initialization is droppped.

    Signed-off-by: Mike Rapoport
    Reviewed-by: Sam Ravnborg
    Signed-off-by: David S. Miller

    Mike Rapoport
     
  • Signed-off-by: Mike Rapoport
    Signed-off-by: David S. Miller

    Mike Rapoport
     
  • Switch to the generic noncoherent direct mapping implementation.

    This removes the previous sync_single_for_device implementation, which
    looks bogus given that no syncing is happening in the similar but more
    important map_single case.

    Signed-off-by: Christoph Hellwig
    Acked-by: Sam Ravnborg
    Signed-off-by: David S. Miller

    Christoph Hellwig
     

18 Aug, 2018

1 commit

  • Use new return type vm_fault_t for fault handler. For now, this is just
    documenting that the function returns a VM_FAULT value rather than an
    errno. Once all instances are converted, vm_fault_t will become a
    distinct type.

    Ref-> commit 1c8f422059ae ("mm: change return type to vm_fault_t")

    In this patch all the caller of handle_mm_fault() are changed to return
    vm_fault_t type.

    Link: http://lkml.kernel.org/r/20180617084810.GA6730@jordon-HP-15-Notebook-PC
    Signed-off-by: Souptick Joarder
    Cc: Matthew Wilcox
    Cc: Richard Henderson
    Cc: Tony Luck
    Cc: Matt Turner
    Cc: Vineet Gupta
    Cc: Russell King
    Cc: Catalin Marinas
    Cc: Will Deacon
    Cc: Richard Kuo
    Cc: Geert Uytterhoeven
    Cc: Michal Simek
    Cc: James Hogan
    Cc: Ley Foon Tan
    Cc: Jonas Bonn
    Cc: James E.J. Bottomley
    Cc: Benjamin Herrenschmidt
    Cc: Palmer Dabbelt
    Cc: Yoshinori Sato
    Cc: David S. Miller
    Cc: Richard Weinberger
    Cc: Guan Xuetao
    Cc: Thomas Gleixner
    Cc: "H. Peter Anvin"
    Cc: "Levin, Alexander (Sasha Levin)"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Souptick Joarder
     

16 Aug, 2018

3 commits

  • Pull crypto updates from Herbert Xu:
    "API:
    - Fix dcache flushing crash in skcipher.
    - Add hash finup self-tests.
    - Reschedule during speed tests.

    Algorithms:
    - Remove insecure vmac and replace it with vmac64.
    - Add public key verification for DH/ECDH.

    Drivers:
    - Decrease priority of sha-mb on x86.
    - Improve NEON latency/throughput on ARM64.
    - Add md5/sha384/sha512/des/3des to inside-secure.
    - Support eip197d in inside-secure.
    - Only register algorithms supported by the host in virtio.
    - Add cts and remove incompatible cts1 from ccree.
    - Add hisilicon SEC security accelerator driver.
    - Replace msm hwrng driver with qcom pseudo rng driver.

    Misc:
    - Centralize CRC polynomials"

    * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (121 commits)
    crypto: arm64/ghash-ce - implement 4-way aggregation
    crypto: arm64/ghash-ce - replace NEON yield check with block limit
    crypto: hisilicon - sec_send_request() can be static
    lib/mpi: remove redundant variable esign
    crypto: arm64/aes-ce-gcm - don't reload key schedule if avoidable
    crypto: arm64/aes-ce-gcm - implement 2-way aggregation
    crypto: arm64/aes-ce-gcm - operate on two input blocks at a time
    crypto: dh - make crypto_dh_encode_key() make robust
    crypto: dh - fix calculating encoded key size
    crypto: ccp - Check for NULL PSP pointer at module unload
    crypto: arm/chacha20 - always use vrev for 16-bit rotates
    crypto: ccree - allow bigger than sector XTS op
    crypto: ccree - zero all of request ctx before use
    crypto: ccree - remove cipher ivgen left overs
    crypto: ccree - drop useless type flag during reg
    crypto: ablkcipher - fix crash flushing dcache in error path
    crypto: blkcipher - fix crash flushing dcache in error path
    crypto: skcipher - fix crash flushing dcache in error path
    crypto: skcipher - remove unnecessary setting of walk->nbytes
    crypto: scatterwalk - remove scatterwalk_samebuf()
    ...

    Linus Torvalds
     
  • Pull networking updates from David Miller:
    "Highlights:

    - Gustavo A. R. Silva keeps working on the implicit switch fallthru
    changes.

    - Support 802.11ax High-Efficiency wireless in cfg80211 et al, From
    Luca Coelho.

    - Re-enable ASPM in r8169, from Kai-Heng Feng.

    - Add virtual XFRM interfaces, which avoids all of the limitations of
    existing IPSEC tunnels. From Steffen Klassert.

    - Convert GRO over to use a hash table, so that when we have many
    flows active we don't traverse a long list during accumluation.

    - Many new self tests for routing, TC, tunnels, etc. Too many
    contributors to mention them all, but I'm really happy to keep
    seeing this stuff.

    - Hardware timestamping support for dpaa_eth/fsl-fman from Yangbo Lu.

    - Lots of cleanups and fixes in L2TP code from Guillaume Nault.

    - Add IPSEC offload support to netdevsim, from Shannon Nelson.

    - Add support for slotting with non-uniform distribution to netem
    packet scheduler, from Yousuk Seung.

    - Add UDP GSO support to mlx5e, from Boris Pismenny.

    - Support offloading of Team LAG in NFP, from John Hurley.

    - Allow to configure TX queue selection based upon RX queue, from
    Amritha Nambiar.

    - Support ethtool ring size configuration in aquantia, from Anton
    Mikaev.

    - Support DSCP and flowlabel per-transport in SCTP, from Xin Long.

    - Support list based batching and stack traversal of SKBs, this is
    very exciting work. From Edward Cree.

    - Busyloop optimizations in vhost_net, from Toshiaki Makita.

    - Introduce the ETF qdisc, which allows time based transmissions. IGB
    can offload this in hardware. From Vinicius Costa Gomes.

    - Add parameter support to devlink, from Moshe Shemesh.

    - Several multiplication and division optimizations for BPF JIT in
    nfp driver, from Jiong Wang.

    - Lots of prepatory work to make more of the packet scheduler layer
    lockless, when possible, from Vlad Buslov.

    - Add ACK filter and NAT awareness to sch_cake packet scheduler, from
    Toke Høiland-Jørgensen.

    - Support regions and region snapshots in devlink, from Alex Vesker.

    - Allow to attach XDP programs to both HW and SW at the same time on
    a given device, with initial support in nfp. From Jakub Kicinski.

    - Add TLS RX offload and support in mlx5, from Ilya Lesokhin.

    - Use PHYLIB in r8169 driver, from Heiner Kallweit.

    - All sorts of changes to support Spectrum 2 in mlxsw driver, from
    Ido Schimmel.

    - PTP support in mv88e6xxx DSA driver, from Andrew Lunn.

    - Make TCP_USER_TIMEOUT socket option more accurate, from Jon
    Maxwell.

    - Support for templates in packet scheduler classifier, from Jiri
    Pirko.

    - IPV6 support in RDS, from Ka-Cheong Poon.

    - Native tproxy support in nf_tables, from Máté Eckl.

    - Maintain IP fragment queue in an rbtree, but optimize properly for
    in-order frags. From Peter Oskolkov.

    - Improvde handling of ACKs on hole repairs, from Yuchung Cheng"

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1996 commits)
    bpf: test: fix spelling mistake "REUSEEPORT" -> "REUSEPORT"
    hv/netvsc: Fix NULL dereference at single queue mode fallback
    net: filter: mark expected switch fall-through
    xen-netfront: fix warn message as irq device name has '/'
    cxgb4: Add new T5 PCI device ids 0x50af and 0x50b0
    net: dsa: mv88e6xxx: missing unlock on error path
    rds: fix building with IPV6=m
    inet/connection_sock: prefer _THIS_IP_ to current_text_addr
    net: dsa: mv88e6xxx: bitwise vs logical bug
    net: sock_diag: Fix spectre v1 gadget in __sock_diag_cmd()
    ieee802154: hwsim: using right kind of iteration
    net: hns3: Add vlan filter setting by ethtool command -K
    net: hns3: Set tx ring' tc info when netdev is up
    net: hns3: Remove tx ring BD len register in hns3_enet
    net: hns3: Fix desc num set to default when setting channel
    net: hns3: Fix for phy link issue when using marvell phy driver
    net: hns3: Fix for information of phydev lost problem when down/up
    net: hns3: Fix for command format parsing error in hclge_is_all_function_id_zero
    net: hns3: Add support for serdes loopback selftest
    bnxt_en: take coredump_record structure off stack
    ...

    Linus Torvalds
     
  • Pull Kconfig consolidation from Masahiro Yamada:
    "Consolidation of Kconfig files by Christoph Hellwig.

    Move the source statements of arch-independent Kconfig files instead
    of duplicating the includes in every arch/$(SRCARCH)/Kconfig"

    * tag 'kconfig-v4.19-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
    kconfig: add a Memory Management options" menu
    kconfig: move the "Executable file formats" menu to fs/Kconfig.binfmt
    kconfig: use a menu in arch/Kconfig to reduce clutter
    kconfig: include kernel/Kconfig.preempt from init/Kconfig
    Kconfig: consolidate the "Kernel hacking" menu
    kconfig: include common Kconfig files from top-level Kconfig
    kconfig: remove duplicate SWAP symbol defintions
    um: create a proper drivers Kconfig
    um: cleanup Kconfig files
    um: stop abusing KBUILD_KCONFIG

    Linus Torvalds
     

15 Aug, 2018

1 commit

  • Pull mtd updates from Boris Brezillon:
    "JFFS2 changes:
    - Support 64-bit timestamps

    MTD core changes:
    - Support sub-partitions
    - Clarify mtd_oob_ops documentation
    - Make Kconfig formatting consistent
    - Fix potential overflows in mtdchar_{write,read}()
    - Fallback to ->_{read,write}() when ->_{read,write}_oob() is missing
    and no OOB data were requested
    - Remove VLA usage in the bch lib

    MTD driver changes:
    - Use mtd_device_register() instead of mtd_device_parse_register()
    where applicable
    - Use proper printk format to print physical addresses in the
    solutionengine driver
    - Add missing mtd_set_of_node() call in the powernv driver
    - Remove unneeded variables in a few drivers
    - Plug the TRX part parser to the DT partition parsers logic
    - Check ioremap_cache() return code in the gpio-addr-flash driver
    - Stop using VMLINUX_SYMBOL_STR() in gen_probe.c

    SPI NOR core changes:
    - Apply reset hacks only when reset is explicitly marked as broken in
    the DT

    SPI NOR driver changes:
    - Minor cleanup/fixes in the m25p80 driver
    - Release flash_np in the nxp-spifi driver
    - Add suspend/resume hooks to the atmel-quadspi driver
    - Include gpio/consumer.h instead of gpio.h in the atmel-quadspi
    driver
    - Use %pK instead of %p in the stm32-quadspi driver
    - Improve timeout handling in the cadence-quadspi driver
    - Use mtd_device_register() instead of mtd_device_parse_register() in
    the intel-spi driver

    NAND core changes:
    - Add the SPI-NAND framework.
    - Create a helper to find the best ECC configuration.
    - Create NAND controller operations.
    - Allocate dynamically ONFI parameters structure.
    - Add defines for ONFI version bits.
    - Add manufacturer fixup for ONFI parameter page.
    - Add an option to specify NAND chip as a boot device.
    - Add Reed-Solomon error correction algorithm.
    - Better name for the controller structure.
    - Remove unused caller_is_module() definition.
    - Make subop helpers return unsigned values.
    - Expose _notsupp() helpers for raw page accessors.
    - Add default values for dynamic timings.
    - Kill the chip->scan_bbt() hook.
    - Rename nand_default_bbt() into nand_create_bbt().
    - Start to clean the nand_chip structure.
    - Remove stale prototype from rawnand.h.

    Raw NAND controllers drivers changes:
    - Qcom: structuring cleanup.
    - Denali: use core helper to find the best ECC configuration.
    - Possible build of almost all drivers by adding a dependency on
    COMPILE_TEST for almost all of them in Kconfig, implies various
    fixes, Kconfig cleanup, GPIO headers inclusion cleanup, and even
    changes in sparc64 and ia64 architectures.
    - Clean the ->probe() functions error path of a lot of drivers.
    - Migrate all drivers to use nand_scan() instead of
    nand_scan_ident()/nand_scan_tail() pair.
    - Use mtd_device_register() where applicable to simplify the code.
    - Marvell:
    * Handle on-die ECC.
    * Better clocks handling.
    * Remove bogus comment.
    * Add suspend and resume support.
    - Tegra: add NAND controller driver.
    - Atmel:
    * Add module param to avoid using dma.
    * Drop Wenyou Yang from MAINTAINERS.
    - Denali: optimize timings handling.
    - FSMC: Stop using chip->read_buf().
    - FSL:
    * Switch to SPDX license tag identifiers.
    * Fix qualifiers in MXC init functions.

    Raw NAND chip drivers changes:
    - Micron:
    * Add fixup for ONFI revision.
    * Update ecc_stats.corrected.
    * Make ECC activation stateful.
    * Avoid enabling/disabling ECC when it can't be disabled.
    * Get the actual number of bitflips.
    * Allow forced on-die ECC.
    * Support 8/512 on-die ECC.
    * Fix on-die ECC detection logic.
    - Hynix:
    * Fix decoding the OOB size on H27UCG8T2BTR.
    * Use ->exec_op() in hynix_nand_reg_write_op()"

    * tag 'mtd/for-4.19' of git://git.infradead.org/linux-mtd: (188 commits)
    mtd: rawnand: atmel: Select GENERIC_ALLOCATOR
    MAINTAINERS: drop Wenyou Yang from Atmel NAND driver support
    mtd: rawnand: allocate dynamically ONFI parameters during detection
    mtd: spi-nor: only apply reset hacks to broken hardware
    mtd: spi-nor: cadence-quadspi: fix timeout handling
    mtd: spi-nor: atmel-quadspi: Include gpio/consumer.h instead of gpio.h
    mtd: spi-nor: intel-spi: use mtd_device_register()
    mtd: spi-nor: stm32-quadspi: replace "%p" with "%pK"
    mtd: spi-nor: atmel-quadspi: add suspend/resume hooks
    mtd: rawnand: allocate model parameter dynamically
    mtd: rawnand: do not export nand_scan_[ident|tail]() anymore
    mtd: rawnand: txx9ndfmc: convert driver to nand_scan()
    mtd: rawnand: txx9ndfmc: clarify ECC parameters assignation
    mtd: rawnand: tegra: convert driver to nand_scan()
    mtd: rawnand: jz4740: convert driver to nand_scan()
    mtd: rawnand: jz4740: group nand_scan_{ident, tail} calls
    mtd: rawnand: jz4740: fix probe function error path
    mtd: rawnand: docg4: convert driver to nand_scan()
    mtd: rawnand: do not execute nand_scan_ident() if maxchips is zero
    mtd: rawnand: atmel: convert driver to nand_scan()
    ...

    Linus Torvalds
     

14 Aug, 2018

2 commits

  • Pull perf update from Thomas Gleixner:
    "The perf crowd presents:

    Kernel updates:

    - Removal of jprobes

    - Cleanup and consolidatation the handling of kprobes

    - Cleanup and consolidation of hardware breakpoints

    - The usual pile of fixes and updates to PMUs and event descriptors

    Tooling updates:

    - Updates and improvements all over the place. Nothing outstanding,
    just the (good) boring incremental grump work"

    * 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (103 commits)
    perf trace: Do not require --no-syscalls to suppress strace like output
    perf bpf: Include uapi/linux/bpf.h from the 'perf trace' script's bpf.h
    perf tools: Allow overriding MAX_NR_CPUS at compile time
    perf bpf: Show better message when failing to load an object
    perf list: Unify metric group description format with PMU event description
    perf vendor events arm64: Update ThunderX2 implementation defined pmu core events
    perf cs-etm: Generate branch sample for CS_ETM_TRACE_ON packet
    perf cs-etm: Generate branch sample when receiving a CS_ETM_TRACE_ON packet
    perf cs-etm: Support dummy address value for CS_ETM_TRACE_ON packet
    perf cs-etm: Fix start tracing packet handling
    perf build: Fix installation directory for eBPF
    perf c2c report: Fix crash for empty browser
    perf tests: Fix indexing when invoking subtests
    perf trace: Beautify the AF_INET & AF_INET6 'socket' syscall 'protocol' args
    perf trace beauty: Add beautifiers for 'socket''s 'protocol' arg
    perf trace beauty: Do not print NULL strarray entries
    perf beauty: Add a generator for IPPROTO_ socket's protocol constants
    tools include uapi: Grab a copy of linux/in.h
    perf tests: Fix complex event name parsing
    perf evlist: Fix error out while applying initial delay and LBR
    ...

    Linus Torvalds
     
  • Pull locking/atomics update from Thomas Gleixner:
    "The locking, atomics and memory model brains delivered:

    - A larger update to the atomics code which reworks the ordering
    barriers, consolidates the atomic primitives, provides the new
    atomic64_fetch_add_unless() primitive and cleans up the include
    hell.

    - Simplify cmpxchg() instrumentation and add instrumentation for
    xchg() and cmpxchg_double().

    - Updates to the memory model and documentation"

    * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (48 commits)
    locking/atomics: Rework ordering barriers
    locking/atomics: Instrument cmpxchg_double*()
    locking/atomics: Instrument xchg()
    locking/atomics: Simplify cmpxchg() instrumentation
    locking/atomics/x86: Reduce arch_cmpxchg64*() instrumentation
    tools/memory-model: Rename litmus tests to comply to norm7
    tools/memory-model/Documentation: Fix typo, smb->smp
    sched/Documentation: Update wake_up() & co. memory-barrier guarantees
    locking/spinlock, sched/core: Clarify requirements for smp_mb__after_spinlock()
    sched/core: Use smp_mb() in wake_woken_function()
    tools/memory-model: Add informal LKMM documentation to MAINTAINERS
    locking/atomics/Documentation: Describe atomic_set() as a write operation
    tools/memory-model: Make scripts executable
    tools/memory-model: Remove ACCESS_ONCE() from model
    tools/memory-model: Remove ACCESS_ONCE() from recipes
    locking/memory-barriers.txt/kokr: Update Korean translation to fix broken DMA vs. MMIO ordering example
    MAINTAINERS: Add Daniel Lustig as an LKMM reviewer
    tools/memory-model: Fix ISA2+pooncelock+pooncelock+pombonce name
    tools/memory-model: Add litmus test for full multicopy atomicity
    locking/refcount: Always allow checked forms
    ...

    Linus Torvalds
     

11 Aug, 2018

1 commit

  • Holding uts_sem as a writer while accessing userspace memory allows a
    namespace admin to stall all processes that attempt to take uts_sem.
    Instead, move data through stack buffers and don't access userspace memory
    while uts_sem is held.

    Cc: stable@vger.kernel.org
    Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
    Signed-off-by: Jann Horn
    Signed-off-by: Eric W. Biederman

    Jann Horn
     

03 Aug, 2018

1 commit


02 Aug, 2018

3 commits

  • Almost all architectures include it. Add a ARCH_NO_PREEMPT symbol to
    disable preempt support for alpha, hexagon, non-coldfire m68k and
    user mode Linux.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Masahiro Yamada

    Christoph Hellwig
     
  • Move the source of lib/Kconfig.debug and arch/$(ARCH)/Kconfig.debug to
    the top-level Kconfig. For two architectures that means moving their
    arch-specific symbols in that menu into a new arch Kconfig.debug file,
    and for a few more creating a dummy file so that we can include it
    unconditionally.

    Also move the actual 'Kernel hacking' menu to lib/Kconfig.debug, where
    it belongs.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Masahiro Yamada

    Christoph Hellwig
     
  • Instead of duplicating the source statements in every architecture just
    do it once in the toplevel Kconfig file.

    Note that with this the inclusion of arch/$(SRCARCH/Kconfig moves out of
    the top-level Kconfig into arch/Kconfig so that don't violate ordering
    constraits while keeping a sensible menu structure.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Masahiro Yamada

    Christoph Hellwig
     

31 Jul, 2018

2 commits

  • Some drivers need these for compile-testing. On most architectures
    they come from asm-generic/io.h, but not on sparc64, which has its
    own definitions.

    Since we already have ioread*_rep()/iowrite*_rep() that have the
    same behavior on sparc64 (i.e. all PCI I/O space is memory mapped),
    we can rename the existing helpers and add macros to define them
    to the same implementation.

    Signed-off-by: Arnd Bergmann
    Acked-by: David S. Miller
    Tested-by: Boris Brezillon
    Signed-off-by: Miquel Raynal

    Arnd Bergmann
     
  • This is necessary to be able to include when
    CONFIG_GENERIC_MSI_IRQ_DOMAIN is enabled. Without this, a build with
    CONFIG_GENERIC_MSI_IRQ_DOMAIN fails with:

    In file included from drivers//ata/ahci.c:45:0:
    >> include/linux/msi.h:226:10: error: unknown type name 'msi_alloc_info_t'; did you mean 'sg_alloc_fn'?
    msi_alloc_info_t *arg);
    ^~~~~~~~~~~~~~~~
    sg_alloc_fn
    include/linux/msi.h:230:9: error: unknown type name 'msi_alloc_info_t'; did you mean 'sg_alloc_fn'?
    msi_alloc_info_t *arg);
    ^~~~~~~~~~~~~~~~
    sg_alloc_fn
    include/linux/msi.h:239:12: error: unknown type name 'msi_alloc_info_t'; did you mean 'sg_alloc_fn'?
    msi_alloc_info_t *arg);
    ^~~~~~~~~~~~~~~~
    sg_alloc_fn
    include/linux/msi.h:240:22: error: unknown type name 'msi_alloc_info_t'; did you mean 'sg_alloc_fn'?
    void (*msi_finish)(msi_alloc_info_t *arg, int retval);
    ^~~~~~~~~~~~~~~~
    sg_alloc_fn
    include/linux/msi.h:241:20: error: unknown type name 'msi_alloc_info_t'; did you mean 'sg_alloc_fn'?
    void (*set_desc)(msi_alloc_info_t *arg,
    ^~~~~~~~~~~~~~~~
    sg_alloc_fn
    include/linux/msi.h:316:18: error: unknown type name 'msi_alloc_info_t'; did you mean 'sg_alloc_fn'?
    int nvec, msi_alloc_info_t *args);
    ^~~~~~~~~~~~~~~~
    sg_alloc_fn
    include/linux/msi.h:318:29: error: unknown type name 'msi_alloc_info_t'; did you mean 'sg_alloc_fn'?
    int virq, int nvec, msi_alloc_info_t *args);
    ^~~~~~~~~~~~~~~~
    sg_alloc_fn

    Signed-off-by: Thomas Petazzoni
    Signed-off-by: David S. Miller

    Thomas Petazzoni