FreeBSD: Don't set the PZERO flag to mtx_sleep.
We also don't support anything old enough to need tsleep.main
parent
06e182d025
commit
6777c6bb8b
|
@ -663,7 +663,7 @@ void drm_close(void *data)
|
|||
}
|
||||
/* Contention */
|
||||
retcode = mtx_sleep((void *)&dev->lock.lock_queue,
|
||||
&dev->dev_lock, PZERO | PCATCH, "drmlk2", 0);
|
||||
&dev->dev_lock, PCATCH, "drmlk2", 0);
|
||||
if (retcode)
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -79,7 +79,7 @@ int drm_lock(struct drm_device *dev, void *data, struct drm_file *file_priv)
|
|||
|
||||
/* Contention */
|
||||
ret = mtx_sleep((void *)&dev->lock.lock_queue, &dev->dev_lock,
|
||||
PZERO | PCATCH, "drmlk2", 0);
|
||||
PCATCH, "drmlk2", 0);
|
||||
if (ret != 0)
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -1406,12 +1406,7 @@ void radeon_do_release(struct drm_device * dev)
|
|||
#ifdef __linux__
|
||||
schedule();
|
||||
#else
|
||||
#if defined(__FreeBSD__) && __FreeBSD_version > 500000
|
||||
mtx_sleep(&ret, &dev->dev_lock, PZERO, "rdnrel",
|
||||
1);
|
||||
#else
|
||||
tsleep(&ret, PZERO, "rdnrel", 1);
|
||||
#endif
|
||||
mtx_sleep(&ret, &dev->dev_lock, 0, "rdnrel", 1);
|
||||
#endif
|
||||
}
|
||||
radeon_do_cp_stop(dev_priv);
|
||||
|
|
Loading…
Reference in New Issue