All of lore.kernel.org
 help / color / mirror / Atom feed
* [for-4.17] automation: Build Xen according to the type of the job
@ 2022-10-21 13:22 Michal Orzel
  2022-10-21 13:31 ` Andrew Cooper
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Michal Orzel @ 2022-10-21 13:22 UTC (permalink / raw)
  To: xen-devel; +Cc: Michal Orzel, Doug Goldstein, Stefano Stabellini, Henry Wang

All the build jobs exist in two flavors: debug and non-debug, where the
former sets 'debug' variable to 'y' and the latter to 'n'. This variable
is only being recognized by the toolstack, because Xen requires
enabling/disabling debug build via e.g. menuconfig/config file.
As a corollary, we end up building/testing Xen with CONFIG_DEBUG always
set to a default value ('y' for unstable and 'n' for stable branches),
regardless of the type of the build job.

Fix this behavior by setting CONFIG_DEBUG according to the 'debug' value.

Signed-off-by: Michal Orzel <michal.orzel@amd.com>
---
Xen used debug variable to control the build type before switching to Kconfig.
Support for GitLab CI was added later, which means that this issue was always
present. This is a low risk for 4.17 with a benefit of being able to test Xen
in both debug and non-debug versions.
---
 automation/scripts/build | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/automation/scripts/build b/automation/scripts/build
index 8c0882f3aa33..a5934190634b 100755
--- a/automation/scripts/build
+++ b/automation/scripts/build
@@ -21,12 +21,13 @@ if [[ "${RANDCONFIG}" == "y" ]]; then
     make -j$(nproc) -C xen KCONFIG_ALLCONFIG=tools/kconfig/allrandom.config randconfig
     hypervisor_only="y"
 else
+    echo "CONFIG_DEBUG=${debug}" > xen/.config
+
     if [[ -n "${EXTRA_XEN_CONFIG}" ]]; then
-        echo "${EXTRA_XEN_CONFIG}" > xen/.config
-        make -j$(nproc) -C xen olddefconfig
-    else
-        make -j$(nproc) -C xen defconfig
+        echo "${EXTRA_XEN_CONFIG}" >> xen/.config
     fi
+
+    make -j$(nproc) -C xen olddefconfig
 fi
 
 # Save the config file before building because build failure causes the script
-- 
2.25.1



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

* Re: [for-4.17] automation: Build Xen according to the type of the job
  2022-10-21 13:22 [for-4.17] automation: Build Xen according to the type of the job Michal Orzel
@ 2022-10-21 13:31 ` Andrew Cooper
  2022-10-21 14:32   ` Michal Orzel
  2022-10-21 13:46 ` Henry Wang
  2022-10-21 19:08 ` Stefano Stabellini
  2 siblings, 1 reply; 6+ messages in thread
From: Andrew Cooper @ 2022-10-21 13:31 UTC (permalink / raw)
  To: Michal Orzel, xen-devel@lists.xenproject.org
  Cc: Doug Goldstein, Stefano Stabellini, Henry Wang

On 21/10/2022 14:22, Michal Orzel wrote:
> All the build jobs exist in two flavors: debug and non-debug, where the
> former sets 'debug' variable to 'y' and the latter to 'n'. This variable
> is only being recognized by the toolstack, because Xen requires
> enabling/disabling debug build via e.g. menuconfig/config file.
> As a corollary, we end up building/testing Xen with CONFIG_DEBUG always
> set to a default value ('y' for unstable and 'n' for stable branches),
> regardless of the type of the build job.
>
> Fix this behavior by setting CONFIG_DEBUG according to the 'debug' value.
>
> Signed-off-by: Michal Orzel <michal.orzel@amd.com>
> ---
> Xen used debug variable to control the build type before switching to Kconfig.
> Support for GitLab CI was added later, which means that this issue was always
> present. This is a low risk for 4.17 with a benefit of being able to test Xen
> in both debug and non-debug versions.

Both series were floating around for ages before being accepted.  It's
quite possible that one bitrotted around the other.

This should be backported, and therefore should be considered for 4.17
at this point.

Is there a Gitlab CI run which includes this patch?

~Andrew

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

* RE: [for-4.17] automation: Build Xen according to the type of the job
  2022-10-21 13:22 [for-4.17] automation: Build Xen according to the type of the job Michal Orzel
  2022-10-21 13:31 ` Andrew Cooper
@ 2022-10-21 13:46 ` Henry Wang
  2022-10-21 19:08 ` Stefano Stabellini
  2 siblings, 0 replies; 6+ messages in thread
From: Henry Wang @ 2022-10-21 13:46 UTC (permalink / raw)
  To: Michal Orzel, xen-devel@lists.xenproject.org
  Cc: Doug Goldstein, Stefano Stabellini

Hi Michal,

> -----Original Message-----
> From: Michal Orzel <michal.orzel@amd.com>
> Subject: [for-4.17] automation: Build Xen according to the type of the job
> 
> All the build jobs exist in two flavors: debug and non-debug, where the
> former sets 'debug' variable to 'y' and the latter to 'n'. This variable
> is only being recognized by the toolstack, because Xen requires
> enabling/disabling debug build via e.g. menuconfig/config file.
> As a corollary, we end up building/testing Xen with CONFIG_DEBUG always
> set to a default value ('y' for unstable and 'n' for stable branches),
> regardless of the type of the build job.
> 
> Fix this behavior by setting CONFIG_DEBUG according to the 'debug' value.
> 
> Signed-off-by: Michal Orzel <michal.orzel@amd.com>

Release-acked-by: Henry Wang <Henry.Wang@arm.com>

Kind regards,
Henry


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

* Re: [for-4.17] automation: Build Xen according to the type of the job
  2022-10-21 13:31 ` Andrew Cooper
@ 2022-10-21 14:32   ` Michal Orzel
  2022-10-21 16:20     ` Michal Orzel
  0 siblings, 1 reply; 6+ messages in thread
From: Michal Orzel @ 2022-10-21 14:32 UTC (permalink / raw)
  To: Andrew Cooper, xen-devel@lists.xenproject.org
  Cc: Doug Goldstein, Stefano Stabellini, Henry Wang

Hi Andrew,

On 21/10/2022 15:31, Andrew Cooper wrote:
> 
> 
> On 21/10/2022 14:22, Michal Orzel wrote:
>> All the build jobs exist in two flavors: debug and non-debug, where the
>> former sets 'debug' variable to 'y' and the latter to 'n'. This variable
>> is only being recognized by the toolstack, because Xen requires
>> enabling/disabling debug build via e.g. menuconfig/config file.
>> As a corollary, we end up building/testing Xen with CONFIG_DEBUG always
>> set to a default value ('y' for unstable and 'n' for stable branches),
>> regardless of the type of the build job.
>>
>> Fix this behavior by setting CONFIG_DEBUG according to the 'debug' value.
>>
>> Signed-off-by: Michal Orzel <michal.orzel@amd.com>
>> ---
>> Xen used debug variable to control the build type before switching to Kconfig.
>> Support for GitLab CI was added later, which means that this issue was always
>> present. This is a low risk for 4.17 with a benefit of being able to test Xen
>> in both debug and non-debug versions.
> 
> Both series were floating around for ages before being accepted.  It's
> quite possible that one bitrotted around the other.
> 
> This should be backported, and therefore should be considered for 4.17
> at this point.
> 
> Is there a Gitlab CI run which includes this patch?

I submitted the one here not long ago:
https://gitlab.com/xen-project/people/morzel/xen-orzelmichal/-/pipelines/673396949

and there is already one failure in Arm boot-cpupools test because the script sets null
scheduler for the domain which is not present in non-debug build...

> 
> ~Andrew

~Michal


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

* Re: [for-4.17] automation: Build Xen according to the type of the job
  2022-10-21 14:32   ` Michal Orzel
@ 2022-10-21 16:20     ` Michal Orzel
  0 siblings, 0 replies; 6+ messages in thread
From: Michal Orzel @ 2022-10-21 16:20 UTC (permalink / raw)
  To: Andrew Cooper, xen-devel@lists.xenproject.org
  Cc: Doug Goldstein, Stefano Stabellini, Henry Wang


On 21/10/2022 16:32, Michal Orzel wrote:
> 
> 
> Hi Andrew,
> 
> On 21/10/2022 15:31, Andrew Cooper wrote:
>>
>>
>> On 21/10/2022 14:22, Michal Orzel wrote:
>>> All the build jobs exist in two flavors: debug and non-debug, where the
>>> former sets 'debug' variable to 'y' and the latter to 'n'. This variable
>>> is only being recognized by the toolstack, because Xen requires
>>> enabling/disabling debug build via e.g. menuconfig/config file.
>>> As a corollary, we end up building/testing Xen with CONFIG_DEBUG always
>>> set to a default value ('y' for unstable and 'n' for stable branches),
>>> regardless of the type of the build job.
>>>
>>> Fix this behavior by setting CONFIG_DEBUG according to the 'debug' value.
>>>
>>> Signed-off-by: Michal Orzel <michal.orzel@amd.com>
>>> ---
>>> Xen used debug variable to control the build type before switching to Kconfig.
>>> Support for GitLab CI was added later, which means that this issue was always
>>> present. This is a low risk for 4.17 with a benefit of being able to test Xen
>>> in both debug and non-debug versions.
>>
>> Both series were floating around for ages before being accepted.  It's
>> quite possible that one bitrotted around the other.
>>
>> This should be backported, and therefore should be considered for 4.17
>> at this point.
>>
>> Is there a Gitlab CI run which includes this patch?
> 
> I submitted the one here not long ago:
> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitlab.com%2Fxen-project%2Fpeople%2Fmorzel%2Fxen-orzelmichal%2F-%2Fpipelines%2F673396949&amp;data=05%7C01%7Cmichal.orzel%40amd.com%7Cd091891dbc3a4144356d08dab37120ae%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638019595719666762%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&amp;sdata=r6qIERShnnovl57xvY%2Fo8eKozAy9NBlqyj0le56ZClY%3D&amp;reserved=0
> 
> and there is already one failure in Arm boot-cpupools test because the script sets null
> scheduler for the domain which is not present in non-debug build...

The CI finished running the pipeline and it looks like the null sched issue is the only one (at least this means that this patch is worth having).
I will push a fix for the boot-cpupools test (I will also mark it as for-4.17).

> 
>>
>> ~Andrew
> 
> ~Michal
> 

~Michal


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

* Re: [for-4.17] automation: Build Xen according to the type of the job
  2022-10-21 13:22 [for-4.17] automation: Build Xen according to the type of the job Michal Orzel
  2022-10-21 13:31 ` Andrew Cooper
  2022-10-21 13:46 ` Henry Wang
@ 2022-10-21 19:08 ` Stefano Stabellini
  2 siblings, 0 replies; 6+ messages in thread
From: Stefano Stabellini @ 2022-10-21 19:08 UTC (permalink / raw)
  To: Michal Orzel; +Cc: xen-devel, Doug Goldstein, Stefano Stabellini, Henry Wang

On Fri, 21 Oct 2022, Michal Orzel wrote:
> All the build jobs exist in two flavors: debug and non-debug, where the
> former sets 'debug' variable to 'y' and the latter to 'n'. This variable
> is only being recognized by the toolstack, because Xen requires
> enabling/disabling debug build via e.g. menuconfig/config file.
> As a corollary, we end up building/testing Xen with CONFIG_DEBUG always
> set to a default value ('y' for unstable and 'n' for stable branches),
> regardless of the type of the build job.
> 
> Fix this behavior by setting CONFIG_DEBUG according to the 'debug' value.
> 
> Signed-off-by: Michal Orzel <michal.orzel@amd.com>

Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>


> ---
> Xen used debug variable to control the build type before switching to Kconfig.
> Support for GitLab CI was added later, which means that this issue was always
> present. This is a low risk for 4.17 with a benefit of being able to test Xen
> in both debug and non-debug versions.
> ---
>  automation/scripts/build | 9 +++++----
>  1 file changed, 5 insertions(+), 4 deletions(-)
> 
> diff --git a/automation/scripts/build b/automation/scripts/build
> index 8c0882f3aa33..a5934190634b 100755
> --- a/automation/scripts/build
> +++ b/automation/scripts/build
> @@ -21,12 +21,13 @@ if [[ "${RANDCONFIG}" == "y" ]]; then
>      make -j$(nproc) -C xen KCONFIG_ALLCONFIG=tools/kconfig/allrandom.config randconfig
>      hypervisor_only="y"
>  else
> +    echo "CONFIG_DEBUG=${debug}" > xen/.config
> +
>      if [[ -n "${EXTRA_XEN_CONFIG}" ]]; then
> -        echo "${EXTRA_XEN_CONFIG}" > xen/.config
> -        make -j$(nproc) -C xen olddefconfig
> -    else
> -        make -j$(nproc) -C xen defconfig
> +        echo "${EXTRA_XEN_CONFIG}" >> xen/.config
>      fi
> +
> +    make -j$(nproc) -C xen olddefconfig
>  fi
>  
>  # Save the config file before building because build failure causes the script
> -- 
> 2.25.1
> 


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

end of thread, other threads:[~2022-10-21 19:08 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-21 13:22 [for-4.17] automation: Build Xen according to the type of the job Michal Orzel
2022-10-21 13:31 ` Andrew Cooper
2022-10-21 14:32   ` Michal Orzel
2022-10-21 16:20     ` Michal Orzel
2022-10-21 13:46 ` Henry Wang
2022-10-21 19:08 ` Stefano Stabellini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.