提交 a0016408 编写于 作者: C Cornelia Huck 提交者: Linus Torvalds

[PATCH] s390: ccwgroup online attribute

Make the interface for setting ccw group devices on-/offline consistent with
that for ccw devices: Check if the device driver provided a set_{on,off}line
function and just set the device on-/offline if not.
Signed-off-by: NCornelia Huck <cohuck@de.ibm.com>
Signed-off-by: NMartin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 9b4554aa
/*
* drivers/s390/cio/ccwgroup.c
* bus driver for ccwgroup
* $Revision: 1.29 $
* $Revision: 1.32 $
*
* Copyright (C) 2002 IBM Deutschland Entwicklung GmbH,
* IBM Corporation
......@@ -274,7 +274,7 @@ ccwgroup_set_online(struct ccwgroup_device *gdev)
goto out;
}
gdrv = to_ccwgroupdrv (gdev->dev.driver);
if ((ret = gdrv->set_online(gdev)))
if ((ret = gdrv->set_online ? gdrv->set_online(gdev) : 0))
goto out;
gdev->state = CCWGROUP_ONLINE;
......@@ -300,7 +300,7 @@ ccwgroup_set_offline(struct ccwgroup_device *gdev)
goto out;
}
gdrv = to_ccwgroupdrv (gdev->dev.driver);
if ((ret = gdrv->set_offline(gdev)))
if ((ret = gdrv->set_offline ? gdrv->set_offline(gdev) : 0))
goto out;
gdev->state = CCWGROUP_OFFLINE;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册