Re: [PATCH] crypto: tcrypt - removed unused variable.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 1/16/2013 7:48 AM, Vakul Garg wrote:
Removed unused variable for storing output string from:

	(a) test_ahash_jiffies_digest()
	(b) test_ahash_jiffies()
	(c) test_ahash_cycles_digest()
	(d) test_ahash_cycles()

This variable is not needed in above functions since the caller function
test_ahash_speed() already sets output buffer in the ahash transform using
ahash_request_set_crypt().

Signed-off-by: Vakul Garg <vakul@xxxxxxxxxxxxx>
---

@@ -519,14 +519,14 @@ static int test_ahash_jiffies_digest(struct ahash_request *req, int blen,
  }

  static int test_ahash_jiffies(struct ahash_request *req, int blen,
-			      int plen, char *out, int sec)
+			      int plen, int sec)
  {
  	unsigned long start, end;
  	int bcount, pcount;
  	int ret;

  	if (plen == blen)
-		return test_ahash_jiffies_digest(req, blen, out, sec);
+		return test_ahash_jiffies_digest(req, blen, sec);

  	for (start = jiffies, end = start + sec * HZ, bcount = 0;
  	     time_before(jiffies, end); bcount++) {

You should also remove the deprecated comment in test_ahash_jiffies:
/* we assume there is enough space in 'out' for the result */

Regards,
Horia


--
To unsubscribe from this list: send the line "unsubscribe linux-crypto" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux