On 15 Aug 2002, Gilad Ben-Yossef wrote:
>
> Thus spake mm/shmem.c:
>
> idx = (address - vma->vm_start) >> PAGE_CACHE_SHIFT;
> idx += vma->vm_pgoff;
>
> But include/linux/mm.h says:
>
> unsigned long vm_pgoff; /* Offset (within vm_file) in PAGE_SIZE
> units, *not* PAGE_CACHE_SIZE */
Good observation, but it's certainly not something for Marcelo to worry
about for 2.4. This is only one of many confusions which would need to
be fixed to get PAGE_CACHE_SIZE > PAGE_SIZE working. mm/shmem.c
is probably especially confused (since it's backing a PAGE_CACHE_SIZE-
orientated filesystem with PAGE_SIZE-orientated swap), but much else too.
I think it was a mistake to introduce the PAGE_CACHE_SIZE definition
before it could be allowed to diverge from PAGE_SIZE: I find it very
hard to work out the right way to go, and would prefer it to vanish.
But Ben LaHaise did succeed in getting a PAGE_CACHE_SIZE > PAGE_SIZE
patch working on 2.4.6 (no patch to mm/shmem.c, but it was a little
different then anyway, right or wrong I don't know).
Hugh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Thu Aug 15 2002 - 22:00:41 EST