Re: [PATCH] s390/dasd: fix error checks in dasd_copy_pair_store()

From: Stefan Haberland
Date: Mon Jul 01 2024 - 06:59:56 EST


Am 27.05.24 um 15:50 schrieb Carlos López:
dasd_add_busid() can return an error via ERR_PTR() if an allocation
fails. However, two callsites in dasd_copy_pair_store() do not check
the result, potentially resulting in a NULL pointer dereference. Fix
this by checking the result with IS_ERR() and returning the error up
the stack.

Fixes: a91ff09d39f9b ("s390/dasd: add copy pair setup")
Signed-off-by: Carlos López <clopez@xxxxxxx>
---

Applied, thanks.