diff options
author | Thomas Atkins <Thomas.Atkins@Sun.COM> | 2009-10-05 12:25:17 -0400 |
---|---|---|
committer | Thomas Atkins <Thomas.Atkins@Sun.COM> | 2009-10-05 12:25:17 -0400 |
commit | d5508a7fb37e6b070e142ee081bec69a3d20bd6c (patch) | |
tree | 6d37a947279a0d7d15f004a9ed96f906b8347f23 /usr/src | |
parent | e31df31051ab05e561eab5b23bb1c00627a10d64 (diff) | |
download | illumos-gate-d5508a7fb37e6b070e142ee081bec69a3d20bd6c.tar.gz |
6831548 sndr is causing ufs to hang
Diffstat (limited to 'usr/src')
-rw-r--r-- | usr/src/uts/common/avs/ns/rdc/rdc_clnt.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/avs/ns/rdc/rdc_io.h | 17 | ||||
-rw-r--r-- | usr/src/uts/common/avs/ns/rdc/rdc_svc.c | 3 |
3 files changed, 18 insertions, 4 deletions
diff --git a/usr/src/uts/common/avs/ns/rdc/rdc_clnt.c b/usr/src/uts/common/avs/ns/rdc/rdc_clnt.c index fa353bcc87..971cb09ec0 100644 --- a/usr/src/uts/common/avs/ns/rdc/rdc_clnt.c +++ b/usr/src/uts/common/avs/ns/rdc/rdc_clnt.c @@ -2180,6 +2180,7 @@ _rdc_remote_flush(rdc_aio_t *aio) * another set that has not resumed */ krdc->remote_index = rdc_net_state(krdc->index, CCIO_SLAVE); + DTRACE_PROBE1(remote_index_negative, int, krdc->remote_index); } @@ -2356,6 +2357,7 @@ _rdc_remote_flush(rdc_aio_t *aio) rdc_ooreply++; } #endif + DTRACE_PROBE1(pendvec_return, int, vecp->seq); if (group->asyncstall) { cv_broadcast(&group->asyncqcv); diff --git a/usr/src/uts/common/avs/ns/rdc/rdc_io.h b/usr/src/uts/common/avs/ns/rdc/rdc_io.h index d729efa441..6acf96686c 100644 --- a/usr/src/uts/common/avs/ns/rdc/rdc_io.h +++ b/usr/src/uts/common/avs/ns/rdc/rdc_io.h @@ -19,7 +19,7 @@ * CDDL HEADER END */ /* - * Copyright 2008 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ @@ -643,10 +643,19 @@ typedef struct rdc_host_u { /* * macro used to determine if the incomming sq, with sequence * value x, should be placed before the sq with sequence value y. - * This has to account for integer wrap. + * This has to account for integer wrap. We account for integer + * wrap by checking if the difference between x and y is within + * half of the maximum integer value (RDC_MAXINT) or not. */ -#define RDC_INFRONT(x, y) (((x < y) && ((y - x) < 1000)) ? 1 : \ - ((x > y) && ((x - y) > 1000)) ? 1 : 0) + +#define RDC_BITSPERBYTE 8 +#define RDC_BITS(type) (RDC_BITSPERBYTE * (long)sizeof (type)) +#define RDC_HIBITI ((unsigned)1 << (RDC_BITS(int) - 1)) +#define RDC_MAXINT ((int)(~RDC_HIBITI)) +#define RDC_RANGE ((RDC_MAXINT / 2) -1) + +#define RDC_INFRONT(x, y) (((x < y) && ((y - x) < RDC_RANGE)) ? 1 : \ + ((x > y) && ((x - y) > RDC_RANGE)) ? 1 : 0) diff --git a/usr/src/uts/common/avs/ns/rdc/rdc_svc.c b/usr/src/uts/common/avs/ns/rdc/rdc_svc.c index 32fc14dd51..3ce99afd96 100644 --- a/usr/src/uts/common/avs/ns/rdc/rdc_svc.c +++ b/usr/src/uts/common/avs/ns/rdc/rdc_svc.c @@ -1040,6 +1040,8 @@ r_net_write6(SVCXPRT *xprt) RDC_MAXPENDQ, group->seqack, diskio.seq, maxseq, group->seq); #endif + DTRACE_PROBE2(qsize_exceeded, int, diskio.seq, + int, maxseq); if (!(rdc_get_vflags(urdc) & RDC_VOL_FAILED)) { rdc_many_enter(krdc); @@ -2564,6 +2566,7 @@ rdc_setbitind(int *pendcnt, net_pendvec_t *pvec, rdc_net_dataset_t *dset, pvec[pc].alen = dset->fbalen; pvec[pc].pindex = pindex; *pendcnt = pc + 1; + DTRACE_PROBE1(pvec_reply, int, seq); } /* |