mbox series

[00/10] sparc64: Fix CPU online bug and warning fixes

Message ID 20240330-sparc64-warnings-v1-0-37201023ee2f@ravnborg.org
Headers show
Series sparc64: Fix CPU online bug and warning fixes | expand

Message

Sam Ravnborg via B4 Relay March 30, 2024, 9:57 a.m. UTC
Nick Bowler reported that sparc64 failed to bring all his CPU's online,
and that turned out to be an easy fix.

The sparc64 build was rather noisy with a lot of warnings which had
irritated me enough to go ahead and fix them.
With this set of patches my arch/sparc/ is almost warning free for
all{no,yes,mod}config + defconfig builds.

There is one warning about "clone3 not implemented", which I have ignored.

The warning fixes hides the fact that sparc64 is not yet y2038 prepared,
and it would be preferable if someone knowledgeable would fix this
poperly.

All fixes looks like 6.9 material to me.

	Sam 

---
Sam Ravnborg (10):
      sparc64: Fix prototype warning for init_vdso_image
      sparc64: Fix prototype warnings in traps_64.c
      sparc64: Fix prototype warning for vmemmap_free
      sparc64: Fix prototype warning for alloc_irqstack_bootmem
      sparc64: Fix prototype warning for uprobe_trap
      sparc64: Fix prototype warning for dma_4v_iotsb_bind
      sparc64: Fix prototype warnings in adi_64.c
      sparc64: Fix prototype warning for sched_clock
      sparc64: Fix number of online CPUs
      sparc64: Fix prototype warnings for vdso

 arch/sparc/include/asm/smp_64.h  |  2 --
 arch/sparc/include/asm/vdso.h    | 10 ++++++++++
 arch/sparc/kernel/adi_64.c       | 14 +++++++-------
 arch/sparc/kernel/kernel.h       |  4 ++++
 arch/sparc/kernel/pci_sun4v.c    |  6 +++---
 arch/sparc/kernel/prom_64.c      |  4 +++-
 arch/sparc/kernel/setup_64.c     |  3 +--
 arch/sparc/kernel/smp_64.c       | 14 --------------
 arch/sparc/kernel/time_64.c      |  1 +
 arch/sparc/kernel/traps_64.c     | 10 +++++-----
 arch/sparc/kernel/uprobes.c      |  2 ++
 arch/sparc/mm/init_64.c          |  5 -----
 arch/sparc/vdso/vclock_gettime.c |  1 +
 arch/sparc/vdso/vma.c            |  5 +++--
 14 files changed, 40 insertions(+), 41 deletions(-)
---
base-commit: 84b76d05828a1909e20d0f66553b876b801f98c8
change-id: 20240329-sparc64-warnings-668cc90ef53b

Best regards,

Comments

Arnd Bergmann March 30, 2024, 10:19 a.m. UTC | #1
On Sat, Mar 30, 2024, at 10:57, Sam Ravnborg via B4 Relay wrote:
> Nick Bowler reported that sparc64 failed to bring all his CPU's online,
> and that turned out to be an easy fix.
>
> The sparc64 build was rather noisy with a lot of warnings which had
> irritated me enough to go ahead and fix them.
> With this set of patches my arch/sparc/ is almost warning free for
> all{no,yes,mod}config + defconfig builds.

Patches 1-9 look good to me,

Acked-by: Arnd Bergmann <arnd@arndb.de>

> There is one warning about "clone3 not implemented", which I have ignored.
>
> The warning fixes hides the fact that sparc64 is not yet y2038 prepared,
> and it would be preferable if someone knowledgeable would fix this
> poperly.

The clone3 bug has been around for ages, it's probably not even that
hard to fix and just needs a little bit of testing.

If anyone wants to work on the time64 support for the vdso, I can
explain the details for how it's done.

Both of these are real bugs that should be addressed, unlike
the other warning fixes that are mostly cosmetic aside from
allowing the build with CONFIG_WERROR=y.

     Arnd
Sam Ravnborg March 30, 2024, 6:39 p.m. UTC | #2
Hi Arnd,

On Sat, Mar 30, 2024 at 11:19:37AM +0100, Arnd Bergmann wrote:
> On Sat, Mar 30, 2024, at 10:57, Sam Ravnborg via B4 Relay wrote:
> > Nick Bowler reported that sparc64 failed to bring all his CPU's online,
> > and that turned out to be an easy fix.
> >
> > The sparc64 build was rather noisy with a lot of warnings which had
> > irritated me enough to go ahead and fix them.
> > With this set of patches my arch/sparc/ is almost warning free for
> > all{no,yes,mod}config + defconfig builds.
> 
> Patches 1-9 look good to me,
> 
> Acked-by: Arnd Bergmann <arnd@arndb.de>
Thanks!

> 
> > There is one warning about "clone3 not implemented", which I have ignored.
> >
> > The warning fixes hides the fact that sparc64 is not yet y2038 prepared,
> > and it would be preferable if someone knowledgeable would fix this
> > poperly.
> 
> The clone3 bug has been around for ages, it's probably not even that
> hard to fix and just needs a little bit of testing.
I looked briefly and it involves a better understanding of the window
register manipulation than what I have today.

> 
> If anyone wants to work on the time64 support for the vdso, I can
> explain the details for how it's done.
I am happy to type the patches but need to rely on others for testing.
Anything to help me get started would be super.

	Sam
Andreas Larsson April 22, 2024, 1:11 p.m. UTC | #3
On 2024-03-30 19:39, Sam Ravnborg wrote:
> Hi Arnd,
> 
> On Sat, Mar 30, 2024 at 11:19:37AM +0100, Arnd Bergmann wrote:
>> On Sat, Mar 30, 2024, at 10:57, Sam Ravnborg via B4 Relay wrote:
>>> Nick Bowler reported that sparc64 failed to bring all his CPU's online,
>>> and that turned out to be an easy fix.
>>>
>>> The sparc64 build was rather noisy with a lot of warnings which had
>>> irritated me enough to go ahead and fix them.
>>> With this set of patches my arch/sparc/ is almost warning free for
>>> all{no,yes,mod}config + defconfig builds.
>>
>> Patches 1-9 look good to me,
>>
>> Acked-by: Arnd Bergmann <arnd@arndb.de>
> Thanks!

Picking up patches 1-8 to my for-next with

Reviewed-by: Andreas Larsson <andreas@gaisler.com>
Tested-by: Andreas Larsson <andreas@gaisler.com>

and, having run it only on single core qemu, patch 9 with

Reviewed-by: Andreas Larsson <andreas@gaisler.com>

>>
>>> There is one warning about "clone3 not implemented", which I have ignored.
>>>
>>> The warning fixes hides the fact that sparc64 is not yet y2038 prepared,
>>> and it would be preferable if someone knowledgeable would fix this
>>> poperly.
>>
>> The clone3 bug has been around for ages, it's probably not even that
>> hard to fix and just needs a little bit of testing.
> I looked briefly and it involves a better understanding of the window
> register manipulation than what I have today.
> 
>>
>> If anyone wants to work on the time64 support for the vdso, I can
>> explain the details for how it's done.
>
> I am happy to type the patches but need to rely on others for testing.
> Anything to help me get started would be super.

I'm not picking up patch 10 at the moment, but it would be really nice
to get allmodconfig builds to not fail due to prototype Werrors.

Thanks,
Andreas