logo       


[SSI] openssi/kernel/include/cluster/ssi/cfs cfs_fs_sb.h,1.4,1.5 cfs_mount.: msg#00122

Subject: [SSI] openssi/kernel/include/cluster/ssi/cfs cfs_fs_sb.h,1.4,1.5 cfs_mount.h,1.4,1.5 cfs_page.h,1.4,1.5
Update of /cvsroot/ssic-linux/openssi/kernel/include/cluster/ssi/cfs
In directory 
sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4193/include/cluster/ssi/cfs

Modified Files:
        cfs_fs_sb.h cfs_mount.h cfs_page.h 
Log Message:
Changes to get fs and clsuter/ssi/cfs to compile


Index: cfs_mount.h
===================================================================
RCS file: 
/cvsroot/ssic-linux/openssi/kernel/include/cluster/ssi/cfs/cfs_mount.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- cfs_mount.h 20 Oct 2004 20:47:56 -0000      1.4
+++ cfs_mount.h 12 Nov 2004 03:21:46 -0000      1.5
@@ -58,7 +58,7 @@
 #endif
 
 struct inode *cfs_get_pfs_inode(const struct inode *);
-#ifdef CONFIG_DEVFS_XXX
+#ifdef CONFIG_DEVFS_FS
 void cfs_devfs_hack(struct vfsmount **, struct dentry **);
 void cfs_devfs_down_i_sem(struct dentry *);
 void cfs_devfs_up_i_sem(struct dentry *);
@@ -81,15 +81,14 @@
 void print_cfsmount(struct vfsmount *);
 int cfs_stackable(char *);
 int cfs_domount(struct super_block **sbp, struct nameidata *nd);
-struct super_block *cfs_layered_mount(
-               struct super_block *, struct super_block *, int);
+int cfs_layered_mount(struct super_block *, struct super_block *, int);
 struct svrcfstok *svrtok_lookup(struct cfs_fh *, struct dentry *, struct 
super_block *);
 extern int cfs_mount_root(char *, clusternode_t);
 extern int cfs_prep_remount_all(struct vfsmount *, int, int, void *);
 extern void cfs_remount_all(struct vfsmount *, int, int, void *);
 extern int cfs_remote_mount(struct super_block *,
                                            struct cfsmountargs *, int);
-extern struct super_block * cfs_shm_mount(struct super_block *,
+extern int cfs_shm_mount(struct super_block *,
                                        struct cfsmountargs *, int);
 extern void cfs_shm_init(void);
 extern int cfs_remount(char *, int, char *, unsigned long, void *);

Index: cfs_page.h
===================================================================
RCS file: 
/cvsroot/ssic-linux/openssi/kernel/include/cluster/ssi/cfs/cfs_page.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- cfs_page.h  27 Oct 2004 04:33:13 -0000      1.4
+++ cfs_page.h  12 Nov 2004 03:21:46 -0000      1.5
@@ -1,5 +1,5 @@
 /*
- * include/cluster/ssi/cfs/cfs_page.h
+ * linux/include/cluster/ssi/cfs/cfs_page.h
  *
  * Copyright (C) 2000 Trond Myklebust
  *
@@ -11,48 +11,58 @@
 
 
 #include <linux/list.h>
-#include <linux/mm.h>
+#include <linux/pagemap.h>
 #include <linux/wait.h>
+#include <cluster/ssi/cfs/cfs_fs_sb.h>
 #include <linux/sunrpc/auth.h>
 #ifdef SKIP
 #include <cluster/ssi/cfs/cfs_xdr.h>
 #endif
 
+#include <asm/atomic.h>
+
 /*
  * Valid flags for a dirty buffer
  */
 #define PG_BUSY                        0
-#define        PG_DOWN                 1
+#define PG_NEED_COMMIT         1
+#define PG_NEED_RESCHED                2
+#define        PG_DOWN                 3
 
 struct cfs_page {
        struct list_head        wb_list,        /* Defines state of page: */
-                               wb_lru,         /* superblock lru list */
                                *wb_list_head;  /*      read/write/commit */
        struct file             *wb_file;
+       fl_owner_t              wb_lockowner;
        struct inode            *wb_inode;
+#ifdef SSI_SKIP        /* Don't delete this, keeps include/linux/nfs_page.h 
comparison */
+       struct nfs4_state       *wb_state;
+#endif /* SSI_SKIP */
        struct page             *wb_page;       /* page to read in/write out */
+       atomic_t                wb_complete;    /* i/os we're waiting for */
        wait_queue_head_t       wb_wait;        /* wait queue */
-       unsigned long           wb_timeout;     /* when to read/write/commit */
        unsigned long           wb_index;       /* Offset >> PAGE_CACHE_SHIFT */
-       unsigned int            wb_offset,      /* Offset of read/write */
+       unsigned int            wb_offset,      /* Offset & ~PAGE_CACHE_MASK */
+                               wb_pgbase,      /* Start of page data */
                                wb_bytes,       /* Length of request */
                                wb_count;       /* reference count */
        unsigned long           wb_flags;
 };
 
 #define CFS_WBACK_BUSY(req)    (test_bit(PG_BUSY,&(req)->wb_flags))
+#define CFS_NEED_COMMIT(req)   (test_bit(PG_NEED_COMMIT,&(req)->wb_flags))
+#define CFS_NEED_RESCHED(req)  (test_bit(PG_NEED_RESCHED,&(req)->wb_flags))
 #define CFS_REQ_DOWN(req)      (test_bit(PG_DOWN,&(req)->wb_flags))
 
 extern struct cfs_page *cfs_create_request(struct file *, struct inode *,
                                            struct page *,
                                            unsigned int, unsigned int);
+extern void cfs_clear_request(struct cfs_page *req);
 extern void cfs_release_request(struct cfs_page *req);
 
 
 extern void cfs_list_add_request(struct cfs_page *, struct list_head *);
 
-extern int cfs_scan_lru(struct list_head *, struct list_head *, int);
-extern int cfs_scan_lru_timeout(struct list_head *, struct list_head *, int);
 extern int cfs_scan_list(struct list_head *, struct list_head *,
                          unsigned long, unsigned int);
 extern int cfs_coalesce_requests(struct list_head *, struct list_head *,
@@ -94,8 +104,7 @@
        smp_mb__before_clear_bit();
        clear_bit(PG_BUSY, &req->wb_flags);
        smp_mb__after_clear_bit();
-       if (waitqueue_active(&req->wb_wait))
-               wake_up_all(&req->wb_wait);
+       wake_up_all(&req->wb_wait);
        cfs_release_request(req);
 }
 
@@ -116,36 +125,48 @@
        req->wb_list_head = NULL;
 }
 
-static inline struct cfs_page *
-cfs_list_entry(struct list_head *head)
+static inline int
+cfs_defer_commit(struct cfs_page *req)
 {
-       return list_entry(head, struct cfs_page, wb_list);
+       if (test_and_set_bit(PG_NEED_COMMIT, &req->wb_flags))
+               return 0;
+       return 1;
 }
 
-static inline
-loff_t req_offset(struct cfs_page *req)
+static inline void
+cfs_clear_commit(struct cfs_page *req)
 {
-       return (((loff_t)req->wb_index) << PAGE_CACHE_SHIFT) + req->wb_offset;
+       smp_mb__before_clear_bit();
+       clear_bit(PG_NEED_COMMIT, &req->wb_flags);
+       smp_mb__after_clear_bit();
 }
 
-static inline void
-__cfs_add_lru(struct list_head *head, struct cfs_page *req)
+static inline int
+cfs_defer_reschedule(struct cfs_page *req)
 {
-       list_add_tail(&req->wb_lru, head);
+       if (test_and_set_bit(PG_NEED_RESCHED, &req->wb_flags))
+               return 0;
+       return 1;
 }
 
 static inline void
-__cfs_del_lru(struct cfs_page *req)
+cfs_clear_reschedule(struct cfs_page *req)
 {
-       if (list_empty(&req->wb_lru))
-               return;
-       list_del_init(&req->wb_lru);
+       smp_mb__before_clear_bit();
+       clear_bit(PG_NEED_RESCHED, &req->wb_flags);
+       smp_mb__after_clear_bit();
 }
 
 static inline struct cfs_page *
-cfs_lru_entry(struct list_head *head)
+cfs_list_entry(struct list_head *head)
 {
-        return list_entry(head, struct cfs_page, wb_lru);
+       return list_entry(head, struct cfs_page, wb_list);
+}
+
+static inline
+loff_t req_offset(struct cfs_page *req)
+{
+       return (((loff_t)req->wb_index) << PAGE_CACHE_SHIFT) + req->wb_offset;
 }
 
 /*

Index: cfs_fs_sb.h
===================================================================
RCS file: 
/cvsroot/ssic-linux/openssi/kernel/include/cluster/ssi/cfs/cfs_fs_sb.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- cfs_fs_sb.h 20 Oct 2004 20:47:56 -0000      1.4
+++ cfs_fs_sb.h 12 Nov 2004 03:21:46 -0000      1.5
@@ -80,12 +80,14 @@
        unsigned int            namelen;
        char *                  hostname;       /* remote hostname */
 #endif
+       struct list_head        dirty_down,
+                               read_down;
+#ifdef SSI_XXX_NOTUSED
        struct list_head        lru_read,
                                lru_dirty,
                                lru_commit,
-                               lru_busy,
-                               dirty_down,
-                               read_down;
+                               lru_busy;
+#endif
 } cfs_mntinfo_t;
 
 /*



-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click


Ruby Jobs
Java Jobs
Jobs in California
more...
what
job title, keywords
where
city, state, zip
jobs by job search
<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
encryption.gpg....    ietf.rfc822/199...    freebsd.devel.i...    lang.haskell.li...    mail.squirrelma...    web.zope.plone....    yellowdog.gener...    text.xml.xalan....    recreation.phot...    kde.devel.educa...    hardware.bus.ca...    printing.ghosts...    voip.peering/20...    assembly/2006-0...    org.user-groups...    culture.interne...    network.i2p/200...    boot-loaders.ya...    xfree86.render/...    qnx.openqnx.dev...    jakarta.velocit...    user-groups.pal...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe