spin_lock_init(&sbi->ll_lock);
INIT_LIST_HEAD(&sbi->ll_pglist);
sbi->ll_pglist_gen = 0;
- sbi->ll_max_read_ahead_pages = SBI_DEFAULT_RA_MAX;
+ if (num_physpages < SBI_DEFAULT_RA_MAX / 4)
+ sbi->ll_ra_info.ra_max_pages = num_physpages / 4;
+ else
+ sbi->ll_ra_info.ra_max_pages = SBI_DEFAULT_RA_MAX;
INIT_LIST_HEAD(&sbi->ll_conn_chain);
INIT_HLIST_HEAD(&sbi->ll_orphan_dentry_list);
INIT_LIST_HEAD(&sbi->ll_mnt_list);
RETURN(fl);
}
-void ll_options(char *options, char **ost, char **mdc, int *flags,
- char **clone_opts)
+void ll_options(char *options, char **ost, char **mdc, int *flags)
{
char *this_char;
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))
continue;
if (!*mdc && (*mdc = ll_read_opt("mdc", this_char)))
continue;
- if (!*clone_opts && (*clone_opts = ll_read_opt("clone",
- this_char)))
- continue;
if (!(*flags & LL_SBI_NOLCK) &&
((*flags) = (*flags) |
ll_set_opt("nolock", this_char,
struct ll_sb_info *sbi;
char *osc = NULL;
char *mdc = NULL;
- char *clone_opts = NULL;
int err;
ENTRY;
RETURN(-ENOMEM);
sbi->ll_flags |= LL_SBI_READAHEAD;
- ll_options(data, &osc, &mdc, &sbi->ll_flags, &clone_opts);
+ ll_options(data, &osc, &mdc, &sbi->ll_flags);
if (!osc) {
CERROR("no osc\n");
OBD_FREE(mdc, strlen(mdc) + 1);
if (osc)
OBD_FREE(osc, strlen(osc) + 1);
- if (clone_opts)
- OBD_FREE(clone_opts, strlen(clone_opts) + 1);
RETURN(err);
} /* ll_read_super */
GOTO(out, err);
}
- if (lmd->lmd_nal == SOCKNAL) {
- PCFG_INIT(pcfg, NAL_CMD_ADD_AUTOCONN);
+ if (lmd->lmd_nal == SOCKNAL ||
+ lmd->lmd_nal == OPENIBNAL) {
+ PCFG_INIT(pcfg, NAL_CMD_ADD_PEER);
pcfg.pcfg_nal = lmd->lmd_nal;
pcfg.pcfg_nid = lmd->lmd_server_nid;
pcfg.pcfg_id = lmd->lmd_server_ipaddr;
err = class_process_config(&lcfg);
out_del_conn:
- if (lmd->lmd_nal == SOCKNAL) {
- PCFG_INIT(pcfg, NAL_CMD_DEL_AUTOCONN);
+ if (lmd->lmd_nal == SOCKNAL ||
+ lmd->lmd_nal == OPENIBNAL) {
+ PCFG_INIT(pcfg, NAL_CMD_DEL_PEER);
pcfg.pcfg_nal = lmd->lmd_nal;
pcfg.pcfg_nid = lmd->lmd_server_nid;
- pcfg.pcfg_id = lmd->lmd_server_ipaddr;
- pcfg.pcfg_flags = 1; /*share*/
+ pcfg.pcfg_flags = 1; /* single_share */
err = libcfs_nal_cmd(&pcfg);
if (err <0)
GOTO(out, err);
LASSERT(atomic_read(&inode->i_sem.count) <= 0);
up(&inode->i_sem);
rc = ll_extent_lock(NULL, inode, lsm, LCK_PW, &policy, &lockh,
- ast_flags);
+ ast_flags, &ll_i2sbi(inode)->ll_seek_stime);
down(&inode->i_sem);
if (rc != 0)
RETURN(rc);
struct obd_statfs osfs;
int rc;
- CDEBUG(D_VFSTRACE, "VFS Op:\n");
+ CDEBUG(D_VFSTRACE, "VFS Op: superblock %p\n", sb);
lprocfs_counter_incr(ll_s2sbi(sb)->ll_stats, LPROC_LL_STAFS);
/* For now we will always get up-to-date statfs values, but in the
struct obd_device *obd;
struct obd_ioctl_data ioc_data = { 0 };
ENTRY;
- CDEBUG(D_VFSTRACE, "VFS Op:\n");
-
+
+ CDEBUG(D_VFSTRACE, "VFS Op: superblock %p count %d active %d\n", sb,
+ sb->s_count, atomic_read(&sb->s_active));
+
obd = class_exp2obd(sbi->ll_mdc_exp);
if (obd == NULL) {
CERROR("Invalid MDC connection handle "LPX64"\n",