Re: [PATCH v2] scsi: qedf: Use kcalloc() and add check for bdt_info
From: Markus Elfring
Date: Sun Feb 02 2025 - 11:54:58 EST
…
> +++ b/drivers/scsi/qedf/qedf_io.c
…
@@ -254,9 +254,7 @@ struct qedf_cmd_mgr *qedf_cmd_mgr_alloc(struct qedf_ctx *qedf)
}
/* Allocate pool of io_bdts - one for each qedf_ioreq */
…
+ cmgr->io_bdt_pool = kcalloc(num_ios, sizeof(struct io_bdt *), GFP_KERNEL);
…
See also:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/coding-style.rst?h=v6.13#n941
Regards,
Markus