Lines Matching refs:error

36 	int error;
38 error = 0;
41 error = linux_ioctl_register_handler(&linux_ntsync_handler);
42 if (error != 0) {
44 "error %d\n", error);
57 error = EOPNOTSUPP;
60 return (error);
131 int error, ref;
134 return (error = ENOIOCTL);
144 error = ENOIOCTL;
148 error = dsw->d_ioctl(dev, cmd, data, 0, td);
152 return (error);
169 int error, error1, lcmd;
175 error = fget_cap(td, args->fd, &cap_no_rights, NULL, &fp, NULL);
176 if (error != 0)
182 error = copyin(data, &lsa, sizeof(lsa));
184 if (error == 0) {
185 error = linux_ntsync_cdev_ioctl(td,
190 error = copyin(data, &lma, sizeof(lma));
192 if (error == 0) {
193 error = linux_ntsync_cdev_ioctl(td,
198 error = copyin(data, &lea, sizeof(lea));
200 if (error == 0) {
201 error = linux_ntsync_cdev_ioctl(td,
206 error = copyin(data, &lwa, sizeof(lwa));
208 if (error == 0) {
209 error = linux_ntsync_cdev_ioctl(td,
211 if (error == 0 || error == EOWNERDEAD) {
214 if (error == 0)
215 error = error1;
220 error = copyin(data, &lwa, sizeof(lwa));
222 if (error == 0) {
223 error = linux_ntsync_cdev_ioctl(td,
225 if (error == 0 || error == EOWNERDEAD) {
228 if (error == 0)
229 error = error1;
235 error = ENOTTY;
238 error = copyin(data, &val, sizeof(val));
239 if (error == 0) {
240 error = ntsync_sem_release(td, fp, &val);
241 if (error == 0)
242 error = copyout(&val, data, sizeof(val));
247 error = ENOTTY;
250 error = ntsync_sem_read(td, fp, &sa);
251 if (error == 0) {
253 error = copyout(&lsa, data, sizeof(lsa));
258 error = ENOTTY;
261 error = copyin(data, &lma, sizeof(lma));
263 if (error == 0) {
264 error = ntsync_mutex_unlock(td, fp, &ma);
265 if (error == 0) {
267 error = copyout(&lma, data, sizeof(lma));
273 error = ENOTTY;
276 error = copyin(data, &val, sizeof(val));
277 if (error == 0)
278 error = ntsync_mutex_kill(td, fp, val);
282 error = ENOTTY;
285 error = ntsync_mutex_read(td, fp, &ma, &doco);
289 if (error == 0)
290 error = error1;
295 error = ENOTTY;
298 error = ntsync_event_set(td, fp, &val);
299 if (error == 0)
300 error = copyout(&val, data, sizeof(val));
304 error = ENOTTY;
307 error = ntsync_event_reset(td, fp, &val);
308 if (error == 0)
309 error = copyout(&val, data, sizeof(val));
313 error = ENOTTY;
316 error = ntsync_event_pulse(td, fp, &val);
317 if (error == 0)
318 error = copyout(&val, data, sizeof(val));
322 error = ENOTTY;
325 error = ntsync_event_read(td, fp, &ea);
326 if (error == 0) {
328 error = copyout(&lea, data, sizeof(lea));
332 error = ENOTTY;
337 return (error);