afs_Trace4(afs_iclSetp, CM_TRACE_READ, ICL_TYPE_POINTER, avc,
ICL_TYPE_OFFSET, ICL_HANDLE_OFFSET(filePos), ICL_TYPE_INT32,
totalLength, ICL_TYPE_OFFSET,
- ICL_HANDLE_OFFSET(avc->m.Length));
+ ICL_HANDLE_OFFSET(avc->f.m.Length));
error = 0;
transferLength = 0;
if (!noLock)
ObtainReadLock(&avc->lock);
#if defined(AFS_TEXT_ENV) && !defined(AFS_VM_RDWR_ENV)
if (avc->flushDV.high == AFS_MAXDV && avc->flushDV.low == AFS_MAXDV) {
- hset(avc->flushDV, avc->m.DataVersion);
+ hset(avc->flushDV, avc->f.m.DataVersion);
}
#endif
* Locks held:
* avc->lock(R)
*/
- if (filePos >= avc->m.Length) {
+ if (filePos >= avc->f.m.Length) {
if (len > AFS_ZEROS)
len = sizeof(afs_zeros); /* and in 0 buffer */
len = 0;
AFS_UIOMOVE(afs_zeros, trimlen, UIO_READ, tuiop, code);
}
- while (avc->m.Length > 0 && totalLength > 0) {
+ while (avc->f.m.Length > 0 && totalLength > 0) {
/* read all of the cached info */
- if (filePos >= avc->m.Length)
+ if (filePos >= avc->f.m.Length)
break; /* all done */
if (noLock) {
if (tdc) {
* 2 requests never return a null dcache entry, btw.
*/
if (!(tdc->dflags & DFFetching)
- && !hsame(avc->m.DataVersion, tdc->f.versionNo)) {
+ && !hsame(avc->f.m.DataVersion, tdc->f.versionNo)) {
/* have cache entry, it is not coming in now,
* and we'll need new data */
tagain:
} else {
/* no longer fetching, verify data version
* (avoid new GetDCache call) */
- if (hsame(avc->m.DataVersion, tdc->f.versionNo)
+ if (hsame(avc->f.m.DataVersion, tdc->f.versionNo)
&& ((len = tdc->validPos - filePos) > 0)) {
offset = filePos - AFS_CHUNKTOBASE(tdc->f.chunk);
} else {
/* don't have current data, so get it below */
afs_Trace3(afs_iclSetp, CM_TRACE_VERSIONNO,
ICL_TYPE_INT64, ICL_HANDLE_OFFSET(filePos),
- ICL_TYPE_HYPER, &avc->m.DataVersion,
+ ICL_TYPE_HYPER, &avc->f.m.DataVersion,
ICL_TYPE_HYPER, &tdc->f.versionNo);
ReleaseReadLock(&tdc->lock);
afs_PutDCache(tdc);
len = AFS_CHUNKTOSIZE(tdc->f.chunk) - offset; /* bytes left in chunk addr space */
if (len > totalLength)
len = totalLength; /* and still within xfr request */
- tlen = avc->m.Length - offset; /* and still within file */
+ tlen = avc->f.m.Length - offset; /* and still within file */
if (len > tlen)
len = tlen;
if (len > AFS_ZEROS)
offset = AFS_CHUNKTOBASE(offset); /* base of next chunk */
ObtainReadLock(&adc->lock);
ObtainSharedLock(&adc->mflock, 662);
- if (offset < avc->m.Length && !(adc->mflags & DFNextStarted)
+ if (offset < avc->f.m.Length && !(adc->mflags & DFNextStarted)
&& !afs_BBusy()) {
struct brequest *bp;
afs_Trace4(afs_iclSetp, CM_TRACE_READ, ICL_TYPE_POINTER, avc,
ICL_TYPE_OFFSET, ICL_HANDLE_OFFSET(filePos), ICL_TYPE_INT32,
totalLength, ICL_TYPE_OFFSET,
- ICL_HANDLE_OFFSET(avc->m.Length));
+ ICL_HANDLE_OFFSET(avc->f.m.Length));
error = 0;
transferLength = 0;
if (!noLock)
ObtainReadLock(&avc->lock);
#if defined(AFS_TEXT_ENV) && !defined(AFS_VM_RDWR_ENV)
if (avc->flushDV.high == AFS_MAXDV && avc->flushDV.low == AFS_MAXDV) {
- hset(avc->flushDV, avc->m.DataVersion);
+ hset(avc->flushDV, avc->f.m.DataVersion);
}
#endif
- if (filePos >= avc->m.Length) {
+ if (filePos >= avc->f.m.Length) {
if (len > AFS_ZEROS)
len = sizeof(afs_zeros); /* and in 0 buffer */
len = 0;
AFS_UIOMOVE(afs_zeros, trimlen, UIO_READ, tuiop, code);
}
- while (avc->m.Length > 0 && totalLength > 0) {
+ while (avc->f.m.Length > 0 && totalLength > 0) {
/* read all of the cached info */
- if (filePos >= avc->m.Length)
+ if (filePos >= avc->f.m.Length)
break; /* all done */
if (noLock) {
if (tdc) {
* data already coming, we don't need to do this, obviously. Type
* 2 requests never return a null dcache entry, btw. */
if (!(tdc->dflags & DFFetching)
- && !hsame(avc->m.DataVersion, tdc->f.versionNo)) {
+ && !hsame(avc->f.m.DataVersion, tdc->f.versionNo)) {
/* have cache entry, it is not coming in now, and we'll need new data */
tagain:
if (trybusy && !afs_BBusy()) {
} else {
/* no longer fetching, verify data version (avoid new
* GetDCache call) */
- if (hsame(avc->m.DataVersion, tdc->f.versionNo)
+ if (hsame(avc->f.m.DataVersion, tdc->f.versionNo)
&& ((len = tdc->validPos - filePos) > 0)) {
offset = filePos - AFS_CHUNKTOBASE(tdc->f.chunk);
} else {
/* don't have current data, so get it below */
afs_Trace3(afs_iclSetp, CM_TRACE_VERSIONNO,
ICL_TYPE_INT64, ICL_HANDLE_OFFSET(filePos),
- ICL_TYPE_HYPER, &avc->m.DataVersion,
+ ICL_TYPE_HYPER, &avc->f.m.DataVersion,
ICL_TYPE_HYPER, &tdc->f.versionNo);
ReleaseReadLock(&tdc->lock);
afs_PutDCache(tdc);
len = AFS_CHUNKTOSIZE(tdc->f.chunk) - offset; /* bytes left in chunk addr space */
if (len > totalLength)
len = totalLength; /* and still within xfr request */
- tlen = avc->m.Length - offset; /* and still within file */
+ tlen = avc->f.m.Length - offset; /* and still within file */
if (len > tlen)
len = tlen;
if (len > AFS_ZEROS)