kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 1/2] selftests: kvm: Adding config fragments
@ 2019-08-09  7:24 Naresh Kamboju
  2019-08-09  7:24 ` [PATCH v3 2/2] selftests: kvm: x86_64: " Naresh Kamboju
  2019-08-09  7:39 ` [PATCH v3 1/2] selftests: kvm: " Paolo Bonzini
  0 siblings, 2 replies; 6+ messages in thread
From: Naresh Kamboju @ 2019-08-09  7:24 UTC (permalink / raw)
  To: naresh.kamboju, pbonzini, shuah
  Cc: linux-kernel, drjones, sean.j.christopherson, linux-kselftest, kvm

selftests kvm all test cases need pre-required kernel config for the
tests to get pass.

CONFIG_KVM=y

The KVM tests are skipped without these configs:

        dev_fd = open(KVM_DEV_PATH, O_RDONLY);
        if (dev_fd < 0)
                exit(KSFT_SKIP);

Signed-off-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Acked-by: Shuah Khan <skhan@linuxfoundation.org>
---
 tools/testing/selftests/kvm/config | 1 +
 1 file changed, 1 insertion(+)
 create mode 100644 tools/testing/selftests/kvm/config

diff --git a/tools/testing/selftests/kvm/config b/tools/testing/selftests/kvm/config
new file mode 100644
index 000000000000..14f90d8d6801
--- /dev/null
+++ b/tools/testing/selftests/kvm/config
@@ -0,0 +1 @@
+CONFIG_KVM=y
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH v3 2/2] selftests: kvm: x86_64: Adding config fragments
  2019-08-09  7:24 [PATCH v3 1/2] selftests: kvm: Adding config fragments Naresh Kamboju
@ 2019-08-09  7:24 ` Naresh Kamboju
  2019-08-09  7:39 ` [PATCH v3 1/2] selftests: kvm: " Paolo Bonzini
  1 sibling, 0 replies; 6+ messages in thread
From: Naresh Kamboju @ 2019-08-09  7:24 UTC (permalink / raw)
  To: naresh.kamboju, pbonzini, shuah
  Cc: linux-kernel, drjones, sean.j.christopherson, linux-kselftest, kvm

selftests kvm x86_64 test cases need pre-required kernel configs for the
tests to get pass when you are using Intel or AMD CPU.

CONFIG_KVM_INTEL=y
CONFIG_KVM_AMD=y

Signed-off-by: Naresh Kamboju <naresh.kamboju@linaro.org>
---
 tools/testing/selftests/kvm/x86_64/config | 2 ++
 1 file changed, 2 insertions(+)
 create mode 100644 tools/testing/selftests/kvm/x86_64/config

diff --git a/tools/testing/selftests/kvm/x86_64/config b/tools/testing/selftests/kvm/x86_64/config
new file mode 100644
index 000000000000..4df8c7f54885
--- /dev/null
+++ b/tools/testing/selftests/kvm/x86_64/config
@@ -0,0 +1,2 @@
+CONFIG_KVM_INTEL=y
+CONFIG_KVM_AMD=y
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v3 1/2] selftests: kvm: Adding config fragments
  2019-08-09  7:24 [PATCH v3 1/2] selftests: kvm: Adding config fragments Naresh Kamboju
  2019-08-09  7:24 ` [PATCH v3 2/2] selftests: kvm: x86_64: " Naresh Kamboju
@ 2019-08-09  7:39 ` Paolo Bonzini
  2019-08-09  7:53   ` Naresh Kamboju
  1 sibling, 1 reply; 6+ messages in thread
From: Paolo Bonzini @ 2019-08-09  7:39 UTC (permalink / raw)
  To: Naresh Kamboju, shuah
  Cc: linux-kernel, drjones, sean.j.christopherson, linux-kselftest, kvm

On 09/08/19 09:24, Naresh Kamboju wrote:
> selftests kvm all test cases need pre-required kernel config for the
> tests to get pass.
> 
> CONFIG_KVM=y
> 
> The KVM tests are skipped without these configs:
> 
>         dev_fd = open(KVM_DEV_PATH, O_RDONLY);
>         if (dev_fd < 0)
>                 exit(KSFT_SKIP);
> 
> Signed-off-by: Naresh Kamboju <naresh.kamboju@linaro.org>
> Acked-by: Shuah Khan <skhan@linuxfoundation.org>
> ---
>  tools/testing/selftests/kvm/config | 1 +
>  1 file changed, 1 insertion(+)
>  create mode 100644 tools/testing/selftests/kvm/config
> 
> diff --git a/tools/testing/selftests/kvm/config b/tools/testing/selftests/kvm/config
> new file mode 100644
> index 000000000000..14f90d8d6801
> --- /dev/null
> +++ b/tools/testing/selftests/kvm/config
> @@ -0,0 +1 @@
> +CONFIG_KVM=y
> 

I think this is more complicated without a real benefit, so I'll merge v2.

Paolo

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3 1/2] selftests: kvm: Adding config fragments
  2019-08-09  7:39 ` [PATCH v3 1/2] selftests: kvm: " Paolo Bonzini
@ 2019-08-09  7:53   ` Naresh Kamboju
  2019-08-09 10:18     ` Paolo Bonzini
  0 siblings, 1 reply; 6+ messages in thread
From: Naresh Kamboju @ 2019-08-09  7:53 UTC (permalink / raw)
  To: Paolo Bonzini
  Cc: Shuah Khan, open list, Andrew Jones, sean.j.christopherson,
	open list:KERNEL SELFTEST FRAMEWORK, kvm list, Dan Rue

On Fri, 9 Aug 2019 at 13:09, Paolo Bonzini <pbonzini@redhat.com> wrote:
>
> On 09/08/19 09:24, Naresh Kamboju wrote:
> > selftests kvm all test cases need pre-required kernel config for the
> > tests to get pass.
> >
> > CONFIG_KVM=y
> >
> > The KVM tests are skipped without these configs:
> >
> >         dev_fd = open(KVM_DEV_PATH, O_RDONLY);
> >         if (dev_fd < 0)
> >                 exit(KSFT_SKIP);
> >
> > Signed-off-by: Naresh Kamboju <naresh.kamboju@linaro.org>
> > Acked-by: Shuah Khan <skhan@linuxfoundation.org>
> > ---
> >  tools/testing/selftests/kvm/config | 1 +
> >  1 file changed, 1 insertion(+)
> >  create mode 100644 tools/testing/selftests/kvm/config
> >
> > diff --git a/tools/testing/selftests/kvm/config b/tools/testing/selftests/kvm/config
> > new file mode 100644
> > index 000000000000..14f90d8d6801
> > --- /dev/null
> > +++ b/tools/testing/selftests/kvm/config
> > @@ -0,0 +1 @@
> > +CONFIG_KVM=y
> >
>
> I think this is more complicated without a real benefit, so I'll merge v2.

With the recent changes to 'kselftest-merge' nested configs also get merged.
Please refer this below commit for more details.
---
commit 6d3db46c8e331908775b0135dc7d2e5920bf6d90
Author: Dan Rue <dan.rue@linaro.org>
Date:   Mon May 20 10:16:14 2019 -0500

    kbuild: teach kselftest-merge to find nested config files

    Current implementation of kselftest-merge only finds config files that
    are one level deep using `$(srctree)/tools/testing/selftests/*/config`.

    Often, config files are added in nested directories, and do not get
    picked up by kselftest-merge.

    Use `find` to catch all config files under
    `$(srctree)/tools/testing/selftests` instead.

    Signed-off-by: Dan Rue <dan.rue@linaro.org>
    Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>

- Naresh

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3 1/2] selftests: kvm: Adding config fragments
  2019-08-09  7:53   ` Naresh Kamboju
@ 2019-08-09 10:18     ` Paolo Bonzini
  2019-08-09 14:58       ` Naresh Kamboju
  0 siblings, 1 reply; 6+ messages in thread
From: Paolo Bonzini @ 2019-08-09 10:18 UTC (permalink / raw)
  To: Naresh Kamboju
  Cc: Shuah Khan, open list, Andrew Jones, sean.j.christopherson,
	open list:KERNEL SELFTEST FRAMEWORK, kvm list, Dan Rue

On 09/08/19 09:53, Naresh Kamboju wrote:
>> I think this is more complicated without a real benefit, so I'll merge v2.
> With the recent changes to 'kselftest-merge' nested configs also get merged.
> Please refer this below commit for more details.

Sure---both v2 and v3 work but this one adds more config files with
little benefit.

Paolo

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3 1/2] selftests: kvm: Adding config fragments
  2019-08-09 10:18     ` Paolo Bonzini
@ 2019-08-09 14:58       ` Naresh Kamboju
  0 siblings, 0 replies; 6+ messages in thread
From: Naresh Kamboju @ 2019-08-09 14:58 UTC (permalink / raw)
  To: Paolo Bonzini
  Cc: Shuah Khan, open list, Andrew Jones, sean.j.christopherson,
	open list:KERNEL SELFTEST FRAMEWORK, kvm list, Dan Rue

On Fri, 9 Aug 2019 at 15:48, Paolo Bonzini <pbonzini@redhat.com> wrote:
>
> On 09/08/19 09:53, Naresh Kamboju wrote:
> >> I think this is more complicated without a real benefit, so I'll merge v2.
> > With the recent changes to 'kselftest-merge' nested configs also get merged.
> > Please refer this below commit for more details.
>
> Sure---both v2 and v3 work but this one adds more config files with
> little benefit.

I vote for v3.
Because  x86_64/config have its own specific configs now.
No objections and no questions will be asked from other architecture guys.

- Naresh

>
> Paolo

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-08-09 14:58 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-09  7:24 [PATCH v3 1/2] selftests: kvm: Adding config fragments Naresh Kamboju
2019-08-09  7:24 ` [PATCH v3 2/2] selftests: kvm: x86_64: " Naresh Kamboju
2019-08-09  7:39 ` [PATCH v3 1/2] selftests: kvm: " Paolo Bonzini
2019-08-09  7:53   ` Naresh Kamboju
2019-08-09 10:18     ` Paolo Bonzini
2019-08-09 14:58       ` Naresh Kamboju

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).