Re: [PATCH 1/2 v2] scsi: be2iscsi: set errno on error path

From: Martin K. Petersen
Date: Mon Dec 05 2016 - 17:30:46 EST


>>>>> "Pan" == Pan Bian <bianpan2016@xxxxxxx> writes:

Pan> Variable ret is reset in the loop, and its value will be 0 during
Pan> the after repeat of the loop. Then, if pci_alloc_consistent()
Pan> returns NULL, the return value is 0. 0 means no error, which may
Pan> make it impossible for the callers of beiscsi_create_cqs() to
Pan> detect the memory allocation error. This patch fixes the bug,
Pan> assigning "-ENOMEM" to ret on the path that the call to
Pan> pci_alloc_consistent() fails.

What are the differences between v1 and v2 for these patches? I see no
changelog...

--
Martin K. Petersen Oracle Linux Engineering