}
LUSTRE_RW_ATTR(pcc_dio_attach_size_mb);
+static ssize_t
+pcc_max_attach_thread_num_show(struct kobject *kobj, struct attribute *attr,
+ char *buffer)
+{
+ struct ll_sb_info *sbi = container_of(kobj, struct ll_sb_info,
+ ll_kset.kobj);
+ struct pcc_super *super = &sbi->ll_pcc_super;
+
+ return sprintf(buffer, "%u\n", super->pccs_maximum_queued_attaches);
+}
+
+static ssize_t
+pcc_max_attach_thread_num_store(struct kobject *kobj, struct attribute *attr,
+ const char *buffer, size_t count)
+{
+ struct ll_sb_info *sbi = container_of(kobj, struct ll_sb_info,
+ ll_kset.kobj);
+ struct pcc_super *super = &sbi->ll_pcc_super;
+ unsigned int val;
+ int rc;
+
+ rc = kstrtouint(buffer, 0, &val);
+ if (rc)
+ return rc;
+
+ super->pccs_maximum_queued_attaches = val;
+ return count;
+}
+LUSTRE_RW_ATTR(pcc_max_attach_thread_num);
+
static ssize_t pcc_mode_show(struct kobject *kobj, struct attribute *attr,
- char *buffer)
+ char *buffer)
{
struct ll_sb_info *sbi = container_of(kobj, struct ll_sb_info,
ll_kset.kobj);
&lustre_attr_inode_cache.attr,
&lustre_attr_pcc_async_threshold.attr,
&lustre_attr_pcc_dio_attach_size_mb.attr,
+ &lustre_attr_pcc_max_attach_thread_num.attr,
&lustre_attr_pcc_mode.attr,
&lustre_attr_pcc_async_affinity.attr,
&lustre_attr_opencache_threshold_count.attr,