linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH VKMS v3] drm/doc: Add VKMS module description and use to "Testing and Validation"
@ 2019-11-04 16:27 Gabriela Bittencourt
  2019-11-05  0:26 ` Rodrigo Siqueira
  0 siblings, 1 reply; 2+ messages in thread
From: Gabriela Bittencourt @ 2019-11-04 16:27 UTC (permalink / raw)
  To: outreachy-kernel, manasi.d.navare, rodrigosiqueiramelo,
	hamohammed.sa, daniel, airlied, maarten.lankhorst, mripard, sean,
	corbet, dri-devel, linux-doc, linux-kernel, lkcamp
  Cc: Gabriela Bittencourt

Add a description on VKMS module and the cases in which it should be used.
There's a brief explanation on how to set it and use it in a VM, along with
an example of running an igt-test.

Changes since V3:
 Rodrigo:
 - Change the log message to imperative
 - Fix some bad spelling/writing
 - Add a blank line before enumeration

Changes since V2:
 Andre:
 - Avoid repetition of words in the same sentence;
 - Make the explanation on 'setting the kernel' shorter, eliminate the
   'make menuconfig' command;
 - Add tab on enumeration to have one line per item;
 - Clarify from each machine igt-tests commands should be ran on.

Signed-off-by: Gabriela Bittencourt <gabrielabittencourt00@gmail.com>
---

Tested the patch using 'make htmldocs' to make sure the output .html is
correct.

Hi DRM-community,
this is my first (of many, I hope)  patch in this subsystem. I hope to have
a lot of learning (and fun :)) working with you guys.
I'm starting by documenting the VKMS driver in "Userland interfaces", if I
have been inaccurate in my description or if I misunderstood some concept,
please let me know.
---
 Documentation/gpu/drm-uapi.rst | 37 ++++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)

diff --git a/Documentation/gpu/drm-uapi.rst b/Documentation/gpu/drm-uapi.rst
index 94f90521f58c..8271c1e240b7 100644
--- a/Documentation/gpu/drm-uapi.rst
+++ b/Documentation/gpu/drm-uapi.rst
@@ -285,6 +285,43 @@ run-tests.sh is a wrapper around piglit that will execute the tests matching
 the -t options. A report in HTML format will be available in
 ./results/html/index.html. Results can be compared with piglit.
 
+Using VKMS to test DRM API
+--------------------------
+
+VKMS is a software-only model of a KMS driver that is useful for testing
+and for running compositors. VKMS aims to enable a virtual display without
+the need for a hardware display capability. These characteristics made VKMS
+a perfect tool for validating the DRM core behavior and also support the
+compositor developer. VKMS makes it possible to test DRM functions in a
+virtual machine without display, simplifying the validation of some of the
+core changes.
+
+To Validate changes in DRM API with VKMS, start setting the kernel: make
+sure to enable VKMS module; compile the kernel with the VKMS enabled and
+install it in the target machine. VKMS can be run in a Virtual Machine
+(QEMU, virtme or similar). It's recommended the use of KVM with the minimum
+of 1GB of RAM and four cores.
+
+It's possible to run the IGT-tests in a VM in two ways:
+
+	1. Use IGT inside a VM
+	2. Use IGT from the host machine and write the results in a shared directory.
+
+As follow, there is an example of using a VM with a shared directory with
+the host machine to run igt-tests. As an example it's used virtme::
+
+	$ virtme-run --rwdir /path/for/shared_dir --kdir=path/for/kernel/directory --mods=auto
+
+Run the igt-tests in the guest machine, as example it's ran the 'kms_flip'
+tests::
+
+	$ /path/for/igt-gpu-tools/scripts/run-tests.sh -p -s -t "kms_flip.*" -v
+
+In this example, instead of build the igt_runner, Piglit is used
+(-p option); it's created html summary of the tests results and it's saved
+in the folder "igt-gpu-tools/results"; it's executed only the igt-tests
+matching the -t option.
+
 Display CRC Support
 -------------------
 
-- 
2.20.1


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

* Re: [PATCH VKMS v3] drm/doc: Add VKMS module description and use to "Testing and Validation"
  2019-11-04 16:27 [PATCH VKMS v3] drm/doc: Add VKMS module description and use to "Testing and Validation" Gabriela Bittencourt
@ 2019-11-05  0:26 ` Rodrigo Siqueira
  0 siblings, 0 replies; 2+ messages in thread
From: Rodrigo Siqueira @ 2019-11-05  0:26 UTC (permalink / raw)
  To: Gabriela Bittencourt
  Cc: outreachy-kernel, manasi.d.navare, hamohammed.sa, daniel,
	airlied, maarten.lankhorst, mripard, sean, corbet, dri-devel,
	linux-doc, linux-kernel, lkcamp

[-- Attachment #1: Type: text/plain, Size: 3848 bytes --]

lgtm, I'll apply it tomorrow.

Thanks

Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com>

On 11/04, Gabriela Bittencourt wrote:
> Add a description on VKMS module and the cases in which it should be used.
> There's a brief explanation on how to set it and use it in a VM, along with
> an example of running an igt-test.
> 
> Changes since V3:
>  Rodrigo:
>  - Change the log message to imperative
>  - Fix some bad spelling/writing
>  - Add a blank line before enumeration
> 
> Changes since V2:
>  Andre:
>  - Avoid repetition of words in the same sentence;
>  - Make the explanation on 'setting the kernel' shorter, eliminate the
>    'make menuconfig' command;
>  - Add tab on enumeration to have one line per item;
>  - Clarify from each machine igt-tests commands should be ran on.
> 
> Signed-off-by: Gabriela Bittencourt <gabrielabittencourt00@gmail.com>
> ---
> 
> Tested the patch using 'make htmldocs' to make sure the output .html is
> correct.
> 
> Hi DRM-community,
> this is my first (of many, I hope)  patch in this subsystem. I hope to have
> a lot of learning (and fun :)) working with you guys.
> I'm starting by documenting the VKMS driver in "Userland interfaces", if I
> have been inaccurate in my description or if I misunderstood some concept,
> please let me know.
> ---
>  Documentation/gpu/drm-uapi.rst | 37 ++++++++++++++++++++++++++++++++++
>  1 file changed, 37 insertions(+)
> 
> diff --git a/Documentation/gpu/drm-uapi.rst b/Documentation/gpu/drm-uapi.rst
> index 94f90521f58c..8271c1e240b7 100644
> --- a/Documentation/gpu/drm-uapi.rst
> +++ b/Documentation/gpu/drm-uapi.rst
> @@ -285,6 +285,43 @@ run-tests.sh is a wrapper around piglit that will execute the tests matching
>  the -t options. A report in HTML format will be available in
>  ./results/html/index.html. Results can be compared with piglit.
>  
> +Using VKMS to test DRM API
> +--------------------------
> +
> +VKMS is a software-only model of a KMS driver that is useful for testing
> +and for running compositors. VKMS aims to enable a virtual display without
> +the need for a hardware display capability. These characteristics made VKMS
> +a perfect tool for validating the DRM core behavior and also support the
> +compositor developer. VKMS makes it possible to test DRM functions in a
> +virtual machine without display, simplifying the validation of some of the
> +core changes.
> +
> +To Validate changes in DRM API with VKMS, start setting the kernel: make
> +sure to enable VKMS module; compile the kernel with the VKMS enabled and
> +install it in the target machine. VKMS can be run in a Virtual Machine
> +(QEMU, virtme or similar). It's recommended the use of KVM with the minimum
> +of 1GB of RAM and four cores.
> +
> +It's possible to run the IGT-tests in a VM in two ways:
> +
> +	1. Use IGT inside a VM
> +	2. Use IGT from the host machine and write the results in a shared directory.
> +
> +As follow, there is an example of using a VM with a shared directory with
> +the host machine to run igt-tests. As an example it's used virtme::
> +
> +	$ virtme-run --rwdir /path/for/shared_dir --kdir=path/for/kernel/directory --mods=auto
> +
> +Run the igt-tests in the guest machine, as example it's ran the 'kms_flip'
> +tests::
> +
> +	$ /path/for/igt-gpu-tools/scripts/run-tests.sh -p -s -t "kms_flip.*" -v
> +
> +In this example, instead of build the igt_runner, Piglit is used
> +(-p option); it's created html summary of the tests results and it's saved
> +in the folder "igt-gpu-tools/results"; it's executed only the igt-tests
> +matching the -t option.
> +
>  Display CRC Support
>  -------------------
>  
> -- 
> 2.20.1
> 

-- 
Rodrigo Siqueira
Software Engineer, Advanced Micro Devices (AMD)
https://siqueira.tech

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

end of thread, other threads:[~2019-11-05  0:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-04 16:27 [PATCH VKMS v3] drm/doc: Add VKMS module description and use to "Testing and Validation" Gabriela Bittencourt
2019-11-05  0:26 ` Rodrigo Siqueira

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).