Hi, all, perhaps it is better to address this message to a specific kernel forum but this seems to affect both 2.2 and 2.4. I am making benchmarks (in a very specific area) and want to clear cashes of some files. I do this by calling truncate_inode_pages inside a tiny driver. I know about O_DIRECT parameter in open function for kernel 2.4 and later but I want this to work with 2.2 too.
A problem: this works poorly with a "recently" created file. After creating and closing a file truncate_inode_pages does not clear all linux cashes! However after rebooting a PC (and I suppose after remounting a partition) all cashes are cleared all right.