Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1281246

[lustre cleanups 3/6] Clean up another C warnining:

From Valdis Kletnieks <Valdis.Kletnieks@vt.edu>
Newsgroups linux.kernel
Subject [lustre cleanups 3/6] Clean up another C warnining:
Date 2015-12-01 23:10 +0100
Message-ID <qB1hx-73C-21@gated-at.bofh.it> (permalink)
References <qB1hw-73C-9@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


drivers/staging/lustre/lustre/fid/../include/lustre_cfg.h: In function 'lustre_cfg_free':
drivers/staging/lustre/lustre/fid/../include/lustre_cfg.h:253:6: warning: variable 'len' set but not used [-Wunused-but-set-variable]
  int len;

Yep, we're just gonna call kfree, no need to calculate len. Bye-bye.

Signed-off-by: Valdis Kletnieks <Valdis.Kletnieks@vt.edu>
---
diff --git a/drivers/staging/lustre/lustre/include/lustre_cfg.h b/drivers/staging/lustre/lustre/include/lustre_cfg.h
index eb6b292b7b25..d30d8b054c92 100644
--- a/drivers/staging/lustre/lustre/include/lustre_cfg.h
+++ b/drivers/staging/lustre/lustre/include/lustre_cfg.h
@@ -252,10 +252,6 @@ static inline struct lustre_cfg *lustre_cfg_new(int cmd,
 
 static inline void lustre_cfg_free(struct lustre_cfg *lcfg)
 {
-	int len;
-
-	len = lustre_cfg_len(lcfg->lcfg_bufcount, lcfg->lcfg_buflens);
-
 	kfree(lcfg);
 	return;
 }
-- 
2.6.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[lustre cleanups 0/6] Patch series to make lustre safe(r) for W=1 compiles Valdis Kletnieks <Valdis.Kletnieks@vt.edu> - 2015-12-01 23:10 +0100
  [lustre cleanups 4/6] Fix another C compiler whine: Valdis Kletnieks <Valdis.Kletnieks@vt.edu> - 2015-12-01 23:10 +0100
  [lustre cleanups 1/6] Swap inline/const to kill 272 warnings Valdis Kletnieks <Valdis.Kletnieks@vt.edu> - 2015-12-01 23:10 +0100
  [lustre cleanups 3/6] Clean up another C warnining: Valdis Kletnieks <Valdis.Kletnieks@vt.edu> - 2015-12-01 23:10 +0100
  [lustre cleanups 6/6] Nuke another unsigned >= 0 assert Valdis Kletnieks <Valdis.Kletnieks@vt.edu> - 2015-12-01 23:10 +0100
  [lustre cleanups 5/6] Nuke an unsigned >= 0 assert Valdis Kletnieks <Valdis.Kletnieks@vt.edu> - 2015-12-01 23:10 +0100
  Re: [lustre cleanups 0/6] Patch series to make lustre safe(r) for  W=1 compiles "Dilger, Andreas" <andreas.dilger@intel.com> - 2015-12-04 07:30 +0100

csiph-web