From: pcaulfield@sourceware.org <pcaulfield@sourceware.org>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] cluster cman-kernel/src/cnxman.c cman-kernel/s ...
Date: 25 Jan 2008 10:50:38 -0000 [thread overview]
Message-ID: <20080125105038.30450.qmail@sourceware.org> (raw)
CVSROOT: /cvs/cluster
Module name: cluster
Branch: STABLE
Changes by: pcaulfield at sourceware.org 2008-01-25 10:50:36
Modified files:
cman-kernel/src: cnxman.c membership.c
dlm-kernel/src : lowcomms.c memory.c
Log message:
Make cman & dlm compile with 2.6.24 kernels.
I know no-one cares about this branch any more, but it makes my life a
little easier. And no, I am /not/ doing gfs-kernel too...
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/cman-kernel/src/cnxman.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.42.2.12.4.1.2.16&r2=1.42.2.12.4.1.2.17
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/cman-kernel/src/membership.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.44.2.18.6.9&r2=1.44.2.18.6.10
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/dlm-kernel/src/lowcomms.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.22.2.8.4.2.2.4&r2=1.22.2.8.4.2.2.5
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/dlm-kernel/src/memory.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.3.8.1&r2=1.3.8.2
--- cluster/cman-kernel/src/Attic/cnxman.c 2007/02/27 10:38:04 1.42.2.12.4.1.2.16
+++ cluster/cman-kernel/src/Attic/cnxman.c 2008/01/25 10:50:36 1.42.2.12.4.1.2.17
@@ -929,12 +929,12 @@
return;
}
-static struct sock *cl_alloc_sock(struct socket *sock, int gfp, int protocol)
+static struct sock *cl_alloc_sock(struct net *net, struct socket *sock, int gfp, int protocol)
{
struct sock *sk;
struct cluster_sock *c;
- if ((sk = sk_alloc(AF_CLUSTER, gfp, &cl_proto, 1)) == NULL)
+ if ((sk = sk_alloc(net, AF_CLUSTER, gfp, &cl_proto)) == NULL)
goto no_sock;
if (sock) {
@@ -1022,7 +1022,7 @@
return 0;
}
-static int cl_create(struct socket *sock, int protocol)
+static int cl_create(struct net *net, struct socket *sock, int protocol)
{
struct sock *sk;
@@ -1045,7 +1045,7 @@
if (!atomic_read(&cnxman_running) && protocol != CLPROTO_MASTER)
return -ENETDOWN;
- if ((sk = cl_alloc_sock(sock, GFP_KERNEL, protocol)) == NULL)
+ if ((sk = cl_alloc_sock(net, sock, GFP_KERNEL, protocol)) == NULL)
return -ENOBUFS;
sk->sk_protocol = protocol;
--- cluster/cman-kernel/src/Attic/membership.c 2007/01/19 16:21:36 1.44.2.18.6.9
+++ cluster/cman-kernel/src/Attic/membership.c 2008/01/25 10:50:36 1.44.2.18.6.10
@@ -166,7 +166,7 @@
/* State of the node */
static enum { STARTING, NEWCLUSTER, JOINING, JOINWAIT, JOINACK, TRANSITION,
TRANSITION_COMPLETE, MEMBER, REJECTED, LEFT_CLUSTER, MASTER
-} node_state = LEFT_CLUSTER;
+} cman_node_state = LEFT_CLUSTER;
/* Sub-state when we are MASTER */
static enum { MASTER_START, MASTER_COLLECT, MASTER_CONFIRM,
@@ -303,18 +303,18 @@
cman_set_realtime(current, 1);
- while (node_state != REJECTED && node_state != LEFT_CLUSTER &&
+ while (cman_node_state != REJECTED && cman_node_state != LEFT_CLUSTER &&
quit_threads == 0) {
/* Scan the nodes list for dead nodes */
- if (node_state == MEMBER)
+ if (cman_node_state == MEMBER)
check_for_dead_nodes();
set_task_state(current, TASK_INTERRUPTIBLE);
schedule();
set_task_state(current, TASK_RUNNING);
- if (node_state != REJECTED && node_state != LEFT_CLUSTER)
+ if (cman_node_state != REJECTED && cman_node_state != LEFT_CLUSTER)
send_hello();
}
if (timer_pending(&hello_timer))
@@ -383,7 +383,7 @@
transition_end_time = jiffies;
/* Main loop */
- while (node_state != REJECTED && node_state != LEFT_CLUSTER && !quit_threads) {
+ while (cman_node_state != REJECTED && cman_node_state != LEFT_CLUSTER && !quit_threads) {
struct task_struct *tsk = current;
@@ -394,8 +394,8 @@
if (!skb_peek(&mem_socket->sk->sk_receive_queue) &&
wake_flags == 0) {
- if (node_state == JOINACK ||
- node_state == JOINWAIT)
+ if (cman_node_state == JOINACK ||
+ cman_node_state == JOINWAIT)
schedule_timeout(HZ);
else
schedule();
@@ -405,7 +405,7 @@
remove_wait_queue(mem_socket->sk->sk_sleep, &wait);
/* Are we being shut down? */
- if (node_state == LEFT_CLUSTER || quit_threads ||
+ if (cman_node_state == LEFT_CLUSTER || quit_threads ||
signal_pending(current))
break;
@@ -444,26 +444,26 @@
/* Got a JOINACK but no JOIN-CONF, start waiting for HELLO
* messages again */
- if (node_state == JOINACK &&
+ if (cman_node_state == JOINACK &&
time_after(jiffies,
join_time + cman_config.join_timeout * HZ)) {
P_MEMB
("Waited a long time for a join-conf, going back to JOINWAIT state\n");
- node_state = JOINWAIT;
+ cman_node_state = JOINWAIT;
joinwait_time = jiffies;
}
/* Have we had an ACK for our JOINREQ message ? */
- if (node_state == JOINING &&
+ if (cman_node_state == JOINING &&
time_after(jiffies,
join_time + cman_config.join_timeout * HZ)) {
P_MEMB("didn't get JOINACK, going back to JOINWAIT\n");
- node_state = JOINWAIT;
+ cman_node_state = JOINWAIT;
joinwait_time = jiffies;
}
/* Have we been in joinwait for too long... */
- if (node_state == JOINWAIT &&
+ if (cman_node_state == JOINWAIT &&
time_after(jiffies,
joinwait_time + cman_config.joinwait_timeout * HZ)) {
printk(KERN_WARNING CMAN_NAME
@@ -483,7 +483,7 @@
if (timer_pending(&transition_timer))
del_timer(&transition_timer);
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
P_MEMB("closing down\n");
quit_threads = 1; /* force other thread to exit too */
@@ -510,7 +510,7 @@
P_MEMB("Timer wakeup - checking for dead master node %ld\n", jiffies);
/* Resend JOINCONF if it got lost on the wire */
- if (node_state == MASTER && master_state == MASTER_CONFIRM) {
+ if (cman_node_state == MASTER && master_state == MASTER_CONFIRM) {
mod_timer(&transition_timer,
jiffies + cman_config.joinconf_timeout * HZ);
if (++joinconf_count < cman_config.max_retries) {
@@ -534,7 +534,7 @@
}
/* See if the master is still there */
- if (node_state == TRANSITION || node_state == TRANSITION_COMPLETE) {
+ if (cman_node_state == TRANSITION || cman_node_state == TRANSITION_COMPLETE) {
/* If we are in transition and master_node is NULL then we are
* waiting for ENDTRANS after JOIN-CONF */
@@ -578,7 +578,7 @@
}
/* If we are the master node then restart the transition */
- if (node_state == MASTER) {
+ if (cman_node_state == MASTER) {
start_transition(TRANS_RESTART, us);
}
@@ -588,7 +588,7 @@
static void form_cluster(void)
{
printk(KERN_INFO CMAN_NAME ": forming a new cluster\n");
- node_state = MEMBER;
+ cman_node_state = MEMBER;
we_are_a_cluster_member = TRUE;
us->state = NODESTATE_MEMBER;
if (wanted_nodeid)
@@ -603,7 +603,7 @@
/* This does the initial JOIN part of the membership process. Actually most of
* is done in the message processing routines but this is the main loop that
- * controls it. The side-effect of this routine is "node_state" which tells the
+ * controls it. The side-effect of this routine is "cman_node_state" which tells the
* real main loop (in the kernel thread routine) what to do next */
static void join_or_form_cluster()
{
@@ -635,21 +635,21 @@
dispatch_messages(mem_socket);
}
if (quit_threads)
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
}
while (time_before(jiffies, start_time + cman_config.joinwait_timeout * HZ) &&
- node_state == STARTING);
+ cman_node_state == STARTING);
- if (node_state == STARTING) {
+ if (cman_node_state == STARTING) {
start_time = jiffies;
joinwait_time = jiffies;
- node_state = NEWCLUSTER;
+ cman_node_state = NEWCLUSTER;
}
/* If we didn't hear any HELLO messages then start sending NEWCLUSTER messages */
while (time_before(jiffies, start_time + cman_config.newcluster_timeout * HZ) &&
- node_state == NEWCLUSTER) {
+ cman_node_state == NEWCLUSTER) {
DECLARE_WAITQUEUE(wait, current);
@@ -669,19 +669,19 @@
dispatch_messages(mem_socket);
}
/* Did we get a lower "NEWCLUSTER" message ? */
- if (node_state == STARTING) {
+ if (cman_node_state == STARTING) {
P_MEMB("NEWCLUSTER: restarting joinwait\n");
goto restart_joinwait;
}
if (quit_threads)
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
}
/* If we didn't hear any HELLO messages then form a new cluster */
- if (node_state == NEWCLUSTER) {
+ if (cman_node_state == NEWCLUSTER) {
form_cluster();
}
else
@@ -730,7 +730,7 @@
return result;
}
- node_state = STARTING;
+ cman_node_state = STARTING;
return 0;
}
@@ -884,7 +884,7 @@
mod_timer(&hello_timer, jiffies + cman_config.hello_timer * HZ);
- if (node_state >= TRANSITION) {
+ if (cman_node_state >= TRANSITION) {
if (!wake_up_process(hello_task))
P_MEMB("Failed to wake up hello thread\n");
}
@@ -974,7 +974,7 @@
leavereason = 0;
transitionreason = TRANS_NONE;
- node_state = MEMBER;
+ cman_node_state = MEMBER;
transition_end_time = jiffies;
sm_member_update(cluster_is_quorate);
@@ -1026,7 +1026,7 @@
saddr.scl_port = CLUSTER_PORT_MEMBERSHIP;
/* If we are in transition then use the current master */
- if (node_state == TRANSITION) {
+ if (cman_node_state == TRANSITION) {
node = master_node;
}
if (!node) {
@@ -1059,7 +1059,7 @@
}
/* And exit */
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
wake_up_process(membership_task);
return 0;
}
@@ -1130,24 +1130,24 @@
break;
case CLUSTER_MEM_JOINCONF:
- if (node_state == JOINACK) {
+ if (cman_node_state == JOINACK) {
do_process_joinconf(msg, buf, len);
}
break;
case CLUSTER_MEM_CONFACK:
- if (node_state == MASTER && master_state == MASTER_CONFIRM) {
+ if (cman_node_state == MASTER && master_state == MASTER_CONFIRM) {
end_transition();
}
break;
case CLUSTER_MEM_MASTERVIEW:
- if (node_state == TRANSITION)
+ if (cman_node_state == TRANSITION)
do_process_masterview(msg, buf, len);
break;
case CLUSTER_MEM_JOINACK:
- if (node_state == JOINING || node_state == JOINWAIT) {
+ if (cman_node_state == JOINING || cman_node_state == JOINWAIT) {
do_process_joinack(msg, buf, len);
}
break;
@@ -1170,12 +1170,12 @@
break;
case CLUSTER_MEM_VIEWACK:
- if (node_state == MASTER && master_state == MASTER_COLLECT)
+ if (cman_node_state == MASTER && master_state == MASTER_COLLECT)
result = do_process_viewack(msg, buf, len);
break;
case CLUSTER_MEM_STARTACK:
- if (node_state == MASTER)
+ if (cman_node_state == MASTER)
result = do_process_startack(msg, buf, len);
break;
@@ -1184,7 +1184,7 @@
break;
case CLUSTER_MEM_NOMINATE:
- if (node_state != MASTER)
+ if (cman_node_state != MASTER)
result = do_process_nominate(msg, buf, len);
break;
@@ -1281,7 +1281,7 @@
printk(KERN_WARNING CMAN_NAME
": too many transition restarts - will die\n");
us->leave_reason = CLUSTER_LEAVEFLAG_INCONSISTENT;
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
quit_threads = 1;
wake_up_process(membership_task);
wake_up_interruptible(&cnxman_waitq);
@@ -1303,7 +1303,7 @@
if (reason == TRANS_NEWNODE)
joining_node = node;
- node_state = MASTER;
+ cman_node_state = MASTER;
master_state = MASTER_START;
responses_collected = 0;
responses_expected = cluster_members - 1;
@@ -1404,7 +1404,7 @@
/* If we are in normal operation then become master and initiate a
* state-transition */
- if (node_state == MEMBER) {
+ if (cman_node_state == MEMBER) {
start_transition(TRANS_REMNODE, node);
return;
}
@@ -1412,11 +1412,11 @@
/* If we are a slave in transition then see if it's the master that has
* failed. If not then ignore it. If it /is/ the master then elect a
* new one */
- if (node_state == TRANSITION) {
+ if (cman_node_state == TRANSITION) {
if (master_node == node) {
if (elect_master(&node, 0)) {
del_timer(&transition_timer);
- node_state = MASTER;
+ cman_node_state = MASTER;
master_node->leave_reason = CLUSTER_LEAVEFLAG_NORESPONSE;
start_transition(TRANS_DEADMASTER, master_node);
@@ -1430,7 +1430,7 @@
/* If we are the master then we need to start the transition all over
* again */
- if (node_state == MASTER) {
+ if (cman_node_state == MASTER) {
/* Cancel timer */
del_timer(&transition_timer);
@@ -1772,7 +1772,7 @@
if (node->us) {
printk(KERN_INFO CMAN_NAME
": killed by NODEDOWN message\n");
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
quit_threads = 1;
wake_up_process(membership_task);
wake_up_interruptible(&cnxman_waitq);
@@ -1843,7 +1843,7 @@
/* Got a STARTACK response from a node */
static int do_process_startack(struct msghdr *msg, char *buf, int len)
{
- if (node_state != MASTER && master_state != MASTER_START) {
+ if (cman_node_state != MASTER && master_state != MASTER_START) {
P_MEMB("Got StartACK when not in MASTER_STARTING substate\n");
return 0;
}
@@ -1882,7 +1882,7 @@
set_quorate(total_votes);
leavereason = 0;
joining_temp_nodeid = 0;
- node_state = MEMBER;
+ cman_node_state = MEMBER;
notify_listeners();
sm_member_update(cluster_is_quorate);
}
@@ -1973,7 +1973,7 @@
dissenting_nodes = 0;
kfree(node_opinion);
node_opinion = NULL;
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
quit_threads = 1;
wake_up_process(membership_task);
wake_up_interruptible(&cnxman_waitq);
@@ -2056,7 +2056,7 @@
struct sockaddr_cl *saddr = (struct sockaddr_cl *) msg->msg_name;
/* Someone else's state transition */
- if (node_state != TRANSITION && node_state != JOINACK)
+ if (cman_node_state != TRANSITION && cman_node_state != JOINACK)
return 0;
/* Check we got it from the MASTER node */
@@ -2075,7 +2075,7 @@
P_MEMB("our new node ID is %d\n", us->node_id);
}
- node_state = TRANSITION_COMPLETE;
+ cman_node_state = TRANSITION_COMPLETE;
if (endmsg->new_node_id)
confirm_joiner();
@@ -2086,7 +2086,7 @@
if (wait_for_completion_barrier() != 0) {
P_MEMB("Barrier timed out - restart client(ie do nowt)\n");
- node_state = TRANSITION;
+ cman_node_state = TRANSITION;
mod_timer(&transition_timer,
jiffies + cman_config.transition_timeout * HZ);
return 0;
@@ -2106,7 +2106,7 @@
joining_node = NULL;
joining_temp_nodeid = 0;
- node_state = MEMBER;
+ cman_node_state = MEMBER;
transitionreason = TRANS_NONE;
/* Notify other listeners that transition has completed */
@@ -2158,8 +2158,8 @@
return 0;
/* Someone else's state transition */
- if (node_state != MEMBER &&
- node_state != TRANSITION && node_state != MASTER)
+ if (cman_node_state != MEMBER &&
+ cman_node_state != TRANSITION && cman_node_state != MASTER)
return 0;
/* Ignore old generation STARTTRANS messages */
@@ -2176,7 +2176,7 @@
cluster_generation = newgen;
/* If we are also a master then decide between us */
- if (node_state == MASTER) {
+ if (cman_node_state == MASTER) {
int not_master = 0;
@@ -2206,7 +2206,7 @@
/* Back down */
P_MEMB("Backing down from MASTER status\n");
master_node = node;
- node_state = TRANSITION;
+ cman_node_state = TRANSITION;
/* If we were bringing a new node into the cluster then
* we will have to abandon that now and tell the new
@@ -2229,13 +2229,13 @@
}
/* Do non-MASTER STARTTRANS bits */
- if (node_state == MEMBER) {
+ if (cman_node_state == MEMBER) {
P_MEMB("Normal transition start\n");
/* Save the master info */
master_node = find_node_by_nodeid(saddr->scl_nodeid);
- node_state = TRANSITION;
+ cman_node_state = TRANSITION;
if (startmsg->reason == TRANS_NEWNODE) {
add_node_from_starttrans(msg, buf, len);
@@ -2251,7 +2251,7 @@
}
/* We are in transition but this may be a restart */
- if (node_state == TRANSITION) {
+ if (cman_node_state == TRANSITION) {
struct cluster_node *oldjoin = joining_node;
master_node = find_node_by_nodeid(saddr->scl_nodeid);
@@ -2362,19 +2362,19 @@
join_time = jiffies;
if (ackmsg->acktype == JOINACK_TYPE_OK) {
- node_state = JOINACK;
+ cman_node_state = JOINACK;
}
if (ackmsg->acktype == JOINACK_TYPE_NAK) {
printk(KERN_WARNING CMAN_NAME
": Cluster membership rejected\n");
P_MEMB("Got JOINACK NACK\n");
- node_state = REJECTED;
+ cman_node_state = REJECTED;
}
if (ackmsg->acktype == JOINACK_TYPE_WAIT) {
P_MEMB("Got JOINACK WAIT\n");
- node_state = JOINWAIT;
+ cman_node_state = JOINWAIT;
joinwait_time = jiffies;
}
@@ -2498,8 +2498,8 @@
/* If we are in a state transition then tell the new node to wait a bit
* longer */
- if (node_state != MEMBER) {
- if (node_state == MASTER || node_state == TRANSITION) {
+ if (cman_node_state != MEMBER) {
+ if (cman_node_state == MASTER || cman_node_state == TRANSITION) {
send_joinack(msg->msg_name, msg->msg_namelen,
JOINACK_TYPE_WAIT);
}
@@ -2599,22 +2599,22 @@
{
/* If we are also in STARTING state then back down for a random period
* of time */
- if (node_state == STARTING) {
+ if (cman_node_state == STARTING) {
P_MEMB("got NEWCLUSTER, backing down for %d seconds\n", node_hash());
start_time = jiffies + node_hash() * HZ;
}
- if (node_state == NEWCLUSTER) {
+ if (cman_node_state == NEWCLUSTER) {
uint32_t otherip;
memcpy(&otherip, buf+1, sizeof(otherip));
otherip = le32_to_cpu(otherip);
P_MEMB("got NEWCLUSTER, remote ip = %x, us = %x\n", otherip, low32_of_ip());
if (otherip < low32_of_ip())
- node_state = STARTING;
+ cman_node_state = STARTING;
}
- if (node_state == MEMBER)
+ if (cman_node_state == MEMBER)
send_hello();
return 0;
@@ -2745,7 +2745,7 @@
printk(KERN_ERR CMAN_NAME
": Error procssing joinconf message - giving up on cluster join\n");
us->leave_reason = CLUSTER_LEAVEFLAG_PANIC;
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
return -1;
}
@@ -2755,7 +2755,7 @@
struct sockaddr_cl *addr = msg->msg_name;
us->state = NODESTATE_MEMBER;
- node_state = TRANSITION;
+ cman_node_state = TRANSITION;
we_are_a_cluster_member = TRUE;
ackmsg = CLUSTER_MEM_CONFACK;
@@ -2776,8 +2776,8 @@
static int num_nodes;
/* Someone else's state transition */
- if (node_state != MEMBER &&
- node_state != TRANSITION && node_state != MASTER)
+ if (cman_node_state != MEMBER &&
+ cman_node_state != TRANSITION && cman_node_state != MASTER)
return 0;
/* First message, zero the counter */
@@ -2831,20 +2831,20 @@
/* We are starting up. Send a join message to the node whose HELLO we
* just received */
- if (node_state == STARTING || node_state == JOINWAIT ||
- node_state == JOINING || node_state == NEWCLUSTER) {
+ if (cman_node_state == STARTING || cman_node_state == JOINWAIT ||
+ cman_node_state == JOINING || cman_node_state == NEWCLUSTER) {
struct sockaddr_cl *addr = msg->msg_name;
printk(KERN_INFO CMAN_NAME ": sending membership request\n");
send_joinreq(addr, msg->msg_namelen);
join_time = jiffies;
- node_state = JOINING;
+ cman_node_state = JOINING;
return 0;
}
/* Only process HELLOs if we are not in transition */
- if (node_state == MEMBER) {
+ if (cman_node_state == MEMBER) {
node = find_node_by_nodeid(saddr->scl_nodeid);
if (node && node->state != NODESTATE_DEAD) {
@@ -2855,7 +2855,7 @@
* of grace in which this is allowable */
if (cluster_generation !=
le32_to_cpu(hellomsg->generation)
- && node_state == MEMBER
+ && cman_node_state == MEMBER
&& time_after(jiffies,
cman_config.hello_timer * HZ +
transition_end_time)) {
@@ -2871,7 +2871,7 @@
}
if (cluster_members != le16_to_cpu(hellomsg->members)
- && node_state == MEMBER) {
+ && cman_node_state == MEMBER) {
printk(KERN_DEBUG CMAN_NAME
": nmembers in HELLO message from %d does not match our view (got %d, exp %d)\n",
saddr->scl_nodeid,
@@ -2893,7 +2893,7 @@
/* If we get a master hello and we are not the master then start a CHECK transition, cos the
real master must have gone away in a period of confusion */
- if (node_state != MASTER && hellomsg->flags & HELLO_FLAG_MASTER) {
+ if (cman_node_state != MASTER && hellomsg->flags & HELLO_FLAG_MASTER) {
node = find_node_by_nodeid(saddr->scl_nodeid);
start_transition(TRANS_CHECK, node);
}
@@ -2914,7 +2914,7 @@
": Being told to leave the cluster by node %d\n",
saddr->scl_nodeid);
- node_state = LEFT_CLUSTER;
+ cman_node_state = LEFT_CLUSTER;
quit_threads = 1;
wake_up_process(membership_task);
wake_up_interruptible(&cnxman_waitq);
@@ -3219,8 +3219,8 @@
* state transition */
int in_transition()
{
- return node_state == TRANSITION ||
- node_state == TRANSITION_COMPLETE || node_state == MASTER;
+ return cman_node_state == TRANSITION ||
+ cman_node_state == TRANSITION_COMPLETE || cman_node_state == MASTER;
}
/* Return the current membership state as a string for the main line to put
@@ -3228,7 +3228,7 @@
* not exported... */
char *membership_state(char *buf, int buflen)
{
- switch (node_state) {
+ switch (cman_node_state) {
case STARTING:
strncpy(buf, "Starting", buflen);
break;
@@ -3264,7 +3264,7 @@
strncpy(buf, "Transition-Master", buflen);
break;
default:
- sprintf(buf, "Unknown: code=%d", node_state);
+ sprintf(buf, "Unknown: code=%d", cman_node_state);
break;
}
--- cluster/dlm-kernel/src/Attic/lowcomms.c 2007/07/16 09:27:32 1.22.2.8.4.2.2.4
+++ cluster/dlm-kernel/src/Attic/lowcomms.c 2008/01/25 10:50:36 1.22.2.8.4.2.2.5
@@ -1268,7 +1268,7 @@
conn_array_size = dlm_config.conn_increment;
con_cache = kmem_cache_create("dlm_conn", sizeof(struct connection),
- __alignof__(struct connection), 0, NULL, NULL);
+ __alignof__(struct connection), 0, NULL);
if (!con_cache)
goto fail_free_conn;
--- cluster/dlm-kernel/src/Attic/memory.c 2007/02/07 15:25:04 1.3.8.1
+++ cluster/dlm-kernel/src/Attic/memory.c 2008/01/25 10:50:36 1.3.8.2
@@ -44,39 +44,39 @@
rsb_cache_small =
kmem_cache_create("dlm_rsb(small)",
(sizeof(struct dlm_rsb) + LARGE_RSB_NAME + BYTES_PER_WORD-1) & ~(BYTES_PER_WORD-1),
- __alignof__(struct dlm_rsb), 0, NULL, NULL);
+ __alignof__(struct dlm_rsb), 0, NULL);
if (!rsb_cache_small)
goto out;
rsb_cache_large =
kmem_cache_create("dlm_rsb(large)",
sizeof(struct dlm_rsb) + DLM_RESNAME_MAXLEN,
- __alignof__(struct dlm_rsb), 0, NULL, NULL);
+ __alignof__(struct dlm_rsb), 0, NULL);
if (!rsb_cache_large)
goto out_free_rsbs;
lkb_cache = kmem_cache_create("dlm_lkb", sizeof(struct dlm_lkb),
- __alignof__(struct dlm_lkb), 0, NULL, NULL);
+ __alignof__(struct dlm_lkb), 0, NULL);
if (!lkb_cache)
goto out_free_rsbl;
resdir_cache_large =
kmem_cache_create("dlm_resdir(l)",
sizeof(struct dlm_direntry) + DLM_RESNAME_MAXLEN,
- __alignof__(struct dlm_direntry), 0, NULL, NULL);
+ __alignof__(struct dlm_direntry), 0, NULL);
if (!resdir_cache_large)
goto out_free_lkb;
resdir_cache_small =
kmem_cache_create("dlm_resdir(s)",
(sizeof(struct dlm_direntry) + LARGE_RES_NAME + BYTES_PER_WORD-1) & ~(BYTES_PER_WORD-1),
- __alignof__(struct dlm_direntry), 0, NULL, NULL);
+ __alignof__(struct dlm_direntry), 0, NULL);
if (!resdir_cache_small)
goto out_free_resl;
/* LVB cache also holds ranges, so should be 64bit aligned */
lvb_cache = kmem_cache_create("dlm_lvb/range", DLM_LVB_LEN,
- __alignof__(uint64_t), 0, NULL, NULL);
+ __alignof__(uint64_t), 0, NULL);
if (!lkb_cache)
goto out_free_ress;
reply other threads:[~2008-01-25 10:50 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080125105038.30450.qmail@sourceware.org \
--to=pcaulfield@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.