diff options
author | Alexander Motin <mav@FreeBSD.org> | 2014-10-09 05:53:58 +0000 |
---|---|---|
committer | Alexander Motin <mav@FreeBSD.org> | 2014-10-09 05:53:58 +0000 |
commit | 840a5dd44739f0f4f7e70b2789fc0cead4daccf3 (patch) | |
tree | 5bd1bf6b3903bbe12dce4ff021c21dd49048cf79 /sys/cam/cam_xpt.c | |
parent | 514929b193731aec3ea60abb3a09ad24fa4dc0f3 (diff) | |
download | src-840a5dd44739f0f4f7e70b2789fc0cead4daccf3.tar.gz src-840a5dd44739f0f4f7e70b2789fc0cead4daccf3.zip |
Use proper variable when looping through periphs with CAM_PERIPH_FREE.
PR: 194256
Submitted by: Scott M. Ferris <smferris@gmail.com>
MFC after: 3 days
Sponsored by: EMC/Isilon Storage Division
Notes
Notes:
svn path=/head/; revision=272805
Diffstat (limited to 'sys/cam/cam_xpt.c')
-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 3cba1b0e676e..5042d91d9d7f 100644 --- a/sys/cam/cam_xpt.c +++ b/sys/cam/cam_xpt.c @@ -2195,7 +2195,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); @@ -2269,7 +2269,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(); |