mbox series

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

Message ID 20231120224912.1421916-1-andrew.cooper3@citrix.com (mailing list archive)
Headers show
Series xen: Enable -Wwrite-strings | expand

Message

Andrew Cooper Nov. 20, 2023, 10:49 p.m. UTC
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

Comments

Andrew Cooper Nov. 20, 2023, 11:31 p.m. UTC | #1
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
Stefano Stabellini Nov. 21, 2023, 1:45 a.m. UTC | #2
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>