]>
Commit | Line | Data |
---|---|---|
2cb7cef9 BS |
1 | From: Gerald Schaefer <geraldsc@de.ibm.com> |
2 | Subject: zfcp: fix wka port processing | |
3 | References: bnc#518291,LTC#54673 | |
4 | ||
5 | Symptom: Remote port cannot be opened. | |
6 | Problem: After an "open port" request for the WKA port did not | |
7 | return within half a second, the WKA port for the | |
8 | directory server remains in the state OPENING, | |
9 | preventing any succeeding request to open the port. | |
10 | Solution: Make sure to always update the WKA port status from the | |
11 | corresponding FSF handler and do not rely on the timeout | |
12 | in zfcp_wka_port_get. | |
13 | ||
14 | Acked-by: John Jolly <jjolly@suse.de> | |
15 | --- | |
16 | ||
17 | drivers/s390/scsi/zfcp_fc.c | 8 +++----- | |
18 | drivers/s390/scsi/zfcp_fsf.c | 4 ++-- | |
19 | 2 files changed, 5 insertions(+), 7 deletions(-) | |
20 | ||
21 | --- a/drivers/s390/scsi/zfcp_fc.c 2009-07-13 11:07:50.000000000 +0200 | |
22 | +++ b/drivers/s390/scsi/zfcp_fc.c 2009-07-13 11:18:09.000000000 +0200 | |
23 | @@ -56,11 +56,9 @@ static int zfcp_wka_port_get(struct zfcp | |
24 | ||
25 | mutex_unlock(&wka_port->mutex); | |
26 | ||
27 | - wait_event_timeout( | |
28 | - wka_port->completion_wq, | |
29 | - wka_port->status == ZFCP_WKA_PORT_ONLINE || | |
30 | - wka_port->status == ZFCP_WKA_PORT_OFFLINE, | |
31 | - HZ >> 1); | |
32 | + wait_event(wka_port->completion_wq, | |
33 | + wka_port->status == ZFCP_WKA_PORT_ONLINE || | |
34 | + wka_port->status == ZFCP_WKA_PORT_OFFLINE); | |
35 | ||
36 | if (wka_port->status == ZFCP_WKA_PORT_ONLINE) { | |
37 | atomic_inc(&wka_port->refcount); | |
38 | --- a/drivers/s390/scsi/zfcp_fsf.c 2009-07-13 11:07:50.000000000 +0200 | |
39 | +++ b/drivers/s390/scsi/zfcp_fsf.c 2009-07-13 11:18:09.000000000 +0200 | |
40 | @@ -1616,10 +1616,10 @@ static void zfcp_fsf_open_wka_port_handl | |
41 | case FSF_ACCESS_DENIED: | |
42 | wka_port->status = ZFCP_WKA_PORT_OFFLINE; | |
43 | break; | |
44 | - case FSF_PORT_ALREADY_OPEN: | |
45 | - break; | |
46 | case FSF_GOOD: | |
47 | wka_port->handle = header->port_handle; | |
48 | + /* fall through */ | |
49 | + case FSF_PORT_ALREADY_OPEN: | |
50 | wka_port->status = ZFCP_WKA_PORT_ONLINE; | |
51 | } | |
52 | out: |