Angelo G. Del Regno
24b59982a7
treewide: Backport new vmalloc for large performance benefits
...
This is a backport from Linux 5.2-rc1 of a patch series to greatly enhance vmalloc's performance
especially on embedded systems, plus all of its dependencies that were missing in kernel 4.9.
For all the informations, refer to LKML: https://lkml.org/lkml/2018/10/19/786
Brief informations:
Currently an allocation of the new VA area is done over busy list iteration until a suitable hole
is found between two busy areas. Therefore each new allocation causes the list being grown.
Due to long list and different permissive parameters an allocation can take a long time on
embedded devices(milliseconds).
This patch organizes the vmalloc memory layout into free areas of the VMALLOC_START-VMALLOC_END range.
It uses a red-black tree that keeps blocks sorted by their offsets in pair with linked list
keeping the free space in order of increasing addresses.
Quote Phoronix:
With this patch from Uladzislau Rezki, calling vmalloc() can take up to 67% less time compared
to the behavior on Linux 5.1 and prior, at least with tests done by the developer under QEMU.
Personal tests are showing that the device is more responsive when memory pressure is
high and when huge allocations are to be done, it's also noticeably faster in this case, like
when starting Chrome with more than 100 opened tabs after a system reboot (so, an
uncached complete load of it).
Shameless kanged from:
https://github.com/sonyxperiadev/kernel / Pull Request 2016
Signed-off-by: sweetyicecare <gabrielseedev@outlook.com>
Signed-off-by: Aoihara <veronicadisa6@gmail.com>
Signed-off-by: KangMamles <imzea69@gmail.com>
Signed-off-by: Sorayukii <sorayukii69@gmail.com>
2026-05-15 17:48:25 +07:00
..
bcache
Merge branch 'android-4.9-q' of https://android.googlesource.com/kernel/common into lineage-17.1-caf-sdm845
2021-01-17 05:04:08 +02:00
persistent-data
dm space map common: add bounds check to sm_ll_lookup_bitmap()
2022-01-27 08:47:38 +01:00
bitmap.c
md/bitmap: md_bitmap_get_counter returns wrong blocks
2020-11-10 10:23:54 +01:00
bitmap.h
dm-android-verity.c
ANDROID: android-verity: Prevent double-freeing metadata
2022-06-07 16:40:32 +00:00
dm-android-verity.h
dm-bio-prison.c
dm: Use kzalloc for all structs with embedded biosets/mempools
2019-11-06 12:18:01 +01:00
dm-bio-prison.h
dm-bio-record.h
dm-bow.c
ANDROID: dm-bow: Protect Ranges fetched and erased from the RB tree
2025-02-14 15:30:53 +02:00
dm-bufio.c
treewide: Backport new vmalloc for large performance benefits
2026-05-15 17:48:25 +07:00
dm-bufio.h
dm-builtin.c
dm-cache-block-types.h
dm-cache-metadata.c
dm cache: Fix ABBA deadlock between shrink_slab and dm_cache_metadata_abort
2023-01-07 12:07:36 +01:00
dm-cache-metadata.h
dm-cache-policy-cleaner.c
dm-cache-policy-internal.h
dm-cache-policy-smq.c
dm-cache-policy.c
dm-cache-policy.h
dm-cache-target.c
Merge branch 'android-4.9-q' of https://android.googlesource.com/kernel/common into lineage-20
2023-01-19 15:42:12 +01:00
dm-core.h
dm-crypt.c
Merge remote-tracking branch 'common/android-4.9-q' into android12-4.9-sdm845
2022-06-12 01:39:01 +03:00
dm-default-key.c
dm-default-key: fix wrong encryption/decryption when f2fs moves blocks
2018-10-16 16:16:53 +05:30
dm-delay.c
dm delay: fix a crash when invalid device is specified
2019-05-25 18:26:54 +02:00
dm-era-target.c
Merge remote-tracking branch 'common/android-4.9-q' into android12-4.9-sdm845
2022-07-18 14:05:31 +03:00
dm-exception-store.c
dm-exception-store.h
dm-flakey.c
dm flakey: check for null arg_name in parse_features()
2020-04-24 07:59:05 +02:00
dm-io.c
dm: Use kzalloc for all structs with embedded biosets/mempools
2019-11-06 12:18:01 +01:00
dm-ioctl.c
This is the 4.9.334 stable release
2022-11-28 15:45:23 +00:00
dm-kcopyd.c
dm: Use kzalloc for all structs with embedded biosets/mempools
2019-11-06 12:18:01 +01:00
dm-linear.c
dm-log-userspace-base.c
dm-log-userspace-transfer.c
dm-log-userspace-transfer.h
dm-log-writes.c
dm-log.c
dm-mpath.c
dm-mpath.h
dm-path-selector.c
dm-path-selector.h
dm-queue-length.c
dm-raid.c
dm raid: fix address sanitizer warning in raid_status
2022-08-25 11:09:26 +02:00
dm-raid1.c
dm-region-hash.c
dm: Use kzalloc for all structs with embedded biosets/mempools
2019-11-06 12:18:01 +01:00
dm-req-crypt.c
drivers: md: Remove SECTOR_SIZE definition
2021-01-17 05:13:26 +02:00
dm-round-robin.c
dm-rq.c
Merge branch 'android-4.9-q' of https://android.googlesource.com/kernel/common into lineage-18.1-caf-sdm845
2021-05-26 19:04:48 +03:00
dm-rq.h
dm-service-time.c
dm-snap-persistent.c
block: fix an integer overflow in logical block size
2020-01-23 08:19:38 +01:00
dm-snap-transient.c
dm-snap.c
dm snapshot: properly fix a crash when an origin has no snapshots
2021-06-03 08:23:29 +02:00
dm-stats.c
treewide: Backport new vmalloc for large performance benefits
2026-05-15 17:48:25 +07:00
dm-stats.h
dm-stripe.c
dm-switch.c
dm-sysfs.c
dm-table.c
FROMGIT: dm: do not allow readahead to limit IO size
2022-11-30 02:22:44 +02:00
dm-target.c
dm-thin-metadata.c
dm thin: Use last transaction's pmd->root when commit failed
2023-01-07 12:07:36 +01:00
dm-thin-metadata.h
dm thin: fix passdown_double_checking_shared_status()
2019-01-31 08:12:36 +01:00
dm-thin.c
Merge branch 'android-4.9-q' of https://android.googlesource.com/kernel/common into lineage-20
2023-01-19 15:42:12 +01:00
dm-uevent.c
dm-uevent.h
dm-verity-avb.c
ANDROID: AVB error handler to invalidate vbmeta partition.
2018-08-10 17:41:36 +00:00
dm-verity-fec.c
dm verity: switch to using asynchronous hash crypto API
2022-11-30 02:21:57 +02:00
dm-verity-fec.h
dm-verity-target.c
FROMLIST: dm-verity: skip verity_handle_error on I/O errors
2022-11-30 02:22:36 +02:00
dm-verity.h
dm verity: switch to using asynchronous hash crypto API
2022-11-30 02:21:57 +02:00
dm-zero.c
dm.c
Merge remote-tracking branch 'common/android-4.9-q' into android12-4.9-sdm845
2022-06-12 01:39:01 +03:00
dm.h
faulty.c
Kconfig
Merge android-4.9.166 ( 0166b9e) into msm-4.9
2019-05-23 14:26:39 +08:00
linear.c
linear.h
Makefile
Merge android-4.9.166 ( 0166b9e) into msm-4.9
2019-05-23 14:26:39 +08:00
md-cluster.c
md-cluster: fix wild pointer of unlock_all_bitmaps()
2020-08-21 11:01:58 +02:00
md-cluster.h
md.c
Merge branch 'android-4.9-q' of https://android.googlesource.com/kernel/common into lineage-20
2023-01-19 15:42:12 +01:00
md.h
multipath.c
multipath.h
raid0.c
Merge android-4.9.211(5af9b7f) into msm-4.9
2020-03-13 15:56:44 +08:00
raid0.h
raid1.c
Merge branch 'android-4.9-q' of https://android.googlesource.com/kernel/common into lineage-20
2023-01-19 15:42:12 +01:00
raid1.h
raid5-cache.c
raid5.c
Merge remote-tracking branch 'common/android-4.9-q' into android12-4.9-sdm845
2022-09-06 06:20:26 +03:00
raid5.h
raid10.c
Merge remote-tracking branch 'common/android-4.9-q' into android12-4.9-sdm845
2022-09-06 06:20:26 +03:00
raid10.h