Would it be possible to add immediate second open call without O_DIRECT, just after the first one (with O_DIRECT) fails with EINVAL, before giving up on a file completely? It's still better to have verification run slower than to redownload everything, isn't it?
Nothing extracted yet.
During installation Ubuntu offers option to ecnrypt home directory, which puts all user files on ecryptfs. When verifying integrity of game cache, Steam tries to use Direct I/O (open with O_DIRECT flag), which is not implemented for encryptfs. Validation fails with"Validation: file locked" logged in content_log.txt and all game files are downloaded again, whether they are really broken or not.