raw/ntb: check memory allocations
authorChengwen Feng <fengchengwen@huawei.com>
Wed, 21 Apr 2021 02:08:16 +0000 (10:08 +0800)
committerThomas Monjalon <thomas@monjalon.net>
Wed, 5 May 2021 20:53:04 +0000 (22:53 +0200)
commit403f21feb87fc9e0e2f61c1e4576cc1b9300ed4b
tree25cc34203e3a2e4f3243d260dfb4d4d4fc82dad9
parent586f12881dc0fc37720e55f59c8a11a9e184388d
raw/ntb: check memory allocations

This patch adds checking for rte_zmalloc() result when init Intel ntb
device, also fix the same bug when start ntb device.

Fixes: 034c328eb025 ("raw/ntb: support Intel NTB")
Fixes: c39d1e082a4b ("raw/ntb: setup queues")
Cc: stable@dpdk.org
Signed-off-by: Chengwen Feng <fengchengwen@huawei.com>
Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
Acked-by: Xiaoyun Li <xiaoyun.li@intel.com>
drivers/raw/ntb/ntb.c
drivers/raw/ntb/ntb_hw_intel.c