modlib:Allow loading elf from block devices

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
This commit is contained in:
anjiahao
2024-10-12 12:29:06 +08:00
committed by Xiang Xiao
parent 434442d707
commit 4f92d7aafd
-8
View File
@@ -70,14 +70,6 @@ static inline int modlib_fileinfo(FAR struct mod_loadinfo_s *loadinfo)
return -errval;
}
/* Verify that it is a regular file */
if (!S_ISREG(buf.st_mode))
{
berr("ERROR: Not a regular file. mode: %d\n", buf.st_mode);
return -ENOENT;
}
/* Return some stats info of the file in the loadinfo structure */
loadinfo->filelen = buf.st_size;