Wei Yang
96ae4c9019
maple_tree: cleanup function descriptions
...
This patch tries to cleanup some function description:
* function name mismatch
* parameter name mismatch
* parameter all end up with ':'
* not prefix '*' if parameter is a pointer
There is still some missing description of parameters, I didn't add them
since I am not sure the exact meaning.
Link: https://lkml.kernel.org/r/20240830220400.2007-1-richard.weiyang@gmail.com
Signed-off-by: Wei Yang <richard.weiyang@gmail.com >
Reviewed-by: Liam R. Howlett <Liam.Howlett@Oracle.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-09 16:39:05 -07:00
Wei Yang
21a449bedf
maple_tree: dump error message based on format
...
Just do what mt_dump_range64() does.
Dump the error message based on format.
Link: https://lkml.kernel.org/r/20240826012422.29935-2-richard.weiyang@gmail.com
Signed-off-by: Wei Yang <richard.weiyang@gmail.com >
Cc: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox <willy@infradead.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-09 16:39:01 -07:00
Wei Yang
8152831069
maple_tree: arange64 node is not a leaf node
...
mt_dump_arange64() only applies to an entry whose type is maple_arange_64,
in which mte_is_leaf() must return false.
Since mte_is_leaf() here is always false, we can remove this condition
check.
Link: https://lkml.kernel.org/r/20240826012422.29935-1-richard.weiyang@gmail.com
Signed-off-by: Wei Yang <richard.weiyang@gmail.com >
Reviewed-by: Liam R. Howlett <Liam.Howlett@Oracle.com >
Cc: Matthew Wilcox <willy@infradead.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-09 16:39:01 -07:00
Zhen Lei
63a4a9b52c
debugobjects: Remove redundant checks in fill_pool()
...
fill_pool() checks locklessly at the beginning whether the pool has to be
refilled. After that it checks locklessly in a loop whether the free list
contains objects and repeats the refill check.
If both conditions are true, it acquires the pool lock and tries to move
objects from the free list to the pool repeating the same checks again.
There are two redundant issues with that:
1) The repeated check for the fill condition
2) The loop processing
The repeated check is pointless as it was just established that fill is
required. The condition has to be re-evaluated under the lock anyway.
The loop processing is not required either because there is practically
zero chance that a repeated attempt will succeed if the checks under the
lock terminate the moving of objects.
Remove the redundant check and replace the loop with a simple if condition.
[ tglx: Massaged change log ]
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com >
Signed-off-by: Thomas Gleixner <tglx@linutronix.de >
Link: https://lore.kernel.org/all/20240904133944.2124-4-thunder.leizhen@huawei.com
2024-09-09 16:40:26 +02:00
Zhen Lei
684d28feb8
debugobjects: Fix conditions in fill_pool()
...
fill_pool() uses 'obj_pool_min_free' to decide whether objects should be
handed back to the kmem cache. But 'obj_pool_min_free' records the lowest
historical value of the number of objects in the object pool and not the
minimum number of objects which should be kept in the pool.
Use 'debug_objects_pool_min_level' instead, which holds the minimum number
which was scaled to the number of CPUs at boot time.
[ tglx: Massage change log ]
Fixes: d26bf5056f ("debugobjects: Reduce number of pool_lock acquisitions in fill_pool()")
Fixes: 36c4ead6f6 ("debugobjects: Add global free list and the counter")
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com >
Signed-off-by: Thomas Gleixner <tglx@linutronix.de >
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/all/20240904133944.2124-3-thunder.leizhen@huawei.com
2024-09-09 16:40:25 +02:00
Zhen Lei
e4757c710b
debugobjects: Fix the compilation attributes of some global variables
...
1. Both debug_objects_pool_min_level and debug_objects_pool_size are
read-only after initialization, change attribute '__read_mostly' to
'__ro_after_init', and remove '__data_racy'.
2. Many global variables are read in the debug_stats_show() function, but
didn't mask KCSAN's detection. Add '__data_racy' for them.
Suggested-by: Thomas Gleixner <tglx@linutronix.de >
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com >
Signed-off-by: Thomas Gleixner <tglx@linutronix.de >
Link: https://lore.kernel.org/all/20240904133944.2124-2-thunder.leizhen@huawei.com
2024-09-09 16:40:25 +02:00
Kent Overstreet
b3f9da79e7
lib/generic-radix-tree.c: add preallocation
...
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev >
2024-09-09 09:41:47 -04:00
Kent Overstreet
f659463381
lib/generic-radix-tree.c: genradix_ptr_inlined()
...
Provide an inlined fast path
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev >
2024-09-09 09:41:47 -04:00
Anna-Maria Behnsen
bd7c8ff9fe
treewide: Fix wrong singular form of jiffies in comments
...
There are several comments all over the place, which uses a wrong singular
form of jiffies.
Replace 'jiffie' by 'jiffy'. No functional change.
Signed-off-by: Anna-Maria Behnsen <anna-maria@linutronix.de >
Signed-off-by: Thomas Gleixner <tglx@linutronix.de >
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org > # m68k
Link: https://lore.kernel.org/all/20240904-devel-anna-maria-b4-timers-flseep-v1-3-e98760256370@linutronix.de
2024-09-08 20:47:40 +02:00
Jakub Kicinski
502cc061de
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
...
Cross-merge networking fixes after downstream PR.
Conflicts:
drivers/net/phy/phy_device.c
2560db6ede ("net: phy: Fix missing of_node_put() for leds")
1dce520abd ("net: phy: Use for_each_available_child_of_node_scoped()")
https://lore.kernel.org/20240904115823.74333648@canb.auug.org.au
Adjacent changes:
drivers/net/ethernet/xilinx/xilinx_axienet.h
drivers/net/ethernet/xilinx/xilinx_axienet_main.c
858430db28 ("net: xilinx: axienet: Fix race in axienet_stop")
76abb5d675 ("net: xilinx: axienet: Add statistics support")
Signed-off-by: Jakub Kicinski <kuba@kernel.org >
2024-09-05 20:37:20 -07:00
Linus Torvalds
120434e5b3
Merge tag 'linux_kselftest-kunit-fixes-6.11-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest
...
Pull kunit fix fromShuah Khan:
"One single fix to a use-after-free bug resulting from
kunit_driver_create() failing to copy the driver name leaving it on
the stack or freeing it"
* tag 'linux_kselftest-kunit-fixes-6.11-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest:
kunit: Device wrappers should also manage driver name
2024-09-05 09:43:38 -07:00
Tejun Heo
649e980dad
Merge branch 'bpf/master' into for-6.12
...
Pull bpf/master to receive baebe9aaba ("bpf: allow passing struct
bpf_iter_<type> as kfunc arguments") and related changes in preparation for
the DSQ iterator patchset.
Signed-off-by: Tejun Heo <tj@kernel.org >
2024-09-04 11:41:32 -10:00
Matthew Wilcox (Oracle)
e27ad6560e
printf: remove %pGt support
...
Patch series "Increase the number of bits available in page_type".
Kent wants more than 16 bits in page_type, so I resurrected this old patch
and expanded it a bit. It's a bit more efficient than our current scheme
(1 4-byte insn vs 3 insns of 13 bytes total) to test a single page type.
This patch (of 4):
An upcoming patch will convert page type from being a bitfield to a
single byte, so we will not be able to use %pG to print the page type
any more. The printing of the symbolic name will be restored in that
patch.
Link: https://lkml.kernel.org/r/20240821173914.2270383-1-willy@infradead.org
Link: https://lkml.kernel.org/r/20240821173914.2270383-2-willy@infradead.org
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org >
Acked-by: David Hildenbrand <david@redhat.com >
Cc: Hyeonggon Yoo <42.hyeyoo@gmail.com >
Cc: Kent Overstreet <kent.overstreet@linux.dev >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-03 21:15:42 -07:00
Alexander Lobakin
00d066a4d4
netdev_features: convert NETIF_F_LLTX to dev->lltx
...
NETIF_F_LLTX can't be changed via Ethtool and is not a feature,
rather an attribute, very similar to IFF_NO_QUEUE (and hot).
Free one netdev_features_t bit and make it a "hot" private flag.
Signed-off-by: Alexander Lobakin <aleksander.lobakin@intel.com >
Signed-off-by: Paolo Abeni <pabeni@redhat.com >
2024-09-03 11:36:43 +02:00
Yang Ruibin
38676d9e33
lib: fix the NULL vs IS_ERR() bug for debugfs_create_dir()
...
debugfs_create_dir() returns error pointers. It never returns NULL. So
use IS_ERR() to check it.
Link: https://lkml.kernel.org/r/20240821073441.9701-1-11162571@vivo.com
Signed-off-by: Yang Ruibin <11162571@vivo.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:40 -07:00
Andy Shevchenko
fb54ea1ee8
dimlib: use *-y instead of *-objs in Makefile
...
*-objs suffix is reserved rather for (user-space) host programs while
usually *-y suffix is used for kernel drivers (although *-objs works for
that purpose for now).
Let's correct the old usages of *-objs in Makefiles.
Link: https://lkml.kernel.org/r/20240821155140.611514-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com >
Acked-by: Florian Fainelli <florian.fainelli@broadcom.com >
Reviewed-by: Alexander Lobakin <aleksander.lobakin@intel.com >
Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk >
Cc: Tal Gilboa <talgi@nvidia.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:40 -07:00
Uros Bizjak
16d9691ad4
lib/percpu_counter: add missing __percpu qualifier to a cast
...
Add missing __percpu qualifier to a (void *) cast to fix
percpu_counter.c:212:36: warning: cast removes address space '__percpu' of expression
percpu_counter.c:212:33: warning: incorrect type in assignment (different address spaces)
percpu_counter.c:212:33: expected signed int [noderef] [usertype] __percpu *counters
percpu_counter.c:212:33: got void *
sparse warnings.
Found by GCC's named address space checks.
There were no changes in the resulting object file.
Link: https://lkml.kernel.org/r/20240814064437.940162-1-ubizjak@gmail.com
Signed-off-by: Uros Bizjak <ubizjak@gmail.com >
Cc: Dennis Zhou <dennis@kernel.org >
Cc: Tejun Heo <tj@kernel.org >
Cc: Christoph Lameter <cl@linux.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:34 -07:00
Kuan-Wei Chiu
cbf164cd44
lib/bcd: optimize _bin2bcd() for improved performance
...
The original _bin2bcd() function used / 10 and % 10 operations for
conversion. Although GCC optimizes these operations and does not generate
division or modulus instructions, the new implementation reduces the
number of mov instructions in the generated code for both x86-64 and ARM
architectures.
This optimization calculates the tens digit using (val * 103) >> 10, which
is accurate for values of 'val' in the range [0, 178]. Given that the
valid input range is [0, 99], this method ensures correctness while
simplifying the generated code.
Link: https://lkml.kernel.org/r/20240812170229.229380-1-visitorckw@gmail.com
Signed-off-by: Kuan-Wei Chiu <visitorckw@gmail.com >
Cc: Ching-Chun (Jim) Huang <jserv@ccns.ncku.edu.tw >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:33 -07:00
Jani Nikula
6ce2082fd3
fault-inject: improve build for CONFIG_FAULT_INJECTION=n
...
The fault-inject.h users across the kernel need to add a lot of #ifdef
CONFIG_FAULT_INJECTION to cater for shortcomings in the header. Make
fault-inject.h self-contained for CONFIG_FAULT_INJECTION=n, and add stubs
for DECLARE_FAULT_ATTR(), setup_fault_attr(), should_fail_ex(), and
should_fail() to allow removal of conditional compilation.
[akpm@linux-foundation.org: repair fallout from no longer including debugfs.h into fault-inject.h]
[akpm@linux-foundation.org: fix drivers/misc/xilinx_tmr_inject.c]
[akpm@linux-foundation.org: Add debugfs.h inclusion to more files, per Stephen]
Link: https://lkml.kernel.org/r/20240813121237.2382534-1-jani.nikula@intel.com
Fixes: 6ff1cb355e ("[PATCH] fault-injection capabilities infrastructure")
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Cc: Akinobu Mita <akinobu.mita@gmail.com >
Cc: Abhinav Kumar <quic_abhinavk@quicinc.com >
Cc: Dmitry Baryshkov <dmitry.baryshkov@linaro.org >
Cc: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com >
Cc: Lucas De Marchi <lucas.demarchi@intel.com >
Cc: Rob Clark <robdclark@gmail.com >
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com >
Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com >
Cc: Stephen Rothwell <sfr@canb.auug.org.au >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:33 -07:00
Davidlohr Bueso
a15bec6a8f
lib/rhashtable: cleanup fallback check in bucket_table_alloc()
...
Upon allocation failure, the current check with the nofail bits is
unnecessary, and further stands in the way of discouraging direct use of
__GFP_NOFAIL. Remove this and replace with the proper way of determining
if doing a non-blocking allocation for the nested table case.
Link: https://lkml.kernel.org/r/20240806153927.184515-1-dave@stgolabs.net
Signed-off-by: Davidlohr Bueso <dave@stgolabs.net >
Suggested-by: Michal Hocko <mhocko@suse.com >
Cc: Davidlohr Bueso <dave@stgolabs.net >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:32 -07:00
J. R. Okajima
e0ba72e3a4
lockdep: upper limit LOCKDEP_CHAINS_BITS
...
CONFIG_LOCKDEP_CHAINS_BITS value decides the size of chain_hlocks[] in
kernel/locking/lockdep.c, and it is checked by add_chain_cache() with
BUILD_BUG_ON((1UL << 24) <= ARRAY_SIZE(chain_hlocks));
This patch is just to silence BUILD_BUG_ON().
See also https://lore.kernel.org/all/30795.1620913191@jrobl/
[cmllamas@google.com: fix minor checkpatch issues in commit log]
Link: https://lkml.kernel.org/r/20240723164018.2489615-1-cmllamas@google.com
Signed-off-by: J. R. Okajima <hooanon05g@gmail.com >
Signed-off-by: Carlos Llamas <cmllamas@google.com >
Acked-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp >
Cc: Peter Zijlstra <peterz@infradead.org >
Cc: Boqun Feng <boqun.feng@gmail.com >
Cc: Ingo Molnar <mingo@redhat.com >
Cc: Waiman Long <longman@redhat.com >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:32 -07:00
Thorsten Blum
b6e21b7120
lib: checksum: use ARRAY_SIZE() to improve assert_setup_correct()
...
Use ARRAY_SIZE() to simplify the assert_setup_correct() function and
improve its readability.
Link: https://lkml.kernel.org/r/20240726154946.230928-1-thorsten.blum@toblux.com
Signed-off-by: Thorsten Blum <thorsten.blum@toblux.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:30 -07:00
Deshan Zhang
9a42bfd255
lib/lru_cache: fix spelling mistake "colision"->"collision"
...
There is a spelling mistake in a literal string and in cariable names.
Fix these.
Link: https://lkml.kernel.org/r/20240725093044.1742842-1-deshan@nfschina.com
Signed-off-by: Deshan Zhang <deshan@nfschina.com >
Cc: Christoph Böhmwalder <christoph.boehmwalder@linbit.com >
Cc: Lars Ellenberg <lars.ellenberg@linbit.com >
Cc: Philipp Reisner <philipp.reisner@linbit.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:29 -07:00
Markus Elfring
fbe617af69
closures: use seq_putc() in debug_show()
...
A single line break should be put into a sequence. Thus use the
corresponding function "seq_putc".
This issue was transformed by using the Coccinelle software.
Link: https://lkml.kernel.org/r/e7faa2c4-9590-44b4-8669-69ef810277b1@web.de
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net >
Cc: Kent Overstreet <kent.overstreet@linux.dev >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:29 -07:00
Markus Elfring
7b76689a02
dyndbg: use seq_putc() in ddebug_proc_show()
...
Single characters should be put into a sequence. Thus use the
corresponding function "seq_putc".
This issue was transformed by using the Coccinelle software.
Link: https://lkml.kernel.org/r/375b5b4b-6295-419e-bae9-da724a7a682d@web.de
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net >
Cc: Jason Baron <jbaron@akamai.com >
Cc: Jim Cromie <jim.cromie@gmail.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:29 -07:00
Lasse Collin
c6f371bab2
xz: remove XZ_EXTERN and extern from functions
...
XZ_EXTERN was used to make internal functions static in the preboot code.
However, in other decompressors this hasn't been done. On x86-64, this
makes no difference to the kernel image size.
Omit XZ_EXTERN and let some of the internal functions be extern in the
preboot code. Omitting XZ_EXTERN from include/linux/xz.h fixes warnings
in "make htmldocs" and makes the intradocument links to xz_dec functions
work in Documentation/staging/xz.rst. The alternative would have been to
add "XZ_EXTERN" to c_id_attributes in Documentation/conf.py but omitting
XZ_EXTERN seemed cleaner.
Link: https://lore.kernel.org/lkml/20240723205437.3c0664b0@kaneli/
Link: https://lkml.kernel.org/r/20240724110544.16430-1-lasse.collin@tukaani.org
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Tested-by: Michael Ellerman <mpe@ellerman.id.au > (powerpc)
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Sam James <sam@gentoo.org >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:27 -07:00
Lasse Collin
7472ff8ada
xz: adjust arch-specific options for better kernel compression
...
Use LZMA2 options that match the arch-specific alignment of instructions.
This change reduces compressed kernel size 0-2 % depending on the arch.
On 1-byte-aligned x86 it makes no difference and on 4-byte-aligned archs
it helps the most.
Use the ARM-Thumb filter for ARM-Thumb2 kernels. This reduces compressed
kernel size about 5 %.[1] Previously such kernels were compressed using
the ARM filter which didn't do anything useful with ARM-Thumb2 code.
Add BCJ filter support for ARM64 and RISC-V. Compared to unfiltered XZ or
plain LZMA, the compressed kernel size is reduced about 5 % on ARM64 and 7
% on RISC-V. A new enough version of the xz tool is required: 5.4.0 for
ARM64 and 5.6.0 for RISC-V. With an old xz version, a message is printed
to standard error and the kernel is compressed without the filter.
Update lib/decompress_unxz.c to match the changes to xz_wrap.sh.
Update the CONFIG_KERNEL_XZ help text in init/Kconfig:
- Add the RISC-V and ARM64 filters.
- Clarify that the PowerPC filter is for big endian only.
- Omit IA-64.
Link: https://lore.kernel.org/lkml/1637379771-39449-1-git-send-email-zhongjubin@huawei.com/ [1]
Link: https://lkml.kernel.org/r/20240721133633.47721-15-lasse.collin@tukaani.org
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Reviewed-by: Sam James <sam@gentoo.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Will Deacon <will@kernel.org >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Michael Ellerman <mpe@ellerman.id.au >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:27 -07:00
Lasse Collin
93d09773d1
xz: add RISC-V BCJ filter
...
A later commit updates lib/decompress_unxz.c to enable this filter for
kernel decompression. lib/decompress_unxz.c is already used if
CONFIG_EFI_ZBOOT=y && CONFIG_KERNEL_XZ=y.
This filter can be used by Squashfs without modifications to the Squashfs
kernel code (only needs support in userspace Squashfs-tools).
Link: https://lkml.kernel.org/r/20240721133633.47721-13-lasse.collin@tukaani.org
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Reviewed-by: Sam James <sam@gentoo.org >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Michael Ellerman <mpe@ellerman.id.au >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:26 -07:00
Lasse Collin
4b62813f5e
xz: Add ARM64 BCJ filter
...
Also omit a duplicated check for XZ_DEC_ARM in xz_private.h.
A later commit updates lib/decompress_unxz.c to enable this filter for
kernel decompression. lib/decompress_unxz.c is already used if
CONFIG_EFI_ZBOOT=y && CONFIG_KERNEL_XZ=y.
This filter can be used by Squashfs without modifications to the Squashfs
kernel code (only needs support in userspace Squashfs-tools).
Link: https://lkml.kernel.org/r/20240721133633.47721-12-lasse.collin@tukaani.org
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Reviewed-by: Sam James <sam@gentoo.org >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Michael Ellerman <mpe@ellerman.id.au >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:26 -07:00
Lasse Collin
bdfc041171
xz: optimize for-loop conditions in the BCJ decoders
...
Compilers cannot optimize the addition "i + 4" away since theoretically it
could overflow.
Link: https://lkml.kernel.org/r/20240721133633.47721-11-lasse.collin@tukaani.org
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Reviewed-by: Sam James <sam@gentoo.org >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Michael Ellerman <mpe@ellerman.id.au >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:26 -07:00
Lasse Collin
2ee96abef2
xz: cleanup CRC32 edits from 2018
...
In 2018, a dependency on <linux/crc32poly.h> was added to avoid
duplicating the same constant in multiple files. Two months later it was
found to be a bad idea and the definition of CRC32_POLY_LE macro was moved
into xz_private.h to avoid including <linux/crc32poly.h>.
xz_private.h is a wrong place for it too. Revert back to the upstream
version which has the poly in xz_crc32_init() in xz_crc32.c.
Link: https://lkml.kernel.org/r/20240721133633.47721-10-lasse.collin@tukaani.org
Fixes: faa16bc404 ("lib: Use existing define with polynomial")
Fixes: 242cdad873 ("lib/xz: Put CRC32_POLY_LE in xz_private.h")
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Reviewed-by: Sam James <sam@gentoo.org >
Tested-by: Michael Ellerman <mpe@ellerman.id.au > (powerpc)
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:25 -07:00
Lasse Collin
ff221153aa
xz: fix comments and coding style
...
- Fix comments that were no longer in sync with the code below them.
- Fix language errors.
- Fix coding style.
Link: https://lkml.kernel.org/r/20240721133633.47721-5-lasse.collin@tukaani.org
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Reviewed-by: Sam James <sam@gentoo.org >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Michael Ellerman <mpe@ellerman.id.au >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:24 -07:00
Lasse Collin
836d13a6ef
xz: switch from public domain to BSD Zero Clause License (0BSD)
...
Remove the public domain notices and add SPDX license identifiers.
Change MODULE_LICENSE from "GPL" to "Dual BSD/GPL" because 0BSD should
count as a BSD license variant here.
The switch to 0BSD was done in the upstream XZ Embedded project because
public domain has (real or perceived) legal issues in some jurisdictions.
Link: https://lkml.kernel.org/r/20240721133633.47721-4-lasse.collin@tukaani.org
Signed-off-by: Lasse Collin <lasse.collin@tukaani.org >
Reviewed-by: Sam James <sam@gentoo.org >
Cc: Thomas Gleixner <tglx@linutronix.de >
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
Cc: Albert Ou <aou@eecs.berkeley.edu >
Cc: Catalin Marinas <catalin.marinas@arm.com >
Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com >
Cc: Herbert Xu <herbert@gondor.apana.org.au >
Cc: Joel Stanley <joel@jms.id.au >
Cc: Jonathan Corbet <corbet@lwn.net >
Cc: Jubin Zhong <zhongjubin@huawei.com >
Cc: Jules Maselbas <jmaselbas@zdiv.net >
Cc: Krzysztof Kozlowski <krzk@kernel.org >
Cc: Michael Ellerman <mpe@ellerman.id.au >
Cc: Palmer Dabbelt <palmer@dabbelt.com >
Cc: Paul Walmsley <paul.walmsley@sifive.com >
Cc: Randy Dunlap <rdunlap@infradead.org >
Cc: Rui Li <me@lirui.org >
Cc: Simon Glass <sjg@chromium.org >
Cc: Will Deacon <will@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:24 -07:00
Andrey Konovalov
e24f4de8a7
kcov: don't instrument lib/find_bit.c
...
This file produces large amounts of flaky coverage not useful for the
KCOV's intended use case (guiding the fuzzing process).
Link: https://lkml.kernel.org/r/20240722223726.194658-1-andrey.konovalov@linux.dev
Signed-off-by: Andrey Konovalov <andreyknvl@gmail.com >
Reviewed-by: Dmitry Vyukov <dvyukov@google.com >
Cc: Aleksandr Nogikh <nogikh@google.com >
Cc: Alexander Potapenko <glider@google.com >
Cc: Marco Elver <elver@google.com >
Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk >
Cc: Yury Norov <yury.norov@gmail.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:23 -07:00
Jeff Johnson
053a5e4cbb
lib: test_objpool: add missing MODULE_DESCRIPTION() macro
...
make allmodconfig && make W=1 C=1 reports:
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_objpool.o
Add the missing invocation of the MODULE_DESCRIPTION() macro.
Link: https://lkml.kernel.org/r/20240715-md-lib-test_objpool-v2-1-5a2b9369c37e@quicinc.com
Signed-off-by: Jeff Johnson <quic_jjohnson@quicinc.com >
Reviewed-by: Matt Wu <wuqiang.matt@bytedance.com >
Cc: Masami Hiramatsu <mhiramat@kernel.org >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:23 -07:00
Nicolas Pitre
1635e62e75
mul_u64_u64_div_u64: basic sanity test
...
Verify that edge cases produce proper results, and some more.
[npitre@baylibre.com: avoid undefined shift value]
Link: https://lkml.kernel.org/r/7rrs9pn1-n266-3013-9q6n-1osp8r8s0rrn@syhkavp.arg
Link: https://lkml.kernel.org/r/20240707190648.1982714-3-nico@fluxnic.net
Signed-off-by: Nicolas Pitre <npitre@baylibre.com >
Reviewed-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com >
Cc: Biju Das <biju.das.jz@bp.renesas.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:22 -07:00
Nicolas Pitre
b29a62d87c
mul_u64_u64_div_u64: make it precise always
...
Patch series "mul_u64_u64_div_u64: new implementation", v3.
This provides an implementation for mul_u64_u64_div_u64() that always
produces exact results.
This patch (of 2):
Library facilities must always return exact results. If the caller may be
contented with approximations then it should do the approximation on its
own.
In this particular case the comment in the code says "the algorithm
... below might lose some precision". Well, if you try it with e.g.:
a = 18446462598732840960
b = 18446462598732840960
c = 18446462598732840961
then the produced answer is 0 whereas the exact answer should be
18446462598732840959. This is _some_ precision lost indeed!
Let's reimplement this function so it always produces the exact result
regardless of its inputs while preserving existing fast paths when
possible.
Uwe said:
: My personal interest is to get the calculations in pwm drivers right.
: This function is used in several drivers below drivers/pwm/ . With the
: errors in mul_u64_u64_div_u64(), pwm consumers might not get the
: settings they request. Although I have to admit that I'm not aware it
: breaks real use cases (because typically the periods used are too short
: to make the involved multiplications overflow), but I pretty sure am
: not aware of all usages and it breaks testing.
:
: Another justification is commits like
: https://git.kernel.org/tip/77baa5bafcbe1b2a15ef9c37232c21279c95481c ,
: where people start to work around the precision shortcomings of
: mul_u64_u64_div_u64().
Link: https://lkml.kernel.org/r/20240707190648.1982714-1-nico@fluxnic.net
Link: https://lkml.kernel.org/r/20240707190648.1982714-2-nico@fluxnic.net
Signed-off-by: Nicolas Pitre <npitre@baylibre.com >
Tested-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com >
Reviewed-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com >
Tested-by: Biju Das <biju.das.jz@bp.renesas.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:43:22 -07:00
Sidhartha Kumar
ed4dfd9aa1
maple_tree: make write helper functions void
...
The return value of various write helper functions are not checked. We
can safely change the return type of these functions to be void.
Link: https://lkml.kernel.org/r/20240814161944.55347-18-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:18 -07:00
Sidhartha Kumar
c27e6183c6
maple_tree: remove unneeded mas_wr_walk() in mas_store_prealloc()
...
Users of mas_store_prealloc() enter this function with nodes already
preallocated. This means the store type must be already set. We can then
remove the call to mas_wr_store_type() and initialize the write state to
continue the partial walk that was done when determining the store type.
Link: https://lkml.kernel.org/r/20240814161944.55347-17-sidhartha.kumar@oracle.com
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:18 -07:00
Sidhartha Kumar
add60ea5f6
maple_tree: remove repeated sanity checks from write helper functions
...
These sanity checks are now redundant as they are already checked in
mas_wr_store_type(). We can remove them from mas_wr_append() and
mas_wr_node_store().
Link: https://lkml.kernel.org/r/20240814161944.55347-16-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:17 -07:00
Sidhartha Kumar
9155e84334
maple_tree: remove node allocations from various write helper functions
...
These write helper functions are all called from store paths which
preallocate enough nodes that will be needed for the write. There is no
more need to allocate within the functions themselves.
Link: https://lkml.kernel.org/r/20240814161944.55347-15-sidhartha.kumar@oracle.com
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:17 -07:00
Sidhartha Kumar
4037d44f54
maple_tree: have mas_store() allocate nodes if needed
...
Not all users of mas_store() enter with nodes already preallocated.
Check for the MA_STATE_PREALLOC flag to decide whether to preallocate nodes
within mas_store() rather than relying on future write helper functions
to perform the allocations. This allows the write helper functions to be
simplified as they do not have to do checks to make sure there are
enough allocated nodes to perform the write.
Link: https://lkml.kernel.org/r/20240814161944.55347-14-sidhartha.kumar@oracle.com
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:17 -07:00
Sidhartha Kumar
7987d02779
maple_tree: remove mas_wr_modify()
...
There are no more users of the function, safely remove it.
Link: https://lkml.kernel.org/r/20240814161944.55347-13-sidhartha.kumar@oracle.com
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:17 -07:00
Sidhartha Kumar
62c7b2b984
maple_tree: simplify mas_commit_b_node()
...
The only callers of mas_commit_b_node() are those with store type of
wr_rebalance and wr_split_store. Use mas->store_type to dispatch to the
correct helper function. This allows the removal of mas_reuse_node() as
it is no longer used.
Link: https://lkml.kernel.org/r/20240814161944.55347-12-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:16 -07:00
Sidhartha Kumar
1fd7c4f322
maple_tree: convert mas_insert() to preallocate nodes
...
By setting the store type in mas_insert(), we no longer need to use
mas_wr_modify() to determine the correct store function to use. Instead,
set the store type and call mas_wr_store_entry(). Also, pass in the
requested gfp flags to mas_insert() so they can be passed to the call to
mas_wr_preallocate().
Link: https://lkml.kernel.org/r/20240814161944.55347-11-sidhartha.kumar@oracle.com
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:16 -07:00
Sidhartha Kumar
580fcbd67c
maple_tree: use store type in mas_wr_store_entry()
...
When storing an entry, we can read the store type that was set from a
previous partial walk of the tree. Now that the type of store is known,
select the correct write helper function to use to complete the store.
Also noinline mas_wr_spanning_store() to limit stack frame usage in
mas_wr_store_entry() as it allocates a maple_big_node on the stack.
Link: https://lkml.kernel.org/r/20240814161944.55347-10-sidhartha.kumar@oracle.com
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:16 -07:00
Sidhartha Kumar
23e217a848
maple_tree: print store type in mas_dump()
...
Knowing the store type of the maple state could be helpful for debugging.
Have mas_dump() print mas->store_type.
Link: https://lkml.kernel.org/r/20240814161944.55347-9-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:16 -07:00
Sidhartha Kumar
85db8f2417
maple_tree: use mas_store_gfp() in mtree_store_range()
...
Refactor mtree_store_range() to use mas_store_gfp() which will abstract
the store, memory allocation, and error handling.
Link: https://lkml.kernel.org/r/20240814161944.55347-8-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:15 -07:00
Sidhartha Kumar
7e093834ed
maple_tree: preallocate nodes in mas_erase()
...
Use mas_wr_preallocate() in mas_erase() to preallocate enough nodes to
complete the erase. Add error handling by skipping the store if the
preallocation lead to some error besides no memory.
Link: https://lkml.kernel.org/r/20240814161944.55347-7-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Cc: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:15 -07:00
Sidhartha Kumar
3cd9e92e00
maple_tree: remove mas_destroy() from mas_nomem()
...
Separate call to mas_destroy() from mas_nomem() so we can check for no
memory errors without destroying the current maple state in
mas_store_gfp(). We then add calls to mas_destroy() to callers of
mas_nomem().
Link: https://lkml.kernel.org/r/20240814161944.55347-6-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com >
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com >
Cc: Matthew Wilcox (Oracle) <willy@infradead.org >
Cc: Suren Baghdasaryan <surenb@google.com >
Signed-off-by: Andrew Morton <akpm@linux-foundation.org >
2024-09-01 20:26:15 -07:00