mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-19 10:53:58 +00:00
if_ntb: Log error *before* zeroing relevant variables
Sponsored by: EMC / Isilon Storage Division
This commit is contained in:
parent
4cc8daf782
commit
64448a2a50
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=291705
@ -1358,10 +1358,10 @@ ntb_set_mw(struct ntb_transport_ctx *nt, int num_mw, size_t size)
|
||||
mw->virt_addr = contigmalloc(mw->buff_size, M_NTB_IF, M_ZERO, 0,
|
||||
mw->addr_limit, mw->xlat_align, 0);
|
||||
if (mw->virt_addr == NULL) {
|
||||
ntb_printf(0, "Unable to allocate MW buffer of size %zu/%zu\n",
|
||||
mw->buff_size, mw->xlat_size);
|
||||
mw->xlat_size = 0;
|
||||
mw->buff_size = 0;
|
||||
printf("ntb: Unable to allocate MW buffer of size %zu\n",
|
||||
mw->xlat_size);
|
||||
return (ENOMEM);
|
||||
}
|
||||
/* TODO: replace with bus_space_* functions */
|
||||
|
Loading…
Reference in New Issue
Block a user