Commit 52581b89 authored by Oleg Drokin's avatar Oleg Drokin Committed by Greg Kroah-Hartman

staging/lustre/fld: Adjust comments to better conform to coding style

This patch fixes "Block comments use a trailing */ on a separate line"
warnings from checkpatch.
Signed-off-by: default avatarOleg Drokin <green@linuxhacker.ru>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c56e256d
...@@ -183,7 +183,8 @@ static void fld_fix_new_list(struct fld_cache *cache) ...@@ -183,7 +183,8 @@ static void fld_fix_new_list(struct fld_cache *cache)
} }
/* we could have overlap over next /* we could have overlap over next
* range too. better restart. */ * range too. better restart.
*/
goto restart_fixup; goto restart_fixup;
} }
...@@ -302,7 +303,8 @@ static void fld_cache_overlap_handle(struct fld_cache *cache, ...@@ -302,7 +303,8 @@ static void fld_cache_overlap_handle(struct fld_cache *cache,
const u32 mdt = range->lsr_index; const u32 mdt = range->lsr_index;
/* this is overlap case, these case are checking overlapping with /* this is overlap case, these case are checking overlapping with
* prev range only. fixup will handle overlapping with next range. */ * prev range only. fixup will handle overlapping with next range.
*/
if (f_curr->fce_range.lsr_index == mdt) { if (f_curr->fce_range.lsr_index == mdt) {
f_curr->fce_range.lsr_start = min(f_curr->fce_range.lsr_start, f_curr->fce_range.lsr_start = min(f_curr->fce_range.lsr_start,
...@@ -317,7 +319,8 @@ static void fld_cache_overlap_handle(struct fld_cache *cache, ...@@ -317,7 +319,8 @@ static void fld_cache_overlap_handle(struct fld_cache *cache,
} else if (new_start <= f_curr->fce_range.lsr_start && } else if (new_start <= f_curr->fce_range.lsr_start &&
f_curr->fce_range.lsr_end <= new_end) { f_curr->fce_range.lsr_end <= new_end) {
/* case 1: new range completely overshadowed existing range. /* case 1: new range completely overshadowed existing range.
* e.g. whole range migrated. update fld cache entry */ * e.g. whole range migrated. update fld cache entry
*/
f_curr->fce_range = *range; f_curr->fce_range = *range;
kfree(f_new); kfree(f_new);
......
...@@ -67,8 +67,7 @@ struct lu_fld_hash { ...@@ -67,8 +67,7 @@ struct lu_fld_hash {
struct fld_cache_entry { struct fld_cache_entry {
struct list_head fce_lru; struct list_head fce_lru;
struct list_head fce_list; struct list_head fce_list;
/** /** fld cache entries are sorted on range->lsr_start field. */
* fld cache entries are sorted on range->lsr_start field. */
struct lu_seq_range fce_range; struct lu_seq_range fce_range;
}; };
...@@ -79,32 +78,25 @@ struct fld_cache { ...@@ -79,32 +78,25 @@ struct fld_cache {
*/ */
rwlock_t fci_lock; rwlock_t fci_lock;
/** /** Cache shrink threshold */
* Cache shrink threshold */
int fci_threshold; int fci_threshold;
/** /** Preferred number of cached entries */
* Preferred number of cached entries */
int fci_cache_size; int fci_cache_size;
/** /** Current number of cached entries. Protected by \a fci_lock */
* Current number of cached entries. Protected by \a fci_lock */
int fci_cache_count; int fci_cache_count;
/** /** LRU list fld entries. */
* LRU list fld entries. */
struct list_head fci_lru; struct list_head fci_lru;
/** /** sorted fld entries. */
* sorted fld entries. */
struct list_head fci_entries_head; struct list_head fci_entries_head;
/** /** Cache statistics. */
* Cache statistics. */
struct fld_stats fci_stat; struct fld_stats fci_stat;
/** /** Cache name used for debug and messages. */
* Cache name used for debug and messages. */
char fci_name[LUSTRE_MDT_MAXNAMELEN]; char fci_name[LUSTRE_MDT_MAXNAMELEN];
unsigned int fci_no_shrink:1; unsigned int fci_no_shrink:1;
}; };
......
...@@ -58,7 +58,8 @@ ...@@ -58,7 +58,8 @@
#include "fld_internal.h" #include "fld_internal.h"
/* TODO: these 3 functions are copies of flow-control code from mdc_lib.c /* TODO: these 3 functions are copies of flow-control code from mdc_lib.c
* It should be common thing. The same about mdc RPC lock */ * It should be common thing. The same about mdc RPC lock
*/
static int fld_req_avail(struct client_obd *cli, struct mdc_cache_waiter *mcw) static int fld_req_avail(struct client_obd *cli, struct mdc_cache_waiter *mcw)
{ {
int rc; int rc;
...@@ -124,7 +125,8 @@ fld_rrb_scan(struct lu_client_fld *fld, u64 seq) ...@@ -124,7 +125,8 @@ fld_rrb_scan(struct lu_client_fld *fld, u64 seq)
* it should go to index 0 directly, instead of calculating * it should go to index 0 directly, instead of calculating
* hash again, and also if other MDTs is not being connected, * hash again, and also if other MDTs is not being connected,
* the fld lookup requests(for seq on MDT0) should not be * the fld lookup requests(for seq on MDT0) should not be
* blocked because of other MDTs */ * blocked because of other MDTs
*/
if (fid_seq_is_norm(seq)) if (fid_seq_is_norm(seq))
hash = fld_rrb_hash(fld, seq); hash = fld_rrb_hash(fld, seq);
else else
...@@ -139,7 +141,8 @@ fld_rrb_scan(struct lu_client_fld *fld, u64 seq) ...@@ -139,7 +141,8 @@ fld_rrb_scan(struct lu_client_fld *fld, u64 seq)
if (hash != 0) { if (hash != 0) {
/* It is possible the remote target(MDT) are not connected to /* It is possible the remote target(MDT) are not connected to
* with client yet, so we will refer this to MDT0, which should * with client yet, so we will refer this to MDT0, which should
* be connected during mount */ * be connected during mount
*/
hash = 0; hash = 0;
goto again; goto again;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment