lkml.org 
[lkml]   [2023]   [Nov]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v5 05/14] virt: sev-guest: Add vmpck_id to snp_guest_dev struct
From
On 10/30/2023 10:42 PM, Tom Lendacky wrote:
> On 10/30/23 11:16, Dionna Amalie Glaze wrote:
>> On Sun, Oct 29, 2023 at 11:38 PM Nikunj A Dadhania <nikunj@amd.com> wrote:

>>> @@ -656,32 +674,14 @@ static const struct file_operations snp_guest_fops = {
>>>          .unlocked_ioctl = snp_guest_ioctl,
>>>   };
>>>
>>> -static u8 *get_vmpck(int id, struct snp_secrets_page_layout *layout, u32 **seqno)
>>> +bool snp_assign_vmpck(struct snp_guest_dev *dev, int vmpck_id)
>>>   {
>>> -       u8 *key = NULL;
>>> +       if (WARN_ON(vmpck_id > 3))
>>> +               return false;
>>
>> The vmpck_id is an int for some reason, so < 0 is also a problem. Can
>> we not use unsigned int?

Yes, I will update that in my next revision,

Thanks
Nikunj

\
 
 \ /
  Last update: 2023-11-02 05:06    [W:0.079 / U:1.392 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site