diff options
author | Ilya Dryomov <idryomov@gmail.com> | 2016-09-27 06:35:55 -0400 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2016-10-05 17:02:10 -0400 |
commit | 64f77566e1c84990d6c448bb3960f899521c0b7d (patch) | |
tree | 975780fa44c1ea893a0f442012c8f7893f54cf1e /net | |
parent | 74a5293832b3c1f7cb8f86fb9af9ee747138d355 (diff) |
crush: remove redundant local variable
Remove extra x1 variable, it's just temporary placeholder that
clutters the code unnecessarily.
Reflects ceph.git commit 0d19408d91dd747340d70287b4ef9efd89e95c6b.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'net')
-rw-r--r-- | net/ceph/crush/mapper.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/ceph/crush/mapper.c b/net/ceph/crush/mapper.c index 511ade95339a..a421e905331a 100644 --- a/net/ceph/crush/mapper.c +++ b/net/ceph/crush/mapper.c | |||
@@ -245,7 +245,7 @@ static int bucket_straw_choose(struct crush_bucket_straw *bucket, | |||
245 | /* compute 2^44*log2(input+1) */ | 245 | /* compute 2^44*log2(input+1) */ |
246 | static __u64 crush_ln(unsigned int xin) | 246 | static __u64 crush_ln(unsigned int xin) |
247 | { | 247 | { |
248 | unsigned int x = xin, x1; | 248 | unsigned int x = xin; |
249 | int iexpon, index1, index2; | 249 | int iexpon, index1, index2; |
250 | __u64 RH, LH, LL, xl64, result; | 250 | __u64 RH, LH, LL, xl64, result; |
251 | 251 | ||
@@ -273,12 +273,11 @@ static __u64 crush_ln(unsigned int xin) | |||
273 | /* RH*x ~ 2^48 * (2^15 + xf), xf<2^8 */ | 273 | /* RH*x ~ 2^48 * (2^15 + xf), xf<2^8 */ |
274 | xl64 = (__s64)x * RH; | 274 | xl64 = (__s64)x * RH; |
275 | xl64 >>= 48; | 275 | xl64 >>= 48; |
276 | x1 = xl64; | ||
277 | 276 | ||
278 | result = iexpon; | 277 | result = iexpon; |
279 | result <<= (12 + 32); | 278 | result <<= (12 + 32); |
280 | 279 | ||
281 | index2 = x1 & 0xff; | 280 | index2 = xl64 & 0xff; |
282 | /* LL ~ 2^48*log2(1.0+index2/2^15) */ | 281 | /* LL ~ 2^48*log2(1.0+index2/2^15) */ |
283 | LL = __LL_tbl[index2]; | 282 | LL = __LL_tbl[index2]; |
284 | 283 | ||