From: chainsx Date: Mon, 3 Jul 2023 17:31:28 +0000 (+0800) Subject: fix: fix and add ums gadget(usb mass storage gadget) X-Git-Tag: accepted/tizen/unified/x/20240510.061411~69 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d43b782d700e607e23e3dfaf05142219e44c8f4d;p=platform%2Fkernel%2Fu-boot-thead.git fix: fix and add ums gadget(usb mass storage gadget) --- diff --git a/arch/riscv/include/asm/bitops.h b/arch/riscv/include/asm/bitops.h index 536629bb..57556c37 100644 --- a/arch/riscv/include/asm/bitops.h +++ b/arch/riscv/include/asm/bitops.h @@ -90,6 +90,16 @@ static inline int __test_and_clear_bit(int nr, void *addr) return retval; } +static inline int test_and_clear_bit(int nr, volatile void * addr) +{ + unsigned long flags = 0; + int out; + + out = __test_and_clear_bit(nr, addr); + + return out; +} + static inline int __test_and_change_bit(int nr, void *addr) { int mask, retval; diff --git a/configs/light_lpi4a_defconfig b/configs/light_lpi4a_defconfig index 047dd946..8d0cf4ac 100644 --- a/configs/light_lpi4a_defconfig +++ b/configs/light_lpi4a_defconfig @@ -63,6 +63,7 @@ CONFIG_MMC_SDHCI_SNPS=y CONFIG_MMC_SDHCI_SDMA=y CONFIG_CMD_MMC=y CONFIG_CMD_MMC_RPMB=y +CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_SUPPORT_EMMC_RPMB=y CONFIG_DM_MTD=y CONFIG_MTD_SPI_NAND=y @@ -82,6 +83,7 @@ CONFIG_USB_GADGET=y CONFIG_USB_GADGET_MANUFACTURER="U-Boot-THEAD" CONFIG_USB_GADGET_VENDOR_NUM=0x1234 CONFIG_USB_GADGET_PRODUCT_NUM=0x8888 +CONFIG_USB_FUNCTION_MASS_STORAGE=y # CONFIG_SPL_USE_TINY_PRINTF is not set # CONFIG_EFI_LOADER is not set # CONFIG_LIGHT_SEC_BOOT is not set