mirror of
https://github.com/apache/nuttx.git
synced 2026-06-07 17:33:08 +08:00
fs/directory: update readdir interface for all filesystem
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
This commit is contained in:
@@ -321,12 +321,6 @@ struct fs_dirent_s
|
||||
#endif
|
||||
#endif /* !CONFIG_DISABLE_MOUNTPOINT */
|
||||
} u;
|
||||
|
||||
/* In any event, this the actual struct dirent that is returned by
|
||||
* readdir
|
||||
*/
|
||||
|
||||
struct dirent fd_dir; /* Populated when readdir is called */
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
#include <time.h>
|
||||
#include <dirent.h>
|
||||
|
||||
#include <nuttx/mutex.h>
|
||||
#include <nuttx/semaphore.h>
|
||||
@@ -305,7 +306,7 @@ struct mountpt_operations
|
||||
int (*closedir)(FAR struct inode *mountpt,
|
||||
FAR struct fs_dirent_s *dir);
|
||||
int (*readdir)(FAR struct inode *mountpt,
|
||||
FAR struct fs_dirent_s *dir);
|
||||
FAR struct fs_dirent_s *dir, FAR struct dirent *entry);
|
||||
int (*rewinddir)(FAR struct inode *mountpt,
|
||||
FAR struct fs_dirent_s *dir);
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@ struct procfs_operations
|
||||
int (*opendir)(FAR const char *relpath,
|
||||
FAR struct fs_dirent_s *dir);
|
||||
int (*closedir)(FAR struct fs_dirent_s *dir);
|
||||
int (*readdir)(FAR struct fs_dirent_s *dir);
|
||||
int (*readdir)(FAR struct fs_dirent_s *dir, FAR struct dirent *entry);
|
||||
int (*rewinddir)(FAR struct fs_dirent_s *dir);
|
||||
|
||||
/* Operations on paths */
|
||||
|
||||
Reference in New Issue
Block a user