FreeBSD Bugzilla – Attachment 202296 Details for
Bug 235700
oce(4) driver causes fatal trap 12 on boot with emulex 10gbe nic
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Bounds check array accesses in oce driver
oce_if.c.patch (text/plain), 808 bytes, created by
Ryan Moeller
on 2019-02-23 19:45:04 UTC
(
hide
)
Description:
Bounds check array accesses in oce driver
Filename:
MIME Type:
Creator:
Ryan Moeller
Created:
2019-02-23 19:45:04 UTC
Size:
808 bytes
patch
obsolete
>diff --git a/sys/dev/oce/oce_if.c b/sys/dev/oce/oce_if.c >index 221a871a7ceb..c554043126cc 100644 >--- a/sys/dev/oce/oce_if.c >+++ b/sys/dev/oce/oce_if.c >@@ -2378,8 +2378,6 @@ oce_eqd_set_periodic(POCE_SOFTC sc) > uint64_t now = 0, delta; > int eqd, i, num = 0; > uint32_t tx_reqs = 0, rxpkts = 0, pps; >- struct oce_wq *wq; >- struct oce_rq *rq; > > #define ticks_to_msecs(t) (1000 * (t) / hz) > >@@ -2394,10 +2392,10 @@ oce_eqd_set_periodic(POCE_SOFTC sc) > goto modify_eqd; > } > >- rq = sc->rq[i]; >- rxpkts = rq->rx_stats.rx_pkts; >- wq = sc->wq[i]; >- tx_reqs = wq->tx_stats.tx_reqs; >+ if (i < sc->nrqs) >+ rxpkts = sc->rq[i]->rx_stats.rx_pkts; >+ if (i < sc->nwqs) >+ tx_reqs = sc->wq[i]->tx_stats.tx_reqs; > now = ticks; > > if (!aic->ticks || now < aic->ticks ||
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 235700
:
201962
|
202047
| 202296