svn commit: r331223 - head/sys/cam/scsi
Kenneth D. Merry
ken at FreeBSD.org
Mon Mar 19 20:19:01 UTC 2018
Author: ken
Date: Mon Mar 19 20:19:00 2018
New Revision: 331223
URL: https://svnweb.freebsd.org/changeset/base/331223
Log:
cam_periph_acquire() now returns an errno.
The ch(4) driver was missed in change 328918, which changed
cam_periph_acquire() to return an errno instead of cam_status.
As a result, ch(4) failed to attach.
Sponsored by: Spectra Logic
Modified:
head/sys/cam/scsi/scsi_ch.c
Modified: head/sys/cam/scsi/scsi_ch.c
==============================================================================
--- head/sys/cam/scsi/scsi_ch.c Mon Mar 19 19:32:05 2018 (r331222)
+++ head/sys/cam/scsi/scsi_ch.c Mon Mar 19 20:19:00 2018 (r331223)
@@ -419,7 +419,7 @@ chregister(struct cam_periph *periph, void *arg)
* instance for it. We'll release this reference once the devfs
* instance has been freed.
*/
- if (cam_periph_acquire(periph) != CAM_REQ_CMP) {
+ if (cam_periph_acquire(periph) != 0) {
xpt_print(periph->path, "%s: lost periph during "
"registration!\n", __func__);
cam_periph_lock(periph);
@@ -467,7 +467,7 @@ chopen(struct cdev *dev, int flags, int fmt, struct th
int error;
periph = (struct cam_periph *)dev->si_drv1;
- if (cam_periph_acquire(periph) != CAM_REQ_CMP)
+ if (cam_periph_acquire(periph) != 0)
return (ENXIO);
softc = (struct ch_softc *)periph->softc;
More information about the svn-src-all
mailing list