diff options
| author | lm66018 <none@none> | 2007-12-10 01:35:27 -0800 |
|---|---|---|
| committer | lm66018 <none@none> | 2007-12-10 01:35:27 -0800 |
| commit | 928da554c8c4cc86ee5c49c1f3e8706d88eee546 (patch) | |
| tree | 37ddac4d1ec355445f2441a4548b581e3284fe39 /usr/src | |
| parent | a20d514e1b317d52819891ca08b32cec2eb5ff04 (diff) | |
| download | illumos-gate-928da554c8c4cc86ee5c49c1f3e8706d88eee546.tar.gz | |
6634346 cnex panics if DTrace probes use values which have been destroyed by a call to remove intr
Diffstat (limited to 'usr/src')
| -rw-r--r-- | usr/src/uts/sun4v/io/cnex.c | 16 | ||||
| -rw-r--r-- | usr/src/uts/sun4v/sys/cnex.h | 3 |
2 files changed, 11 insertions, 8 deletions
diff --git a/usr/src/uts/sun4v/io/cnex.c b/usr/src/uts/sun4v/io/cnex.c index 5808cd0eba..a6e4b0c56a 100644 --- a/usr/src/uts/sun4v/io/cnex.c +++ b/usr/src/uts/sun4v/io/cnex.c @@ -218,7 +218,7 @@ static struct dev_ops cnex_ops = { */ static struct modldrv modldrv = { &mod_driverops, - "sun4v channel-devices nexus %I%", + "sun4v channel-devices nexus 1.11", &cnex_ops, }; @@ -620,7 +620,9 @@ cnex_add_intr(dev_info_t *dip, uint64_t id, cnex_intrtype_t itype, iinfo->arg1 = arg1; iinfo->arg2 = arg2; - iinfo->cldcp = cldcp; + /* save data for DTrace probes used by intrstat(1m) */ + iinfo->dip = cldcp->dip; + iinfo->id = cldcp->id; iinfo->icookie = MINVINTR_COOKIE + iinfo->ino; @@ -894,7 +896,7 @@ cnex_clr_intr(dev_info_t *dip, uint64_t id, cnex_intrtype_t itype) return (EINVAL); } - D1("cnex_rem_intr: interrupt ino=0x%x\n", iinfo->ino); + D1("%s: interrupt ino=0x%x\n", __func__, iinfo->ino); /* check if a handler is already added */ if (iinfo->hdlr == 0) { @@ -943,19 +945,19 @@ cnex_intr_wrapper(caddr_t arg) * probes('channelintr__start','channelintr__complete') * are provided here. */ - DTRACE_PROBE4(channelintr__start, uint64_t, iinfo->cldcp->id, + DTRACE_PROBE4(channelintr__start, uint64_t, iinfo->id, cnex_intr_t *, iinfo, void *, handler, caddr_t, handler_arg1); - DTRACE_PROBE4(interrupt__start, dev_info_t, iinfo->cldcp->dip, + DTRACE_PROBE4(interrupt__start, dev_info_t, iinfo->dip, void *, handler, caddr_t, handler_arg1, caddr_t, handler_arg2); D1("cnex_intr_wrapper:ino=0x%llx invoke client handler\n", iinfo->ino); res = (*handler)(handler_arg1, handler_arg2); - DTRACE_PROBE4(interrupt__complete, dev_info_t, iinfo->cldcp->dip, + DTRACE_PROBE4(interrupt__complete, dev_info_t, iinfo->dip, void *, handler, caddr_t, handler_arg1, int, res); - DTRACE_PROBE4(channelintr__complete, uint64_t, iinfo->cldcp->id, + DTRACE_PROBE4(channelintr__complete, uint64_t, iinfo->id, cnex_intr_t *, iinfo, void *, handler, caddr_t, handler_arg1); return (res); diff --git a/usr/src/uts/sun4v/sys/cnex.h b/usr/src/uts/sun4v/sys/cnex.h index cb413b9ecf..83e1c17feb 100644 --- a/usr/src/uts/sun4v/sys/cnex.h +++ b/usr/src/uts/sun4v/sys/cnex.h @@ -56,10 +56,11 @@ typedef struct cnex_intr { uint64_t ino; /* dev intr number */ uint64_t cpuid; /* Target CPU */ uint64_t icookie; /* dev intr cookie */ + uint64_t id; /* LDC channel ID */ + dev_info_t *dip; /* LDC channel devinfo */ uint_t (*hdlr)(); /* intr handler */ caddr_t arg1; /* intr argument 1 */ caddr_t arg2; /* intr argument 2 */ - struct cnex_ldc *cldcp; /* back pointer to the ldc */ } cnex_intr_t; /* cnex interrupt types */ |
