diff options
author | Ursula Braun <braunu@de.ibm.com> | 2008-04-24 10:15:26 +0200 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2008-04-29 01:56:34 -0400 |
commit | a74b08c7fcfc49727cb9e4409ec0410674410c93 (patch) | |
tree | 3430256acc3b5e1c475e80ea3ce0290589fa3b99 /drivers/s390/net/qeth_core_main.c | |
parent | 8af7c5aebc9a7b46f6ea55ee5a216dce4005f538 (diff) | |
download | talos-obmc-linux-a74b08c7fcfc49727cb9e4409ec0410674410c93.tar.gz talos-obmc-linux-a74b08c7fcfc49727cb9e4409ec0410674410c93.zip |
qeth: read number of ports from card
Read out number of ports from the hardware.
Signed-off-by: Ursula Braun <braunu@de.ibm.com>
Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/s390/net/qeth_core_main.c')
-rw-r--r-- | drivers/s390/net/qeth_core_main.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 820c332096e2..436bf1f6d4a6 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -3803,8 +3803,9 @@ retry: QETH_DBF_TEXT_(SETUP, 2, "2err%d", rc); return rc; } - - mpno = QETH_MAX_PORTNO; + mpno = qdio_get_ssqd_pct(CARD_DDEV(card)); + if (mpno) + mpno = min(mpno - 1, QETH_MAX_PORTNO); if (card->info.portno > mpno) { PRINT_ERR("Device %s does not offer port number %d \n.", CARD_BUS_ID(card), card->info.portno); |