diff --git a/include/nuttx/fs/fs.h b/include/nuttx/fs/fs.h index f338d4e585098..1ef0704af54ea 100644 --- a/include/nuttx/fs/fs.h +++ b/include/nuttx/fs/fs.h @@ -30,6 +30,7 @@ #include #include +#include #include #include @@ -251,33 +252,6 @@ struct file_operations /* This structure provides information about the state of a block driver */ #ifndef CONFIG_DISABLE_MOUNTPOINT -struct geometry -{ - bool geo_available; /* true: The device is available */ - bool geo_mediachanged; /* true: The media has changed since last query */ - bool geo_writeenabled; /* true: It is okay to write to this device */ - blkcnt_t geo_nsectors; /* Number of sectors on the device */ - blksize_t geo_sectorsize; /* Size of one sector */ - - /* NULL-terminated string representing the device model */ - - char geo_model[NAME_MAX + 1]; -}; - -struct partition_info_s -{ - size_t numsectors; /* Number of sectors in the partition */ - size_t sectorsize; /* Size in bytes of a single sector */ - off_t startsector; /* Offset to the first section/block of the - * managed sub-region */ - - /* NULL-terminated string representing the name of the parent node of the - * partition. - */ - - char parent[NAME_MAX + 1]; -}; - /* This structure is provided by block devices when they register with the * system. It is used by file systems to perform filesystem transfers. It * differs from the normal driver vtable in several ways -- most notably in diff --git a/include/nuttx/fs/ioctl.h b/include/nuttx/fs/ioctl.h index 6d98dc43a9c05..aa383e7084a57 100644 --- a/include/nuttx/fs/ioctl.h +++ b/include/nuttx/fs/ioctl.h @@ -28,6 +28,8 @@ ****************************************************************************/ #include + +#include #include /**************************************************************************** @@ -757,6 +759,33 @@ * Public Type Definitions ****************************************************************************/ +struct geometry +{ + bool geo_available; /* true: The device is available */ + bool geo_mediachanged; /* true: The media has changed since last query */ + bool geo_writeenabled; /* true: It is okay to write to this device */ + blkcnt_t geo_nsectors; /* Number of sectors on the device */ + blksize_t geo_sectorsize; /* Size of one sector */ + + /* NULL-terminated string representing the device model */ + + char geo_model[NAME_MAX + 1]; +}; + +struct partition_info_s +{ + size_t numsectors; /* Number of sectors in the partition */ + size_t sectorsize; /* Size in bytes of a single sector */ + off_t startsector; /* Offset to the first section/block of the + * managed sub-region */ + + /* NULL-terminated string representing the name of the parent node of the + * partition. + */ + + char parent[NAME_MAX + 1]; +}; + struct pipe_peek_s { FAR void *buf; diff --git a/include/nuttx/streams.h b/include/nuttx/streams.h index dcf832566eba0..e07d60e1c2467 100644 --- a/include/nuttx/streams.h +++ b/include/nuttx/streams.h @@ -30,14 +30,14 @@ #include #ifdef CONFIG_LIBC_LZF -#include +# include #endif #include #ifndef CONFIG_DISABLE_MOUNTPOINT -#include -#ifdef CONFIG_MTD -#include -#endif +# include +# ifdef CONFIG_MTD +# include +# endif #endif /****************************************************************************