mirror of
https://github.com/apache/nuttx.git
synced 2026-06-04 23:03:27 +08:00
Run codespell -w against all files
and fix the wrong correction
This commit is contained in:
@@ -97,7 +97,7 @@ int closedir(FAR DIR *dirp)
|
||||
if (idir->fd_root)
|
||||
{
|
||||
/* This is the 'root' inode of the directory. This means different
|
||||
* things wih different filesystems.
|
||||
* things with different filesystems.
|
||||
*/
|
||||
|
||||
#ifndef CONFIG_DISABLE_MOUNTPOINT
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
* Input Parameters:
|
||||
* path - The path to the inode to create
|
||||
* bops - The block driver operations structure
|
||||
* mode - inmode priviledges (not used)
|
||||
* mode - inmode privileges (not used)
|
||||
* priv - Private, user data that will be associated with the inode.
|
||||
*
|
||||
* Returned Value:
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
* Input Parameters:
|
||||
* path - The path to the inode to create
|
||||
* fops - The file operations structure
|
||||
* mode - inmode priviledges (not used)
|
||||
* mode - inmode privileges (not used)
|
||||
* priv - Private, user data that will be associated with the inode.
|
||||
*
|
||||
* Returned Value:
|
||||
|
||||
+1
-1
@@ -1495,7 +1495,7 @@ static int fat_dup(FAR const struct file *oldp, FAR struct file *newp)
|
||||
* the opened file will be unknown to the other. That is a lurking
|
||||
* bug!
|
||||
*
|
||||
* One good solution to this might be to add a refernce count to the
|
||||
* One good solution to this might be to add a reference count to the
|
||||
* file structure. Then, instead of dup'ing the whole structure
|
||||
* as is done here, just increment the reference count on the
|
||||
* structure. The would have to be integrated with open logic as
|
||||
|
||||
@@ -2769,7 +2769,7 @@ int fat_dirnamewrite(struct fat_mountpt_s *fs, struct fat_dirinfo_s *dirinfo)
|
||||
}
|
||||
|
||||
/* On return, fat_lfsfname() will leave the short file name entry in the
|
||||
* cache. So we can just fall throught to write that directory entry, perhaps
|
||||
* cache. So we can just fall through to write that directory entry, perhaps
|
||||
* using the short file name alias for the long file name.
|
||||
*/
|
||||
|
||||
@@ -2814,7 +2814,7 @@ int fat_dirwrite(struct fat_mountpt_s *fs, struct fat_dirinfo_s *dirinfo,
|
||||
}
|
||||
|
||||
/* On return, fat_lfsfname() will leave the short file name entry in the
|
||||
* cache. So we can just fall throught to write that directory entry, perhaps
|
||||
* cache. So we can just fall through to write that directory entry, perhaps
|
||||
* using the short file name alias for the long file name.
|
||||
*/
|
||||
|
||||
|
||||
@@ -939,7 +939,7 @@ off_t fat_getcluster(struct fat_mountpt_s *fs, uint32_t clusterno)
|
||||
}
|
||||
}
|
||||
|
||||
/* There is no cluster information, or an error occured */
|
||||
/* There is no cluster information, or an error occurred */
|
||||
|
||||
return (off_t)-EINVAL;
|
||||
}
|
||||
|
||||
+1
-1
@@ -219,7 +219,7 @@ static void hostfs_mkpath(FAR struct hostfs_mountpt_s *fs,
|
||||
|
||||
while (relpath[x] != '\0')
|
||||
{
|
||||
/* Test for ".." occurance */
|
||||
/* Test for ".." occurrence */
|
||||
|
||||
if (strncmp(&relpath[x], "..", 2) == 0)
|
||||
{
|
||||
|
||||
+2
-2
@@ -151,7 +151,7 @@ enum lfs_open_flags_e
|
||||
LFS_F_DIRTY = 0x10000, /* File does not match storage */
|
||||
LFS_F_WRITING = 0x20000, /* File has been written since last flush */
|
||||
LFS_F_READING = 0x40000, /* File has been read since last flush */
|
||||
LFS_F_ERRED = 0x80000, /* An error occured during write */
|
||||
LFS_F_ERRED = 0x80000, /* An error occurred during write */
|
||||
};
|
||||
|
||||
/* File seek flags */
|
||||
@@ -655,7 +655,7 @@ int lfs_dir_rewind(FAR lfs_t *lfs, FAR lfs_dir_t *dir);
|
||||
int lfs_traverse(FAR lfs_t *lfs, CODE int (*cb)(FAR void *, lfs_block_t),
|
||||
FAR void *data);
|
||||
|
||||
/* Prunes any recoverable errors that may have occured in the filesystem
|
||||
/* Prunes any recoverable errors that may have occurred in the filesystem
|
||||
*
|
||||
* Not needed to be called by user unless an operation is interrupted
|
||||
* but the filesystem is still mounted. This is already called on first
|
||||
|
||||
+1
-1
@@ -127,7 +127,7 @@ int munmap(FAR void *start, size_t length)
|
||||
goto errout;
|
||||
}
|
||||
|
||||
/* Seach the list of regions */
|
||||
/* Search the list of regions */
|
||||
|
||||
for (prev = NULL, curr = g_rammaps.head; curr; prev = curr, curr = curr->flink)
|
||||
{
|
||||
|
||||
@@ -131,8 +131,8 @@ int mq_unlink(FAR const char *mq_name)
|
||||
ret = inode_remove(fullpath);
|
||||
|
||||
/* inode_remove() should always fail with -EBUSY because we hae a reference
|
||||
* on the inode. -EBUSY means taht the inode was, indeed, unlinked but
|
||||
* thatis could not be freed because there are refrences.
|
||||
* on the inode. -EBUSY means that the inode was, indeed, unlinked but
|
||||
* thatis could not be freed because there are references.
|
||||
*/
|
||||
|
||||
DEBUGASSERT(ret >= 0 || ret == -EBUSY);
|
||||
|
||||
+1
-1
@@ -125,7 +125,7 @@ struct nfsmount
|
||||
|
||||
#define SIZEOF_nfsmount(n) (sizeof(struct nfsmount) + ((n + 3) & ~3) - sizeof(uint32_t))
|
||||
|
||||
/* Mount parameters structure. This structure is use in nfs_decode_args funtion before one
|
||||
/* Mount parameters structure. This structure is use in nfs_decode_args function before one
|
||||
* mount structure is allocated in each NFS mount.
|
||||
*/
|
||||
|
||||
|
||||
+2
-2
@@ -513,7 +513,7 @@ static int nfs_fileopen(FAR struct nfsmount *nmp, FAR struct nfsnode *np,
|
||||
|
||||
if ((oflags & O_WRONLY) != 0)
|
||||
{
|
||||
/* Check if anyone has priveleges to write to the file -- owner,
|
||||
/* Check if anyone has privileges to write to the file -- owner,
|
||||
* group, or other (we are probably "other" and may still not be
|
||||
* able to write).
|
||||
*/
|
||||
@@ -1125,7 +1125,7 @@ static ssize_t nfs_write(FAR struct file *filep, const char *buffer,
|
||||
|
||||
writesize = tmp;
|
||||
|
||||
/* Determine the lowest committment level obtained by any of the RPCs. */
|
||||
/* Determine the lowest commitment level obtained by any of the RPCs. */
|
||||
|
||||
commit = *ptr++;
|
||||
if (committed == NFSV3WRITE_FILESYNC)
|
||||
|
||||
@@ -1299,7 +1299,7 @@ int nxffs_pack(FAR struct nxffs_volume_s *volume)
|
||||
if (wrfile)
|
||||
{
|
||||
/* If there is a write, just set ioffset to the offset of data in
|
||||
* first block. Setting 'packed' to true will supress normal inode
|
||||
* first block. Setting 'packed' to true will suppress normal inode
|
||||
* packing operation. Then we can start compacting the FLASH.
|
||||
*/
|
||||
|
||||
@@ -1359,7 +1359,7 @@ int nxffs_pack(FAR struct nxffs_volume_s *volume)
|
||||
|
||||
if (iooffset + CONFIG_NXFFS_TAILTHRESHOLD < volume->froffset)
|
||||
{
|
||||
/* Setting 'packed' to true will supress normal inode packing
|
||||
/* Setting 'packed' to true will suppress normal inode packing
|
||||
* operation.
|
||||
*/
|
||||
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
*
|
||||
* Description:
|
||||
* Seek to the file position before read or write access. Note that the
|
||||
* simplier nxffs_ioseek() cannot be used for this purpose. File offsets
|
||||
* simpler nxffs_ioseek() cannot be used for this purpose. File offsets
|
||||
* are not easily mapped to FLASH offsets due to intervening block and
|
||||
* data headers.
|
||||
*
|
||||
|
||||
@@ -207,7 +207,7 @@ static int nxffs_badblocks(FAR struct nxffs_volume_s *volume)
|
||||
if (memcmp(blkhdr->magic, g_blockmagic, NXFFS_MAGICSIZE) != 0 ||
|
||||
blkhdr->state != BLOCK_STATE_GOOD)
|
||||
{
|
||||
/* The block is not formated with the NXFFS magic bytes or else
|
||||
/* The block is not formatted with the NXFFS magic bytes or else
|
||||
* the block is specifically marked bad.
|
||||
*/
|
||||
|
||||
|
||||
@@ -135,8 +135,8 @@ int sem_unlink(FAR const char *name)
|
||||
ret = inode_remove(fullpath);
|
||||
|
||||
/* inode_remove() should always fail with -EBUSY because we hae a reference
|
||||
* on the inode. -EBUSY means taht the inode was, indeed, unlinked but
|
||||
* thatis could not be freed because there are refrences.
|
||||
* on the inode. -EBUSY means that the inode was, indeed, unlinked but
|
||||
* thatis could not be freed because there are references.
|
||||
*/
|
||||
|
||||
DEBUGASSERT(ret >= 0 || ret == -EBUSY);
|
||||
|
||||
@@ -68,7 +68,7 @@ General operation
|
||||
Only physical sectors that are in use will have a logical assignment.
|
||||
|
||||
Also contained in the sector header is a flags byte and a sequence number.
|
||||
When a sector is allocated, the COMMITED flag will be "set" (changed from
|
||||
When a sector is allocated, the COMMITTED flag will be "set" (changed from
|
||||
erase state to non-erase state) to indicate the sector data is valid. When
|
||||
a sector's data needs to be deleted, the RELEASED flag will be "set" to
|
||||
indicate the sector is no longer in use. This is done because the erase
|
||||
|
||||
@@ -1965,7 +1965,7 @@ int smartfs_extendfile(FAR struct smartfs_mountpt_s *fs,
|
||||
|
||||
if (readwrite.count > remaining)
|
||||
{
|
||||
/* Futher limit the write to the remaining bytes to write */
|
||||
/* Further limit the write to the remaining bytes to write */
|
||||
|
||||
readwrite.count = remaining;
|
||||
}
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ SPIFFS2 thoughts
|
||||
|
||||
* Instead of exact object id:s in the object lookup tables, use a hash of span index and object id.
|
||||
Eg. object id xor:ed with bit-reversed span index.
|
||||
This should decrease number of actual pages that needs to be visited when looking thru the obj lut.
|
||||
This should decrease number of actual pages that needs to be visited when looking through the obj lut.
|
||||
|
||||
* Logical number of each block. When moving stuff in a garbage collected page, the free
|
||||
page is assigned the same number as the garbage collected. Thus, object index pages do not have to
|
||||
|
||||
@@ -181,7 +181,7 @@ struct spiffs_file_s
|
||||
* Public Function Prototypes
|
||||
****************************************************************************/
|
||||
|
||||
struct stat; /* Foward reference */
|
||||
struct stat; /* Forward reference */
|
||||
|
||||
/****************************************************************************
|
||||
* Name: spiffs_stat_pgndx
|
||||
|
||||
@@ -1104,7 +1104,7 @@ static int spiffs_lucheck_callback(FAR struct spiffs_s *fs, int16_t objid,
|
||||
* objid - The Object ID
|
||||
*
|
||||
* Returned Value:
|
||||
* The index associated with the objid is returned on sucess. -ENOENT
|
||||
* The index associated with the objid is returned on success. -ENOENT
|
||||
* is resutled if the objid was not found.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
@@ -788,7 +788,7 @@ int spiffs_erase_block(FAR struct spiffs_s *fs, int16_t blkndx)
|
||||
* Name: spiffs_objlu_scan
|
||||
*
|
||||
* Description:
|
||||
* Scans thru all obj lu and counts free, deleted and used pages.
|
||||
* Scans through all obj lu and counts free, deleted and used pages.
|
||||
* Find the maximum block erase count Checks magic if enabled
|
||||
*
|
||||
****************************************************************************/
|
||||
@@ -3389,7 +3389,7 @@ ssize_t spiffs_object_read(FAR struct spiffs_s *fs,
|
||||
* Name: spiffs_objlu_find_free_objid
|
||||
*
|
||||
* Description:
|
||||
* Scans thru all object lookup for object index header pages. If total
|
||||
* Scans through all object lookup for object index header pages. If total
|
||||
* possible number of object ids cannot fit into a work buffer, these are
|
||||
* grouped. When a group containing free object ids is found, the object
|
||||
* lu is again scanned for object ids within group and bitmasked. Finally,
|
||||
|
||||
@@ -864,7 +864,7 @@ static int spiffs_gc_clean(FAR struct spiffs_s *fs, int16_t blkndx)
|
||||
}
|
||||
else
|
||||
{
|
||||
/* No more data pages found, passed thru all block, start
|
||||
/* No more data pages found, passed through all block, start
|
||||
* evacuating object indices
|
||||
*/
|
||||
|
||||
|
||||
Reference in New Issue
Block a user