All of lore.kernel.org
 help / color / mirror / Atom feed
* next-20200514 - build issue in drivers/md/dm-zoned-target.c
@ 2020-05-16 11:19 Valdis Klētnieks
  2020-05-16 19:07   ` James Bottomley
  2020-05-18  6:25 ` Hannes Reinecke
  0 siblings, 2 replies; 6+ messages in thread
From: Valdis Klētnieks @ 2020-05-16 11:19 UTC (permalink / raw)
  To: Hannes Reinecke, Alasdair Kergon, Mike Snitzer; +Cc: dm-devel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1441 bytes --]

Am seeing a build error in next-0514.  -0420 built OK.
building a 'make allmodconfig' on a RPi4 in 32-bit mode.

  MODPOST 7575 modules
ERROR: modpost: "__aeabi_uldivmod" [drivers/md/dm-zoned.ko] undefined!

objdump and 'make drivers/md/dm-zoned-target.s' tells
me that the problem is in function dmz_fixup_devices(), near here:

@ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
        ldr     r0, [r6, #56]   @ reg_dev_166->capacity, reg_dev_166->capacity
        adds    r1, r3, r1      @ tmp316, _227, reg_dev_166->capacity
        adc     r0, r2, r0      @ tmp315, _227, reg_dev_166->capacity
        subs    r1, r1, #1      @, tmp316,
@ drivers/md/dm-zoned-target.c:805:             reg_dev->zone_nr_sectors = zoned_dev->zone_nr_sectors;
        strd    r2, [r6, #80]   @, reg_dev,
@ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
        sbc     r0, r0, #0      @, tmp315,
        bl      __aeabi_uldivmod                @
@ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
        str     r1, [r6, #64]   @ tmp306, reg_dev_166->nr_zones

git blame points at this commit:

commit 70978208ec91d798066f4c291bc98ff914bea222
Author: Hannes Reinecke <hare@suse.de>
Date:   Mon May 11 10:24:30 2020 +0200

    dm zoned: metadata version 2

Reverting that commit lets the build complete.



[-- Attachment #2: Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [dm-devel] next-20200514 - build issue in drivers/md/dm-zoned-target.c
  2020-05-16 11:19 next-20200514 - build issue in drivers/md/dm-zoned-target.c Valdis Klētnieks
@ 2020-05-16 19:07   ` James Bottomley
  2020-05-18  6:25 ` Hannes Reinecke
  1 sibling, 0 replies; 6+ messages in thread
From: James Bottomley @ 2020-05-16 19:07 UTC (permalink / raw)
  To: Valdis Klētnieks, Hannes Reinecke, Alasdair Kergon, Mike Snitzer
  Cc: dm-devel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1721 bytes --]

On Sat, 2020-05-16 at 07:19 -0400, Valdis Klētnieks wrote:
> Am seeing a build error in next-0514.  -0420 built OK.
> building a 'make allmodconfig' on a RPi4 in 32-bit mode.
> 
>   MODPOST 7575 modules
> ERROR: modpost: "__aeabi_uldivmod" [drivers/md/dm-zoned.ko]
> undefined!
> 
> objdump and 'make drivers/md/dm-zoned-target.s' tells
> me that the problem is in function dmz_fixup_devices(), near here:
> 
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones =
> DIV_ROUND_UP(reg_dev->capacity,
>         ldr     r0, [r6, #56]   @ reg_dev_166->capacity, reg_dev_166-
> >capacity
>         adds    r1, r3, r1      @ tmp316, _227, reg_dev_166->capacity
>         adc     r0, r2, r0      @ tmp315, _227, reg_dev_166->capacity
>         subs    r1, r1, #1      @, tmp316,
> @ drivers/md/dm-zoned-target.c:805:             reg_dev-
> >zone_nr_sectors = zoned_dev->zone_nr_sectors;
>         strd    r2, [r6, #80]   @, reg_dev,
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones =
> DIV_ROUND_UP(reg_dev->capacity,
>         sbc     r0, r0, #0      @, tmp315,
>         bl      __aeabi_uldivmod                @
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones =
> DIV_ROUND_UP(reg_dev->capacity,
>         str     r1, [r6, #64]   @ tmp306, reg_dev_166->nr_zones
> 
> git blame points at this commit:
> 
> commit 70978208ec91d798066f4c291bc98ff914bea222
> Author: Hannes Reinecke <hare@suse.de>
> Date:   Mon May 11 10:24:30 2020 +0200
> 
>     dm zoned: metadata version 2
> 
> Reverting that commit lets the build complete.

That's because the DIV_ROUND_UP in the patch should actually be
DIV_ROUND_UP_SECTOR_T I think.

James

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: next-20200514 - build issue in drivers/md/dm-zoned-target.c
@ 2020-05-16 19:07   ` James Bottomley
  0 siblings, 0 replies; 6+ messages in thread
From: James Bottomley @ 2020-05-16 19:07 UTC (permalink / raw)
  To: Valdis Klētnieks, Hannes Reinecke, Alasdair Kergon, Mike Snitzer
  Cc: dm-devel, linux-kernel


[-- Attachment #1.1: Type: text/plain, Size: 1721 bytes --]

On Sat, 2020-05-16 at 07:19 -0400, Valdis Klētnieks wrote:
> Am seeing a build error in next-0514.  -0420 built OK.
> building a 'make allmodconfig' on a RPi4 in 32-bit mode.
> 
>   MODPOST 7575 modules
> ERROR: modpost: "__aeabi_uldivmod" [drivers/md/dm-zoned.ko]
> undefined!
> 
> objdump and 'make drivers/md/dm-zoned-target.s' tells
> me that the problem is in function dmz_fixup_devices(), near here:
> 
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones =
> DIV_ROUND_UP(reg_dev->capacity,
>         ldr     r0, [r6, #56]   @ reg_dev_166->capacity, reg_dev_166-
> >capacity
>         adds    r1, r3, r1      @ tmp316, _227, reg_dev_166->capacity
>         adc     r0, r2, r0      @ tmp315, _227, reg_dev_166->capacity
>         subs    r1, r1, #1      @, tmp316,
> @ drivers/md/dm-zoned-target.c:805:             reg_dev-
> >zone_nr_sectors = zoned_dev->zone_nr_sectors;
>         strd    r2, [r6, #80]   @, reg_dev,
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones =
> DIV_ROUND_UP(reg_dev->capacity,
>         sbc     r0, r0, #0      @, tmp315,
>         bl      __aeabi_uldivmod                @
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones =
> DIV_ROUND_UP(reg_dev->capacity,
>         str     r1, [r6, #64]   @ tmp306, reg_dev_166->nr_zones
> 
> git blame points at this commit:
> 
> commit 70978208ec91d798066f4c291bc98ff914bea222
> Author: Hannes Reinecke <hare@suse.de>
> Date:   Mon May 11 10:24:30 2020 +0200
> 
>     dm zoned: metadata version 2
> 
> Reverting that commit lets the build complete.

That's because the DIV_ROUND_UP in the patch should actually be
DIV_ROUND_UP_SECTOR_T I think.

James

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: next-20200514 - build issue in drivers/md/dm-zoned-target.c
  2020-05-16 11:19 next-20200514 - build issue in drivers/md/dm-zoned-target.c Valdis Klētnieks
  2020-05-16 19:07   ` James Bottomley
@ 2020-05-18  6:25 ` Hannes Reinecke
  2020-05-18 16:44   ` Mike Snitzer
  1 sibling, 1 reply; 6+ messages in thread
From: Hannes Reinecke @ 2020-05-18  6:25 UTC (permalink / raw)
  To: Valdis Klētnieks, Alasdair Kergon, Mike Snitzer
  Cc: dm-devel, linux-kernel

On 5/16/20 1:19 PM, Valdis Klētnieks wrote:
> Am seeing a build error in next-0514.  -0420 built OK.
> building a 'make allmodconfig' on a RPi4 in 32-bit mode.
> 
>    MODPOST 7575 modules
> ERROR: modpost: "__aeabi_uldivmod" [drivers/md/dm-zoned.ko] undefined!
> 
> objdump and 'make drivers/md/dm-zoned-target.s' tells
> me that the problem is in function dmz_fixup_devices(), near here:
> 
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
>          ldr     r0, [r6, #56]   @ reg_dev_166->capacity, reg_dev_166->capacity
>          adds    r1, r3, r1      @ tmp316, _227, reg_dev_166->capacity
>          adc     r0, r2, r0      @ tmp315, _227, reg_dev_166->capacity
>          subs    r1, r1, #1      @, tmp316,
> @ drivers/md/dm-zoned-target.c:805:             reg_dev->zone_nr_sectors = zoned_dev->zone_nr_sectors;
>          strd    r2, [r6, #80]   @, reg_dev,
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
>          sbc     r0, r0, #0      @, tmp315,
>          bl      __aeabi_uldivmod                @
> @ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
>          str     r1, [r6, #64]   @ tmp306, reg_dev_166->nr_zones
> 
> git blame points at this commit:
> 
> commit 70978208ec91d798066f4c291bc98ff914bea222
> Author: Hannes Reinecke <hare@suse.de>
> Date:   Mon May 11 10:24:30 2020 +0200
> 
>      dm zoned: metadata version 2
> 
> Reverting that commit lets the build complete.
> 
> 
I thought I've send a patch to fix that up; DIV_ROUND_UP() needs to be 
changed to DIV_ROUND_UP_ULL().
I'll be checking and will be sending a patch if necessary.

Cheers,

Hannes
-- 
Dr. Hannes Reinecke            Teamlead Storage & Networking
hare@suse.de                               +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: next-20200514 - build issue in drivers/md/dm-zoned-target.c
  2020-05-18  6:25 ` Hannes Reinecke
@ 2020-05-18 16:44   ` Mike Snitzer
  2020-05-18 20:22     ` Valdis Klētnieks
  0 siblings, 1 reply; 6+ messages in thread
From: Mike Snitzer @ 2020-05-18 16:44 UTC (permalink / raw)
  To: Hannes Reinecke
  Cc: Valdis Klētnieks, Alasdair Kergon, dm-devel, linux-kernel

On Mon, May 18 2020 at  2:25am -0400,
Hannes Reinecke <hare@suse.de> wrote:

> On 5/16/20 1:19 PM, Valdis Klētnieks wrote:
> >Am seeing a build error in next-0514.  -0420 built OK.
> >building a 'make allmodconfig' on a RPi4 in 32-bit mode.
> >
> >   MODPOST 7575 modules
> >ERROR: modpost: "__aeabi_uldivmod" [drivers/md/dm-zoned.ko] undefined!
> >
> >objdump and 'make drivers/md/dm-zoned-target.s' tells
> >me that the problem is in function dmz_fixup_devices(), near here:
> >
> >@ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
> >         ldr     r0, [r6, #56]   @ reg_dev_166->capacity, reg_dev_166->capacity
> >         adds    r1, r3, r1      @ tmp316, _227, reg_dev_166->capacity
> >         adc     r0, r2, r0      @ tmp315, _227, reg_dev_166->capacity
> >         subs    r1, r1, #1      @, tmp316,
> >@ drivers/md/dm-zoned-target.c:805:             reg_dev->zone_nr_sectors = zoned_dev->zone_nr_sectors;
> >         strd    r2, [r6, #80]   @, reg_dev,
> >@ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
> >         sbc     r0, r0, #0      @, tmp315,
> >         bl      __aeabi_uldivmod                @
> >@ drivers/md/dm-zoned-target.c:806:             reg_dev->nr_zones = DIV_ROUND_UP(reg_dev->capacity,
> >         str     r1, [r6, #64]   @ tmp306, reg_dev_166->nr_zones
> >
> >git blame points at this commit:
> >
> >commit 70978208ec91d798066f4c291bc98ff914bea222
> >Author: Hannes Reinecke <hare@suse.de>
> >Date:   Mon May 11 10:24:30 2020 +0200
> >
> >     dm zoned: metadata version 2
> >
> >Reverting that commit lets the build complete.
> >
> >
> I thought I've send a patch to fix that up; DIV_ROUND_UP() needs to
> be changed to DIV_ROUND_UP_ULL().
> I'll be checking and will be sending a patch if necessary.

Unless I'm missing something it was fixed up with this commit last
wednesday (13th):

https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git/commit/?h=dm-5.8&id=81a3a1453ec4e5da081e1395732801a600feb352



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: next-20200514 - build issue in drivers/md/dm-zoned-target.c
  2020-05-18 16:44   ` Mike Snitzer
@ 2020-05-18 20:22     ` Valdis Klētnieks
  0 siblings, 0 replies; 6+ messages in thread
From: Valdis Klētnieks @ 2020-05-18 20:22 UTC (permalink / raw)
  To: Mike Snitzer; +Cc: Hannes Reinecke, Alasdair Kergon, dm-devel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 577 bytes --]

On Mon, 18 May 2020 12:44:49 -0400, Mike Snitzer said:

> Unless I'm missing something it was fixed up with this commit last
> wednesday (13th):
>
> https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git/commit/?h=dm-5.8&id=81a3a1453ec4e5da081e1395732801a600feb352

That says:

author	Nathan Chancellor <natechancellor@gmail.com>	2020-05-13 01:45:22 -0700
committer	Mike Snitzer <snitzer@redhat.com>	2020-05-15 10:29:39 -0400

So it didn't make it into next-0514, which is why I got bit by it.  It's in today's linux-next
and life is good. :)

[-- Attachment #2: Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-05-18 20:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-16 11:19 next-20200514 - build issue in drivers/md/dm-zoned-target.c Valdis Klētnieks
2020-05-16 19:07 ` [dm-devel] " James Bottomley
2020-05-16 19:07   ` James Bottomley
2020-05-18  6:25 ` Hannes Reinecke
2020-05-18 16:44   ` Mike Snitzer
2020-05-18 20:22     ` Valdis Klētnieks

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.