Commit 8234177
virt: sev-guest: Remove is_vmpck_empty() helper
Remove is_vmpck_empty() which uses a local array allocation to check if the
VMPCK is empty and replace it with memchr_inv() to directly determine if the
VMPCK is empty without additional memory allocation.
[ bp: Massage commit message. ]
Suggested-by: Borislav Petkov <bp@alien8.de>
Signed-off-by: Nikunj A Dadhania <nikunj@amd.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Link: https://lore.kernel.org/r/20250106124633.1418972-2-nikunj@amd.com1 parent 21fc617 commit 8234177
1 file changed
+2
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | 66 | | |
77 | 67 | | |
78 | 68 | | |
| |||
335 | 325 | | |
336 | 326 | | |
337 | 327 | | |
338 | | - | |
| 328 | + | |
339 | 329 | | |
340 | 330 | | |
341 | 331 | | |
| |||
1024 | 1014 | | |
1025 | 1015 | | |
1026 | 1016 | | |
1027 | | - | |
| 1017 | + | |
1028 | 1018 | | |
1029 | 1019 | | |
1030 | 1020 | | |
| |||
0 commit comments