On 02.04.2020 12:19, Andrew Cooper wrote:
> With the newly cleaned up vendor logic, each struct microcode_patch is a
> trivial object in memory with no dependent allocations.
> 
> This is unlikely to change moving forwards, and function pointers are
> expensive in the days of retpoline.  Move the responsibility to xfree() back
> to common code.  If the need does arise in the future, we can consider
> reintroducing the hook.
> 
> Signed-off-by: Andrew Cooper <andrew.coop...@citrix.com>

Reviewed-by: Jan Beulich <jbeul...@suse.com>

Yet with the given argumentation, ...

> --- a/xen/arch/x86/cpu/microcode/core.c
> +++ b/xen/arch/x86/cpu/microcode/core.c
> @@ -243,9 +243,9 @@ static struct microcode_patch *parse_blob(const char 
> *buf, size_t len)
>      return NULL;
>  }
>  
> -static void microcode_free_patch(struct microcode_patch *microcode_patch)
> +static void microcode_free_patch(struct microcode_patch *patch)
>  {
> -    microcode_ops->free_patch(microcode_patch);
> +    xfree(patch);
>  }

... drop this wrapper as well? (R-b would also cover this)

Jan

Reply via email to