Whamcloud - gitweb
Minor fixes to
authorbraam <braam>
Sat, 9 Feb 2002 05:12:51 +0000 (05:12 +0000)
committerbraam <braam>
Sat, 9 Feb 2002 05:12:51 +0000 (05:12 +0000)
 - setup scripts to do Elan stuff
 - a few changes to page cache stuff for 2.4.9 (we finally know how to #if it)
 - the usual battle the ext2obd patch
 - removed aclocal.m4 (enhances immunity from automake versions)

lustre/include/linux/lustre_net.h
lustre/llite/rw.c
lustre/ptlrpc/rpc.c
lustre/tests/llmount-client.sh
lustre/tests/llmount-server.sh

index 1af56f1..686fcca 100644 (file)
@@ -101,7 +101,7 @@ int ptl_send_rpc(struct ptlrpc_request *request, struct lustre_peer *peer);
 int rpc_register_service(struct ptlrpc_service *service, char *uuid);
 
 /* FIXME */
-#if 1
+#if 0
 # define LUSTRE_NAL "ksocknal"
 #else
 # define LUSTRE_NAL "kqswnal"
index 0cb0eab..f5b262b 100644 (file)
 #include <linux/lustre_mds.h>
 #include <linux/lustre_light.h>
 
+/*
+ * Add a page to the dirty page list.
+ */
+void __set_page_dirty(struct page *page)
+{
+        struct address_space *mapping;
+        spinlock_t *pg_lock;
+
+        pg_lock = PAGECACHE_LOCK(page);
+        spin_lock(pg_lock);
+
+        mapping = page->mapping;
+        spin_lock(&mapping->page_lock);
+
+        list_del(&page->list);
+        list_add(&page->list, &mapping->dirty_pages);
+
+        spin_unlock(&mapping->page_lock);
+        spin_unlock(pg_lock);
+
+        if (mapping->host)
+                mark_inode_dirty_pages(mapping->host);
+}
 
 static void inline ll_oa_from_inode(struct obdo *oa, struct inode *inode)
 {
@@ -82,22 +105,24 @@ static void inline ll_oa_from_inode(struct obdo *oa, struct inode *inode)
 /*
  * Add a page to the dirty page list.
  */
+#if 0
 void set_page_dirty(struct page *page)
 {
        if (!test_and_set_bit(PG_dirty, &page->flags)) {
                struct address_space *mapping = page->mapping;
 
                if (mapping) {
-                       spin_lock(&pagecache_lock);
                        list_del(&page->list);
                        list_add(&page->list, &mapping->dirty_pages);
-                       spin_unlock(&pagecache_lock);
 
                        if (mapping->host)
                                mark_inode_dirty_pages(mapping->host);
                }
        }
 }
+#endif
+
+
 
 /*
  * Remove page from dirty list
@@ -110,7 +135,6 @@ void __set_page_clean(struct page *page)
        if (!mapping)
                return;
 
-       spin_lock(&pagecache_lock);
        list_del(&page->list);
        list_add(&page->list, &mapping->clean_pages);
 
@@ -119,7 +143,6 @@ void __set_page_clean(struct page *page)
                CDEBUG(D_INODE, "inode clean\n");
                inode->i_state &= ~I_DIRTY_PAGES;
        }
-       spin_unlock(&pagecache_lock);
        EXIT;
 }
 
@@ -284,7 +307,7 @@ int ll_dir_readpage(struct file *file, struct page *page)
 
        SetPageUptodate(page);
  readpage_out:
-       unlock_page(page);
+       obd_unlock_page(page);
         EXIT;
         return rc;
 } /* ll_dir_readpage */
index 4969603..9a19265 100644 (file)
@@ -301,12 +301,12 @@ static int req_init_portals(void)
         return rc;
 }
 
-static int __init req_init(void)
+static int  init_module(void)
 {
         return req_init_portals();
 }
 
-static void __exit req_exit(void)
+static void cleanup_module(void)
 {
         PtlEQFree(req_eq);
 
@@ -319,5 +319,3 @@ MODULE_AUTHOR("Peter J. Braam <braam@clusterfs.com>");
 MODULE_DESCRIPTION("Lustre Request Processor v1.0");
 MODULE_LICENSE("GPL"); 
 
-module_init(req_init);
-module_exit(req_exit);
index aafc15a..6fa09c5 100644 (file)
@@ -1,4 +1,5 @@
 #!/bin/sh
+export PATH=/sbin:/usr/sbin:$PATH
 
 SRCDIR="`dirname $0`"
 . $SRCDIR/common.sh
@@ -8,12 +9,13 @@ SERVER=compila
 mknod /dev/portals c 10 240
 
 insmod $R/usr/src/portals/linux/oslib/portals.o
-insmod $R/usr/src/portals/linux/socknal/ksocknal.o
+# insmod $R/usr/src/portals/linux/socknal/ksocknal.o
+insmod $R/usr/src/portals/linux/qswnal/kqswnal.o
 
 $R/usr/src/portals/linux/utils/ptlctl <<EOF
 mynid
-setup tcp
-connect $SERVER 1234
+setup elan 
+connect 5
 add_uuid self
 add_uuid mds
 EOF
index c1439dd..909611d 100644 (file)
@@ -1,18 +1,22 @@
 #!/bin/sh
 
+export PATH=/sbin:/usr/sbin:$PATH
+
 SRCDIR="`dirname $0`"
 . $SRCDIR/common.sh
 
 mknod /dev/portals c 10 240
 
 insmod $R/usr/src/portals/linux/oslib/portals.o
-insmod $R/usr/src/portals/linux/socknal/ksocknal.o
+# insmod $R/usr/src/portals/linux/socknal/ksocknal.o
+insmod $R/usr/src/portals/linux/qswnal/kqswnal.o
 
-$R/usr/src/portals/linux/utils/acceptor 1234 &
+$R/usr/src/portals/linux/utils/acceptor 1234 &
 
 $R/usr/src/portals/linux/utils/ptlctl <<EOF
 mynid
-setup tcp
+setup elan
+connect 5
 add_uuid self
 EOF