Skip to content

Commit 7c20c39

Browse files
committed
Change function return type
1 parent 11e7a46 commit 7c20c39

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

stm32h7/littlefs_shim.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ const struct lfs_config cfg = {
9191
.metadata_max = 0,
9292
.inline_max = -1};
9393

94-
int lfsshim_mount(lfs_t *lfs, SD_HandleTypeDef *hsd, uint32_t first_block_offset) {
94+
w_status_t lfsshim_mount(lfs_t *lfs, SD_HandleTypeDef *hsd, uint32_t first_block_offset) {
9595
memset(lfs, 0, sizeof(lfs_t));
9696

9797
lfsshim_hsd = hsd;
@@ -101,10 +101,10 @@ int lfsshim_mount(lfs_t *lfs, SD_HandleTypeDef *hsd, uint32_t first_block_offset
101101
return W_IO_ERROR;
102102
}
103103

104-
return 0; // success
104+
return W_SUCCESS;
105105
}
106106

107-
int lfsshim_mount_mbr(lfs_t *lfs, SD_HandleTypeDef *hsd) {
107+
w_status_t lfsshim_mount_mbr(lfs_t *lfs, SD_HandleTypeDef *hsd) {
108108
uint8_t mbr_sector[512];
109109

110110
HAL_StatusTypeDef hal = HAL_SD_ReadBlocks(hsd, mbr_sector, 0, 1, 50U);
@@ -121,5 +121,5 @@ int lfsshim_mount_mbr(lfs_t *lfs, SD_HandleTypeDef *hsd) {
121121
if (lfsshim_mount(lfs, hsd, first_block_offset) != 0) {
122122
return W_IO_ERROR;
123123
}
124-
return 0;
124+
return W_SUCCESS;
125125
}

0 commit comments

Comments
 (0)