> The bch driver supports an IOCTL called BIOC_GEOMETRY that will return
the geometry of the underlying block device.

Yes, I understand. But user application handle all files the same way using
path and
int stat(FAR const char *path, FAR struct stat *buf) function.

I've made a pull request #1118
<https://github.com/apache/incubator-nuttx/pull/1118>
Patch doesn't do the trick for bch driver of course, but at least for block
drivers.
Merge or drop it as you wish, if it is not appropriate.

пн, 25 мая 2020 г. в 17:40, Gregory Nutt <spudan...@gmail.com>:

>
> > It looks like I overthink and the best and simple solution is just to use
> > for all block devices the block_operation function of inode to get
> geometry:
> >     inode->u.i_bops->geometry
> >
> > I miss that bchlib is already use this function to fill bchlib_s
> structure.
> >
> > Will try this approach now.
> The bch driver supports an IOCTL called BIOC_GEOMETRY that will return
> the geometry of the underlying block device.
>

Reply via email to