Whamcloud - gitweb
LU-5710 all: second batch of corrected typos and grammar errors
[fs/lustre-release.git] / lustre / mdt / mdt_hsm_cdt_actions.c
index 0f5e0fe..59cbfe2 100644 (file)
@@ -23,6 +23,7 @@
  * (C) Copyright 2012 Commissariat a l'energie atomique et aux energies
  *     alternatives
  *
+ * Copyright (c) 2013, 2014, Intel Corporation.
  */
 /*
  * lustre/mdt/mdt_hsm_cdt_actions.c
@@ -354,7 +355,7 @@ static void *mdt_hsm_actions_proc_start(struct seq_file *s, loff_t *pos)
        struct agent_action_iterator    *aai = s->private;
        ENTRY;
 
-       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X",
+       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X\n",
                 aai->aai_magic);
 
        aai->aai_ctxt = llog_get_context(mdt2obd_dev(aai->aai_mdt),
@@ -364,7 +365,7 @@ static void *mdt_hsm_actions_proc_start(struct seq_file *s, loff_t *pos)
                RETURN(ERR_PTR(-ENOENT));
        }
 
-       CDEBUG(D_HSM, "llog succesfully initialized, start from "LPD64"\n",
+       CDEBUG(D_HSM, "llog successfully initialized, start from "LPD64"\n",
               *pos);
        /* first call = rewind */
        if (*pos == 0) {
@@ -403,7 +404,7 @@ static int hsm_actions_show_cb(const struct lu_env *env,
        ENTRY;
 
        aai = s->private;
-       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X",
+       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X\n",
                 aai->aai_magic);
 
        /* if rec already printed => skip */
@@ -459,7 +460,7 @@ static int mdt_hsm_actions_proc_show(struct seq_file *s, void *v)
        int                              rc;
        ENTRY;
 
-       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X",
+       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X\n",
                 aai->aai_magic);
 
        CDEBUG(D_HSM, "show from cat %d index %d eof=%d\n",
@@ -488,7 +489,7 @@ static void mdt_hsm_actions_proc_stop(struct seq_file *s, void *v)
        struct agent_action_iterator *aai = s->private;
        ENTRY;
 
-       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X",
+       LASSERTF(aai->aai_magic == AGENT_ACTIONS_IT_MAGIC, "%08X\n",
                 aai->aai_magic);
 
        if (aai->aai_ctxt)
@@ -513,9 +514,6 @@ static int lprocfs_open_hsm_actions(struct inode *inode, struct file *file)
        struct mdt_device               *mdt;
        ENTRY;
 
-       if (LPROCFS_ENTRY_CHECK(PDE(inode)))
-               RETURN(-ENOENT);
-
        rc = seq_open(file, &mdt_hsm_actions_proc_ops);
        if (rc)
                RETURN(rc);
@@ -532,7 +530,7 @@ static int lprocfs_open_hsm_actions(struct inode *inode, struct file *file)
        /* mdt is saved in proc_dir_entry->data by
         * mdt_coordinator_procfs_init() calling lprocfs_register()
         */
-       mdt = (struct mdt_device *)PDE(inode)->data;
+       mdt = (struct mdt_device *)PDE_DATA(inode);
        aai->aai_mdt = mdt;
        s = file->private_data;
        s->private = aai;
@@ -551,7 +549,7 @@ out:
 
 /**
  * lprocfs_release_hsm_actions() is called at end of /proc access.
- * It frees allocated ressources and calls cleanup lprocfs methods.
+ * It frees allocated resources and calls cleanup lprocfs methods.
  */
 static int lprocfs_release_hsm_actions(struct inode *inode, struct file *file)
 {