21 May, 2019

1 commit


17 May, 2019

1 commit

  • Pull nommu generic uaccess updates from Arnd Bergmann:
    "asm-generic: kill and improve nommu generic uaccess helpers

    Christoph Hellwig writes:

    This is a series doing two somewhat interwinded things. It improves
    the asm-generic nommu uaccess helper to optionally be entirely
    generic and not require any arch helpers for the actual uaccess.
    For the generic uaccess.h to actually be generically useful I also
    had to kill off the mess we made of , which really
    shouldn't exist on most architectures"

    * tag 'asm-generic-nommu' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic:
    asm-generic: optimize generic uaccess for 8-byte loads and stores
    asm-generic: provide entirely generic nommu uaccess
    arch: mostly remove
    asm-generic: don't include from

    Linus Torvalds
     

15 May, 2019

1 commit

  • For better maintenance and expansion move the mathematic helpers to the
    separate folder.

    No functional change intended.

    Note, the int_sqrt() is not used as a part of lib, so, moved to regular
    obj.

    Link: http://lkml.kernel.org/r/20190323172531.80025-1-andriy.shevchenko@linux.intel.com
    Signed-off-by: Andy Shevchenko
    Signed-off-by: Mauro Carvalho Chehab
    Cc: Randy Dunlap
    Cc: Thierry Reding
    Cc: Lee Jones
    Cc: Daniel Thompson
    Cc: Ray Jui
    [mchehab+samsung@kernel.org: fix broken doc references for div64.c and gcd.c]
    Link: http://lkml.kernel.org/r/734f49bae5d4052b3c25691dfefad59bea2e5843.1555580999.git.mchehab+samsung@kernel.org
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Shevchenko
     

08 May, 2019

1 commit

  • Pull networking updates from David Miller:
    "Highlights:

    1) Support AES128-CCM ciphers in kTLS, from Vakul Garg.

    2) Add fib_sync_mem to control the amount of dirty memory we allow to
    queue up between synchronize RCU calls, from David Ahern.

    3) Make flow classifier more lockless, from Vlad Buslov.

    4) Add PHY downshift support to aquantia driver, from Heiner
    Kallweit.

    5) Add SKB cache for TCP rx and tx, from Eric Dumazet. This reduces
    contention on SLAB spinlocks in heavy RPC workloads.

    6) Partial GSO offload support in XFRM, from Boris Pismenny.

    7) Add fast link down support to ethtool, from Heiner Kallweit.

    8) Use siphash for IP ID generator, from Eric Dumazet.

    9) Pull nexthops even further out from ipv4/ipv6 routes and FIB
    entries, from David Ahern.

    10) Move skb->xmit_more into a per-cpu variable, from Florian
    Westphal.

    11) Improve eBPF verifier speed and increase maximum program size,
    from Alexei Starovoitov.

    12) Eliminate per-bucket spinlocks in rhashtable, and instead use bit
    spinlocks. From Neil Brown.

    13) Allow tunneling with GUE encap in ipvs, from Jacky Hu.

    14) Improve link partner cap detection in generic PHY code, from
    Heiner Kallweit.

    15) Add layer 2 encap support to bpf_skb_adjust_room(), from Alan
    Maguire.

    16) Remove SKB list implementation assumptions in SCTP, your's truly.

    17) Various cleanups, optimizations, and simplifications in r8169
    driver. From Heiner Kallweit.

    18) Add memory accounting on TX and RX path of SCTP, from Xin Long.

    19) Switch PHY drivers over to use dynamic featue detection, from
    Heiner Kallweit.

    20) Support flow steering without masking in dpaa2-eth, from Ioana
    Ciocoi.

    21) Implement ndo_get_devlink_port in netdevsim driver, from Jiri
    Pirko.

    22) Increase the strict parsing of current and future netlink
    attributes, also export such policies to userspace. From Johannes
    Berg.

    23) Allow DSA tag drivers to be modular, from Andrew Lunn.

    24) Remove legacy DSA probing support, also from Andrew Lunn.

    25) Allow ll_temac driver to be used on non-x86 platforms, from Esben
    Haabendal.

    26) Add a generic tracepoint for TX queue timeouts to ease debugging,
    from Cong Wang.

    27) More indirect call optimizations, from Paolo Abeni"

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1763 commits)
    cxgb4: Fix error path in cxgb4_init_module
    net: phy: improve pause mode reporting in phy_print_status
    dt-bindings: net: Fix a typo in the phy-mode list for ethernet bindings
    net: macb: Change interrupt and napi enable order in open
    net: ll_temac: Improve error message on error IRQ
    net/sched: remove block pointer from common offload structure
    net: ethernet: support of_get_mac_address new ERR_PTR error
    net: usb: smsc: fix warning reported by kbuild test robot
    staging: octeon-ethernet: Fix of_get_mac_address ERR_PTR check
    net: dsa: support of_get_mac_address new ERR_PTR error
    net: dsa: sja1105: Fix status initialization in sja1105_get_ethtool_stats
    vrf: sit mtu should not be updated when vrf netdev is the link
    net: dsa: Fix error cleanup path in dsa_init_module
    l2tp: Fix possible NULL pointer dereference
    taprio: add null check on sched_nest to avoid potential null pointer dereference
    net: mvpp2: cls: fix less than zero check on a u32 variable
    net_sched: sch_fq: handle non connected flows
    net_sched: sch_fq: do not assume EDT packets are ordered
    net: hns3: use devm_kcalloc when allocating desc_cb
    net: hns3: some cleanup for struct hns3_enet_ring
    ...

    Linus Torvalds
     

03 May, 2019

1 commit

  • This provides an unified API for accessing register bit fields
    regardless of memory layout. The basic unit of data for these API
    functions is the u64. The process of transforming an u64 from native CPU
    encoding into the peripheral's encoding is called 'pack', and
    transforming it from peripheral to native CPU encoding is 'unpack'.

    Signed-off-by: Vladimir Oltean
    Signed-off-by: David S. Miller

    Vladimir Oltean
     

29 Apr, 2019

1 commit

  • All architectures which support stacktrace carry duplicated code and
    do the stack storage and filtering at the architecture side.

    Provide a consolidated interface with a callback function for consuming the
    stack entries provided by the architecture specific stack walker. This
    removes lots of duplicated code and allows to implement better filtering
    than 'skip number of entries' in the future without touching any
    architecture specific code.

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Josh Poimboeuf
    Cc: Andy Lutomirski
    Cc: linux-arch@vger.kernel.org
    Cc: Steven Rostedt
    Cc: Alexander Potapenko
    Cc: Alexey Dobriyan
    Cc: Andrew Morton
    Cc: Christoph Lameter
    Cc: Pekka Enberg
    Cc: linux-mm@kvack.org
    Cc: David Rientjes
    Cc: Catalin Marinas
    Cc: Dmitry Vyukov
    Cc: Andrey Ryabinin
    Cc: kasan-dev@googlegroups.com
    Cc: Mike Rapoport
    Cc: Akinobu Mita
    Cc: Christoph Hellwig
    Cc: iommu@lists.linux-foundation.org
    Cc: Robin Murphy
    Cc: Marek Szyprowski
    Cc: Johannes Thumshirn
    Cc: David Sterba
    Cc: Chris Mason
    Cc: Josef Bacik
    Cc: linux-btrfs@vger.kernel.org
    Cc: dm-devel@redhat.com
    Cc: Mike Snitzer
    Cc: Alasdair Kergon
    Cc: Daniel Vetter
    Cc: intel-gfx@lists.freedesktop.org
    Cc: Joonas Lahtinen
    Cc: Maarten Lankhorst
    Cc: dri-devel@lists.freedesktop.org
    Cc: David Airlie
    Cc: Jani Nikula
    Cc: Rodrigo Vivi
    Cc: Tom Zanussi
    Cc: Miroslav Benes
    Link: https://lkml.kernel.org/r/20190425094803.713568606@linutronix.de

    Thomas Gleixner
     

24 Apr, 2019

1 commit


03 Jan, 2019

1 commit

  • Pull the pending 4.21 changes for md from Shaohua.

    * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/shli/md:
    md: fix raid10 hang issue caused by barrier
    raid10: refactor common wait code from regular read/write request
    md: remvoe redundant condition check
    lib/raid6: add option to skip algo benchmarking
    lib/raid6: sort algos in rough performance order
    lib/raid6: check for assembler SSSE3 support
    lib/raid6: avoid __attribute_const__ redefinition
    lib/raid6: add missing include for raid6test
    md: remove set but not used variable 'bi_rdev'

    Jens Axboe
     

29 Dec, 2018

1 commit

  • Pull DMA mapping updates from Christoph Hellwig:
    "A huge update this time, but a lot of that is just consolidating or
    removing code:

    - provide a common DMA_MAPPING_ERROR definition and avoid indirect
    calls for dma_map_* error checking

    - use direct calls for the DMA direct mapping case, avoiding huge
    retpoline overhead for high performance workloads

    - merge the swiotlb dma_map_ops into dma-direct

    - provide a generic remapping DMA consistent allocator for
    architectures that have devices that perform DMA that is not cache
    coherent. Based on the existing arm64 implementation and also used
    for csky now.

    - improve the dma-debug infrastructure, including dynamic allocation
    of entries (Robin Murphy)

    - default to providing chaining scatterlist everywhere, with opt-outs
    for the few architectures (alpha, parisc, most arm32 variants) that
    can't cope with it

    - misc sparc32 dma-related cleanups

    - remove the dma_mark_clean arch hook used by swiotlb on ia64 and
    replace it with the generic noncoherent infrastructure

    - fix the return type of dma_set_max_seg_size (Niklas Söderlund)

    - move the dummy dma ops for not DMA capable devices from arm64 to
    common code (Robin Murphy)

    - ensure dma_alloc_coherent returns zeroed memory to avoid kernel
    data leaks through userspace. We already did this for most common
    architectures, but this ensures we do it everywhere.
    dma_zalloc_coherent has been deprecated and can hopefully be
    removed after -rc1 with a coccinelle script"

    * tag 'dma-mapping-4.21' of git://git.infradead.org/users/hch/dma-mapping: (73 commits)
    dma-mapping: fix inverted logic in dma_supported
    dma-mapping: deprecate dma_zalloc_coherent
    dma-mapping: zero memory returned from dma_alloc_*
    sparc/iommu: fix ->map_sg return value
    sparc/io-unit: fix ->map_sg return value
    arm64: default to the direct mapping in get_arch_dma_ops
    PCI: Remove unused attr variable in pci_dma_configure
    ia64: only select ARCH_HAS_DMA_COHERENT_TO_PFN if swiotlb is enabled
    dma-mapping: bypass indirect calls for dma-direct
    vmd: use the proper dma_* APIs instead of direct methods calls
    dma-direct: merge swiotlb_dma_ops into the dma_direct code
    dma-direct: use dma_direct_map_page to implement dma_direct_map_sg
    dma-direct: improve addressability error reporting
    swiotlb: remove dma_mark_clean
    swiotlb: remove SWIOTLB_MAP_ERROR
    ACPI / scan: Refactor _CCA enforcement
    dma-mapping: factor out dummy DMA ops
    dma-mapping: always build the direct mapping code
    dma-mapping: move dma_cache_sync out of line
    dma-mapping: move various slow path functions out of line
    ...

    Linus Torvalds
     

21 Dec, 2018

1 commit

  • This is helpful for systems where fast startup time is important.
    It is especially nice to avoid benchmarking RAID functions that are
    never used (for example, BTRFS selects RAID6_PQ even if the parity RAID
    mode is not in use).

    This saves 250+ milliseconds of boot time on modern x86 and ARM systems
    with a dozen or more available implementations.

    The new option is defaulted to 'y' to match the previous behavior of
    always benchmarking on init.

    Signed-off-by: Daniel Verkamp
    Signed-off-by: Shaohua Li

    Daniel Verkamp
     

06 Dec, 2018

1 commit

  • These days architectures are mostly out of the business of dealing with
    struct scatterlist at all, unless they have architecture specific iommu
    drivers. Replace the ARCH_HAS_SG_CHAIN symbol with a ARCH_NO_SG_CHAIN
    one only enabled for architectures with horrible legacy iommu drivers
    like alpha and parisc, and conditionally for arm which wants to keep it
    disable for legacy platforms.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Palmer Dabbelt

    Christoph Hellwig
     

16 Nov, 2018

1 commit

  • This lib tracks objects which could be of two types:
    1) root object
    2) nested object - with a "delta" which differentiates it from
    the associated root object
    The objects are tracked by a hashtable and reference-counted. User is
    responsible of implementing callbacks to create/destroy root entity
    related to each root object and callback to create/destroy nested object
    delta.

    Signed-off-by: Jiri Pirko
    Signed-off-by: Ido Schimmel
    Signed-off-by: David S. Miller

    Jiri Pirko
     

01 Nov, 2018

2 commits

  • …l/git/palmer/riscv-linux

    Pull more RISC-V updates from Palmer Dabbelt:
    "This contains the follow-on patches I'd like to target for the 4.20
    merge window. I'm being somewhat conservative here, as while there are
    a few patches on the mailing list that were posted early in the merge
    window I'd like to let those bake for another round -- this was a
    fairly big release as far as RISC-V is concerened, and we need to walk
    before we can run.

    As far as the patches that made it go:

    - A patch to ignore offline CPUs when calculating AT_HWCAP. This
    should fix GDB on the HiFive unleashed, which has an embedded core
    for hart 0 which is exposed to Linux as an offline CPU.

    - A move of EM_RISCV to elf-em.h, which is where it should have been
    to begin with.

    - I've also removed the 64-bit divide routines. I know I'm not really
    playing by my own rules here because I posted the patches this
    morning, but since they shouldn't be in the kernel I think it's
    better to err on the side of going too fast here.

    I don't anticipate any more patch sets for the merge window"

    * tag 'riscv-for-linus-4.20-mw2' of git://git.kernel.org/pub/scm/linux/kernel/git/palmer/riscv-linux:
    Move EM_RISCV into elf-em.h
    RISC-V: properly determine hardware caps
    Revert "lib: Add umoddi3 and udivmoddi4 of GCC library routines"
    Revert "RISC-V: Select GENERIC_LIB_UMODDI3 on RV32"

    Linus Torvalds
     
  • We don't want 64-bit divide in the kernel.

    This reverts commit 6315730e9eab7de5fa9864bb13a352713f48aef1.

    Signed-off-by: Palmer Dabbelt

    Palmer Dabbelt
     

29 Oct, 2018

1 commit

  • Pull XArray conversion from Matthew Wilcox:
    "The XArray provides an improved interface to the radix tree data
    structure, providing locking as part of the API, specifying GFP flags
    at allocation time, eliminating preloading, less re-walking the tree,
    more efficient iterations and not exposing RCU-protected pointers to
    its users.

    This patch set

    1. Introduces the XArray implementation

    2. Converts the pagecache to use it

    3. Converts memremap to use it

    The page cache is the most complex and important user of the radix
    tree, so converting it was most important. Converting the memremap
    code removes the only other user of the multiorder code, which allows
    us to remove the radix tree code that supported it.

    I have 40+ followup patches to convert many other users of the radix
    tree over to the XArray, but I'd like to get this part in first. The
    other conversions haven't been in linux-next and aren't suitable for
    applying yet, but you can see them in the xarray-conv branch if you're
    interested"

    * 'xarray' of git://git.infradead.org/users/willy/linux-dax: (90 commits)
    radix tree: Remove multiorder support
    radix tree test: Convert multiorder tests to XArray
    radix tree tests: Convert item_delete_rcu to XArray
    radix tree tests: Convert item_kill_tree to XArray
    radix tree tests: Move item_insert_order
    radix tree test suite: Remove multiorder benchmarking
    radix tree test suite: Remove __item_insert
    memremap: Convert to XArray
    xarray: Add range store functionality
    xarray: Move multiorder_check to in-kernel tests
    xarray: Move multiorder_shrink to kernel tests
    xarray: Move multiorder account test in-kernel
    radix tree test suite: Convert iteration test to XArray
    radix tree test suite: Convert tag_tagged_items to XArray
    radix tree: Remove radix_tree_clear_tags
    radix tree: Remove radix_tree_maybe_preload_order
    radix tree: Remove split/join code
    radix tree: Remove radix_tree_update_node_t
    page cache: Finish XArray conversion
    dax: Convert page fault handlers to XArray
    ...

    Linus Torvalds
     

23 Oct, 2018

1 commit

  • Add umoddi3 and udivmoddi4 support for 32-bit.

    The RV32 need the umoddi3 to do modulo when the operands are long long
    type, like other libraries implementation such as ucmpdi2, lshrdi3 and
    so on.

    I encounter the undefined reference 'umoddi3' when I use the in
    house dma driver, although it is in house driver, but I think that
    umoddi3 is a common function for RV32.

    The udivmoddi4 and umoddi3 are copies from libgcc in gcc. There are other
    functions use the udivmoddi4 in libgcc, so I separate the umoddi3 and
    udivmoddi4 for flexible extension in the future.

    Signed-off-by: Zong Li
    Signed-off-by: Palmer Dabbelt

    Zong Li
     

21 Oct, 2018

1 commit


30 Sep, 2018

1 commit


23 Aug, 2018

2 commits

  • It seems contributors follow the style of Kconfig entries where explicit
    'default n' is present. The default 'default' is 'n' already, thus, drop
    these lines from Kconfig to make it more clear.

    Link: http://lkml.kernel.org/r/20180719085131.79541-1-andriy.shevchenko@linux.intel.com
    Signed-off-by: Andy Shevchenko
    Acked-by: Coly Li
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Shevchenko
     
  • Patch series "add crc64 calculation as kernel library", v5.

    This patchset adds basic implementation of crc64 calculation as a Linux
    kernel library. Since bcache already does crc64 by itself, this patchset
    also modifies bcache code to use the new crc64 library routine.

    Currently bcache is the only user of crc64 calculation, another potential
    user is bcachefs which is on the way to be in mainline kernel. Therefore
    it makes sense to make crc64 calculation to be a public library.

    bcache uses crc64 as storage checksum, if a change of crc lib routines
    results an inconsistent result, the unmatched checksum may make bcache
    'think' the on-disk is corrupted, such a change should be avoided or
    detected as early as possible. Therefore a patch is being prepared which
    adds a crc test framework, to check consistency of different calculations.

    This patch (of 2):

    Add the re-write crc64 calculation routines for Linux kernel. The CRC64
    polynomical arithmetic follows ECMA-182 specification, inspired by CRC
    paper of Dr. Ross N. Williams (see
    http://www.ross.net/crc/download/crc_v3.txt) and other public domain
    implementations.

    All the changes work in this way,
    - When Linux kernel is built, host program lib/gen_crc64table.c will be
    compiled to lib/gen_crc64table and executed.
    - The output of gen_crc64table execution is an array called as lookup
    table (a.k.a POLY 0x42f0e1eba9ea369) which contain 256 64-bit long
    numbers, this table is dumped into header file lib/crc64table.h.
    - Then the header file is included by lib/crc64.c for normal 64bit crc
    calculation.
    - Function declaration of the crc64 calculation routines is placed in
    include/linux/crc64.h

    Currently bcache is the only user of crc64_be(), another potential user is
    bcachefs which is on the way to be in mainline kernel. Therefore it makes
    sense to move crc64 calculation into lib/crc64.c as public code.

    [colyli@suse.de: fix review comments from v4]
    Link: http://lkml.kernel.org/r/20180726053352.2781-2-colyli@suse.de
    Link: http://lkml.kernel.org/r/20180718165545.1622-2-colyli@suse.de
    Signed-off-by: Coly Li
    Co-developed-by: Andy Shevchenko
    Signed-off-by: Andy Shevchenko
    Reviewed-by: Hannes Reinecke
    Cc: Greg Kroah-Hartman
    Cc: Andy Shevchenko
    Cc: Michael Lyle
    Cc: Kent Overstreet
    Cc: Thomas Gleixner
    Cc: Kate Stewart
    Cc: Eric Biggers
    Cc: Randy Dunlap
    Cc: Noah Massey
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Coly Li
     

20 Jun, 2018

1 commit


16 Jun, 2018

1 commit

  • As we move stuff around, some doc references are broken. Fix some of
    them via this script:
    ./scripts/documentation-file-ref-check --fix

    Manually checked if the produced result is valid, removing a few
    false-positives.

    Acked-by: Takashi Iwai
    Acked-by: Masami Hiramatsu
    Acked-by: Stephen Boyd
    Acked-by: Charles Keepax
    Acked-by: Mathieu Poirier
    Reviewed-by: Coly Li
    Signed-off-by: Mauro Carvalho Chehab
    Acked-by: Jonathan Corbet

    Mauro Carvalho Chehab
     

14 Jun, 2018

1 commit

  • Currently the code is split over various files with dma- prefixes in the
    lib/ and drives/base directories, and the number of files keeps growing.
    Move them into a single directory to keep the code together and remove
    the file name prefixes. To match the irq infrastructure this directory
    is placed under the kernel/ directory.

    Signed-off-by: Christoph Hellwig

    Christoph Hellwig
     

13 Jun, 2018

1 commit

  • Pull MIPS updates from James Hogan:
    "These are the main MIPS changes for 4.18.

    Rough overview:

    - MAINTAINERS: Add Paul Burton as MIPS co-maintainer

    - Misc: Generic compiler intrinsics, Y2038 improvements, Perf+MT fixes

    - Platform support: Netgear WNR1000 V3, Microsemi Ocelot integrated
    switch, Ingenic watchdog cleanups

    More detailed summary:

    Maintainers:

    - Add Paul Burton as MIPS co-maintainer, as I soon won't have access
    to much MIPS hardware, nor enough time to properly maintain MIPS on
    my own.

    Miscellaneous:

    - Use generic GCC library routines from lib/
    - Add notrace to generic ucmpdi2 implementation
    - Rename compiler intrinsic selects to GENERIC_LIB_*
    - vmlinuz: Use generic ashldi3

    - y2038: Convert update/read_persistent_clock() to *_clock64()
    - sni: Remove read_persistent_clock()

    - perf: Fix perf with MT counting other threads
    - Probe for per-TC perf counters in cpu-probe.c
    - Use correct VPE ID for VPE tracing

    Minor cleanups:

    - Avoid unneeded built-in.a in DTS dirs

    - sc-debugfs: Re-use kstrtobool_from_user

    - memset.S: Reinstate delay slot indentation

    - VPE: Fix spelling "uneeded" -> "Unneeded"

    Platform support:

    BCM47xx:

    - Add support for Netgear WNR1000 V3

    - firmware: Support small NVRAM partitions

    - Use __initdata for LEDs platform data

    Ingenic:

    - Watchdog driver & platform code improvements:
    - Disable clock after stopping counter
    - Use devm_* functions
    - Drop module remove function
    - Move platform reset code to restart handler in driver
    - JZ4740: Convert watchdog instantiation to DT
    - JZ4780: Fix watchdog DT node
    - qi_lb60_defconfig: Enable watchdog driver

    Microsemi:

    - Ocelot: Add support for integrated switch
    - pcb123: Connect phys to ports"

    * tag 'mips_4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux: (30 commits)
    MAINTAINERS: Add Paul Burton as MIPS co-maintainer
    MIPS: ptrace: Make FPU context layout comments match reality
    MIPS: memset.S: Reinstate delay slot indentation
    MIPS: perf: Fix perf with MT counting other threads
    MIPS: perf: Use correct VPE ID when setting up VPE tracing
    MIPS: perf: More robustly probe for the presence of per-tc counters
    MIPS: Probe for MIPS MT perf counters per TC
    MIPS: mscc: Connect phys to ports on ocelot_pcb123
    MIPS: mscc: Add switch to ocelot
    MIPS: JZ4740: Drop old platform reset code
    MIPS: qi_lb60: Enable the jz4740-wdt driver
    MIPS: JZ4780: dts: Fix watchdog node
    MIPS: JZ4740: dts: Add bindings for the jz4740-wdt driver
    watchdog: JZ4740: Drop module remove function
    watchdog: JZ4740: Register a restart handler
    watchdog: JZ4740: Use devm_* functions
    watchdog: JZ4740: Disable clock after stopping counter
    MIPS: VPE: Fix spelling mistake: "uneeded" -> "unneeded"
    MIPS: Re-use kstrtobool_from_user()
    MIPS: Convert update_persistent_clock() to update_persistent_clock64()
    ...

    Linus Torvalds
     

09 Jun, 2018

1 commit

  • Pull libnvdimm updates from Dan Williams:
    "This adds a user for the new 'bytes-remaining' updates to
    memcpy_mcsafe() that you already received through Ingo via the
    x86-dax- for-linus pull.

    Not included here, but still targeting this cycle, is support for
    handling memory media errors (poison) consumed via userspace dax
    mappings.

    Summary:

    - DAX broke a fundamental assumption of truncate of file mapped
    pages. The truncate path assumed that it is safe to disconnect a
    pinned page from a file and let the filesystem reclaim the physical
    block. With DAX the page is equivalent to the filesystem block.
    Introduce dax_layout_busy_page() to enable filesystems to wait for
    pinned DAX pages to be released. Without this wait a filesystem
    could allocate blocks under active device-DMA to a new file.

    - DAX arranges for the block layer to be bypassed and uses
    dax_direct_access() + copy_to_iter() to satisfy read(2) calls.
    However, the memcpy_mcsafe() facility is available through the pmem
    block driver. In order to safely handle media errors, via the DAX
    block-layer bypass, introduce copy_to_iter_mcsafe().

    - Fix cache management policy relative to the ACPI NFIT Platform
    Capabilities Structure to properly elide cache flushes when they
    are not necessary. The table indicates whether CPU caches are
    power-fail protected. Clarify that a deep flush is always performed
    on REQ_{FUA,PREFLUSH} requests"

    * tag 'libnvdimm-for-4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm: (21 commits)
    dax: Use dax_write_cache* helpers
    libnvdimm, pmem: Do not flush power-fail protected CPU caches
    libnvdimm, pmem: Unconditionally deep flush on *sync
    libnvdimm, pmem: Complete REQ_FLUSH => REQ_PREFLUSH
    acpi, nfit: Remove ecc_unit_size
    dax: dax_insert_mapping_entry always succeeds
    libnvdimm, e820: Register all pmem resources
    libnvdimm: Debug probe times
    linvdimm, pmem: Preserve read-only setting for pmem devices
    x86, nfit_test: Add unit test for memcpy_mcsafe()
    pmem: Switch to copy_to_iter_mcsafe()
    dax: Report bytes remaining in dax_iomap_actor()
    dax: Introduce a ->copy_to_iter dax operation
    uio, lib: Fix CONFIG_ARCH_HAS_UACCESS_MCSAFE compilation
    xfs, dax: introduce xfs_break_dax_layouts()
    xfs: prepare xfs_break_layouts() for another layout type
    xfs: prepare xfs_break_layouts() to be called with XFS_MMAPLOCK_EXCL
    mm, fs, dax: handle layout changes to pinned dax mappings
    mm: fix __gup_device_huge vs unmap
    mm: introduce MEMORY_DEVICE_FS_DAX and CONFIG_DEV_PAGEMAP_OPS
    ...

    Linus Torvalds
     

23 May, 2018

1 commit


19 May, 2018

2 commits

  • Add a new dma_map_ops implementation that uses dma-direct for the
    address mapping of streaming mappings, and which requires arch-specific
    implemenations of coherent allocate/free.

    Architectures have to provide flushing helpers to ownership trasnfers
    to the device and/or CPU, and can provide optional implementations of
    the coherent mmap functionality, and the cache_flush routines for
    non-coherent long term allocations.

    Signed-off-by: Christoph Hellwig
    Tested-by: Alexey Brodkin
    Acked-by: Vineet Gupta

    Christoph Hellwig
     
  • ARCH_DMA_ADDR_T_64BIT is always true for 64-bit architectures now, so we
    can skip the clause requiring it. 'n' is the default default, so no need
    to explicitly state it.

    Tested-by: Alexey Brodkin
    Acked-by: Vineet Gupta
    Signed-off-by: Christoph Hellwig

    Christoph Hellwig
     

09 May, 2018

5 commits


23 Apr, 2018

1 commit

  • When these are included into arch Kconfig files, maintaining
    alphabetical ordering of the selects means these get split up. To allow
    for keeping things tidier and alphabetical, rename the selects to
    GENERIC_LIB_*

    Signed-off-by: Matt Redfearn
    Acked-by: Palmer Dabbelt
    Cc: Antony Pavlov
    Cc: Ralf Baechle
    Cc: linux-riscv@lists.infradead.org
    Cc: linux-mips@linux-mips.org
    Patchwork: https://patchwork.linux-mips.org/patch/19049/
    Signed-off-by: James Hogan

    Matt Redfearn
     

22 Mar, 2018

1 commit

  • 41f8bba7f555 ("of/pci: Add pci_register_io_range() and
    pci_pio_to_address()") added support for PCI I/O space mapped into CPU
    physical memory space. With that support, the I/O ranges configured for
    PCI/PCIe hosts on some architectures can be mapped to logical PIO and
    converted easily between CPU address and the corresponding logical PIO.
    Based on this, PCI I/O port space can be accessed via in/out accessors that
    use memory read/write.

    But on some platforms, there are bus hosts that access I/O port space with
    host-local I/O port addresses rather than memory addresses.

    Add a more generic I/O mapping method to support those devices. With this
    patch, both the CPU addresses and the host-local port can be mapped into
    the logical PIO space with different logical/fake PIOs. After this, all
    the I/O accesses to either PCI MMIO devices or host-local I/O peripherals
    can be unified into the existing I/O accessors defined in asm-generic/io.h
    and be redirected to the right device-specific hooks based on the input
    logical PIO.

    Tested-by: dann frazier
    Signed-off-by: Zhichang Yuan
    Signed-off-by: Gabriele Paoloni
    Signed-off-by: John Garry
    [bhelgaas: remove -EFAULT return from logic_pio_register_range() per
    https://lkml.kernel.org/r/20180403143909.GA21171@ulmo, fix NULL pointer
    checking per https://lkml.kernel.org/r/20180403211505.GA29612@embeddedor.com]
    Signed-off-by: Bjorn Helgaas
    Reviewed-by: Andy Shevchenko

    Zhichang Yuan
     

01 Feb, 2018

1 commit

  • Pull dma mapping updates from Christoph Hellwig:
    "Except for a runtime warning fix from Christian this is all about
    consolidation of the generic no-IOMMU code, a well as the glue code
    for swiotlb.

    All the code is based on the x86 implementation with hooks to allow
    all architectures that aren't cache coherent to use it.

    The x86 conversion itself has been deferred because the x86
    maintainers were a little busy in the last months"

    * tag 'dma-mapping-4.16' of git://git.infradead.org/users/hch/dma-mapping: (57 commits)
    MAINTAINERS: add the iommu list for swiotlb and xen-swiotlb
    arm64: use swiotlb_alloc and swiotlb_free
    arm64: replace ZONE_DMA with ZONE_DMA32
    mips: use swiotlb_{alloc,free}
    mips/netlogic: remove swiotlb support
    tile: use generic swiotlb_ops
    tile: replace ZONE_DMA with ZONE_DMA32
    unicore32: use generic swiotlb_ops
    ia64: remove an ifdef around the content of pci-dma.c
    ia64: clean up swiotlb support
    ia64: use generic swiotlb_ops
    ia64: replace ZONE_DMA with ZONE_DMA32
    swiotlb: remove various exports
    swiotlb: refactor coherent buffer allocation
    swiotlb: refactor coherent buffer freeing
    swiotlb: wire up ->dma_supported in swiotlb_dma_ops
    swiotlb: add common swiotlb_map_ops
    swiotlb: rename swiotlb_free to swiotlb_exit
    x86: rename swiotlb_dma_ops
    powerpc: rename swiotlb_dma_ops
    ...

    Linus Torvalds
     

15 Jan, 2018

1 commit

  • The trivial direct mapping implementation already does a virtual to
    physical translation which isn't strictly a noop, and will soon learn
    to do non-direct but linear physical to dma translations through the
    device offset and a few small tricks. Rename it to a better fitting
    name.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Vladimir Murzin

    Christoph Hellwig
     

07 Jan, 2018

1 commit

  • Many kernel drivers contain code that allocates and frees both a
    scatterlist and the pages that populate that scatterlist.
    Introduce functions in lib/scatterlist.c that perform these tasks
    instead of duplicating this functionality in multiple drivers.
    Only include these functions in the build if CONFIG_SGL_ALLOC=y
    to avoid that the kernel size increases if this functionality is
    not used.

    Signed-off-by: Bart Van Assche
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Johannes Thumshirn
    Signed-off-by: Jens Axboe

    Bart Van Assche
     

23 Nov, 2017

1 commit

  • Pull MTD updates from Richard Weinberger:
    "General changes:
    - Unconfuse get_unmapped_area and point/unpoint driver methods
    - New partition parser: sharpslpart
    - Kill GENERIC_IO
    - Various fixes

    NAND changes:
    - Add a flag to mark NANDs that require 3 address cycles to encode a
    page address
    - Set a default ECC/free layout when NAND_ECC_NONE is requested
    - Fix a bug in panic_nand_write()
    - Another batch of cleanups for the denali driver
    - Fix PM support in the atmel driver
    - Remove support for platform data in the omap driver
    - Fix subpage write in the omap driver
    - Fix irq handling in the mtk driver
    - Change link order of mtk_ecc and mtk_nand drivers to speed up boot
    time
    - Change log level of ECC error messages in the mxc driver
    - Patch the pxa3xx driver to support Armada 8k platforms
    - Add BAM DMA support to the qcom driver
    - Convert gpio-nand to the GPIO desc API
    - Fix ECC handling in the mt29f driver

    SPI-NOR changes:
    - Introduce system power management support
    - New mechanism to select the proper .quad_enable() hook by JEDEC
    ID, when needed, instead of only by manufacturer ID
    - Add support to new memory parts from Gigadevice, Winbond, Macronix
    and Everspin
    - Maintainance for Cadence, Intel, Mediatek and STM32 drivers"

    * tag 'for-linus-20171120' of git://git.infradead.org/linux-mtd: (85 commits)
    mtd: Avoid probe failures when mtd->dbg.dfs_dir is invalid
    mtd: sharpslpart: Add sharpslpart partition parser
    mtd: Add sanity checks in mtd_write/read_oob()
    mtd: remove the get_unmapped_area method
    mtd: implement mtd_get_unmapped_area() using the point method
    mtd: chips/map_rom.c: implement point and unpoint methods
    mtd: chips/map_ram.c: implement point and unpoint methods
    mtd: mtdram: properly handle the phys argument in the point method
    mtd: mtdswap: fix spelling mistake: 'TRESHOLD' -> 'THRESHOLD'
    mtd: slram: use memremap() instead of ioremap()
    kconfig: kill off GENERIC_IO option
    mtd: Fix C++ comment in include/linux/mtd/mtd.h
    mtd: constify mtd_partition
    mtd: plat-ram: Replace manual resource management by devm
    mtd: nand: Fix writing mtdoops to nand flash.
    mtd: intel-spi: Add Intel Lewisburg PCH SPI super SKU PCI ID
    mtd: nand: mtk: fix infinite ECC decode IRQ issue
    mtd: spi-nor: Add support for mr25h128
    mtd: nand: mtk: change the compile sequence of mtk_nand.o and mtk_ecc.o
    mtd: spi-nor: enable 4B opcodes for mx66l51235l
    ...

    Linus Torvalds
     

18 Nov, 2017

1 commit

  • Extract the string test code into its own source file, to allow
    compiling it either to a loadable module, or built into the kernel.

    Fixes: 03270c13c5ffaa6a ("lib/string.c: add testcases for memset16/32/64")
    Link: http://lkml.kernel.org/r/1505397744-3387-1-git-send-email-geert@linux-m68k.org
    Signed-off-by: Geert Uytterhoeven
    Cc: Matthew Wilcox
    Cc: Shuah Khan
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Geert Uytterhoeven