Skip to content

RFC Current strategy is to use right/left shift to implement div/mult

Mauro Condarelli u-boot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v2 RFC Latest1 patch 0 repliesNew

Changes in v2 from the cover letter

- replace division with right shift (Daniel Schwierzeck).
- remove vocore2-specific change (Daniel Schwierzeck).
- add warning to Kconfig about CONFIG_SYS_MALLOC_LEN (Tom Rini).

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/1Fix missing __udivdi3 in SquashFS implementation.fs/squashfs/Kconfig fs/squashfs/sqfs.c fs/squashfs/sqfs_inode.c+20 -183 replies
1/1Fix missing __udivdi3 in SquashFS implementation.+0 -00 replies
1/1Fix missing __udivdi3 in SquashFS implementation.+0 -01 reply
1/1Fix missing __udivdi3 in SquashFS implementation.+0 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [RFC PATCH v2 0/1] Current strategy is to use right/left shift to implement div/mult

this work *only* under the assumption block-size is always a power of 2; I was unable to find where it is enforced.

Alternative strategy would be to use directly the lower-level do_div(), or the lldiv() wrapper instead.

Please review because I did not find a place where it is enforced that struct blk_desc blksz is a a power of 2 and thus using log2blksz is actually correct.

Changes in v2:
- replace division with right shift (Daniel Schwierzeck).
- remove vocore2-specific change (Daniel Schwierzeck).
- add warning to Kconfig about CONFIG_SYS_MALLOC_LEN (Tom Rini).

Mauro Condarelli (1):
Fix missing __udivdi3 in SquashFS implementation.

 fs/squashfs/Kconfig      |  2 ++
 fs/squashfs/sqfs.c       | 30 +++++++++++++++---------------
 fs/squashfs/sqfs_inode.c |  6 +++---
 3 files changed, 20 insertions(+), 18 deletions(-)
Signature · 1 line
2.25.1