Lines Matching defs:fork
150 * 1) free all UNIX byterange lock from any fork
151 * 2) free all locks of the requested fork
156 static void adf_unlock(struct adouble *ad, struct ad_fd *adf, const int fork, int unlckbrl)
163 || lock[i].user == fork) {
189 /* find a byte lock that overlaps off/len for a particular open fork */
191 const int fork, const int type,
201 (lock[i].user == fork) &&
210 /* search other fork lock lists */
212 const int fork, const int type,
224 (lock[i].user != fork)
246 translate a resource fork lock to an offset
354 int ad_lock(struct adouble *ad, uint32_t eid, int locktype, off_t off, off_t len, int fork)
406 /* see if it's locked by another fork.
410 if (adf_findxlock(adf, fork, ADLOCK_WR |
419 i = adf_findlock(adf, fork, ADLOCK_RD | ADLOCK_WR, lock.l_start, lock.l_len);
462 oldlock = adf_findxlock(adf, fork, ADLOCK_RD, lock.l_start, lock.l_len);
481 adflock->user = fork;
503 int ad_tmplock(struct adouble *ad, uint32_t eid, int locktype, off_t off, off_t len, int fork)
525 /* there's no resource fork. return success */
547 /* see if it's locked by another fork. */
548 if (fork && adf_findxlock(adf, fork,
572 void ad_unlock(struct adouble *ad, const int fork, int unlckbrl)
577 adf_unlock(ad, &ad->ad_data_fork, fork, unlckbrl);
580 adf_unlock(ad, &ad->ad_resource_fork, fork, unlckbrl);
590 * @param eid (r) datafork or ressource fork
628 * other process has fork of file opened
647 /* either there's a lock or we already know one fork is open */