* \retval 0 on success
* \retval negative value on error
*/
-static ssize_t syncjournal_show(struct kobject *kobj, struct attribute *attr,
+static ssize_t sync_journal_show(struct kobject *kobj, struct attribute *attr,
char *buf)
{
struct obd_device *obd = container_of(kobj, struct obd_device,
obd_kset.kobj);
struct ofd_device *ofd = ofd_dev(obd->obd_lu_dev);
- return sprintf(buf, "%u\n", ofd->ofd_syncjournal);
+ return sprintf(buf, "%u\n", ofd->ofd_sync_journal);
}
/**
* \retval \a count on success
* \retval negative number on error
*/
-static ssize_t syncjournal_store(struct kobject *kobj, struct attribute *attr,
+static ssize_t sync_journal_store(struct kobject *kobj, struct attribute *attr,
const char *buffer, size_t count)
{
struct obd_device *obd = container_of(kobj, struct obd_device,
return rc;
spin_lock(&ofd->ofd_flags_lock);
- ofd->ofd_syncjournal = val;
+ ofd->ofd_sync_journal = val;
ofd_slc_set(ofd);
spin_unlock(&ofd->ofd_flags_lock);
return count;
}
-LUSTRE_RW_ATTR(syncjournal);
+LUSTRE_RW_ATTR(sync_journal);
/* This must be longer than the longest string below */
#define SYNC_STATES_MAXLEN 16
&lustre_attr_client_cache_seconds.attr,
&lustre_attr_degraded.attr,
&lustre_attr_fstype.attr,
- &lustre_attr_syncjournal.attr,
+ &lustre_attr_sync_journal.attr,
&lustre_attr_sync_lock_cancel.attr,
&lustre_attr_soft_sync_limit.attr,
&lustre_attr_lfsck_speed_limit.attr,
spinlock_t ofd_flags_lock;
unsigned long ofd_raid_degraded:1,
/* sync journal on writes */
- ofd_syncjournal:1,
+ ofd_sync_journal:1,
/* Protected by ofd_lastid_rwsem. */
ofd_lastid_rebuilding:1,
ofd_record_fid_accessed:1,
* sync on lock cancel if it is not enabled already. */
static inline void ofd_slc_set(struct ofd_device *ofd)
{
- if (ofd->ofd_syncjournal == 1)
+ if (ofd->ofd_sync_journal == 1)
ofd->ofd_lut.lut_sync_lock_cancel = NEVER_SYNC_ON_CANCEL;
else if (ofd->ofd_lut.lut_sync_lock_cancel == NEVER_SYNC_ON_CANCEL)
ofd->ofd_lut.lut_sync_lock_cancel = ALWAYS_SYNC_ON_CANCEL;