Page 1 of 9
Kernel 5.13
Posted: Tue Apr 27, 2021 4:02 pm
by xeno74
Hi All,
The Linux
5.13 merge window is open.
Happy testing!
New:
Download:
linux-image-5.13-alpha1-X1000_X5000.tar.gz
Please test the kernels.
Thanks,
Christian
Re: Kernel 5.13
Posted: Tue Apr 27, 2021 7:25 pm
by kilaueabart
Hate to get my computer "-dirty" again, and 513 sounds kind of unlucky, but I'm giving it a go and so far so good.
Re: Kernel 5.13
Posted: Wed Apr 28, 2021 3:12 am
by xeno74
kilaueabart wrote: ↑Tue Apr 27, 2021 7:25 pm
Hate to get my computer "-dirty" again, and 513 sounds kind of unlucky, but I'm giving it a go and so far so good.
Thank you for testing!
Re: Kernel 5.13
Posted: Fri Apr 30, 2021 12:22 pm
by xeno74
Hi All,
I compiled the latest Git kernel today. Unfortunately this kernel doesn't boot on the X5000 and X1000 anymore. It boots in a virtual e5500 QEMU machine.
I bisected today.
-
-
Code: Select all
git bisect good 9f4ad9e425a1d3b6a34617b8ea226d56a119a717
(Good: Linux 5.12)
-
Code: Select all
git bisect bad 9d31d2338950293ec19d9b095fbaa9030899dcb4
(Bad: Merge tag 'net-next-5.13' -- 2021-04-29 11:57:23)
- git bisect good
- git bisect bad
- git bisect bad
- git bisect bad
- git bisect bad
- git bisect bad
- git bisect bad
- git bisect bad
- git bisect bad
- git bisect bad
- git bisect good
- git bisect good
- git bisect bad
- git bisect bad
Result:
434fb1e7444a2efc3a4ebd950c7f771ebfcffa31 is the first bad commit.
Code: Select all
Author: Gustavo A. R. Silva <gustavoars@kernel.org>
Date: Wed Feb 10 17:49:27 2021 -0600
drm/radeon/nislands_smc.h: Replace one-element array with flexible-array member in struct NISLANDS_SMC_SWSTATE
There is a regular need in the kernel to provide a way to declare having
a dynamically sized set of trailing elements in a structure. Kernel code
should always use “flexible array members”[1] for these cases. The older
style of one-element or zero-length arrays should no longer be used[2].
Use flexible-array member in struct NISLANDS_SMC_SWSTATE, instead of
one-element array.
Also, this helps with the ongoing efforts to enable -Warray-bounds by
fixing the following warnings:
drivers/gpu/drm/radeon/ni_dpm.c: In function ‘ni_convert_power_state_to_smc’:
drivers/gpu/drm/radeon/ni_dpm.c:2521:20: warning: array subscript 1 is above array bounds of ‘NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’ {aka ‘struct NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’} [-Warray-bounds]
2521 | smc_state->levels[i].dpm2.MaxPS =
| ~~~~~~~~~~~~~~~~~^~~
drivers/gpu/drm/radeon/ni_dpm.c:2523:20: warning: array subscript 1 is above array bounds of ‘NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’ {aka ‘struct NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’} [-Warray-bounds]
2523 | smc_state->levels[i].dpm2.NearTDPDec = NISLANDS_DPM2_NEAR_TDP_DEC;
| ~~~~~~~~~~~~~~~~~^~~
drivers/gpu/drm/radeon/ni_dpm.c:2524:20: warning: array subscript 1 is above array bounds of ‘NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’ {aka ‘struct NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’} [-Warray-bounds]
2524 | smc_state->levels[i].dpm2.AboveSafeInc = NISLANDS_DPM2_ABOVE_SAFE_INC;
| ~~~~~~~~~~~~~~~~~^~~
drivers/gpu/drm/radeon/ni_dpm.c:2525:20: warning: array subscript 1 is above array bounds of ‘NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’ {aka ‘struct NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’} [-Warray-bounds]
2525 | smc_state->levels[i].dpm2.BelowSafeInc = NISLANDS_DPM2_BELOW_SAFE_INC;
| ~~~~~~~~~~~~~~~~~^~~
drivers/gpu/drm/radeon/ni_dpm.c:2526:35: warning: array subscript 1 is above array bounds of ‘NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’ {aka ‘struct NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’} [-Warray-bounds]
2526 | smc_state->levels[i].stateFlags |=
| ^~
drivers/gpu/drm/radeon/ni_dpm.c:2526:35: warning: array subscript 1 is above array bounds of ‘NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’ {aka ‘struct NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’} [-Warray-bounds]
2526 | smc_state->levels[i].stateFlags |=
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
2527 | ((i != (state->performance_level_count - 1)) && power_boost_limit) ?
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2528 | PPSMC_STATEFLAG_POWERBOOST : 0;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/radeon/ni_dpm.c:2442:20: warning: array subscript 1 is above array bounds of ‘NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’ {aka ‘struct NISLANDS_SMC_HW_PERFORMANCE_LEVEL[1]’} [-Warray-bounds]
2442 | smc_state->levels[i + 1].aT = cpu_to_be32(a_t);
[1] https://en.wikipedia.org/wiki/Flexible_array_member
[2] https://www.kernel.org/doc/html/v5.9/process/deprecated.html#zero-length-and-one-element-arrays
Link: https://github.com/KSPP/linux/issues/79
Link: https://github.com/KSPP/linux/issues/109
Build-tested-by: kernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/lkml/6023ed54.BfIY+9Uz81I6nq19%25lkp@intel.com/
Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
:040000 040000 825941c1622038715917db88900263261697ff43 44e16f7b0c4f28a6ca1fb7cc71a6d6a7a9db668f M drivers
I was able to revert the first bad commit.
Code: Select all
git revert 434fb1e7444a2efc3a4ebd950c7f771ebfcffa31
Output:
Code: Select all
[master 437344379819] Revert "drm/radeon/nislands_smc.h: Replace one-element array with flexible-array member in struct NISLANDS_SMC_SWSTATE"
1 file changed, 5 insertions(+), 5 deletions(-)
After a new compiling, the kernel boots without any problems.
I created a patch for reverting the bad commit:
Code: Select all
diff -rupN a/drivers/gpu/drm/radeon/nislands_smc.h b/drivers/gpu/drm/radeon/nislands_smc.h
--- a/drivers/gpu/drm/radeon/nislands_smc.h 2021-04-30 12:53:11.426435827 +0200
+++ b/drivers/gpu/drm/radeon/nislands_smc.h 2021-04-30 12:52:35.298525162 +0200
@@ -134,11 +134,11 @@ typedef struct NISLANDS_SMC_HW_PERFORMAN
struct NISLANDS_SMC_SWSTATE
{
- uint8_t flags;
- uint8_t levelCount;
- uint8_t padding2;
- uint8_t padding3;
- NISLANDS_SMC_HW_PERFORMANCE_LEVEL levels[];
+ uint8_t flags;
+ uint8_t levelCount;
+ uint8_t padding2;
+ uint8_t padding3;
+ NISLANDS_SMC_HW_PERFORMANCE_LEVEL levels[1];
};
typedef struct NISLANDS_SMC_SWSTATE NISLANDS_SMC_SWSTATE;
The kernel compiles and boots with this patch on my X1000 and X5000.
Cheers,
Christian
Re: Kernel 5.13
Posted: Fri Apr 30, 2021 3:02 pm
by xeno74
Hi All,
I released the
second alpha of kernel
5.13 for the X1000 and X5000 today.
New:
Download:
linux-image-5.13-alpha2-X1000_X5000.tar.gz
Please test the kernels.
Thanks,
Christian
Re: Kernel 5.13
Posted: Fri Apr 30, 2021 3:35 pm
by xeno74
The same commit is also available for SI graphics cards.
Linux Git
Please also test the alpha2 with Radeon SI graphics cards. It could be, that your AmigaOne doesn't boot. I only patched the alpha2 for NI Radeons.
Re: Kernel 5.13
Posted: Fri Apr 30, 2021 6:35 pm
by kilaueabart
I think maybe I have an SI card, but too senile to remember for sure, or how to find out. In any event, 5.13-a2 seems to be working as it should.
Re: Kernel 5.13
Posted: Sat May 01, 2021 10:17 am
by xeno74
kilaueabart wrote: ↑Fri Apr 30, 2021 6:35 pm
I think maybe I have an SI card, but too senile to remember for sure, or how to find out. In any event, 5.13-a2 seems to be working as it should.
Thanks a lot for testing the alpha2! You can figure out your graphics card with
lspci.
@Skateman
Does the alpha2 boots on your X5000?
Re: Kernel 5.13
Posted: Sat May 01, 2021 3:54 pm
by acefnq
5.13a2 boots and runs fine for me.
Thanks
ace
Re: Kernel 5.13
Posted: Sat May 01, 2021 4:58 pm
by xeno74
acefnq wrote: ↑Sat May 01, 2021 3:54 pm
5.13a2 boots and runs fine for me.
Thanks
ace
Hi Ace,
Great! Thank you for testing!
Which graphics card is installed in your X5000?
Thanks,
Christian