On 26/06/26 04:52PM, Shivang Upadhyay wrote:
> Test boots a powernv11 machine, using a custom dtb.
> Custom dtb has the following bootargs.
> 
>     chosen {
>         bootargs = "hello world";
>     };
> 
> Test Checks wheather above bootargs make it to kernel's command line.

nit: s/wheather/whether

> +    # testdtb for power11, which contains string "hello world" in command 
> line
> +    ASSET_SAMPLE_DTB = Asset(
> +        
> ('https://github.com/roz3x/qemu/raw/refs/heads/sample-dtb/output.dtb'),
> +        'ea1271516264eea1eb58a067a99d0c2ca9528be8dc7d4e46bb2d5ae0d42fc568')

nit: since you are anyways sending a v3, can you rename output.dtb to
something like qemu-powernv10.dtb, etc so in future you don't modify
this generic path unknowingly ?

> +
>      def do_test_linux_boot(self, command_line = KERNEL_COMMON_COMMAND_LINE):
>          self.require_accelerator("tcg")
>          kernel_path = self.ASSET_KERNEL.fetch()
> @@ -104,6 +109,20 @@ def do_test_ppc64_powernv(self, proc):
>          # Device detection output driven by udev probing is sometimes cut off
>          # from console output, suspect S14silence-console init script.
>  
> +    def test_ppc64_powernv_external_dtb(self):
> +        self.set_machine('powernv11')
> +        self.require_accelerator("tcg")
> +
> +        kernel_path = self.ASSET_KERNEL.fetch()
> +        sample_dtb_path = self.ASSET_SAMPLE_DTB.fetch()
> +        self.vm.set_console()
> +        self.vm.add_args('-kernel', kernel_path,
> +                         '-dtb', sample_dtb_path)
> +        self.vm.launch()
> +
> +        # check if custom dtb is reflected or not
> +        wait_for_console_pattern(self, "Kernel command line: hello world", 
> self.panic_message)
> +

Reviewed-by: Aditya Gupta <[email protected]>

Thanks,
- Aditya G


Reply via email to