Commit c9182e0f authored by Peter Oberparleiter's avatar Peter Oberparleiter Committed by Martin Schwidefsky

[S390] cio: observe chpid valid flag

Check validity flag of CHPID description data before continuing with
channel-path initialization.
Signed-off-by: default avatarPeter Oberparleiter <peter.oberparleiter@de.ibm.com>
Signed-off-by: default avatarMartin Schwidefsky <schwidefsky@de.ibm.com>
parent e6b6e10a
...@@ -339,6 +339,10 @@ int chp_new(struct chp_id chpid) ...@@ -339,6 +339,10 @@ int chp_new(struct chp_id chpid)
ret = chsc_determine_channel_path_description(chpid, &chp->desc); ret = chsc_determine_channel_path_description(chpid, &chp->desc);
if (ret) if (ret)
goto out_free; goto out_free;
if ((chp->desc.flags & 0x80) == 0) {
ret = -ENODEV;
goto out_free;
}
/* Get channel-measurement characteristics. */ /* Get channel-measurement characteristics. */
if (css_characteristics_avail && css_chsc_characteristics.scmc if (css_characteristics_avail && css_chsc_characteristics.scmc
&& css_chsc_characteristics.secm) { && css_chsc_characteristics.secm) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment