diff --git a/fs/driver/driver.h b/fs/driver/driver.h index 04a015f25cb..990702db014 100644 --- a/fs/driver/driver.h +++ b/fs/driver/driver.h @@ -99,22 +99,14 @@ int find_blockdriver(FAR const char *pathname, int mountflags, * oriented accessed to the block driver. * * Input Parameters: + * filep - The caller provided location in which to return the 'struct + * file' instance. * blkdev - The path to the block driver * oflags - Character driver open flags * * Returned Value: - * If positive, non-zero file descriptor is returned on success. This - * is the file descriptor of the nameless character driver that mediates - * accesses to the block driver. - * - * Errors that may be returned: - * - * ENOMEM - Failed to create a temporary path name. - * - * Plus: - * - * - Errors reported from bchdev_register() - * - Errors reported from open() or unlink() + * Zero (OK) is returned on success. On failure, a negated errno value is + * returned. * ****************************************************************************/ diff --git a/fs/driver/fs_blockproxy.c b/fs/driver/fs_blockproxy.c index a17c7a200c6..2d809e53928 100644 --- a/fs/driver/fs_blockproxy.c +++ b/fs/driver/fs_blockproxy.c @@ -128,22 +128,14 @@ static FAR char *unique_chardev(void) * oriented accessed to the block driver. * * Input Parameters: + * filep - The caller provided location in which to return the 'struct + * file' instance. * blkdev - The path to the block driver * oflags - Character driver open flags * * Returned Value: - * If positive, non-zero file descriptor is returned on success. This - * is the file descriptor of the nameless character driver that mediates - * accesses to the block driver. - * - * Errors that may be returned: - * - * ENOMEM - Failed to create a temporary path name. - * - * Plus: - * - * - Errors reported from bchdev_register() - * - Errors reported from open() or unlink() + * Zero (OK) is returned on success. On failure, a negated errno value is + * returned. * ****************************************************************************/ @@ -202,9 +194,7 @@ int block_proxy(FAR struct file *filep, FAR const char *blkdev, int oflags) goto errout_with_chardev; } - /* Free the allocate character driver name and return the open file - * descriptor. - */ + /* Free the allocated character driver name. */ kmm_free(chardev); return OK; diff --git a/fs/vfs/fs_open.c b/fs/vfs/fs_open.c index 7379a4d5e95..d7d7caad93d 100644 --- a/fs/vfs/fs_open.c +++ b/fs/vfs/fs_open.c @@ -115,8 +115,7 @@ static int file_vopen(FAR struct file *filep, /* If the inode is block driver, then we may return a character driver * proxy for the block driver. block_proxy() will instantiate a BCH * character driver wrapper around the block driver, open(), then - * unlink() the character driver. On success, block_proxy() will - * return the file descriptor of the opened character driver. + * unlink() the character driver. * * NOTE: This will recurse to open the character driver proxy. */ @@ -128,7 +127,7 @@ static int file_vopen(FAR struct file *filep, inode_release(inode); RELEASE_SEARCH(&desc); - /* Get the file descriptor of the opened character driver proxy */ + /* Get the file structure of the opened character driver proxy */ return block_proxy(filep, path, oflags); }