aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips')
-rw-r--r--arch/mips/sibyte/common/sb_tbprof.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/mips/sibyte/common/sb_tbprof.c b/arch/mips/sibyte/common/sb_tbprof.c
index 87ccdb4b5ac9..48853ab5bcf0 100644
--- a/arch/mips/sibyte/common/sb_tbprof.c
+++ b/arch/mips/sibyte/common/sb_tbprof.c
@@ -410,14 +410,13 @@ static int sbprof_tb_open(struct inode *inode, struct file *filp)
410 return -EBUSY; 410 return -EBUSY;
411 411
412 memset(&sbp, 0, sizeof(struct sbprof_tb)); 412 memset(&sbp, 0, sizeof(struct sbprof_tb));
413 sbp.sbprof_tbbuf = vmalloc(MAX_TBSAMPLE_BYTES); 413 sbp.sbprof_tbbuf = vzalloc(MAX_TBSAMPLE_BYTES);
414 if (!sbp.sbprof_tbbuf) { 414 if (!sbp.sbprof_tbbuf) {
415 sbp.open = SB_CLOSED; 415 sbp.open = SB_CLOSED;
416 wmb(); 416 wmb();
417 return -ENOMEM; 417 return -ENOMEM;
418 } 418 }
419 419
420 memset(sbp.sbprof_tbbuf, 0, MAX_TBSAMPLE_BYTES);
421 init_waitqueue_head(&sbp.tb_sync); 420 init_waitqueue_head(&sbp.tb_sync);
422 init_waitqueue_head(&sbp.tb_read); 421 init_waitqueue_head(&sbp.tb_read);
423 mutex_init(&sbp.lock); 422 mutex_init(&sbp.lock);