1. 24 Dec, 2019 5 commits
    • Maxime Ripard's avatar
      dt-bindings: mfd: Convert Allwinner legacy PRCM bindings to schemas · af287ed0
      Maxime Ripard authored
      The Allwinner SoCs have a legacy set of bindings (and a drivers to
      support it in Linux) to support the PRCM unit found in most recent SoCs.
      
      Now that we have the DT validation in place, let's split into separate file
      and convert the device tree bindings for those controllers to schemas, and
      mark them all as deprecated.
      Signed-off-by: default avatarMaxime Ripard <maxime@cerno.tech>
      Signed-off-by: default avatarRob Herring <robh@kernel.org>
      af287ed0
    • Maxime Ripard's avatar
      dt-bindings: clocks: Convert Allwinner legacy clocks to schemas · f95cad74
      Maxime Ripard authored
      The Allwinner SoCs have a legacy set of bindings (and a framework to
      support it in Linux) for their clock controllers.
      
      Now that we have the DT validation in place, let's split into separate file
      and convert the device tree bindings for those clocks to schemas, and mark
      them all as deprecated.
      Signed-off-by: default avatarMaxime Ripard <maxime@cerno.tech>
      Signed-off-by: default avatarRob Herring <robh@kernel.org>
      f95cad74
    • Maxime Ripard's avatar
      dt-bindings: opp: Convert Allwinner H6 OPP to a schema · b30d8cf5
      Maxime Ripard authored
      The Allwinner H6 SoCs use binning in order to provide binning to
      cpufreq which is supported in Linux, with a matching Device Tree binding.
      
      Now that we have the DT validation in place, let's convert the device tree
      bindings for that controller over to a YAML schemas.
      Signed-off-by: default avatarMaxime Ripard <maxime@cerno.tech>
      Signed-off-by: default avatarRob Herring <robh@kernel.org>
      b30d8cf5
    • Rob Herring's avatar
      of: Rework and simplify phandle cache to use a fixed size · 90dc0d1c
      Rob Herring authored
      The phandle cache was added to speed up of_find_node_by_phandle() by
      avoiding walking the whole DT to find a matching phandle. The
      implementation has several shortcomings:
      
        - The cache is designed to work on a linear set of phandle values.
          This is true for dtc generated DTs, but not for other cases such as
          Power.
        - The cache isn't enabled until of_core_init() and a typical system
          may see hundreds of calls to of_find_node_by_phandle() before that
          point.
        - The cache is freed and re-allocated when the number of phandles
          changes.
        - It takes a raw spinlock around a memory allocation which breaks on
          RT.
      
      Change the implementation to a fixed size and use hash_32() as the
      cache index. This greatly simplifies the implementation. It avoids
      the need for any re-alloc of the cache and taking a reference on nodes
      in the cache. We only have a single source of removing cache entries
      which is of_detach_node().
      
      Using hash_32() removes any assumption on phandle values improving
      the hit rate for non-linear phandle values. The effect on linear values
      using hash_32() is about a 10% collision. The chances of thrashing on
      colliding values seems to be low.
      
      To compare performance, I used a RK3399 board which is a pretty typical
      system. I found that just measuring boot time as done previously is
      noisy and may be impacted by other things. Also bringing up secondary
      cores causes some issues with measuring, so I booted with 'nr_cpus=1'.
      With no caching, calls to of_find_node_by_phandle() take about 20124 us
      for 1248 calls. There's an additional 288 calls before time keeping is
      up. Using the average time per hit/miss with the cache, we can calculate
      these calls to take 690 us (277 hit / 11 miss) with a 128 entry cache
      and 13319 us with no cache or an uninitialized cache.
      
      Comparing the 3 implementations the time spent in
      of_find_node_by_phandle() is:
      
      no cache:        20124 us (+ 13319 us)
      128 entry cache:  5134 us (+ 690 us)
      current cache:     819 us (+ 13319 us)
      
      We could move the allocation of the cache earlier to improve the
      current cache, but that just further complicates the situation as it
      needs to be after slab is up, so we can't do it when unflattening (which
      uses memblock).
      Reported-by: default avatarSebastian Andrzej Siewior <bigeasy@linutronix.de>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: Segher Boessenkool <segher@kernel.crashing.org>
      Cc: Frank Rowand <frowand.list@gmail.com>
      Acked-by: default avatarSebastian Andrzej Siewior <bigeasy@linutronix.de>
      Reviewed-by: default avatarFrank Rowand <frowand.list@gmail.com>
      Tested-by: default avatarFrank Rowand <frowand.list@gmail.com>
      Signed-off-by: default avatarRob Herring <robh@kernel.org>
      90dc0d1c
    • Miquel Raynal's avatar
      dt-bindings: phy: Fix the PX30 DSI PHY compatible in the example · afd36d28
      Miquel Raynal authored
      Use the upstream compatible instead of the BSP one in the example
      section of the DT bindings for this IP.
      
      Fixes: 3817c796 ("dt-bindings: phy: add yaml binding for rockchip,px30-dsi-dphy")
      Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
      Reviewed-by: default avatarHeiko Stuebner <heiko@sntech.de>
      Signed-off-by: default avatarRob Herring <robh@kernel.org>
      afd36d28
  2. 20 Dec, 2019 2 commits
  3. 19 Dec, 2019 4 commits
  4. 18 Dec, 2019 12 commits
  5. 17 Dec, 2019 2 commits
  6. 16 Dec, 2019 9 commits
  7. 15 Dec, 2019 6 commits
    • Linus Torvalds's avatar
      Linux 5.5-rc2 · d1eef1c6
      Linus Torvalds authored
      d1eef1c6
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma · 9603e221
      Linus Torvalds authored
      Pull rdma fixes from Doug Ledford:
       "A small collection of -rc fixes. Mostly. One API addition, but that's
        because we wanted to use it in a fix. There's also a bug fix that is
        going to render the 5.5 kernel's soft-RoCE driver incompatible with
        all soft-RoCE versions prior, but it's required to actually implement
        the protocol according to the RoCE spec and required in order for the
        soft-RoCE driver to be able to successfully work with actual RoCE
        hardware.
      
        Summary:
      
         - Update Steve Wise info
      
         - Fix for soft-RoCE crc calculations (will break back compatibility,
           but only with the soft-RoCE driver, which has had this bug since it
           was introduced and it is an on-the-wire bug, but will make
           soft-RoCE fully compatible with real RoCE hardware)
      
         - cma init fixup
      
         - counters oops fix
      
         - fix for mlx4 init/teardown sequence
      
         - fix for mkx5 steering rules
      
         - introduce a cleanup API, which isn't a fix, but we want to use it
           in the next fix
      
         - fix for mlx5 memory management that uses API in previous patch"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma:
        IB/mlx5: Fix device memory flows
        IB/core: Introduce rdma_user_mmap_entry_insert_range() API
        IB/mlx5: Fix steering rule of drop and count
        IB/mlx4: Follow mirror sequence of device add during device removal
        RDMA/counter: Prevent auto-binding a QP which are not tracked with res
        rxe: correctly calculate iCRC for unaligned payloads
        Update mailmap info for Steve Wise
        RDMA/cma: add missed unregister_pernet_subsys in init failure
      9603e221
    • Linus Torvalds's avatar
      Merge tag 'riscv/for-v5.5-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux · 1522d9da
      Linus Torvalds authored
      Pull RISC-V fixes from Paul Walmsley:
       "Two minor build fixes:
      
         - Fix builds of the ELF loader when built with 'make -j1' (nommu
           only)
      
         - Fix CONFIG_SOC_SIFIVE builds when CONFIG_TTY is disabled (found
           during randconfig testing)"
      
      * tag 'riscv/for-v5.5-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux:
        riscv: only select serial sifive if TTY is enabled
        riscv: Fix build dependency for loader
      1522d9da
    • Linus Torvalds's avatar
      Merge tag 'for-linus-5.5b-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip · b01d7cb4
      Linus Torvalds authored
      Pull xen fixes from Juergen Gross:
       "Two fixes: one for a resource accounting bug in some configurations
        and a fix for another patch which went into rc1"
      
      * tag 'for-linus-5.5b-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
        xen/balloon: fix ballooned page accounting without hotplug enabled
        xen-blkback: prevent premature module unload
      b01d7cb4
    • Linus Torvalds's avatar
      Merge branch 'remove-ksys-mount-dup' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/linux · 2e6d3045
      Linus Torvalds authored
      Pull ksys_mount() and ksys_dup() removal from Dominik Brodowski:
       "This small series replaces all in-kernel calls to the
        userspace-focused ksys_mount() and ksys_dup() with calls to
        kernel-centric functions:
      
        For each replacement of ksys_mount() with do_mount(), one needs to
        verify that the first and third parameter (char *dev_name, char *type)
        are strings allocated in kernelspace and that the fifth parameter
        (void *data) is either NULL or refers to a full page (only occurence
        in init/do_mounts.c::do_mount_root()). The second and fourth
        parameters (char *dir_name, unsigned long flags) are passed by
        ksys_mount() to do_mount() unchanged, and therefore do not require
        particular care.
      
        Moreover, instead of pretending to be userspace, the opening of
        /dev/console as stdin/stdout/stderr can be implemented using in-kernel
        functions as well. Thereby, ksys_dup() can be removed for good"
      
      [ This doesn't get rid of the special "kernel init runs with KERNEL_DS"
        case, but it at least removes _some_ of the users of "treat kernel
        pointers as user pointers for our magical init sequence".
      
        One day we'll hopefully be rid of it all, and can initialize our
        init_thread addr_limit to USER_DS.    - Linus ]
      
      * 'remove-ksys-mount-dup' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/linux:
        fs: remove ksys_dup()
        init: unify opening /dev/console as stdin/stdout/stderr
        init: use do_mount() instead of ksys_mount()
        initrd: use do_mount() instead of ksys_mount()
        devtmpfs: use do_mount() instead of ksys_mount()
      2e6d3045
    • Linus Torvalds's avatar
      Merge tag 'Wimplicit-fallthrough-5.5-rc2' of... · 510c9788
      Linus Torvalds authored
      Merge tag 'Wimplicit-fallthrough-5.5-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gustavoars/linux
      
      Pull fall through fix from Gustavo Silva:
       "Fix compile error on sh by marking expected switch fall-through"
      
      * tag 'Wimplicit-fallthrough-5.5-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gustavoars/linux:
        sh: kgdb: Mark expected switch fall-throughs
      510c9788