diff options
author | mav <mav@FreeBSD.org> | 2014-10-12 06:14:50 +0000 |
---|---|---|
committer | mav <mav@FreeBSD.org> | 2014-10-12 06:14:50 +0000 |
commit | a45382b275e7a354d96ed2689bc0de4d258dc84d (patch) | |
tree | c1325f7cabab4432b20df2519626461bc61bc0d4 /sys | |
parent | 538d05fbccfbf0f5f7049d9004214993f40a027c (diff) | |
download | FreeBSD-src-a45382b275e7a354d96ed2689bc0de4d258dc84d.zip FreeBSD-src-a45382b275e7a354d96ed2689bc0de4d258dc84d.tar.gz |
Use proper variable when looping through periphs with CAM_PERIPH_FREE.
PR: 194256
Submitted by: Scott M. Ferris <smferris@gmail.com>
Sponsored by: EMC/Isilon Storage Division
Diffstat (limited to 'sys')
-rw-r--r-- | sys/cam/cam_xpt.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/cam/cam_xpt.c b/sys/cam/cam_xpt.c index bfad6dd..79d3023 100644 --- a/sys/cam/cam_xpt.c +++ b/sys/cam/cam_xpt.c @@ -2199,7 +2199,7 @@ xptperiphtraverse(struct cam_ed *device, struct cam_periph *start_periph, next_periph = SLIST_NEXT(periph, periph_links); while (next_periph != NULL && (next_periph->flags & CAM_PERIPH_FREE) != 0) - next_periph = SLIST_NEXT(periph, periph_links); + next_periph = SLIST_NEXT(next_periph, periph_links); if (next_periph) next_periph->refcount++; mtx_unlock(&bus->eb_mtx); @@ -2273,7 +2273,7 @@ xptpdperiphtraverse(struct periph_driver **pdrv, next_periph = TAILQ_NEXT(periph, unit_links); while (next_periph != NULL && (next_periph->flags & CAM_PERIPH_FREE) != 0) - next_periph = TAILQ_NEXT(periph, unit_links); + next_periph = TAILQ_NEXT(next_periph, unit_links); if (next_periph) next_periph->refcount++; xpt_unlock_buses(); |