qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v3] s390x: remove direct reference to mem_path g


From: Cornelia Huck
Subject: Re: [Qemu-devel] [PATCH v3] s390x: remove direct reference to mem_path global form s390x code
Date: Tue, 29 Jan 2019 13:39:31 +0100

On Mon, 28 Jan 2019 16:32:38 +0100
Igor Mammedov <address@hidden> wrote:

In the subject: s/form/from/

> I plan to deprecate -mem-path option and replace it with memory-backend,
> for that it's necessary to get rid of mem_path global variable.
> Do it for s390x case, replacing it with alternative way to enable
> 1Mb hugepages capability.
> 
> To do that, replace qemu_mempath_getpagesize() with qemu_getrampagesize()
> which also checks for -mem-path provided RAM.
> 
> Signed-off-by: Igor Mammedov <address@hidden>
> Reviewed-by: David Hildenbrand <address@hidden>
> ---
> v3:
>   fixup, typo in commit msg (Philippe Mathieu-Daudé <address@hidden>)
> v2:
>   * s/qemu_mempath_getpagesize/qemu_getrampagesiz/ and drop the rest of 
> changes
>           David Hildenbrand <address@hidden>
> ---
>  target/s390x/kvm.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c
> index 2ebf26a..90766fa 100644
> --- a/target/s390x/kvm.c
> +++ b/target/s390x/kvm.c
> @@ -287,7 +287,7 @@ void kvm_s390_crypto_reset(void)
>  
>  static int kvm_s390_configure_mempath_backing(KVMState *s)
>  {
> -    size_t path_psize = qemu_mempath_getpagesize(mem_path);
> +    size_t path_psize = qemu_getrampagesize();
>  
>      if (path_psize == 4 * KiB) {
>          return 0;
> @@ -319,7 +319,7 @@ int kvm_arch_init(MachineState *ms, KVMState *s)
>  {
>      MachineClass *mc = MACHINE_GET_CLASS(ms);
>  
> -    if (mem_path && kvm_s390_configure_mempath_backing(s)) {
> +    if (kvm_s390_configure_mempath_backing(s)) {
>          return -EINVAL;
>      }
>  

This needs an #include "exec/ram_addr.h", or the compilation fails.

Should I fix it up while applying, or will you resend?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]