Re: [RFC PATCH v4 28/28] x86: Add support to make use of Secure Memory Encryption

Borislav Petkov
2017-03-07T18:14:30Z

On Tue, Mar 07, 2017 at 10:05:00AM -0600, Tom Lendacky wrote:
> I can do that. Because phys_base hasn't been updated yet, I'll have to
> create "on" and "off" constants and get their address in a similar way
> to the command line option so that I can do the strncmp properly.

Actually, wouldn't it be simpler to inspect the passed in buffer for
containing the chars 'o', 'n' - in that order, or 'o', 'f', 'f' - in
that order too? Because __cmdline_find_option() does copy the option
characters into the buffer.

Then you wouldn't need those "on" and "off" constants...

--
Regards/Gruss,
Boris.

Good mailing practices for 400: avoid top-posting and trim the reply.