diff options
author | Asahi Lina <lina@asahilina.net> | 2024-11-23 11:29:38 +0100 |
---|---|---|
committer | Miguel Ojeda <ojeda@kernel.org> | 2024-11-25 00:11:07 +0100 |
commit | b7ed2b6f4e8d7f64649795e76ee9db67300de8eb (patch) | |
tree | 6c52dd614e82d4577d777576a18f87d8d2751196 /samples/uhid | |
parent | docs: rust: remove spurious item in `expect` list (diff) | |
download | linux-b7ed2b6f4e8d7f64649795e76ee9db67300de8eb.tar.xz linux-b7ed2b6f4e8d7f64649795e76ee9db67300de8eb.zip |
rust: alloc: Fix `ArrayLayout` allocations
We were accidentally allocating a layout for the *square* of the object
size due to a variable shadowing mishap.
Fixes memory bloat and page allocation failures in drm/asahi.
Reported-by: Janne Grunau <j@jannau.net>
Fixes: 9e7bbfa18276 ("rust: alloc: introduce `ArrayLayout`")
Signed-off-by: Asahi Lina <lina@asahilina.net>
Acked-by: Danilo Krummrich <dakr@kernel.org>
Reviewed-by: Neal Gompa <neal@gompa.dev>
Link: https://lore.kernel.org/r/20241123-rust-fix-arraylayout-v1-1-197e64c95bd4@asahilina.net
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
Diffstat (limited to 'samples/uhid')
0 files changed, 0 insertions, 0 deletions