Whamcloud - gitweb
Fix three problems related to lock extent revocation:
authoradilger <adilger>
Thu, 4 Mar 2004 08:33:01 +0000 (08:33 +0000)
committeradilger <adilger>
Thu, 4 Mar 2004 08:33:01 +0000 (08:33 +0000)
commit67786af2fa8faa488fc85606a42b7066c0dbc32d
treebf398e00180f195c7452c1e4945e1adf2398806e
parent7b62fa0c4b6577a2e702e972f71afbb5f0eb9556
Fix three problems related to lock extent revocation:
- we were incorrectly calculating the "end" index value to be at the beginning
  of the next stripe instead of at the end of the current stripe (extra +1 for
  end, instead of using <= end for page indices)
- when comparing end << PAGE_CACHE_SHIFT for overflow against extent->end we
  used an unsigned long (which overflowed during the test ;-) so we always
  evicted pages to EOF (may have been a culprit in bug 2106 also)
- when matching against other locks (to see if page is under 2 locks) we
  were doing so in the file offset space (from page->index) instead of in
  the osc/extent space so we were matching against the wrong locks, if any

Change LL_CDEBUG_PAGE() to take a debug mask, so we can use it for error cases.
b=2765
lustre/llite/file.c
lustre/llite/llite_internal.h
lustre/llite/rw.c
lustre/llite/rw24.c
lustre/llite/rw26.c