On Wed, Dec 20, 2006 at 08:22:12PM -0700, Snider, Tim
wrote:> There are patches for the vanilla 2.6.18 kernel in Lustre 1.5.95. Does
anyone know if they are complete and work? The alternative would be to use /
port the patches that John Dunning has for 2.6.15.
> Thanks,
> Tim
This patches work with OSS and clients on vanilla 2.6.18.
MDS has problem in mballoc code on 2.6.18, so I use 2.6.12.6 on MDS.
--
Serge Ryabchun
-------------- next part --------------
diff -Nru lustre-1.5.95-/lnet/include/libcfs/linux/kp30.h
lustre-1.5.95/lnet/include/libcfs/linux/kp30.h
--- lustre-1.5.95-/lnet/include/libcfs/linux/kp30.h 2006-08-19
10:22:52.000000000 +0300
+++ lustre-1.5.95/lnet/include/libcfs/linux/kp30.h 2006-11-02 00:41:10.000000000
+0200
@@ -181,7 +181,7 @@
#define LWT_MEMORY (16<<20)
-#if !KLWT_SUPPORT
+#if !defined(KLWT_SUPPORT)
# if defined(__KERNEL__)
# if !defined(BITS_PER_LONG)
# error "BITS_PER_LONG not defined"
diff -Nru lustre-1.5.95-/lnet/klnds/o2iblnd/o2iblnd_cb.c
lustre-1.5.95/lnet/klnds/o2iblnd/o2iblnd_cb.c
--- lustre-1.5.95-/lnet/klnds/o2iblnd/o2iblnd_cb.c 2006-07-12 19:27:28.000000000
+0300
+++ lustre-1.5.95/lnet/klnds/o2iblnd/o2iblnd_cb.c 2006-11-02 00:41:10.000000000
+0200
@@ -511,7 +511,7 @@
LASSERT (page != NULL);
return page;
}
-#if CONFIG_HIGHMEM
+#ifdef CONFIG_HIGHMEM
if (vaddr >= PKMAP_BASE &&
vaddr < (PKMAP_BASE + LAST_PKMAP * PAGE_SIZE)) {
/* No highmem pages only used for bulk (kiov) I/O */
@@ -524,7 +524,7 @@
return page;
}
-#if !IBNAL_MAP_ON_DEMAND
+#ifndef IBNAL_MAP_ON_DEMAND
int
kiblnd_setup_rd_iov(kib_tx_t *tx, kib_rdma_desc_t *rd,
unsigned int niov, struct iovec *iov, int offset, int nob)
diff -Nru lustre-1.5.95-/lnet/klnds/socklnd/socklnd.c
lustre-1.5.95/lnet/klnds/socklnd/socklnd.c
--- lustre-1.5.95-/lnet/klnds/socklnd/socklnd.c 2006-08-15 18:05:25.000000000
+0300
+++ lustre-1.5.95/lnet/klnds/socklnd/socklnd.c 2006-11-02 00:41:10.000000000
+0200
@@ -2134,7 +2134,7 @@
spin_lock_init (&kss->kss_lock);
CFS_INIT_LIST_HEAD (&kss->kss_rx_conns);
CFS_INIT_LIST_HEAD (&kss->kss_tx_conns);
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
CFS_INIT_LIST_HEAD (&kss->kss_zctxdone_list);
#endif
cfs_waitq_init (&kss->kss_waitq);
diff -Nru lustre-1.5.95-/lnet/klnds/socklnd/socklnd.h
lustre-1.5.95/lnet/klnds/socklnd/socklnd.h
--- lustre-1.5.95-/lnet/klnds/socklnd/socklnd.h 2006-07-25 22:49:19.000000000
+0300
+++ lustre-1.5.95/lnet/klnds/socklnd/socklnd.h 2006-11-02 00:41:10.000000000
+0200
@@ -95,7 +95,7 @@
spinlock_t kss_lock; /* serialise */
struct list_head kss_rx_conns; /* conn waiting to be read */
struct list_head kss_tx_conns; /* conn waiting to be written
*/
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
struct list_head kss_zctxdone_list; /* completed ZC transmits */
#endif
cfs_waitq_t kss_waitq; /* where scheduler sleeps */
@@ -135,17 +135,17 @@
int *ksnd_keepalive_intvl; /* time between probes */
int *ksnd_credits; /* # concurrent sends */
int *ksnd_peercredits; /* # concurrent sends to 1 peer
*/
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
unsigned int *ksnd_zc_min_frag; /* minimum zero copy frag size
*/
#endif
-#if CPU_AFFINITY
+#ifdef CPU_AFFINITY
int *ksnd_irq_affinity; /* enable IRQ affinity? */
#endif
-#if SOCKNAL_BACKOFF
+#ifdef SOCKNAL_BACKOFF
int *ksnd_backoff_init; /* initial TCP backoff */
int *ksnd_backoff_max; /* maximum TCP backoff */
#endif
-#if CONFIG_SYSCTL && !CFS_SYSFS_MODULE_PARM
+#if defined(CONFIG_SYSCTL) && !defined(CFS_SYSFS_MODULE_PARM)
cfs_sysctl_table_header_t *ksnd_sysctl; /* sysctl interface */
#endif
} ksock_tunables_t;
@@ -225,7 +225,7 @@
lnet_kiov_t *tx_kiov; /* packet page frags */
struct ksock_conn *tx_conn; /* owning conn */
lnet_msg_t *tx_lnetmsg; /* lnet message for
lnet_finalize() */
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
zccd_t tx_zccd; /* zero copy callback
descriptor */
#endif
int tx_desc_size; /* size of this descriptor */
@@ -300,10 +300,10 @@
int ksnc_tx_ready; /* write space */
int ksnc_tx_scheduled; /* being progressed */
-#if !SOCKNAL_SINGLE_FRAG_RX
+#ifndef SOCKNAL_SINGLE_FRAG_RX
struct iovec ksnc_rx_scratch_iov[LNET_MAX_IOV];
#endif
-#if !SOCKNAL_SINGLE_FRAG_TX
+#ifndef SOCKNAL_SINGLE_FRAG_TX
struct iovec ksnc_tx_scratch_iov[LNET_MAX_IOV];
#endif
} ksock_conn_t;
diff -Nru lustre-1.5.95-/lnet/klnds/socklnd/socklnd_cb.c
lustre-1.5.95/lnet/klnds/socklnd/socklnd_cb.c
--- lustre-1.5.95-/lnet/klnds/socklnd/socklnd_cb.c 2006-08-16 18:27:57.000000000
+0300
+++ lustre-1.5.95/lnet/klnds/socklnd/socklnd_cb.c 2006-11-02 00:41:10.000000000
+0200
@@ -334,7 +334,7 @@
RETURN (rc);
}
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
void
ksocknal_zc_callback (zccd_t *zcd)
{
@@ -363,7 +363,7 @@
ENTRY;
if (tx->tx_conn != NULL) {
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
/* zero copy completion isn''t always from
* process_transmit() so it needs to keep a ref on
* tx_conn... */
@@ -402,7 +402,7 @@
void
ksocknal_tx_launched (ksock_tx_t *tx)
{
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
if (atomic_read (&tx->tx_zccd.zccd_count) != 1) {
ksock_conn_t *conn = tx->tx_conn;
@@ -528,7 +528,7 @@
list_for_each (tmp, &peer->ksnp_conns) {
ksock_conn_t *c = list_entry(tmp, ksock_conn_t, ksnc_list);
-#if SOCKNAL_ROUND_ROBIN
+#ifdef SOCKNAL_ROUND_ROBIN
const int nob = 0;
#else
int nob = atomic_read(&c->ksnc_tx_nob) +
@@ -571,7 +571,7 @@
/* prefer the typed selection */
conn = (typed != NULL) ? typed : fallback;
-#if SOCKNAL_ROUND_ROBIN
+#ifdef SOCKNAL_ROUND_ROBIN
if (conn != NULL) {
/* round-robin all else being equal */
list_del (&conn->ksnc_list);
@@ -602,7 +602,7 @@
atomic_add (tx->tx_nob, &conn->ksnc_tx_nob);
tx->tx_conn = conn;
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
zccd_init (&tx->tx_zccd, ksocknal_zc_callback);
/* NB this sets 1 ref on zccd, so the callback can only occur after
* I''ve released this ref. */
@@ -712,7 +712,7 @@
g_lock = &ksocknal_data.ksnd_global_lock;
for (retry = 0;; retry = 1) {
-#if !SOCKNAL_ROUND_ROBIN
+#ifndef SOCKNAL_ROUND_ROBIN
read_lock (g_lock);
peer = ksocknal_find_peer_locked(ni, id);
if (peer != NULL) {
@@ -1109,7 +1109,7 @@
spin_lock_bh (&sched->kss_lock);
rc = (!ksocknal_data.ksnd_shuttingdown &&
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
list_empty(&sched->kss_zctxdone_list) &&
#endif
list_empty(&sched->kss_rx_conns) &&
@@ -1133,7 +1133,7 @@
cfs_daemonize (name);
cfs_block_allsigs ();
-#if (CONFIG_SMP && CPU_AFFINITY)
+#if defined(CONFIG_SMP) && defined(CPU_AFFINITY)
id = ksocknal_sched2cpu(id);
if (cpu_online(id)) {
cpumask_t m;
@@ -1244,7 +1244,7 @@
did_something = 1;
}
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
if (!list_empty (&sched->kss_zctxdone_list)) {
ksock_tx_t *tx
list_entry(sched->kss_zctxdone_list.next,
diff -Nru lustre-1.5.95-/lnet/klnds/socklnd/socklnd_lib-linux.c
lustre-1.5.95/lnet/klnds/socklnd/socklnd_lib-linux.c
--- lustre-1.5.95-/lnet/klnds/socklnd/socklnd_lib-linux.c 2006-08-21
19:31:45.000000000 +0300
+++ lustre-1.5.95/lnet/klnds/socklnd/socklnd_lib-linux.c 2006-11-02
00:41:10.000000000 +0200
@@ -4,7 +4,7 @@
#include "socklnd.h"
-# if CONFIG_SYSCTL && !CFS_SYSFS_MODULE_PARM
+#if defined(CONFIG_SYSCTL) && !defined(CFS_SYSFS_MODULE_PARM)
static ctl_table ksocknal_ctl_table[21];
ctl_table ksocknal_top_ctl_table[] = {
@@ -39,7 +39,7 @@
ksocknal_ctl_table[i++] = (ctl_table)
{j++, "eager_ack", ksocknal_tunables.ksnd_eager_ack,
sizeof (int), 0644, NULL, &proc_dointvec};
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
ksocknal_ctl_table[i++] = (ctl_table)
{j++, "zero_copy", ksocknal_tunables.ksnd_zc_min_frag,
sizeof (int), 0644, NULL, &proc_dointvec};
@@ -59,7 +59,7 @@
ksocknal_ctl_table[i++] = (ctl_table)
{j++, "nagle", ksocknal_tunables.ksnd_nagle,
sizeof(int), 0644, NULL, &proc_dointvec};
-#if CPU_AFFINITY
+#ifdef CPU_AFFINITY
ksocknal_ctl_table[i++] = (ctl_table)
{j++, "irq_affinity", ksocknal_tunables.ksnd_irq_affinity,
sizeof(int), 0644, NULL, &proc_dointvec};
@@ -73,7 +73,7 @@
ksocknal_ctl_table[i++] = (ctl_table)
{j++, "keepalive_intvl", ksocknal_tunables.ksnd_keepalive_intvl,
sizeof(int), 0644, NULL, &proc_dointvec};
-#if SOCKNAL_BACKOFF
+#ifdef SOCKNAL_BACKOFF
ksocknal_ctl_table[i++] = (ctl_table)
{j++, "backoff_init",
ksocknal_tunables.ksnd_backoff_init,
sizeof(int), 0644, NULL, &proc_dointvec};
@@ -116,7 +116,7 @@
void
ksocknal_lib_bind_irq (unsigned int irq)
{
-#if (defined(CONFIG_SMP) && CPU_AFFINITY)
+#if defined(CONFIG_SMP) && defined(CPU_AFFINITY)
int bind;
int cpu;
char cmdline[64];
@@ -189,7 +189,7 @@
ksocknal_lib_sock_irq (struct socket *sock)
{
int irq = 0;
-#if CPU_AFFINITY
+#ifdef CPU_AFFINITY
struct dst_entry *dst;
if (!*ksocknal_tunables.ksnd_irq_affinity)
@@ -211,7 +211,7 @@
return irq;
}
-#if (SOCKNAL_ZC && SOCKNAL_VADDR_ZC)
+#if defined(SOCKNAL_ZC) && defined(SOCKNAL_VADDR_ZC)
static struct page *
ksocknal_kvaddr_to_page (unsigned long vaddr)
{
@@ -220,7 +220,7 @@
if (vaddr >= VMALLOC_START &&
vaddr < VMALLOC_END)
page = vmalloc_to_page ((void *)vaddr);
-#if CONFIG_HIGHMEM
+#ifdef CONFIG_HIGHMEM
else if (vaddr >= PKMAP_BASE &&
vaddr < (PKMAP_BASE + LAST_PKMAP * PAGE_SIZE))
page = vmalloc_to_page ((void *)vaddr);
@@ -241,7 +241,7 @@
ksocknal_lib_send_iov (ksock_conn_t *conn, ksock_tx_t *tx)
{
struct socket *sock = conn->ksnc_sock;
-#if (SOCKNAL_ZC && SOCKNAL_VADDR_ZC)
+#if defined(SOCKNAL_ZC) && defined(SOCKNAL_VADDR_ZC)
unsigned long vaddr = (unsigned long)iov->iov_base
int offset = vaddr & (PAGE_SIZE - 1);
int zcsize = MIN (iov->iov_len, PAGE_SIZE - offset);
@@ -253,7 +253,7 @@
/* NB we can''t trust socket ops to either consume our iovs
* or leave them alone. */
-#if (SOCKNAL_ZC && SOCKNAL_VADDR_ZC)
+#if defined(SOCKNAL_ZC) && defined(SOCKNAL_VADDR_ZC)
if (zcsize >= ksocknal_data.ksnd_zc_min_frag &&
(sock->sk->sk_route_caps & NETIF_F_SG) &&
(sock->sk->sk_route_caps & (NETIF_F_IP_CSUM |
NETIF_F_NO_CSUM | NETIF_F_HW_CSUM)) &&
@@ -271,7 +271,7 @@
} else
#endif
{
-#if SOCKNAL_SINGLE_FRAG_TX
+#ifdef SOCKNAL_SINGLE_FRAG_TX
struct iovec scratch;
struct iovec *scratchiov = &scratch;
unsigned int niov = 1;
@@ -318,7 +318,7 @@
/* NB we can''t trust socket ops to either consume our iovs
* or leave them alone. */
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
if (kiov->kiov_len >= *ksocknal_tunables.ksnd_zc_min_frag
&&
(sock->sk->sk_route_caps & NETIF_F_SG) &&
(sock->sk->sk_route_caps & (NETIF_F_IP_CSUM |
NETIF_F_NO_CSUM | NETIF_F_HW_CSUM))) {
@@ -339,7 +339,7 @@
} else
#endif
{
-#if SOCKNAL_SINGLE_FRAG_TX || !SOCKNAL_RISK_KMAP_DEADLOCK
+#if defined(SOCKNAL_SINGLE_FRAG_TX) || !defined(SOCKNAL_RISK_KMAP_DEADLOCK)
struct iovec scratch;
struct iovec *scratchiov = &scratch;
unsigned int niov = 1;
@@ -403,7 +403,7 @@
int
ksocknal_lib_recv_iov (ksock_conn_t *conn)
{
-#if SOCKNAL_SINGLE_FRAG_RX
+#ifdef SOCKNAL_SINGLE_FRAG_RX
struct iovec scratch;
struct iovec *scratchiov = &scratch;
unsigned int niov = 1;
@@ -447,7 +447,7 @@
int
ksocknal_lib_recv_kiov (ksock_conn_t *conn)
{
-#if SOCKNAL_SINGLE_FRAG_RX || !SOCKNAL_RISK_KMAP_DEADLOCK
+#if defined(SOCKNAL_SINGLE_FRAG_RX) || !defined(SOCKNAL_RISK_KMAP_DEADLOCK)
struct iovec scratch;
struct iovec *scratchiov = &scratch;
unsigned int niov = 1;
@@ -589,7 +589,7 @@
}
/* TCP_BACKOFF_* sockopt tunables unsupported in stock kernels */
-#if SOCKNAL_BACKOFF
+#ifdef SOCKNAL_BACKOFF
if (*ksocknal_tunables.ksnd_backoff_init > 0) {
option = *ksocknal_tunables.ksnd_backoff_init;
diff -Nru lustre-1.5.95-/lnet/klnds/socklnd/socklnd_modparams.c
lustre-1.5.95/lnet/klnds/socklnd/socklnd_modparams.c
--- lustre-1.5.95-/lnet/klnds/socklnd/socklnd_modparams.c 2006-07-25
22:49:19.000000000 +0300
+++ lustre-1.5.95/lnet/klnds/socklnd/socklnd_modparams.c 2006-11-02
00:41:10.000000000 +0200
@@ -80,19 +80,19 @@
CFS_MODULE_PARM(keepalive_intvl, "i", int, 0644,
"seconds between probes");
-#if CPU_AFFINITY
+#ifdef CPU_AFFINITY
static int enable_irq_affinity = SOCKNAL_IRQ_AFFINITY;
CFS_MODULE_PARM(enable_irq_affinity, "i", int, 0644,
"enable IRQ affinity");
#endif
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
static unsigned int zc_min_frag = SOCKNAL_ZC_MIN_FRAG;
CFS_MODULE_PARM(zc_min_frag, "i", int, 0644,
"minimum fragment to zero copy");
#endif
-#if SOCKNAL_BACKOFF
+#ifdef SOCKNAL_BACKOFF
static int backoff_init = SOCKNAL_BACKOFF_INIT;
CFS_MODULE_PARM(backoff_init, "i", int, 0644,
"seconds for initial tcp backoff");
@@ -118,13 +118,13 @@
.ksnd_keepalive_idle = &keepalive_idle,
.ksnd_keepalive_count = &keepalive_count,
.ksnd_keepalive_intvl = &keepalive_intvl,
-#if SOCKNAL_ZC
+#ifdef SOCKNAL_ZC
.ksnd_zc_min_frag = &zc_min_frag,
#endif
-#if CPU_AFFINITY
+#ifdef CPU_AFFINITY
.ksnd_irq_affinity = &enable_irq_affinity,
#endif
-#if SOCKNAL_BACKOFF
+#ifdef SOCKNAL_BACKOFF
.ksnd_backoff_init = &backoff_init,
.ksnd_backoff_max = &backoff_max,
#endif
diff -Nru lustre-1.5.95-/lnet/libcfs/linux/linux-proc.c
lustre-1.5.95/lnet/libcfs/linux/linux-proc.c
--- lustre-1.5.95-/lnet/libcfs/linux/linux-proc.c 2006-06-29 20:10:03.000000000
+0300
+++ lustre-1.5.95/lnet/libcfs/linux/linux-proc.c 2006-11-02 00:41:10.000000000
+0200
@@ -229,7 +229,7 @@
int insert_proc(void)
{
struct proc_dir_entry *ent;
-#if PORTALS_PROFILING
+#ifdef PORTALS_PROFILING
unsigned char dir[128];
if (ARRAY_SIZE(prof_ents) != MAX_PROFS) {
@@ -290,7 +290,7 @@
void remove_proc(void)
{
-#if PORTALS_PROFILING
+#ifdef PORTALS_PROFILING
unsigned char dir[128];
int end;
diff -Nru lustre-1.5.95-/lustre/include/obd_support.h
lustre-1.5.95/lustre/include/obd_support.h
--- lustre-1.5.95-/lustre/include/obd_support.h 2006-09-06 20:44:57.000000000
+0300
+++ lustre-1.5.95/lustre/include/obd_support.h 2006-11-02 00:41:10.000000000
+0200
@@ -314,7 +314,7 @@
#define POISON(ptr, c, s) memset(ptr, c, s)
#endif
-#if POISON_BULK
+#ifdef POISON_BULK
#define POISON_PAGE(page, val) do { memset(kmap(page), val, PAGE_SIZE); \
kunmap(page); } while (0)
#else
diff -Nru
lustre-1.5.95-/lustre/kernel_patches/patches/export-tasklist-2.6.18-vanilla.patch
lustre-1.5.95/lustre/kernel_patches/patches/export-tasklist-2.6.18-vanilla.patch
---
lustre-1.5.95-/lustre/kernel_patches/patches/export-tasklist-2.6.18-vanilla.patch
1970-01-01 03:00:00.000000000 +0300
+++
lustre-1.5.95/lustre/kernel_patches/patches/export-tasklist-2.6.18-vanilla.patch
2006-11-02 00:41:10.000000000 +0200
@@ -0,0 +1,11 @@
+--- linux-2.6.18/kernel/fork.c- 2006-11-01 23:38:27.000000000 +0200
++++ linux-2.6.18/kernel/fork.c 2006-11-01 23:38:48.000000000 +0200
+@@ -65,6 +65,8 @@
+
+ __cacheline_aligned DEFINE_RWLOCK(tasklist_lock); /* outer */
+
++EXPORT_SYMBOL(tasklist_lock);
++
+ int nr_processes(void)
+ {
+ int cpu;
diff -Nru
lustre-1.5.95-/lustre/kernel_patches/patches/ext3-utsname-2.6.18-vanilla.patch
lustre-1.5.95/lustre/kernel_patches/patches/ext3-utsname-2.6.18-vanilla.patch
---
lustre-1.5.95-/lustre/kernel_patches/patches/ext3-utsname-2.6.18-vanilla.patch
1970-01-01 03:00:00.000000000 +0300
+++
lustre-1.5.95/lustre/kernel_patches/patches/ext3-utsname-2.6.18-vanilla.patch
2006-11-02 00:41:10.000000000 +0200
@@ -0,0 +1,10 @@
+--- linux-2.6.18/fs/ext3/super.c- 2006-11-01 23:32:05.000000000 +0200
++++ linux-2.6.18/fs/ext3/super.c 2006-11-01 23:32:31.000000000 +0200
+@@ -19,6 +19,7 @@
+ #include <linux/module.h>
+ #include <linux/string.h>
+ #include <linux/fs.h>
++#include <linux/utsname.h>
+ #include <linux/time.h>
+ #include <linux/jbd.h>
+ #include <linux/ext3_fs.h>
diff -Nru lustre-1.5.95-/lustre/kernel_patches/series/2.6.18-vanilla.series
lustre-1.5.95/lustre/kernel_patches/series/2.6.18-vanilla.series
--- lustre-1.5.95-/lustre/kernel_patches/series/2.6.18-vanilla.series 2006-08-31
09:22:25.000000000 +0300
+++ lustre-1.5.95/lustre/kernel_patches/series/2.6.18-vanilla.series 2006-11-02
00:41:33.000000000 +0200
@@ -2,18 +2,21 @@
vfs_intent-2.6.18-vanilla.patch
vfs_nointent-2.6.18-vanilla.patch
vfs_races-2.6.18-vanilla.patch
-ext3-wantedi-misc-2.6.18-vanilla.patch
+ext3-wantedi-misc-2.6.18-vanilla.patch
+ext3-utsname-2.6.18-vanilla.patch
jbd-jcberr-2.6.18-vanilla.patch
iopen-misc-2.6.18-vanilla.patch
export-truncate-2.6.18-vanilla.patch
export_symbols-2.6.18-vanilla.patch
+export-tasklist-2.6.18-vanilla.patch
dev_read_only-2.6.18-vanilla.patch
export-2.6.18-vanilla.patch
lookup_bdev_init_intent-2.6.18-vanilla.patch
8kstack-2.6.12.patch
remove-suid-2.6-suse.patch
export-show_task-2.6.18-vanilla.patch
-sd_iostats-2.6-rhel4.patch
+sd_iostats-2.6-rhel4.patch
+fsprivate-2.6.patch
export_symbol_numa-2.6-fc5.patch
tcp-zero-copy-2.6.18-vanilla.patch
export-do_kern_mount.patch
diff -Nru lustre-1.5.95-/lustre/ldiskfs/Makefile.in
lustre-1.5.95/lustre/ldiskfs/Makefile.in
--- lustre-1.5.95-/lustre/ldiskfs/Makefile.in 2006-07-25 04:13:13.000000000
+0300
+++ lustre-1.5.95/lustre/ldiskfs/Makefile.in 2006-11-02 00:41:10.000000000 +0200
@@ -11,7 +11,7 @@
linux_headers := $(wildcard @LINUX@/include/linux/ext3*.h)
ext3_sources := $(filter-out %.mod.c,$(wildcard @LINUX@/fs/ext3/*.c))
-new_sources := iopen.c iopen.h extents.c mballoc.c
+new_sources := iopen.c iopen.h extents.c mballoc.c al.h
new_headers := ext3_extents.h
ldiskfs_patched_sources := $(notdir $(ext3_sources) $(ext3_headers))
$(new_sources) $(new_headers)
ldiskfs_sources := $(ldiskfs_patched_sources)
diff -Nru lustre-1.5.95-/lustre/llite/dcache.c
lustre-1.5.95/lustre/llite/dcache.c
--- lustre-1.5.95-/lustre/llite/dcache.c 2006-09-01 08:39:40.000000000 +0300
+++ lustre-1.5.95/lustre/llite/dcache.c 2006-11-02 00:41:10.000000000 +0200
@@ -619,7 +619,7 @@
ENTRY;
if (nd && nd->flags & LOOKUP_LAST &&
!(nd->flags & LOOKUP_LINK_NOTLAST))
- rc = ll_revalidate_it(dentry, nd->flags,
&nd->intent);
+ rc = ll_revalidate_it(dentry, nd->flags,
&nd->intent.open);
else
rc = ll_revalidate_it(dentry, 0, NULL);
diff -Nru lustre-1.5.95-/lustre/llite/llite_internal.h
lustre-1.5.95/lustre/llite/llite_internal.h
--- lustre-1.5.95-/lustre/llite/llite_internal.h 2006-09-01 08:39:40.000000000
+0300
+++ lustre-1.5.95/lustre/llite/llite_internal.h 2006-11-02 00:41:10.000000000
+0200
@@ -48,7 +48,7 @@
static inline struct lookup_intent *ll_nd2it(struct nameidata *nd)
{
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))
- return &nd->intent;
+ return &nd->intent.open;
#else
return nd->intent;
#endif
@@ -511,14 +511,22 @@
void ll_clear_inode(struct inode *inode);
int ll_setattr_raw(struct inode *inode, struct iattr *attr);
int ll_setattr(struct dentry *de, struct iattr *attr);
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
int ll_statfs(struct super_block *sb, struct kstatfs *sfs);
+#else
+int ll_statfs(struct dentry *de, struct kstatfs *sfs);
+#endif
int ll_statfs_internal(struct super_block *sb, struct obd_statfs *osfs,
__u64 max_age);
void ll_update_inode(struct inode *inode, struct lustre_md *md);
void ll_read_inode2(struct inode *inode, void *opaque);
int ll_iocontrol(struct inode *inode, struct file *file,
unsigned int cmd, unsigned long arg);
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
void ll_umount_begin(struct super_block *sb);
+#else
+void ll_umount_begin(struct vfsmount *, int);
+#endif
int ll_remount_fs(struct super_block *sb, int *flags, char *data);
int ll_prep_inode(struct obd_export *exp, struct inode **inode,
struct ptlrpc_request *req, int offset, struct super_block
*);
diff -Nru lustre-1.5.95-/lustre/llite/llite_lib.c
lustre-1.5.95/lustre/llite/llite_lib.c
--- lustre-1.5.95-/lustre/llite/llite_lib.c 2006-09-01 08:39:40.000000000 +0300
+++ lustre-1.5.95/lustre/llite/llite_lib.c 2006-11-02 00:41:10.000000000 +0200
@@ -1410,8 +1410,14 @@
RETURN(rc);
}
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
int ll_statfs(struct super_block *sb, struct kstatfs *sfs)
{
+#else
+int ll_statfs(struct dentry *de, struct kstatfs *sfs)
+{
+ struct super_block *sb = de->d_sb;
+#endif
struct obd_statfs osfs;
int rc;
@@ -1754,8 +1760,14 @@
}
/* umount -f client means force down, don''t save state */
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
void ll_umount_begin(struct super_block *sb)
{
+#else
+void ll_umount_begin(struct vfsmount *mnt, int flags)
+{
+ struct super_block *sb = mnt->mnt_sb;
+#endif
struct lustre_sb_info *lsi = s2lsi(sb);
struct ll_sb_info *sbi = ll_s2sbi(sb);
struct obd_device *obd;
diff -Nru lustre-1.5.95-/lustre/llite/namei.c lustre-1.5.95/lustre/llite/namei.c
--- lustre-1.5.95-/lustre/llite/namei.c 2006-08-10 16:46:05.000000000 +0300
+++ lustre-1.5.95/lustre/llite/namei.c 2006-11-02 00:41:10.000000000 +0200
@@ -559,7 +559,7 @@
ENTRY;
if (nd && nd->flags & LOOKUP_LAST &&
!(nd->flags & LOOKUP_LINK_NOTLAST))
- de = ll_lookup_it(parent, dentry, &nd->intent,
nd->flags);
+ de = ll_lookup_it(parent, dentry, &nd->intent.open,
nd->flags);
else
de = ll_lookup_it(parent, dentry, NULL, 0);
@@ -873,11 +873,11 @@
static int ll_create_nd(struct inode *dir, struct dentry *dentry, int mode,
struct nameidata *nd)
{
- if (!nd || !nd->intent.d.lustre.it_disposition)
+ if (!nd || !nd->intent.open.d.lustre.it_disposition)
/* No saved request? Just mknod the file */
return ll_mknod_generic(dir, &dentry->d_name, mode, 0,
dentry);
- return ll_create_it(dir, dentry, mode, &nd->intent);
+ return ll_create_it(dir, dentry, mode, &nd->intent.open);
}
#endif
#endif
diff -Nru lustre-1.5.95-/lustre/llite/rw26.c lustre-1.5.95/lustre/llite/rw26.c
--- lustre-1.5.95-/lustre/llite/rw26.c 2006-06-11 19:54:28.000000000 +0300
+++ lustre-1.5.95/lustre/llite/rw26.c 2006-11-02 00:41:10.000000000 +0200
@@ -58,6 +58,7 @@
/* It is safe to not check anything in invalidatepage/releasepage below
because they are run with page locked and all our io is happening with
locked page too */
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
static int ll_invalidatepage(struct page *page, unsigned long offset)
{
if (offset)
@@ -66,6 +67,13 @@
ll_removepage(page);
return 1;
}
+#else
+static void ll_invalidatepage(struct page *page, unsigned long offset)
+{
+ if (!offset && PagePrivate(page))
+ ll_removepage(page);
+}
+#endif
static int ll_releasepage(struct page *page, gfp_t gfp_mask)
{
diff -Nru lustre-1.5.95-/lustre/lvfs/fsfilt_ext3.c
lustre-1.5.95/lustre/lvfs/fsfilt_ext3.c
--- lustre-1.5.95-/lustre/lvfs/fsfilt_ext3.c 2006-09-01 12:25:26.000000000 +0300
+++ lustre-1.5.95/lustre/lvfs/fsfilt_ext3.c 2006-11-02 00:41:10.000000000 +0200
@@ -728,7 +728,11 @@
memset(&sfs, 0, sizeof(sfs));
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
rc = sb->s_op->statfs(sb, &sfs);
+#else
+ rc = sb->s_op->statfs(sb->s_root, &sfs);
+#endif
if (!rc && sfs.f_bfree < sfs.f_ffree) {
sfs.f_files = (sfs.f_files - sfs.f_ffree) + sfs.f_bfree;
diff -Nru lustre-1.5.95-/lustre/obdclass/obd_mount.c
lustre-1.5.95/lustre/obdclass/obd_mount.c
--- lustre-1.5.95-/lustre/obdclass/obd_mount.c 2006-09-07 01:00:20.000000000
+0300
+++ lustre-1.5.95/lustre/obdclass/obd_mount.c 2006-11-02 00:41:10.000000000
+0200
@@ -1379,8 +1379,14 @@
EXIT;
}
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
static void server_umount_begin(struct super_block *sb)
{
+#else
+static void server_umount_begin(struct vfsmount *mnt, int flags)
+{
+ struct super_block *sb = mnt->mnt_sb;
+#endif
struct lustre_sb_info *lsi = s2lsi(sb);
ENTRY;
@@ -1393,13 +1399,23 @@
EXIT;
}
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
static int server_statfs (struct super_block *sb, struct kstatfs *buf)
{
+#else
+static int server_statfs (struct dentry *de, struct kstatfs *buf)
+{
+ struct super_block *sb = de->d_sb;
+#endif
struct vfsmount *mnt = s2lsi(sb)->lsi_srv_mnt;
ENTRY;
if (mnt && mnt->mnt_sb &&
mnt->mnt_sb->s_op->statfs) {
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
int rc = mnt->mnt_sb->s_op->statfs(mnt->mnt_sb,
buf);
+#else
+ int rc = mnt->mnt_sb->s_op->statfs(mnt->mnt_root,
buf);
+#endif
if (!rc) {
buf->f_type = sb->s_magic;
RETURN(0);
diff -Nru lustre-1.5.95-/lustre/obdfilter/filter.c
lustre-1.5.95/lustre/obdfilter/filter.c
--- lustre-1.5.95-/lustre/obdfilter/filter.c 2006-09-06 13:23:35.000000000 +0300
+++ lustre-1.5.95/lustre/obdfilter/filter.c 2006-11-02 00:41:10.000000000 +0200
@@ -438,7 +438,7 @@
return found;
}
-#if DO_FMD_DROP
+#ifdef DO_FMD_DROP
/* drop fmd list reference so it will disappear when last reference is put.
* This isn''t so critical because it would in fact only affect the one
client
* that is doing the unlink and at worst we have an stale entry referencing
diff -Nru lustre-1.5.95-/lustre/obdfilter/filter_io_26.c
lustre-1.5.95/lustre/obdfilter/filter_io_26.c
--- lustre-1.5.95-/lustre/obdfilter/filter_io_26.c 2006-09-06 05:58:53.000000000
+0300
+++ lustre-1.5.95/lustre/obdfilter/filter_io_26.c 2006-11-02 00:41:10.000000000
+0200
@@ -387,11 +387,15 @@
if (!locked)
LOCK_INODE_MUTEX(inode);
if (inode->i_mapping->nrpages) {
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
current->flags |= PF_SYNCWRITE;
+#endif
rc = filemap_fdatawrite(inode->i_mapping);
if (rc == 0)
rc = filemap_fdatawait(inode->i_mapping);
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
current->flags &= ~PF_SYNCWRITE;
+#endif
}
if (!locked)
UNLOCK_INODE_MUTEX(inode);
diff -Nru lustre-1.5.95-/lustre/ptlrpc/pack_generic.c
lustre-1.5.95/lustre/ptlrpc/pack_generic.c
--- lustre-1.5.95-/lustre/ptlrpc/pack_generic.c 2006-09-01 03:53:21.000000000
+0300
+++ lustre-1.5.95/lustre/ptlrpc/pack_generic.c 2006-11-02 00:41:10.000000000
+0200
@@ -36,6 +36,7 @@
#include <obd_support.h>
#include <obd_class.h>
#include <lustre_net.h>
+#include <lustre_ver.h>
#if LUSTRE_VERSION_CODE > OBD_OCD_VERSION(2,0,0,0)
#error "lustre_msg_v1 has been deprecated since 1.6.0, please remove
it"
diff -Nru lustre-1.5.95-/lustre/ptlrpc/service.c
lustre-1.5.95/lustre/ptlrpc/service.c
--- lustre-1.5.95-/lustre/ptlrpc/service.c 2006-07-12 01:12:42.000000000 +0300
+++ lustre-1.5.95/lustre/ptlrpc/service.c 2006-11-02 00:41:10.000000000 +0200
@@ -542,7 +542,7 @@
svc->srv_n_active_reqs);
}
-#if SWAB_PARANOIA
+#ifdef SWAB_PARANOIA
/* Clear request swab mask; this is a new request */
request->rq_req_swab_mask = 0;
#endif
@@ -880,7 +880,7 @@
ptlrpc_daemonize(data->name);
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,9) && CONFIG_NUMA
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,9)) &&
defined(CONFIG_NUMA)
/* we need to do this before any per-thread allocation is done so that
* we get the per-thread allocations on local node. bug 7342 */
if (svc->srv_cpu_affinity) {
--- lustre-1.5.95/lustre/llite/namei.c- 2006-11-02 19:42:55.000000000 +0200
+++ lustre-1.5.95/lustre/llite/namei.c 2006-11-02 19:43:40.000000000 +0200
@@ -369,7 +369,7 @@
* such inode, because if some vendor''s kernel contains this bugfix
already,
* we will break everything then. We will use our own reimplementation
* instead. */
-#if !defined(HAVE_D_ADD_UNIQUE) || (LINUX_VERSION_CODE <
KERNEL_VERSION(2,6,16))
+#if !defined(HAVE_D_ADD_UNIQUE) || (LINUX_VERSION_CODE <
KERNEL_VERSION(2,6,19))
/* Search "inode"''s alias list for a dentry that has the
same name and parent as
* de. If found, return it. If not found, return de. */
struct dentry *ll_find_alias(struct inode *inode, struct dentry *de)