public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Akinobu Mita <akinobu.mita@gmail.com>
To: linux-kernel@vger.kernel.org, akpm@linux-foundation.org
Cc: Akinobu Mita <akinobu.mita@gmail.com>, Dan Williams <djbw@fb.com>,
	Vinod Koul <vinod.koul@intel.com>
Subject: [PATCH -v3 01/23] raid6test: use prandom_bytes()
Date: Mon,  4 Mar 2013 21:58:09 +0900	[thread overview]
Message-ID: <1362401911-14074-2-git-send-email-akinobu.mita@gmail.com> (raw)
In-Reply-To: <1362401911-14074-1-git-send-email-akinobu.mita@gmail.com>

Use prandom_bytes() to generate random bytes for test data.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Dan Williams <djbw@fb.com>
Cc: Vinod Koul <vinod.koul@intel.com>
---

No change from v2

 crypto/async_tx/raid6test.c | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/crypto/async_tx/raid6test.c b/crypto/async_tx/raid6test.c
index aa2b027..4a92bac 100644
--- a/crypto/async_tx/raid6test.c
+++ b/crypto/async_tx/raid6test.c
@@ -46,15 +46,10 @@ static void callback(void *param)
 
 static void makedata(int disks)
 {
-	int i, j;
+	int i;
 
 	for (i = 0; i < disks; i++) {
-		for (j = 0; j < PAGE_SIZE/sizeof(u32); j += sizeof(u32)) {
-			u32 *p = page_address(data[i]) + j;
-
-			*p = random32();
-		}
-
+		prandom_bytes(page_address(data[i]), PAGE_SIZE);
 		dataptrs[i] = data[i];
 	}
 }
-- 
1.8.1.2


  reply	other threads:[~2013-03-04 12:59 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-04 12:58 [PATCH -v3 00/23] rename random32 to prandom Akinobu Mita
2013-03-04 12:58 ` Akinobu Mita [this message]
2013-03-04 12:58 ` [PATCH -v3 02/23] uuid: use prandom_bytes() Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 03/23] x86: pageattr-test: remove srandom32 call Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 04/23] x86: rename random32() to prandom_u32() Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 05/23] lib/: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 06/23] mm/: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 07/23] kernel/: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 08/23] drbd: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 09/23] infiniband: " Akinobu Mita
2013-03-04 15:41   ` Steve Wise
2013-03-04 12:58 ` [PATCH -v3 10/23] mmc: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 11/23] video/uvesafb: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 12/23] xfs: " Akinobu Mita
2013-03-07 18:48   ` Ben Myers
2013-03-04 12:58 ` [PATCH -v3 13/23] uwb: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 14/23] lguest: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 15/23] scsi: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 16/23] drivers/net: " Akinobu Mita
2013-03-04 13:37   ` Arend van Spriel
2013-03-04 21:53     ` Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 17/23] net/sunrpc: " Akinobu Mita
2013-03-04 22:44   ` Myklebust, Trond
2013-03-04 12:58 ` [PATCH -v3 18/23] net/sched: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 19/23] net/netfilter: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 20/23] net/core: " Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 21/23] net/core: remove duplicate statements by do-while loop Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 22/23] net: rename random32 to prandom Akinobu Mita
2013-03-04 12:58 ` [PATCH -v3 23/23] remove unused random32() and srandom32() Akinobu Mita

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1362401911-14074-2-git-send-email-akinobu.mita@gmail.com \
    --to=akinobu.mita@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=djbw@fb.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vinod.koul@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox