* [PATCH] s390/dasd: convert to use ERR_CAST()
@ 2025-08-19 8:42 zhang.enpei
0 siblings, 0 replies; only message in thread
From: zhang.enpei @ 2025-08-19 8:42 UTC (permalink / raw)
To: sth
Cc: hoeppner, hca, gor, agordeev, borntraeger, svens, linux-s390,
linux-kernel
[-- Attachment #1.1.1: Type: text/plain, Size: 839 bytes --]
From: Zhang Enpei <zhang.enpei@zte.com.cn>
Use ERR_CAST() since the macro clearly indicates that this is a pointer
to an error value and a type conversion was performed.
Signed-off-by: Zhang Enpei <zhang.enpei@zte.com.cn>
---
drivers/s390/block/dasd_devmap.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/s390/block/dasd_devmap.c b/drivers/s390/block/dasd_devmap.c
index ddbdf1f85d44..0f4900d246e8 100644
--- a/drivers/s390/block/dasd_devmap.c
+++ b/drivers/s390/block/dasd_devmap.c
@@ -555,7 +555,7 @@ dasd_create_device(struct ccw_device *cdev)
devmap = dasd_devmap_from_cdev(cdev);
if (IS_ERR(devmap))
- return (void *) devmap;
+ return ERR_CAST(devmap);
device = dasd_alloc_device();
if (IS_ERR(device))
--
2.25.1
[-- Attachment #1.1.2: Type: text/html , Size: 1518 bytes --]
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2025-08-19 8:43 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-19 8:42 [PATCH] s390/dasd: convert to use ERR_CAST() zhang.enpei
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).