[PATCH 0/6] xen: Enable -Wwrite-strings

Andrew Cooper posted 6 patches 5 months, 1 week ago
Patches applied successfully (tree, apply log)
git fetch https://gitlab.com/xen-project/patchew/xen tags/patchew/20231120224912.1421916-1-andrew.cooper3@citrix.com
There is a newer version of this series
xen/Makefile                     |  2 +-
xen/arch/arm/efi/efi-boot.h      |  2 +-
xen/arch/arm/platforms/brcm.c    |  2 +-
xen/arch/arm/platforms/exynos5.c |  2 +-
xen/arch/x86/efi/efi-boot.h      |  3 ++-
xen/arch/x86/setup.c             | 21 +++++++++++----------
xen/drivers/char/arm-uart.c      | 12 ++++++++----
7 files changed, 25 insertions(+), 19 deletions(-)
[PATCH 0/6] xen: Enable -Wwrite-strings
Posted by Andrew Cooper 5 months, 1 week ago
I got carried away and fixed all remaining -Wwrite-strings issues I could
reproduce in local builds.

Pipeline in Gitlab:

  https://gitlab.com/xen-project/people/andyhhp/xen/-/pipelines/1079379918

Andrew Cooper (6):
  x86/setup: Make the loader variable const
  x86/setup: Rework cmdline_cook() to be compatible with -Wwrite-strings
  xen/efi: Make efi-boot.h compile with -Wwrite-strings
  arm/duart: make dt_uart_init() compile with -Wwrite-strings
  arm/platforms: Make compatbile with -Wwrite-strings
  xen: Enable -Wwrite-strings

 xen/Makefile                     |  2 +-
 xen/arch/arm/efi/efi-boot.h      |  2 +-
 xen/arch/arm/platforms/brcm.c    |  2 +-
 xen/arch/arm/platforms/exynos5.c |  2 +-
 xen/arch/x86/efi/efi-boot.h      |  3 ++-
 xen/arch/x86/setup.c             | 21 +++++++++++----------
 xen/drivers/char/arm-uart.c      | 12 ++++++++----
 7 files changed, 25 insertions(+), 19 deletions(-)


base-commit: fa2da5bce90b3777aa7a323e1cf201c97b56d278
-- 
2.30.2
Re: [PATCH 0/6] xen: Enable -Wwrite-strings
Posted by Andrew Cooper 5 months, 1 week ago
On 20/11/2023 10:49 pm, Andrew Cooper wrote:
> I got carried away and fixed all remaining -Wwrite-strings issues I could
> reproduce in local builds.
>
> Pipeline in Gitlab:
>
>   https://gitlab.com/xen-project/people/andyhhp/xen/-/pipelines/1079379918

Randconfig found:

https://gitlab.com/xen-project/people/andyhhp/xen/-/jobs/5580160813

which looks to be the ACPI support.

diff --git a/xen/arch/arm/acpi/domain_build.c
b/xen/arch/arm/acpi/domain_build.c
index ed824c017882..b58389ce9e9f 100644
--- a/xen/arch/arm/acpi/domain_build.c
+++ b/xen/arch/arm/acpi/domain_build.c
@@ -245,7 +245,7 @@ static int __init acpi_create_rsdp(struct domain *d,
struct membank tbl_add[])
 
 static void __init acpi_xsdt_modify_entry(u64 entry[],
                                           unsigned long entry_count,
-                                          char *signature, u64 addr)
+                                          const char *signature, u64 addr)
 {
     int i;
     struct acpi_table_header *table;


should fix it, and it probably wants to merge into patch 5.

~Andrew

Re: [PATCH 0/6] xen: Enable -Wwrite-strings
Posted by Stefano Stabellini 5 months, 1 week ago
On Mon, 20 Nov 2023, Andrew Cooper wrote:

> On 20/11/2023 10:49 pm, Andrew Cooper wrote:
> > I got carried away and fixed all remaining -Wwrite-strings issues I could
> > reproduce in local builds.
> >
> > Pipeline in Gitlab:
> >
> >   https://gitlab.com/xen-project/people/andyhhp/xen/-/pipelines/1079379918
> 
> Randconfig found:
> 
> https://gitlab.com/xen-project/people/andyhhp/xen/-/jobs/5580160813
> 
> which looks to be the ACPI support.
> 
> diff --git a/xen/arch/arm/acpi/domain_build.c
> b/xen/arch/arm/acpi/domain_build.c
> index ed824c017882..b58389ce9e9f 100644
> --- a/xen/arch/arm/acpi/domain_build.c
> +++ b/xen/arch/arm/acpi/domain_build.c
> @@ -245,7 +245,7 @@ static int __init acpi_create_rsdp(struct domain *d,
> struct membank tbl_add[])
>  
>  static void __init acpi_xsdt_modify_entry(u64 entry[],
>                                            unsigned long entry_count,
> -                                          char *signature, u64 addr)
> +                                          const char *signature, u64 addr)
>  {
>      int i;
>      struct acpi_table_header *table;
> 
> 
> should fix it, and it probably wants to merge into patch 5.


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