2022-08-17 22:32:19

by Sudip Mukherjee

[permalink] [raw]
Subject: build failure of next-20220817 for amdgpu

Hi All,

Not sure if it has been reported, build of next-20220817 fails with the
error:

ERROR: modpost: "cpu_smallcore_map" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!

Trying to do a git bisect to find out the offending commit.

I will be happy to test any patch or provide any extra log if needed.


--
Regards
Sudip


2022-08-18 02:09:39

by Alex Deucher

[permalink] [raw]
Subject: Re: build failure of next-20220817 for amdgpu

On Wed, Aug 17, 2022 at 6:03 PM Sudip Mukherjee (Codethink)
<[email protected]> wrote:
>
> Hi All,
>
> Not sure if it has been reported, build of next-20220817 fails with the
> error:
>
> ERROR: modpost: "cpu_smallcore_map" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
>
> Trying to do a git bisect to find out the offending commit.
>

Thanks. I don't see that symbol in the driver at all. Not sure where
it is coming from.

Alex


> I will be happy to test any patch or provide any extra log if needed.
>
>
> --
> Regards
> Sudip

2022-08-18 02:24:34

by Randy Dunlap

[permalink] [raw]
Subject: Re: build failure of next-20220817 for amdgpu



On 8/17/22 19:01, Alex Deucher wrote:
> On Wed, Aug 17, 2022 at 6:03 PM Sudip Mukherjee (Codethink)
> <[email protected]> wrote:
>>
>> Hi All,
>>
>> Not sure if it has been reported, build of next-20220817 fails with the
>> error:
>>
>> ERROR: modpost: "cpu_smallcore_map" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
>>
>> Trying to do a git bisect to find out the offending commit.
>>
>
> Thanks. I don't see that symbol in the driver at all. Not sure where
> it is coming from.
>

It's powerpc only.

Sudip, is it non-CONFIG_SMP by any chance?

>
>
>> I will be happy to test any patch or provide any extra log if needed.
>>
>>
>> --
>> Regards
>> Sudip

--
~Randy

2022-08-18 10:58:59

by Sudip Mukherjee

[permalink] [raw]
Subject: Re: build failure of next-20220817 for amdgpu

On Thu, Aug 18, 2022 at 3:09 AM Randy Dunlap <[email protected]> wrote:
>
>
>
> On 8/17/22 19:01, Alex Deucher wrote:
> > On Wed, Aug 17, 2022 at 6:03 PM Sudip Mukherjee (Codethink)
> > <[email protected]> wrote:
> >>
> >> Hi All,
> >>
> >> Not sure if it has been reported, build of next-20220817 fails with the
> >> error:
> >>
> >> ERROR: modpost: "cpu_smallcore_map" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
> >>
> >> Trying to do a git bisect to find out the offending commit.
> >>
> >
> > Thanks. I don't see that symbol in the driver at all. Not sure where
> > it is coming from.
> >
>
> It's powerpc only.
>
> Sudip, is it non-CONFIG_SMP by any chance?

Ohhh.. really sorry for the incomplete report. I should not try to
mail while travelling.

The error is seen with powerpc allmodconfig and it has CONFIG_SMP=y.

--
Regards
Sudip

2022-08-18 15:45:38

by Randy Dunlap

[permalink] [raw]
Subject: Re: build failure of next-20220817 for amdgpu



On 8/18/22 03:43, Sudip Mukherjee wrote:
> On Thu, Aug 18, 2022 at 3:09 AM Randy Dunlap <[email protected]> wrote:
>>
>>
>>
>> On 8/17/22 19:01, Alex Deucher wrote:
>>> On Wed, Aug 17, 2022 at 6:03 PM Sudip Mukherjee (Codethink)
>>> <[email protected]> wrote:
>>>>
>>>> Hi All,
>>>>
>>>> Not sure if it has been reported, build of next-20220817 fails with the
>>>> error:
>>>>
>>>> ERROR: modpost: "cpu_smallcore_map" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
>>>>
>>>> Trying to do a git bisect to find out the offending commit.
>>>>
>>>
>>> Thanks. I don't see that symbol in the driver at all. Not sure where
>>> it is coming from.
>>>
>>
>> It's powerpc only.
>>
>> Sudip, is it non-CONFIG_SMP by any chance?
>
> Ohhh.. really sorry for the incomplete report. I should not try to
> mail while travelling.
>
> The error is seen with powerpc allmodconfig and it has CONFIG_SMP=y.

OK, I see that also, but it doesn't make any sense (to me).

I did 'objdump' on the code file (amdgpu.o) and it's listed as
undefined but there are no code references to it.

--
~Randy

2022-08-18 20:04:30

by Sudip Mukherjee

[permalink] [raw]
Subject: Re: build failure of next-20220817 for amdgpu due to 7bc913085765 ("drm/amdkfd: Try to schedule bottom half on same core")

On Thu, Aug 18, 2022 at 4:10 PM Randy Dunlap <[email protected]> wrote:
>
>
>
> On 8/18/22 03:43, Sudip Mukherjee wrote:
> > On Thu, Aug 18, 2022 at 3:09 AM Randy Dunlap <[email protected]> wrote:
> >>
> >>
> >>
> >> On 8/17/22 19:01, Alex Deucher wrote:
> >>> On Wed, Aug 17, 2022 at 6:03 PM Sudip Mukherjee (Codethink)
> >>> <[email protected]> wrote:
> >>>>
> >>>> Hi All,
> >>>>
> >>>> Not sure if it has been reported, build of next-20220817 fails with the
> >>>> error:
> >>>>
> >>>> ERROR: modpost: "cpu_smallcore_map" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined!
> >>>>
> >>>> Trying to do a git bisect to find out the offending commit.
> >>>>
> >>>
> >>> Thanks. I don't see that symbol in the driver at all. Not sure where
> >>> it is coming from.
> >>>
> >>
> >> It's powerpc only.
> >>
> >> Sudip, is it non-CONFIG_SMP by any chance?
> >
> > Ohhh.. really sorry for the incomplete report. I should not try to
> > mail while travelling.
> >
> > The error is seen with powerpc allmodconfig and it has CONFIG_SMP=y.
>
> OK, I see that also, but it doesn't make any sense (to me).
>
> I did 'objdump' on the code file (amdgpu.o) and it's listed as
> undefined but there are no code references to it.

cpu_smt_mask() is called by drivers/gpu/drm/amd/amdkfd/kfd_device.c.
and cpu_smt_mask() is an inline function in
arch/powerpc/include/asm/smp.h which is doing "return
per_cpu(cpu_smallcore_map, cpu);"

So, the offending commit is 7bc913085765 ("drm/amdkfd: Try to schedule
bottom half on same core").


--
Regards
Sudip