From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mauro Condarelli Date: Wed, 30 Sep 2020 17:45:10 +0200 Subject: [RFC PATCH v2 0/1] Current strategy is to use right/left shift to implement div/mult Message-ID: <20200930154511.630103-1-mc5686@mclink.it> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de 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