Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

scsi: qedf: Use vzalloc() instead of vmalloc()/memset(0)

Use vzalloc() instead of vmalloc() and memset(0) to simpify the code.

Link: https://lore.kernel.org/r/20210518132018.1312995-1-yangyingliang@huawei.com
Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

Yang Yingliang and committed by
Martin K. Petersen
2a38d2a8 b592d662

+1 -2
+1 -2
drivers/scsi/qedf/qedf_dbg.c
··· 106 106 int 107 107 qedf_alloc_grc_dump_buf(u8 **buf, uint32_t len) 108 108 { 109 - *buf = vmalloc(len); 109 + *buf = vzalloc(len); 110 110 if (!(*buf)) 111 111 return -ENOMEM; 112 112 113 - memset(*buf, 0, len); 114 113 return 0; 115 114 } 116 115