Re: [tip: x86/urgent] x86/tdx: Prepare for using "INFO" call for a second purpose
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- Subject: Re: [tip: x86/urgent] x86/tdx: Prepare for using "INFO" call for a second purpose
- From: Dave Hansen <dave.hansen@xxxxxxxxx>
- Date: Sun, 6 Nov 2022 09:02:27 -0800
- Cc: linux-kernel@xxxxxxxxxxxxxxx, linux-tip-commits@xxxxxxxxxxxxxxx, "Kirill A. Shutemov" <kirill.shutemov@xxxxxxxxxxxxxxx>, x86@xxxxxxxxxx
- In-reply-to: <Y2esXPWwulendusf@zn.tnic>
- References: <166734513630.7716.12952231613533508782.tip-bot2@tip-bot2> <Y2esXPWwulendusf@zn.tnic>
- User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.2
On 11/6/22 04:45, Borislav Petkov wrote:
> On Tue, Nov 01, 2022 at 11:25:36PM -0000, tip-bot2 for Dave Hansen wrote:
>> @@ -121,7 +121,7 @@ static u64 get_cc_mask(void)
>> * The highest bit of a guest physical address is the "sharing" bit.
>> * Set it for shared pages and clear it for private pages.
>> */
>> - return BIT_ULL(gpa_width - 1);
>> + *cc_mask = BIT_ULL(gpa_width - 1);
>> }
> I'm looking at the next patch too and I still don't see what the point
> is of making it a void?
>
> IOW, what's wrong with doing this?
It's fine for now, except that the naming on this:
- tdx_parse_tdinfo(&cc_mask);
+ cc_mask = tdx_parse_tdinfo();
is a bit funky since tdx_parse_tdinfo() is doing a couple of things and
will need to return a second item shortly.
But, zero objections if you want to make it that way for now.
[Index of Archives]
[Linux Stable Commits]
[Linux Stable Kernel]
[Linux Kernel]
[Linux USB Devel]
[Linux Video &Media]
[Linux Audio Users]
[Yosemite News]
[Linux SCSI]