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
This commit is contained in:
parent
3809903c0e
commit
fddccc44e2
@ -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 thread *td)
|
||||
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;
|
||||
|
Loading…
Reference in New Issue
Block a user