[ Upstream commit 3884f03edd34887514a0865a80769cd5362d5c3b ]
mtd-ram can potentially be larger than 4GB. get_bitmask_order() uses
fls() that is not guaranteed to work with values larger than 32-bit.
Specifically on aarch64 fls() returns 0 when all 32 LSB bits are clear.
Use fls64() instead.
Fixes: ba32ce95cbd987 ("mtd: maps: Merge gpio-addr-flash.c into physmap-core.c")
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/9fbf3664ce00f8b07867f1011834015f21d162a5.1707388458.git.baruch@tkos.co.il
Signed-off-by: Sasha Levin <sashal@kernel.org>
|
||
|---|---|---|
| .. | ||
| amd76xrom.c | ||
| cfi_flagadm.c | ||
| ck804xrom.c | ||
| dc21285.c | ||
| esb2rom.c | ||
| ichxrom.c | ||
| impa7.c | ||
| intel_vr_nor.c | ||
| Kconfig | ||
| l440gx.c | ||
| lantiq-flash.c | ||
| Makefile | ||
| map_funcs.c | ||
| netsc520.c | ||
| nettel.c | ||
| pci.c | ||
| pcmciamtd.c | ||
| physmap-bt1-rom.c | ||
| physmap-bt1-rom.h | ||
| physmap-core.c | ||
| physmap-gemini.c | ||
| physmap-gemini.h | ||
| physmap-ixp4xx.c | ||
| physmap-ixp4xx.h | ||
| physmap-versatile.c | ||
| physmap-versatile.h | ||
| pismo.c | ||
| plat-ram.c | ||
| pxa2xx-flash.c | ||
| sa1100-flash.c | ||
| sbc_gxx.c | ||
| sc520cdp.c | ||
| scb2_flash.c | ||
| scx200_docflash.c | ||
| solutionengine.c | ||
| sun_uflash.c | ||
| ts5500_flash.c | ||
| tsunami_flash.c | ||
| uclinux.c | ||
| vmu-flash.c | ||