From 9f91d1600e57ed07fed3c784e8fd8103f422bf45 Mon Sep 17 00:00:00 2001 From: adilger Date: Wed, 21 May 2003 06:24:57 +0000 Subject: [PATCH] Remove bogus local function prototypes that were causing me grief. Fix header mess as necessary to be able to compile. Most of MDS unlink cookie generation complete. Remove some local variable declarations that are only used in debug messages that appeared when compiling with CDEBUG() as a no-op (reduce stack usage). --- lustre/mds/commit_confd.c | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/lustre/mds/commit_confd.c b/lustre/mds/commit_confd.c index 84ced00..557dc55 100644 --- a/lustre/mds/commit_confd.c +++ b/lustre/mds/commit_confd.c @@ -4,26 +4,26 @@ void commit_add(struct ) { struct obd_import *import = commit_uuid2import(rec-> uuid); - if (!import) { + if (!import) { CERROR("unaware of OST UUID %s - dorpping\n", rec-> uuid); EXIT; return; } - + spin_lock(&import->llcconf_lock); - list_add(&rec-> &import); + list_add(&rec-> &import); spin_unlock(&import->llcconf_lock); EXIT; return; } -void commit_confd_conf_import(struct obd_import *import, +void commit_confd_conf_import(struct obd_import *import, struct llog_commit_confirm_daemon *lccd) { struct list_head *tmp, *save; - list_for_each_safe(&import->import_cc_list, tmp, save) { + list_for_each_safe(&import->import_cc_list, tmp, save) { struct llog_commit_data *cd; if (atomic_read(import->import_cc_count) <= @@ -32,35 +32,35 @@ void commit_confd_conf_import(struct obd_import *import, cd = list_entry(tmp, struct llog_commit_data *, llcconf_entry); atomic_dec(&import->import_cc_count); - commit_confd_add_and_fire(cd); + commit_confd_add_and_fire(cd); } EXIT; return; } -int commit_confd_main(void *data) +int commit_confd_main(void *data) { struct llog_commit_confirm_daemon *lccd = data; - - while (1) { + + while (1) { /* something has happened */ - event_wait(); + event_wait(); if (lccd->flags & LCCD_STOP) break; - - /* lock llccd imporlist */ + + /* lock llccd imporlist */ spin_lock(&lccd->llcconf_lock); - list_for_each_safe(&lccd->llcconf_list, ) { - struct obd_import *import; - import = list_entry(&lccd->llcconf_list, - struct obd_import, + list_for_each_safe(&lccd->llcconf_list, ) { + struct obd_import *import; + import = list_entry(&lccd->llcconf_list, + struct obd_import, import_entry); get_import(import); spin_unlock(&lccd->llcconf_lock); - if (atomic_read(import->import_cc_count) > + if (atomic_read(import->import_cc_count) > lccd->llcconf_highwater) commit_confd_conf_import(import); put_import(import); @@ -68,7 +68,6 @@ int commit_confd_main(void *data) } spin_unlock(&lccd->llcconf_lock); - /* } -- 1.8.3.1