staging/lustre: Remove unneeded ldlm_timeout control
ldlm_timeout is used server-side to determine AST timeouts, so it makes no sense on the client, esp. since it's not really used anywhere. Remove all traces of it except from the config where make it a noop. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
2836cd81a9
commit
082a33441f
|
@ -56,9 +56,7 @@ extern unsigned int obd_dump_on_eviction;
|
|||
/* obd_timeout should only be used for recovery, not for
|
||||
networking / disk / timings affected by load (use Adaptive Timeouts) */
|
||||
extern unsigned int obd_timeout; /* seconds */
|
||||
extern unsigned int ldlm_timeout; /* seconds */
|
||||
extern unsigned int obd_timeout_set;
|
||||
extern unsigned int ldlm_timeout_set;
|
||||
extern unsigned int at_min;
|
||||
extern unsigned int at_max;
|
||||
extern unsigned int at_history;
|
||||
|
@ -105,8 +103,6 @@ int obd_alloc_fail(const void *ptr, const char *name, const char *type,
|
|||
|
||||
/* Timeout definitions */
|
||||
#define OBD_TIMEOUT_DEFAULT 100
|
||||
#define LDLM_TIMEOUT_DEFAULT 20
|
||||
#define MDS_LDLM_TIMEOUT_DEFAULT 6
|
||||
/* Time to wait for all clients to reconnect during recovery (hard limit) */
|
||||
#define OBD_RECOVERY_TIME_HARD (obd_timeout * 9)
|
||||
/* Time to wait for all clients to reconnect during recovery (soft limit) */
|
||||
|
|
|
@ -76,15 +76,6 @@ inline unsigned long round_timeout(unsigned long timeout)
|
|||
return cfs_time_seconds((int)cfs_duration_sec(cfs_time_sub(timeout, 0)) + 1);
|
||||
}
|
||||
|
||||
/* timeout for initial callback (AST) reply (bz10399) */
|
||||
static inline unsigned int ldlm_get_rq_timeout(void)
|
||||
{
|
||||
/* Non-AT value */
|
||||
unsigned int timeout = min(ldlm_timeout, obd_timeout / 3);
|
||||
|
||||
return timeout < 1 ? 1 : timeout;
|
||||
}
|
||||
|
||||
#define ELT_STOPPED 0
|
||||
#define ELT_READY 1
|
||||
#define ELT_TERMINATE 2
|
||||
|
|
|
@ -78,12 +78,8 @@ atomic_t obd_dirty_pages;
|
|||
EXPORT_SYMBOL(obd_dirty_pages);
|
||||
unsigned int obd_timeout = OBD_TIMEOUT_DEFAULT; /* seconds */
|
||||
EXPORT_SYMBOL(obd_timeout);
|
||||
unsigned int ldlm_timeout = LDLM_TIMEOUT_DEFAULT; /* seconds */
|
||||
EXPORT_SYMBOL(ldlm_timeout);
|
||||
unsigned int obd_timeout_set;
|
||||
EXPORT_SYMBOL(obd_timeout_set);
|
||||
unsigned int ldlm_timeout_set;
|
||||
EXPORT_SYMBOL(ldlm_timeout_set);
|
||||
/* Adaptive timeout defs here instead of ptlrpc module for /proc/sys/ access */
|
||||
unsigned int at_min = 0;
|
||||
EXPORT_SYMBOL(at_min);
|
||||
|
|
|
@ -61,8 +61,6 @@ static int proc_set_timeout(struct ctl_table *table, int write,
|
|||
int rc;
|
||||
|
||||
rc = proc_dointvec(table, write, buffer, lenp, ppos);
|
||||
if (ldlm_timeout >= obd_timeout)
|
||||
ldlm_timeout = max(obd_timeout / 3, 1U);
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
@ -136,13 +134,6 @@ static struct ctl_table obd_table[] = {
|
|||
.mode = 0644,
|
||||
.proc_handler = &proc_dointvec
|
||||
},
|
||||
{
|
||||
.procname = "ldlm_timeout",
|
||||
.data = &ldlm_timeout,
|
||||
.maxlen = sizeof(int),
|
||||
.mode = 0644,
|
||||
.proc_handler = &proc_set_timeout
|
||||
},
|
||||
{
|
||||
.procname = "max_dirty_mb",
|
||||
.data = &obd_max_dirty_pages,
|
||||
|
|
|
@ -1123,12 +1123,7 @@ int class_process_config(struct lustre_cfg *lcfg)
|
|||
goto out;
|
||||
}
|
||||
case LCFG_SET_LDLM_TIMEOUT: {
|
||||
CDEBUG(D_IOCTL, "changing lustre ldlm_timeout from %d to %d\n",
|
||||
ldlm_timeout, lcfg->lcfg_num);
|
||||
ldlm_timeout = max(lcfg->lcfg_num, 1U);
|
||||
if (ldlm_timeout >= obd_timeout)
|
||||
ldlm_timeout = max(obd_timeout / 3, 1U);
|
||||
ldlm_timeout_set = 1;
|
||||
/* ldlm_timeout is not used on the client */
|
||||
err = 0;
|
||||
goto out;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue