GIT 1cbc8947c4988413663d7cff13ce25699581e29c git+ssh://master.kernel.org/pub/scm/linux/kernel/git/teigland/dlm.git#test commit Author: David Teigland Date: Thu Feb 21 11:25:42 2008 -0600 dlm: save master info after failed no-queue request When a NOQUEUE request fails, the rsb res_master field is unnecessarily reset to -1, instead of leaving the valid master setting in place. We want to save the looked-up master values while the rsb is on the "toss list" so that another lookup can be avoided if the rsb is soon reused. The fix is to simply leave res_master value alone. Signed-off-by: David Teigland commit f21181de3839dd4ddbb9c96bb5078e6c3393400c Author: Adrian Bunk Date: Wed Feb 13 23:29:38 2008 +0200 dlm: make dlm_print_rsb() static dlm_print_rsb() can now become static. Signed-off-by: Adrian Bunk Signed-off-by: David Teigland commit f5cfe7279ca5161c535ca44cfb078d1b201a6242 Author: Harvey Harrison Date: Wed Feb 13 16:54:29 2008 -0800 dlm: match signedness between dlm_config_info and cluster_set cluster_set is only called from the macro CLUSTER_ATTR which defines read/write access functions. Make the signedness match to avoid sparse warnings every time CLUSTER_ATTR is used (lines 149-159) all of the form: fs/dlm/config.c:149:1: warning: incorrect type in argument 3 (different signedness) fs/dlm/config.c:149:1: expected unsigned int *info_field fs/dlm/config.c:149:1: got int extern [toplevel] * Signed-off-by: Harvey Harrison Signed-off-by: David Teigland fs/dlm/config.c | 2 +- fs/dlm/lock.c | 5 ++--- fs/dlm/lock.h | 1 - 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/fs/dlm/config.c b/fs/dlm/config.c index c3ad1df..7ceaea3 100644 --- a/fs/dlm/config.c +++ b/fs/dlm/config.c @@ -114,7 +114,7 @@ struct cluster_attribute { }; static ssize_t cluster_set(struct cluster *cl, unsigned int *cl_field, - unsigned int *info_field, int check_zero, + int *info_field, int check_zero, const char *buf, size_t len) { unsigned int x; diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c index 8f250ac..2d3d102 100644 --- a/fs/dlm/lock.c +++ b/fs/dlm/lock.c @@ -165,7 +165,7 @@ void dlm_print_lkb(struct dlm_lkb *lkb) lkb->lkb_grmode, lkb->lkb_wait_type, lkb->lkb_ast_type); } -void dlm_print_rsb(struct dlm_rsb *r) +static void dlm_print_rsb(struct dlm_rsb *r) { printk(KERN_ERR "rsb: nodeid %d flags %lx first %x rlc %d name %s\n", r->res_nodeid, r->res_flags, r->res_first_lkid, @@ -1956,8 +1956,7 @@ static void confirm_master(struct dlm_rsb *r, int error) list_del_init(&lkb->lkb_rsb_lookup); r->res_first_lkid = lkb->lkb_id; _request_lock(r, lkb); - } else - r->res_nodeid = -1; + } break; default: diff --git a/fs/dlm/lock.h b/fs/dlm/lock.h index 05d9c82..88e93c8 100644 --- a/fs/dlm/lock.h +++ b/fs/dlm/lock.h @@ -13,7 +13,6 @@ #ifndef __LOCK_DOT_H__ #define __LOCK_DOT_H__ -void dlm_print_rsb(struct dlm_rsb *r); void dlm_dump_rsb(struct dlm_rsb *r); void dlm_print_lkb(struct dlm_lkb *lkb); void dlm_receive_message_saved(struct dlm_ls *ls, struct dlm_message *ms);