Set error value when allocation of IO irq fails in ENA
bus_alloc_resource_any() is not returning error value in case of an error. If the function call fails, the error value was not passed to the ena_up() function. Submitted by: Michal Krawczyk <mk@semihalf.com> Obtained from: Semihalf Sponsored by: Amazon, Inc.
This commit is contained in:
parent
7090f94544
commit
f94e60076d
@ -1998,6 +1998,7 @@ ena_request_io_irq(struct ena_adapter *adapter)
|
||||
irq->res = bus_alloc_resource_any(adapter->pdev, SYS_RES_IRQ,
|
||||
&irq->vector, flags);
|
||||
if (unlikely(irq->res == NULL)) {
|
||||
rc = ENOMEM;
|
||||
device_printf(adapter->pdev, "could not allocate "
|
||||
"irq vector: %d\n", irq->vector);
|
||||
goto err;
|
||||
|
Loading…
x
Reference in New Issue
Block a user