Skip to content

Commit 740afa4

Browse files
committed
Merge tag 'x86_sev_for_v6.2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 sev updates from Borislav Petkov: - Two minor fixes to the sev-guest driver * tag 'x86_sev_for_v6.2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: virt/sev-guest: Add a MODULE_ALIAS virt/sev-guest: Remove unnecessary free in init_crypto()
2 parents 82c7290 + 2874529 commit 740afa4

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

drivers/virt/coco/sev-guest/sev-guest.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -171,12 +171,10 @@ static struct snp_guest_crypto *init_crypto(struct snp_guest_dev *snp_dev, u8 *k
171171
crypto->a_len = crypto_aead_authsize(crypto->tfm);
172172
crypto->authtag = kmalloc(crypto->a_len, GFP_KERNEL_ACCOUNT);
173173
if (!crypto->authtag)
174-
goto e_free_auth;
174+
goto e_free_iv;
175175

176176
return crypto;
177177

178-
e_free_auth:
179-
kfree(crypto->authtag);
180178
e_free_iv:
181179
kfree(crypto->iv);
182180
e_free_crypto:
@@ -800,3 +798,4 @@ MODULE_AUTHOR("Brijesh Singh <[email protected]>");
800798
MODULE_LICENSE("GPL");
801799
MODULE_VERSION("1.0.0");
802800
MODULE_DESCRIPTION("AMD SEV Guest Driver");
801+
MODULE_ALIAS("platform:sev-guest");

0 commit comments

Comments
 (0)