Skip to content
  1. Sep 09, 2023
    • Lad Prabhakar's avatar
      riscv: Kconfig.errata: Add dependency for RISCV_SBI in ERRATA_ANDES config · 2f73b35d
      Lad Prabhakar authored
      
      
      Andes errata uses sbi_ecalll() which is only available if RISCV_SBI is
      enabled. So add an dependency for RISCV_SBI in ERRATA_ANDES config to
      avoid any build failures.
      
      Reported-by: default avatarkernel test robot <lkp@intel.com>
      Closes: https://lore.kernel.org/oe-kbuild-all/202308311610.ec6bm2G8-lkp@intel.com/
      
      
      Signed-off-by: default avatarLad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
      Reviewed-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Tested-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Link: https://lore.kernel.org/r/20230901110320.312674-1-prabhakar.mahadev-lad.rj@bp.renesas.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      2f73b35d
    • Lad Prabhakar's avatar
      riscv: Kconfig.errata: Drop dependency for MMU in ERRATA_ANDES_CMO config · 54adc24c
      Lad Prabhakar authored
      
      
      Now that RISCV_DMA_NONCOHERENT conditionally selects DMA_DIRECT_REMAP
      ie only if MMU is enabled, we no longer need the MMU dependency in
      ERRATA_ANDES_CMO config.
      
      Signed-off-by: default avatarLad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
      Reviewed-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Link: https://lore.kernel.org/r/20230901105858.311745-1-prabhakar.mahadev-lad.rj@bp.renesas.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      54adc24c
    • Lad Prabhakar's avatar
      riscv: Kconfig: Select DMA_DIRECT_REMAP only if MMU is enabled · e7ddd00e
      Lad Prabhakar authored
      
      
      kernel/dma/mapping.c has its use of pgprot_dmacoherent() inside
      an #ifdef CONFIG_MMU block. kernel/dma/pool.c has its use of
      pgprot_dmacoherent() inside an #ifdef CONFIG_DMA_DIRECT_REMAP block.
      So select DMA_DIRECT_REMAP only if MMU is enabled for RISCV_DMA_NONCOHERENT
      config.
      
      This avoids users to explicitly select MMU.
      
      Suggested-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Signed-off-by: default avatarLad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
      Link: https://lore.kernel.org/r/20230901105111.311200-1-prabhakar.mahadev-lad.rj@bp.renesas.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      e7ddd00e
    • Palmer Dabbelt's avatar
      Merge patch series "bpf, riscv: use BPF prog pack allocator in BPF JIT" · 77eea559
      Palmer Dabbelt authored
      Puranjay Mohan <puranjay12@gmail.com> says:
      
      Here is some data to prove the V2 fixes the problem:
      
      Without this series:
      root@rv-selftester:~/src/kselftest/bpf# time ./test_tag
      test_tag: OK (40945 tests)
      
      real    7m47.562s
      user    0m24.145s
      sys     6m37.064s
      
      With this series applied:
      root@rv-selftester:~/src/selftest/bpf# time ./test_tag
      test_tag: OK (40945 tests)
      
      real    7m29.472s
      user    0m25.865s
      sys     6m18.401s
      
      BPF programs currently consume a page each on RISCV. For systems with many BPF
      programs, this adds significant pressure to instruction TLB. High iTLB pressure
      usually causes slow down for the whole system.
      
      Song Liu introduced the BPF prog pack allocator[1] to mitigate the above issue.
      It packs multiple BPF programs into a single huge page. It is currently only
      enabled for the x86_64 BPF JIT.
      
      I enabled this allocator on the ARM64 BPF JIT[2]. It is being reviewed now.
      
      This patch series enables the BPF prog pack allocator for the RISCV BPF JIT.
      
      ======================================================
      Performance Analysis of prog pack allocator on RISCV64
      ======================================================
      
      Test setup:
      ===========
      
      Host machine: Debian GNU/Linux 11 (bullseye)
      Qemu Version: QEMU emulator version 8.0.3 (Debian 1:8.0.3+dfsg-1)
      u-boot-qemu Version: 2023.07+dfsg-1
      opensbi Version: 1.3-1
      
      To test the performance of the BPF prog pack allocator on RV, a stresser
      tool[4] linked below was built. This tool loads 8 BPF programs on the system and
      triggers 5 of them in an infinite loop by doing system calls.
      
      The runner script starts 20 instances of the above which loads 8*20=160 BPF
      programs on the system, 5*20=100 of which are being constantly triggered.
      The script is passed a command which would be run in the above environment.
      
      The script was run with following perf command:
      ./run.sh "perf stat -a \
              -e iTLB-load-misses \
              -e dTLB-load-misses  \
              -e dTLB-store-misses \
              -e instructions \
              --timeout 60000"
      
      The output of the above command is discussed below before and after enabling the
      BPF prog pack allocator.
      
      The tests were run on qemu-system-riscv64 with 8 cpus, 16G memory. The rootfs
      was created using Bjorn's riscv-cross-builder[5] docker container linked below.
      
      Results
      =======
      
      Before enabling prog pack allocator:
      ------------------------------------
      
      Performance counter stats for 'system wide':
      
                 4939048      iTLB-load-misses
                 5468689      dTLB-load-misses
                  465234      dTLB-store-misses
           1441082097998      instructions
      
            60.045791200 seconds time elapsed
      
      After enabling prog pack allocator:
      -----------------------------------
      
      Performance counter stats for 'system wide':
      
                 3430035      iTLB-load-misses
                 5008745      dTLB-load-misses
                  409944      dTLB-store-misses
           1441535637988      instructions
      
            60.046296600 seconds time elapsed
      
      Improvements in metrics
      =======================
      
      It was expected that the iTLB-load-misses would decrease as now a single huge
      page is used to keep all the BPF programs compared to a single page for each
      program earlier.
      
      --------------------------------------------
      The improvement in iTLB-load-misses: -30.5 %
      --------------------------------------------
      
      I repeated this expriment more than 100 times in different setups and the
      improvement was always greater than 30%.
      
      This patch series is boot tested on the Starfive VisionFive 2 board[6].
      The performance analysis was not done on the board because it doesn't
      expose iTLB-load-misses, etc. The stresser program was run on the board to test
      the loading and unloading of BPF programs
      
      [1] https://lore.kernel.org/bpf/20220204185742.271030-1-song@kernel.org/
      [2] https://lore.kernel.org/all/20230626085811.3192402-1-puranjay12@gmail.com/
      [3] https://lore.kernel.org/all/20230626085811.3192402-2-puranjay12@gmail.com/
      [4] https://github.com/puranjaymohan/BPF-Allocator-Bench
      [5] https://github.com/bjoto/riscv-cross-builder
      [6] https://www.starfivetech.com/en/site/boards
      
      * b4-shazam-merge:
        bpf, riscv: use prog pack allocator in the BPF JIT
        riscv: implement a memset like function for text
        riscv: extend patch_text_nosync() for multiple pages
        bpf: make bpf_prog_pack allocator portable
      
      Link: https://lore.kernel.org/r/20230831131229.497941-1-puranjay12@gmail.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      77eea559
    • Palmer Dabbelt's avatar
      Merge patch series "riscv: Introduce KASLR" · f5780555
      Palmer Dabbelt authored
      Alexandre Ghiti <alexghiti@rivosinc.com> says:
      
      The following KASLR implementation allows to randomize the kernel mapping:
      
      - virtually: we expect the bootloader to provide a seed in the device-tree
      - physically: only implemented in the EFI stub, it relies on the firmware to
        provide a seed using EFI_RNG_PROTOCOL. arm64 has a similar implementation
        hence the patch 3 factorizes KASLR related functions for riscv to take
        advantage.
      
      The new virtual kernel location is limited by the early page table that only
      has one PUD and with the PMD alignment constraint, the kernel can only take
      < 512 positions.
      
      * b4-shazam-merge:
        riscv: libstub: Implement KASLR by using generic functions
        libstub: Fix compilation warning for rv32
        arm64: libstub: Move KASLR handling functions to kaslr.c
        riscv: Dump out kernel offset information on panic
        riscv: Introduce virtual kernel mapping KASLR
      
      Link: https://lore.kernel.org/r/20230722123850.634544-1-alexghiti@rivosinc.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      f5780555
    • Palmer Dabbelt's avatar
      Merge patch "RISC-V: Add ptrace support for vectors" · f0936363
      Palmer Dabbelt authored
      This resurrects the vector ptrace() support that was removed for 6.5 due
      to some bugs cropping up as part of the GDB review process.
      
      * b4-shazam-merge:
        RISC-V: Add ptrace support for vectors
      
      Link: https://lore.kernel.org/r/20230825050248.32681-1-andy.chiu@sifive.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      f0936363
    • Palmer Dabbelt's avatar
      Merge patch series "Add non-coherent DMA support for AX45MP" · c23be918
      Palmer Dabbelt authored
      Prabhakar <prabhakar.csengg@gmail.com> says:
      
      From: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
      
      non-coherent DMA support for AX45MP
      ====================================
      
      On the Andes AX45MP core, cache coherency is a specification option so it
      may not be supported. In this case DMA will fail. To get around with this
      issue this patch series does the below:
      
      1] Andes alternative ports is implemented as errata which checks if the
      IOCP is missing and only then applies to CMO errata. One vendor specific
      SBI EXT (ANDES_SBI_EXT_IOCP_SW_WORKAROUND) is implemented as part of
      errata.
      
      Below are the configs which Andes port provides (and are selected by
      RZ/Five):
            - ERRATA_ANDES
            - ERRATA_ANDES_CMO
      
      OpenSBI patch supporting ANDES_SBI_EXT_IOCP_SW_WORKAROUND SBI is now
      part v1.3 release.
      
      2] Andes AX45MP core has a Programmable Physical Memory Attributes (PMA)
      block that allows dynamic adjustment of memory attributes in the runtime.
      It contains a configurable amount of PMA entries implemented as CSR
      registers to control the attributes of memory locations in interest.
      OpenSBI configures the PMA regions as required and creates a reserve memory
      node and propagates it to the higher boot stack.
      
      Currently OpenSBI (upstream) configures the required PMA region and passes
      this a shared DMA pool to Linux.
      
          reserved-memory {
              #address-cells = <2>;
              #size-cells = <2>;
              ranges;
      
              pma_resv0@58000000 {
                  compatible = "shared-dma-pool";
                  reg = <0x0 0x58000000 0x0 0x08000000>;
                  no-map;
                  linux,dma-default;
              };
          };
      
      The above shared DMA pool gets appended to Linux DTB so the DMA memory
      requests go through this region.
      
      3] We provide callbacks to synchronize specific content between memory and
      cache.
      
      4] RZ/Five SoC selects the below configs
              - AX45MP_L2_CACHE
              - DMA_GLOBAL_POOL
              - ERRATA_ANDES
              - ERRATA_ANDES_CMO
      
      ----------x---------------------x--------------------x---------------x----
      
      * b4-shazam-merge:
        soc: renesas: Kconfig: Select the required configs for RZ/Five SoC
        cache: Add L2 cache management for Andes AX45MP RISC-V core
        dt-bindings: cache: andestech,ax45mp-cache: Add DT binding documentation for L2 cache controller
        riscv: mm: dma-noncoherent: nonstandard cache operations support
        riscv: errata: Add Andes alternative ports
        riscv: asm: vendorid_list: Add Andes Technology to the vendors list
      
      Link: https://lore.kernel.org/r/20230818135723.80612-1-prabhakar.mahadev-lad.rj@bp.renesas.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      c23be918
    • Palmer Dabbelt's avatar
      Merge patch series "riscv: dma-mapping: unify support for cache flushes" · 7f215d00
      Palmer Dabbelt authored
      Prabhakar <prabhakar.csengg@gmail.com> says:
      
      From: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
      
      This patch series is a subset from Arnd's original series [0]. Ive just
      picked up the bits required for RISC-V unification of cache flushing.
      Remaining patches from the series [0] will be taken care by Arnd soon.
      
      * b4-shazam-merge:
        riscv: dma-mapping: switch over to generic implementation
        riscv: dma-mapping: skip invalidation before bidirectional DMA
        riscv: dma-mapping: only invalidate after DMA, not flush
      
      Link: https://lore.kernel.org/r/20230816232336.164413-1-prabhakar.mahadev-lad.rj@bp.renesas.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      7f215d00
    • Palmer Dabbelt's avatar
      Merge patch series "RISC-V: Probe for misaligned access speed" · 580253b5
      Palmer Dabbelt authored
      Evan Green <evan@rivosinc.com> says:
      
      The current setting for the hwprobe bit indicating misaligned access
      speed is controlled by a vendor-specific feature probe function. This is
      essentially a per-SoC table we have to maintain on behalf of each vendor
      going forward. Let's convert that instead to something we detect at
      runtime.
      
      We have two assembly routines at the heart of our probe: one that
      does a bunch of word-sized accesses (without aligning its input buffer),
      and the other that does byte accesses. If we can move a larger number of
      bytes using misaligned word accesses than we can with the same amount of
      time doing byte accesses, then we can declare misaligned accesses as
      "fast".
      
      The tradeoff of reducing this maintenance burden is boot time. We spend
      4-6 jiffies per core doing this measurement (0-2 on jiffie edge
      alignment, and 4 on measurement). The timing loop was based on
      raid6_choose_gen(), which uses (16+1)*N jiffies (where N is the number
      of algorithms). By taking only the fastest iteration out of all
      attempts for use in the comparison, variance between runs is very low.
      On my THead C906, it looks like this:
      
      [    0.047563] cpu0: Ratio of byte access time to unaligned word access is 4.34, unaligned accesses are fast
      
      Several others have chimed in with results on slow machines with the
      older algorithm, which took all runs into account, including noise like
      interrupts. Even with this variation, results indicate that in all cases
      (fast, slow, and emulated) the measured numbers are nowhere near each
      other (always multiple factors away).
      
      * b4-shazam-merge:
        RISC-V: alternative: Remove feature_probe_func
        RISC-V: Probe for unaligned access speed
      
      Link: https://lore.kernel.org/r/20230818194136.4084400-1-evan@rivosinc.com
      
      
      Signed-off-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
      580253b5
  2. Sep 06, 2023
  3. Sep 02, 2023
  4. Sep 01, 2023
    • Linus Torvalds's avatar
      Merge tag 'riscv-for-linus-6.6-mw1' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux · e0152e74
      Linus Torvalds authored
      Pull RISC-V updates from Palmer Dabbelt:
      
       - Support for the new "riscv,isa-extensions" and "riscv,isa-base"
         device tree interfaces for probing extensions
      
       - Support for userspace access to the performance counters
      
       - Support for more instructions in kprobes
      
       - Crash kernels can be allocated above 4GiB
      
       - Support for KCFI
      
       - Support for ELFs in !MMU configurations
      
       - ARCH_KMALLOC_MINALIGN has been reduced to 8
      
       - mmap() defaults to sv48-sized addresses, with longer addresses hidden
         behind a hint (similar to Arm and Intel)
      
       - Also various fixes and cleanups
      
      * tag 'riscv-for-linus-6.6-mw1' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux: (51 commits)
        lib/Kconfig.debug: Restrict DEBUG_INFO_SPLIT for RISC-V
        riscv: support PREEMPT_DYNAMIC with static keys
        riscv: Move create_tmp_mapping() to init sections
        riscv: Mark KASAN tmp* page tables variables as static
        riscv: mm: use bitmap_zero() API
        riscv: enable DEBUG_FORCE_FUNCTION_ALIGN_64B
        riscv: remove redundant mv instructions
        RISC-V: mm: Document mmap changes
        RISC-V: mm: Update pgtable comment documentation
        RISC-V: mm: Add tests for RISC-V mm
        RISC-V: mm: Restrict address space for sv39,sv48,sv57
        riscv: enable DMA_BOUNCE_UNALIGNED_KMALLOC for !dma_coherent
        riscv: allow kmalloc() caches aligned to the smallest value
        riscv: support the elf-fdpic binfmt loader
        binfmt_elf_fdpic: support 64-bit systems
        riscv: Allow CONFIG_CFI_CLANG to be selected
        riscv/purgatory: Disable CFI
        riscv: Add CFI error handling
        riscv: Add ftrace_stub_graph
        riscv: Add types to indirectly called assembly functions
        ...
      e0152e74
    • Linus Torvalds's avatar
      Merge tag 'csky-for-linus-6.6-2' of https://github.com/c-sky/csky-linux · a031eba2
      Linus Torvalds authored
      Pull arch/csky fix from Guo Ren:
      
       - Fix compile error by missing header file
      
      * tag 'csky-for-linus-6.6-2' of https://github.com/c-sky/csky-linux:
        csky: Fixup compile error
      a031eba2
    • Linus Torvalds's avatar
      Merge tag 'nfs-for-6.6-1' of git://git.linux-nfs.org/projects/anna/linux-nfs · 99d99825
      Linus Torvalds authored
      Pull NFS client updates from Anna Schumaker:
       "New Features:
         - Enable the NFS v4.2 READ_PLUS operation by default
      
        Stable Fixes:
         - NFSv4/pnfs: minor fix for cleanup path in nfs4_get_device_info
         - NFS: Fix a potential data corruption
      
        Bugfixes:
         - Fix various READ_PLUS issues including:
            - smatch warnings
            - xdr size calculations
            - scratch buffer handling
            - 32bit / highmem xdr page handling
         - Fix checkpatch errors in file.c
         - Fix redundant readdir request after an EOF
         - Fix handling of COPY ERR_OFFLOAD_NO_REQ
         - Fix assignment of xprtdata.cred
      
        Cleanups:
         - Remove unused xprtrdma function declarations
         - Clean up an integer overflow check to avoid a warning
         - Clean up #includes in dns_resolve.c
         - Clean up nfs4_get_device_info so we don't pass a NULL pointer
           to __free_page()
         - Clean up sunrpc TCP socket timeout configuration
         - Guard against READDIR loops when entry names are too long
         - Use EXCHID4_FLAG_USE_PNFS_DS for DS servers"
      
      * tag 'nfs-for-6.6-1' of git://git.linux-nfs.org/projects/anna/linux-nfs: (22 commits)
        pNFS: Fix assignment of xprtdata.cred
        NFSv4.2: fix handling of COPY ERR_OFFLOAD_NO_REQ
        NFS: Guard against READDIR loop when entry names exceed MAXNAMELEN
        NFSv4.1: use EXCHGID4_FLAG_USE_PNFS_DS for DS server
        NFS/pNFS: Set the connect timeout for the pNFS flexfiles driver
        SUNRPC: Don't override connect timeouts in rpc_clnt_add_xprt()
        SUNRPC: Allow specification of TCP client connect timeout at setup
        SUNRPC: Refactor and simplify connect timeout
        SUNRPC: Set the TCP_SYNCNT to match the socket timeout
        NFS: Fix a potential data corruption
        nfs: fix redundant readdir request after get eof
        nfs/blocklayout: Use the passed in gfp flags
        filemap: Fix errors in file.c
        NFSv4/pnfs: minor fix for cleanup path in nfs4_get_device_info
        NFS: Move common includes outside ifdef
        SUNRPC: clean up integer overflow check
        xprtrdma: Remove unused function declaration rpcrdma_bc_post_recv()
        NFS: Enable the READ_PLUS operation by default
        SUNRPC: kmap() the xdr pages during decode
        NFSv4.2: Rework scratch handling for READ_PLUS (again)
        ...
      99d99825
    • Linus Torvalds's avatar
      Merge tag 'nfsd-6.6' of git://git.kernel.org/pub/scm/linux/kernel/git/cel/linux · f35d1706
      Linus Torvalds authored
      Pull nfsd updates from Chuck Lever:
       "I'm thrilled to announce that the Linux in-kernel NFS server now
        offers NFSv4 write delegations. A write delegation enables a client to
        cache data and metadata for a single file more aggressively, reducing
        network round trips and server workload. Many thanks to Dai Ngo for
        contributing this facility, and to Jeff Layton and Neil Brown for
        reviewing and testing it.
      
        This release also sees the removal of all support for DES- and
        triple-DES-based Kerberos encryption types in the kernel's SunRPC
        implementation. These encryption types have been deprecated by the
        Internet community for years and are considered insecure. This change
        affects both the in-kernel NFS client and server.
      
        The server's UDP and TCP socket transports have now fully adopted
        David Howells' new bio_vec iterator so that no more than one sendmsg()
        call is needed to transmit each RPC message. In particular, this helps
        kTLS optimize record boundaries when sending RPC-with-TLS replies, and
        it takes the server a baby step closer to handling file I/O via
        folios.
      
        We've begun work on overhauling the SunRPC thread scheduler to remove
        a costly linked-list walk when looking for an idle RPC service thread
        to wake. The pre-requisites are included in this release. Thanks to
        Neil Brown for his ongoing work on this improvement"
      
      * tag 'nfsd-6.6' of git://git.kernel.org/pub/scm/linux/kernel/git/cel/linux: (56 commits)
        Documentation: Add missing documentation for EXPORT_OP flags
        SUNRPC: Remove unused declaration rpc_modcount()
        SUNRPC: Remove unused declarations
        NFSD: da_addr_body field missing in some GETDEVICEINFO replies
        SUNRPC: Remove return value of svc_pool_wake_idle_thread()
        SUNRPC: make rqst_should_sleep() idempotent()
        SUNRPC: Clean up svc_set_num_threads
        SUNRPC: Count ingress RPC messages per svc_pool
        SUNRPC: Deduplicate thread wake-up code
        SUNRPC: Move trace_svc_xprt_enqueue
        SUNRPC: Add enum svc_auth_status
        SUNRPC: change svc_xprt::xpt_flags bits to enum
        SUNRPC: change svc_rqst::rq_flags bits to enum
        SUNRPC: change svc_pool::sp_flags bits to enum
        SUNRPC: change cache_head.flags bits to enum
        SUNRPC: remove timeout arg from svc_recv()
        SUNRPC: change svc_recv() to return void.
        SUNRPC: call svc_process() from svc_recv().
        nfsd: separate nfsd_last_thread() from nfsd_put()
        nfsd: Simplify code around svc_exit_thread() call in nfsd()
        ...
      f35d1706
    • Linus Torvalds's avatar
      Merge tag '6.6-rc-ksmbd-fixes-part1' of git://git.samba.org/ksmbd · 8ae5d298
      Linus Torvalds authored
      Pull smb server updates from Steve French:
      
       - fix potential overflows in decoding create and in session setup
         requests
      
       - cleanup fixes
      
       - compounding fixes, including one for MacOS compounded read requests
      
       - session setup error handling fix
      
       - fix mode bit bug when applying force_directory_mode and
         force_create_mode
      
       - RDMA (smbdirect) write fix
      
      * tag '6.6-rc-ksmbd-fixes-part1' of git://git.samba.org/ksmbd:
        ksmbd: add missing calling smb2_set_err_rsp() on error
        ksmbd: replace one-element array with flex-array member in struct smb2_ea_info
        ksmbd: fix slub overflow in ksmbd_decode_ntlmssp_auth_blob()
        ksmbd: fix wrong DataOffset validation of create context
        ksmbd: Fix one kernel-doc comment
        ksmbd: reduce descriptor size if remaining bytes is less than request size
        ksmbd: fix `force create mode' and `force directory mode'
        ksmbd: fix wrong interim response on compound
        ksmbd: add support for read compound
        ksmbd: switch to use kmemdup_nul() helper
      8ae5d298
    • Linus Torvalds's avatar
      Merge tag 'jfs-6.6' of github.com:kleikamp/linux-shaggy · 7e5cd6f6
      Linus Torvalds authored
      Pull jfs updates from Dave Kleikamp:
       "A few small fixes"
      
      * tag 'jfs-6.6' of github.com:kleikamp/linux-shaggy:
        jfs: validate max amount of blocks before allocation.
        jfs: remove redundant initialization to pointer ip
        jfs: fix invalid free of JFS_IP(ipimap)->i_imap in diUnmount
        FS: JFS: (trivial) Fix grammatical error in extAlloc
        fs/jfs: prevent double-free in dbUnmount() after failed jfs_remount()
      7e5cd6f6
    • Linus Torvalds's avatar
      Merge tag 'ext4_for_linus-6.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 · 3ef96fcf
      Linus Torvalds authored
      Pull ext4 updates from Ted Ts'o:
       "Many ext4 and jbd2 cleanups and bug fixes:
      
         - Cleanups in the ext4 remount code when going to and from read-only
      
         - Cleanups in ext4's multiblock allocator
      
         - Cleanups in the jbd2 setup/mounting code paths
      
         - Performance improvements when appending to a delayed allocation file
      
         - Miscellaneous syzbot and other bug fixes"
      
      * tag 'ext4_for_linus-6.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: (60 commits)
        ext4: fix slab-use-after-free in ext4_es_insert_extent()
        libfs: remove redundant checks of s_encoding
        ext4: remove redundant checks of s_encoding
        ext4: reject casefold inode flag without casefold feature
        ext4: use LIST_HEAD() to initialize the list_head in mballoc.c
        ext4: do not mark inode dirty every time when appending using delalloc
        ext4: rename s_error_work to s_sb_upd_work
        ext4: add periodic superblock update check
        ext4: drop dio overwrite only flag and associated warning
        ext4: add correct group descriptors and reserved GDT blocks to system zone
        ext4: remove unused function declaration
        ext4: mballoc: avoid garbage value from err
        ext4: use sbi instead of EXT4_SB(sb) in ext4_mb_new_blocks_simple()
        ext4: change the type of blocksize in ext4_mb_init_cache()
        ext4: fix unttached inode after power cut with orphan file feature enabled
        jbd2: correct the end of the journal recovery scan range
        ext4: ext4_get_{dev}_journal return proper error value
        ext4: cleanup ext4_get_dev_journal() and ext4_get_journal()
        jbd2: jbd2_journal_init_{dev,inode} return proper error return value
        jbd2: drop useless error tag in jbd2_journal_wipe()
        ...
      3ef96fcf
    • Linus Torvalds's avatar
      Merge tag 'dlm-6.6' of git://git.kernel.org/pub/scm/linux/kernel/git/teigland/linux-dlm · 659b3613
      Linus Torvalds authored
      Pull dlm updates from David Teigland:
      
       - Allow blocking posix lock requests to be interrupted while waiting.
         This requires a cancel request to be sent to the userspace daemon
         where posix lock requests are processed across the cluster.
      
       - Fix a posix lock patch from the previous cycle in which lock requests
         from different file systems could be mixed up.
      
       - Fix some long standing problems with nfs posix lock cancelation.
      
       - Add a new debugfs file for printing queued callbacks.
      
       - Stop modifying buffers that have been used to receive a message.
      
       - Misc cleanups and some refactoring.
      
      * tag 'dlm-6.6' of git://git.kernel.org/pub/scm/linux/kernel/git/teigland/linux-dlm:
        dlm: fix plock lookup when using multiple lockspaces
        fs: dlm: don't use RCOM_NAMES for version detection
        fs: dlm: create midcomms nodes when configure
        fs: dlm: constify receive buffer
        fs: dlm: drop rxbuf manipulation in dlm_recover_master_copy
        fs: dlm: drop rxbuf manipulation in dlm_copy_master_names
        fs: dlm: get recovery sequence number as parameter
        fs: dlm: cleanup lock order
        fs: dlm: remove clear_members_cb
        fs: dlm: add plock dev tracepoints
        fs: dlm: check on plock ops when exit dlm
        fs: dlm: debugfs for queued callbacks
        fs: dlm: remove unused processed_nodes
        fs: dlm: add missing spin_unlock
        fs: dlm: fix F_CANCELLK to cancel pending request
        fs: dlm: allow to F_SETLKW getting interrupted
        fs: dlm: remove twice newline
      659b3613
    • Linus Torvalds's avatar
      Merge tag 'v6.6-vfs.super.fixes.2' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs · e7e9423d
      Linus Torvalds authored
      Pull more superblock follow-on fixes from Christian Brauner:
       "This contains two more small follow-up fixes for the super work this
        cycle. I went through all filesystems once more and detected two minor
        issues that still needed fixing:
      
         - Some filesystems support mtd devices (e.g., mount -t jffs2 mtd2
           /mnt). The mtd infrastructure uses the sb->s_mtd pointer to find an
           existing superblock. When the mtd device is put and sb->s_mtd
           cleared the superblock can still be found fs_supers and so this
           risks a use-after-free.
      
           Add a small patch that aligns mtd with what we did for regular
           block devices and switch keying to rely on sb->s_dev.
      
           (This was tested with mtd devices and jffs2 as xfstests doesn't
           support mtd devices.)
      
         - Switch nfs back to rely on kill_anon_super() so the superblock is
           removed from the list of active supers before sb->s_fs_info is
           freed"
      
      * tag 'v6.6-vfs.super.fixes.2' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs:
        NFS: switch back to using kill_anon_super
        mtd: key superblock by device number
        fs: export sget_dev()
      e7e9423d
    • Ingo Molnar's avatar
      powerpc: Fix pud_mkwrite() definition after pte_mkwrite() API changes · f441ff73
      Ingo Molnar authored
      Fix up missed semantic mis-merge between commits
      
        161e393c ("mm: Make pte_mkwrite() take a VMA")
        27af67f3 ("powerpc/book3s64/mm: enable transparent pud hugepage")
      
      where the newly introduced powerpc use of 'pte_mkwrite()' needs to use
      the 'novma()' versions as per commit 2f0584f3 ("mm: Rename arch
      pte_mkwrite()'s to pte_mkwrite_novma()").
      
      Fixes: df57721f
      
       ("Merge tag 'x86_shstk_for_6.6-rc1' of [...]")
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      f441ff73