2024-04-08 04:12:59

by Stephen Rothwell

[permalink] [raw]
Subject: linux-next: build failure after merge of the sound-asoc tree

Hi all,

After merging the sound-asoc tree, today's linux-next build (powerpc
allyesconfig) failed like this:

In file included from include/linux/bits.h:22,
from include/linux/gfp_types.h:5,
from include/linux/gfp.h:5,
from include/linux/slab.h:16,
from sound/soc/intel/avs/icl.c:9:
include/linux/build_bug.h:78:41: error: static assertion failed: "sizeof(struct avs_icl_memwnd2) == 65536"
78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
| ^~~~~~~~~~~~~~
include/linux/build_bug.h:77:34: note: in expansion of macro '__static_assert'
77 | #define static_assert(expr, ...) __static_assert(expr, ##__VA_ARGS__, #expr)
| ^~~~~~~~~~~~~~~
sound/soc/intel/avs/icl.c:73:1: note: in expansion of macro 'static_assert'
73 | static_assert(sizeof(struct avs_icl_memwnd2) == 65536);
| ^~~~~~~~~~~~~

Caused by commit

c2b10acb62c1 ("ASoC: Intel: avs: Add assert_static to guarantee ABI sizes")

PAGE_SIZE is 64K for this build.

I have applied this patch for today:

From: Stephen Rothwell <[email protected]>
Date: Mon, 8 Apr 2024 13:50:53 +1000
Subject: [PATCH] ASoC: Intel: avs: stop building when PAGE_SIZE == 64K

Signed-off-by: Stephen Rothwell <[email protected]>
---
sound/soc/intel/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/intel/Kconfig b/sound/soc/intel/Kconfig
index 4b9e498e3303..abe5cba82d50 100644
--- a/sound/soc/intel/Kconfig
+++ b/sound/soc/intel/Kconfig
@@ -211,7 +211,7 @@ config SND_SOC_INTEL_KEEMBAY

config SND_SOC_INTEL_AVS
tristate "Intel AVS driver"
- depends on X86 || COMPILE_TEST
+ depends on X86
depends on PCI
depends on COMMON_CLK
select SND_SOC_ACPI if ACPI
--
2.43.0

--
Cheers,
Stephen Rothwell


Attachments:
(No filename) (499.00 B)
OpenPGP digital signature

2024-04-08 08:24:50

by Cezary Rojewski

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the sound-asoc tree

On 2024-04-08 6:12 AM, Stephen Rothwell wrote:
> Hi all,
>
> After merging the sound-asoc tree, today's linux-next build (powerpc
> allyesconfig) failed like this:
>
> In file included from include/linux/bits.h:22,
> from include/linux/gfp_types.h:5,
> from include/linux/gfp.h:5,
> from include/linux/slab.h:16,
> from sound/soc/intel/avs/icl.c:9:
> include/linux/build_bug.h:78:41: error: static assertion failed: "sizeof(struct avs_icl_memwnd2) == 65536"
> 78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
> | ^~~~~~~~~~~~~~
> include/linux/build_bug.h:77:34: note: in expansion of macro '__static_assert'
> 77 | #define static_assert(expr, ...) __static_assert(expr, ##__VA_ARGS__, #expr)
> | ^~~~~~~~~~~~~~~
> sound/soc/intel/avs/icl.c:73:1: note: in expansion of macro 'static_assert'
> 73 | static_assert(sizeof(struct avs_icl_memwnd2) == 65536);
> | ^~~~~~~~~~~~~
>
> Caused by commit
>
> c2b10acb62c1 ("ASoC: Intel: avs: Add assert_static to guarantee ABI sizes")
>
> PAGE_SIZE is 64K for this build.
>
> I have applied this patch for today:
>
> From: Stephen Rothwell <[email protected]>
> Date: Mon, 8 Apr 2024 13:50:53 +1000
> Subject: [PATCH] ASoC: Intel: avs: stop building when PAGE_SIZE == 64K
>
> Signed-off-by: Stephen Rothwell <[email protected]>
> ---
> sound/soc/intel/Kconfig | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/soc/intel/Kconfig b/sound/soc/intel/Kconfig
> index 4b9e498e3303..abe5cba82d50 100644
> --- a/sound/soc/intel/Kconfig
> +++ b/sound/soc/intel/Kconfig
> @@ -211,7 +211,7 @@ config SND_SOC_INTEL_KEEMBAY
>
> config SND_SOC_INTEL_AVS
> tristate "Intel AVS driver"
> - depends on X86 || COMPILE_TEST
> + depends on X86
> depends on PCI
> depends on COMMON_CLK
> select SND_SOC_ACPI if ACPI

Hello Stephen,

Thank you for the report. I do not believe the patch above is the
correct fix. Below is the context and the proposed fix [1] has just been
sent to alsa-devel.

Recent series for the avs-driver added static_asserts() [2]. Since that
moment, build problems occur when PAGE_SIZE != SZ_4K. Patch originally
designed to fix problems with the window description [3], didn't address
all the problems, unfortunately.


[1]:
https://lore.kernel.org/alsa-devel/[email protected]/
[2]:
https://lore.kernel.org/alsa-devel/[email protected]/
[3]:
https://lore.kernel.org/alsa-devel/[email protected]/


Kind regards,
Czarek

2024-04-08 12:39:09

by Mark Brown

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the sound-asoc tree

On Mon, Apr 08, 2024 at 02:12:16PM +1000, Stephen Rothwell wrote:
> Hi all,
>
> After merging the sound-asoc tree, today's linux-next build (powerpc
> allyesconfig) failed like this:

Copying in Amadeusz and Cezary, this is from the recent AVS changes.

>
> In file included from include/linux/bits.h:22,
> from include/linux/gfp_types.h:5,
> from include/linux/gfp.h:5,
> from include/linux/slab.h:16,
> from sound/soc/intel/avs/icl.c:9:
> include/linux/build_bug.h:78:41: error: static assertion failed: "sizeof(struct avs_icl_memwnd2) == 65536"
> 78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
> | ^~~~~~~~~~~~~~
> include/linux/build_bug.h:77:34: note: in expansion of macro '__static_assert'
> 77 | #define static_assert(expr, ...) __static_assert(expr, ##__VA_ARGS__, #expr)
> | ^~~~~~~~~~~~~~~
> sound/soc/intel/avs/icl.c:73:1: note: in expansion of macro 'static_assert'
> 73 | static_assert(sizeof(struct avs_icl_memwnd2) == 65536);
> | ^~~~~~~~~~~~~
>
> Caused by commit
>
> c2b10acb62c1 ("ASoC: Intel: avs: Add assert_static to guarantee ABI sizes")
>
> PAGE_SIZE is 64K for this build.
>
> I have applied this patch for today:
>
> From: Stephen Rothwell <[email protected]>
> Date: Mon, 8 Apr 2024 13:50:53 +1000
> Subject: [PATCH] ASoC: Intel: avs: stop building when PAGE_SIZE == 64K
>
> Signed-off-by: Stephen Rothwell <[email protected]>
> ---
> sound/soc/intel/Kconfig | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/soc/intel/Kconfig b/sound/soc/intel/Kconfig
> index 4b9e498e3303..abe5cba82d50 100644
> --- a/sound/soc/intel/Kconfig
> +++ b/sound/soc/intel/Kconfig
> @@ -211,7 +211,7 @@ config SND_SOC_INTEL_KEEMBAY
>
> config SND_SOC_INTEL_AVS
> tristate "Intel AVS driver"
> - depends on X86 || COMPILE_TEST
> + depends on X86
> depends on PCI
> depends on COMMON_CLK
> select SND_SOC_ACPI if ACPI
> --
> 2.43.0
>
> --
> Cheers,
> Stephen Rothwell



Attachments:
(No filename) (2.14 kB)
signature.asc (499.00 B)
Download all attachments

2024-04-08 13:57:54

by Cezary Rojewski

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the sound-asoc tree

On 2024-04-08 2:28 PM, Mark Brown wrote:
> On Mon, Apr 08, 2024 at 02:12:16PM +1000, Stephen Rothwell wrote:
>> Hi all,
>>
>> After merging the sound-asoc tree, today's linux-next build (powerpc
>> allyesconfig) failed like this:
>
> Copying in Amadeusz and Cezary, this is from the recent AVS changes.

Hello Mark,

Sorry for the trouble caused by one of my changes. I've replied earlier
today in this very topic and provided a patch [1] which I believe
addresses the problem properly.


[1]:
https://lore.kernel.org/alsa-devel/[email protected]/

>>
>> In file included from include/linux/bits.h:22,
>> from include/linux/gfp_types.h:5,
>> from include/linux/gfp.h:5,
>> from include/linux/slab.h:16,
>> from sound/soc/intel/avs/icl.c:9:
>> include/linux/build_bug.h:78:41: error: static assertion failed: "sizeof(struct avs_icl_memwnd2) == 65536"
>> 78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
>> | ^~~~~~~~~~~~~~
>> include/linux/build_bug.h:77:34: note: in expansion of macro '__static_assert'
>> 77 | #define static_assert(expr, ...) __static_assert(expr, ##__VA_ARGS__, #expr)
>> | ^~~~~~~~~~~~~~~
>> sound/soc/intel/avs/icl.c:73:1: note: in expansion of macro 'static_assert'
>> 73 | static_assert(sizeof(struct avs_icl_memwnd2) == 65536);
>> | ^~~~~~~~~~~~~
>>
>> Caused by commit
>>
>> c2b10acb62c1 ("ASoC: Intel: avs: Add assert_static to guarantee ABI sizes")
>>
>> PAGE_SIZE is 64K for this build.
>>
>> I have applied this patch for today:
>>
>> From: Stephen Rothwell <[email protected]>
>> Date: Mon, 8 Apr 2024 13:50:53 +1000
>> Subject: [PATCH] ASoC: Intel: avs: stop building when PAGE_SIZE == 64K
>>
>> Signed-off-by: Stephen Rothwell <[email protected]>
>> ---
>> sound/soc/intel/Kconfig | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/sound/soc/intel/Kconfig b/sound/soc/intel/Kconfig
>> index 4b9e498e3303..abe5cba82d50 100644
>> --- a/sound/soc/intel/Kconfig
>> +++ b/sound/soc/intel/Kconfig
>> @@ -211,7 +211,7 @@ config SND_SOC_INTEL_KEEMBAY
>>
>> config SND_SOC_INTEL_AVS
>> tristate "Intel AVS driver"
>> - depends on X86 || COMPILE_TEST
>> + depends on X86
>> depends on PCI
>> depends on COMMON_CLK
>> select SND_SOC_ACPI if ACPI
>> --
>> 2.43.0
>>
>> --
>> Cheers,
>> Stephen Rothwell
>
>

2024-04-08 22:34:02

by Stephen Rothwell

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the sound-asoc tree

Hi Cezary,

On Mon, 8 Apr 2024 10:24:28 +0200 Cezary Rojewski <[email protected]> wrote:
>
> Thank you for the report. I do not believe the patch above is the correct fix.

Sure, I just used that to get the build to work so I could continue.

> Below is the context and the proposed fix [1] has just been sent to alsa-devel.
>
> [1]: https://lore.kernel.org/alsa-devel/[email protected]/

I will apply that fix from today (until it appears in the sound-asoc
tree).

--
Cheers,
Stephen Rothwell


Attachments:
(No filename) (499.00 B)
OpenPGP digital signature