it complained that mdls had to have a certain (undocumented) flag set. also, it seemed to imply that in readdir, the locking of pages needed to be done by the thread creating the mdl. so i moved the locking/unlocking there.