-static yaffs_obj_t *yaffsfs_FindObject(yaffs_obj_t *relativeDirectory, const YCHAR *path, int symDepth, int getEquiv);
-static void yaffsfs_RemoveObjectCallback(yaffs_obj_t *obj);
+static struct yaffs_obj *yaffsfs_FindObject(struct yaffs_obj *relativeDirectory, const YCHAR *path, int symDepth, int getEquiv);
+static void yaffsfs_RemoveObjectCallback(struct yaffs_obj *obj);
int inodeId:12; /* Index to corresponding yaffsfs_Inode */
int useCount:10; /* Use count for this handle */
int inodeId:12; /* Index to corresponding yaffsfs_Inode */
int useCount:10; /* Use count for this handle */
* Curveballs: Should match paths that end in '/' too
* Curveball2 Might have "/x/ and "/x/y". Need to return the longest match
*/
* Curveballs: Should match paths that end in '/' too
* Curveball2 Might have "/x/ and "/x/y". Need to return the longest match
*/
- ylist_for_each(cfg, &yaffsfs_deviceList){
- dev = ylist_entry(cfg, yaffs_dev_t, dev_list);
+ list_for_each(cfg, &yaffsfs_deviceList){
+ dev = list_entry(cfg, struct yaffs_dev, dev_list);
dev= yaffsfs_FindDevice(path,restOfPath);
if(dev && dev->is_mounted){
dev= yaffsfs_FindDevice(path,restOfPath);
if(dev && dev->is_mounted){
const YCHAR *path,YCHAR **name,int symDepth)
{
return yaffsfs_DoFindDirectory(relativeDirectory,path,name,symDepth);
const YCHAR *path,YCHAR **name,int symDepth)
{
return yaffsfs_DoFindDirectory(relativeDirectory,path,name,symDepth);
-static yaffs_obj_t *yaffsfs_FindObject(yaffs_obj_t *relativeDirectory, const YCHAR *path,int symDepth, int getEquiv)
+static struct yaffs_obj *yaffsfs_FindObject(struct yaffs_obj *relativeDirectory, const YCHAR *path,int symDepth, int getEquiv)
YCHAR *name;
dir = yaffsfs_FindDirectory(relativeDirectory,path,&name,symDepth);
YCHAR *name;
dir = yaffsfs_FindDirectory(relativeDirectory,path,&name,symDepth);
int yaffs_open_sharing(const YCHAR *path, int oflag, int mode, int sharing)
{
int yaffs_open_sharing(const YCHAR *path, int oflag, int mode, int sharing)
{
- __u8 shareRead = (sharing & YAFFS_SHARE_READ) ? 1 : 0;
- __u8 shareWrite = (sharing & YAFFS_SHARE_WRITE) ? 1 : 0;
- __u8 sharedReadAllowed;
- __u8 sharedWriteAllowed;
- __u8 alreadyReading;
- __u8 alreadyWriting;
- __u8 readRequested;
- __u8 writeRequested;
+ u8 shareRead = (sharing & YAFFS_SHARE_READ) ? 1 : 0;
+ u8 shareWrite = (sharing & YAFFS_SHARE_WRITE) ? 1 : 0;
+ u8 sharedReadAllowed;
+ u8 sharedWriteAllowed;
+ u8 alreadyReading;
+ u8 alreadyWriting;
+ u8 readRequested;
+ u8 writeRequested;
int yaffsfs_do_read(int fd, void *vbuf, unsigned int nbyte, int isPread, int offset)
{
yaffsfs_Handle *h = NULL;
int yaffsfs_do_read(int fd, void *vbuf, unsigned int nbyte, int isPread, int offset)
{
yaffsfs_Handle *h = NULL;
int yaffsfs_do_write(int fd, const void *vbuf, unsigned int nbyte, int isPwrite, int offset)
{
yaffsfs_Handle *h = NULL;
int yaffsfs_do_write(int fd, const void *vbuf, unsigned int nbyte, int isPwrite, int offset)
{
yaffsfs_Handle *h = NULL;
int yaffs_ftruncate(int fd, off_t new_size)
{
yaffsfs_Handle *h = NULL;
int yaffs_ftruncate(int fd, off_t new_size)
{
yaffsfs_Handle *h = NULL;
off_t yaffs_lseek(int fd, off_t offset, int whence)
{
yaffsfs_Handle *h = NULL;
off_t yaffs_lseek(int fd, off_t offset, int whence)
{
yaffsfs_Handle *h = NULL;
- yaffs_obj_t *olddir = NULL;
- yaffs_obj_t *newdir = NULL;
- yaffs_obj_t *obj = NULL;
+ struct yaffs_obj *olddir = NULL;
+ struct yaffs_obj *newdir = NULL;
+ struct yaffs_obj *obj = NULL;
static int yaffs_do_setxattr(const YCHAR *path, const char *name, const void *data, int size, int flags, int follow)
{
static int yaffs_do_setxattr(const YCHAR *path, const char *name, const void *data, int size, int flags, int follow)
{
int yaffs_fsetxattr(int fd, const char *name, const void *data, int size, int flags)
{
int yaffs_fsetxattr(int fd, const char *name, const void *data, int size, int flags)
{
static int yaffs_do_getxattr(const YCHAR *path, const char *name, void *data, int size, int follow)
{
static int yaffs_do_getxattr(const YCHAR *path, const char *name, void *data, int size, int follow)
{
int yaffs_fgetxattr(int fd, const char *name, void *data, int size)
{
int yaffs_fgetxattr(int fd, const char *name, void *data, int size)
{
static int yaffs_do_listxattr(const YCHAR *path, char *data, int size, int follow)
{
static int yaffs_do_listxattr(const YCHAR *path, char *data, int size, int follow)
{
#ifdef CONFIG_YAFFS_WINCE
int yaffs_get_wince_times(int fd, unsigned *wctime, unsigned *watime, unsigned *wmtime)
{
#ifdef CONFIG_YAFFS_WINCE
int yaffs_get_wince_times(int fd, unsigned *wctime, unsigned *watime, unsigned *wmtime)
{
yaffs_dirent de; /* directory entry being used by this dsc */
YCHAR name[NAME_MAX+1]; /* name of directory being searched */
yaffs_dirent de; /* directory entry being used by this dsc */
YCHAR name[NAME_MAX+1]; /* name of directory being searched */
- yaffs_obj_t *dirObj; /* ptr to directory being searched */
- yaffs_obj_t *nextReturn; /* obj to be returned by next readddir */
+ struct yaffs_obj *dirObj; /* ptr to directory being searched */
+ struct yaffs_obj *nextReturn; /* obj to be returned by next readddir */
- dsc->nextReturn = ylist_entry(dsc->dirObj->variant.dir_variant.children.next,
- yaffs_obj_t,siblings);
+ dsc->nextReturn = list_entry(dsc->dirObj->variant.dir_variant.children.next,
+ struct yaffs_obj,siblings);
* If any are the one being removed, then advance the dsc to
* the next one to prevent a hanging ptr.
*/
* If any are the one being removed, then advance the dsc to
* the next one to prevent a hanging ptr.
*/
dsc->magic = YAFFS_MAGIC;
dsc->dirObj = obj;
yaffs_strncpy(dsc->name,dirname,NAME_MAX);
dsc->magic = YAFFS_MAGIC;
dsc->dirObj = obj;
yaffs_strncpy(dsc->name,dirname,NAME_MAX);
int yaffs_link(const YCHAR *oldpath, const YCHAR *newpath)
{
/* Creates a link called newpath to existing oldpath */
int yaffs_link(const YCHAR *oldpath, const YCHAR *newpath)
{
/* Creates a link called newpath to existing oldpath */
obj = yaffsfs_FindObject(NULL,path,0,1);
obj = yaffsfs_FindObject(NULL,path,0,1);