All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v2 0/1] Current strategy is to use right/left shift to implement div/mult
@ 2020-09-30 15:45 Mauro Condarelli
  2020-09-30 15:45 ` [RFC PATCH v2 1/1] Fix missing __udivdi3 in SquashFS implementation Mauro Condarelli
  0 siblings, 1 reply; 9+ messages in thread
From: Mauro Condarelli @ 2020-09-30 15:45 UTC (permalink / raw)
  To: u-boot

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(-)

-- 
2.25.1

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

end of thread, other threads:[~2020-10-01 10:17 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-30 15:45 [RFC PATCH v2 0/1] Current strategy is to use right/left shift to implement div/mult Mauro Condarelli
2020-09-30 15:45 ` [RFC PATCH v2 1/1] Fix missing __udivdi3 in SquashFS implementation Mauro Condarelli
2020-09-30 21:40   ` Daniel Schwierzeck
2020-10-01  7:28   ` Thomas Petazzoni
2020-10-01  7:59     ` Miquel Raynal
2020-10-01  8:41       ` Mauro Condarelli
2020-10-01  8:53         ` Mauro Condarelli
2020-10-01  8:56           ` Miquel Raynal
2020-10-01 10:17             ` Mauro Condarelli

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.