Whamcloud - gitweb
LU-11591 llog: remove partial_chunk variable 30/37830/3
authorMr NeilBrown <neilb@suse.de>
Mon, 9 Mar 2020 02:20:41 +0000 (13:20 +1100)
committerOleg Drokin <green@whamcloud.com>
Tue, 24 Mar 2020 05:22:39 +0000 (05:22 +0000)
This variable is set but never used, so remove it.

Test-Parameters: trivial
Fixes: ec4194e4e78c ("LU-11591 llog: add synchronization for the last record")
Signed-off-by: Mr NeilBrown <neilb@suse.de>
Change-Id: I59ec75ba66a3ca37990d3ffec1d1b8f80350ae52
Reviewed-on: https://review.whamcloud.com/37830
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Alexander Boyko <c17825@cray.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
lustre/obdclass/llog.c

index c9f9616..75224fd 100644 (file)
@@ -499,7 +499,6 @@ static int llog_process_thread(void *arg)
                struct llog_rec_hdr *rec;
                off_t chunk_offset = 0;
                unsigned int buf_offset = 0;
-               bool partial_chunk;
                int     lh_last_idx;
                int     synced_idx = 0;
 
@@ -540,13 +539,10 @@ repeat:
                 * The absolute offset of the current chunk is calculated
                 * from cur_offset value and stored in chunk_offset variable.
                 */
-               if ((cur_offset & (chunk_size - 1)) != 0) {
-                       partial_chunk = true;
+               if ((cur_offset & (chunk_size - 1)) != 0)
                        chunk_offset = cur_offset & ~(chunk_size - 1);
-               } else {
-                       partial_chunk = false;
+               else
                        chunk_offset = cur_offset - chunk_size;
-               }
 
                /* NB: when rec->lrh_len is accessed it is already swabbed
                 * since it is used at the "end" of the loop and the rec