lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Sat, 06 Mar 2010 10:00:22 +0000 From: Catalin Marinas <catalin.marinas@....com> To: Russell King - ARM Linux <linux@....linux.org.uk> Cc: linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org, James Bottomley <James.Bottomley@...senPartnership.com>, Benjamin Herrenschmidt <benh@...nel.crashing.org> Subject: Re: [RFC PATCH] ARM: Assume new page cache pages have dirty D-cache On Fri, 2010-03-05 at 21:16 +0000, Russell King - ARM Linux wrote: > On Fri, Mar 05, 2010 at 04:52:40PM +0000, Catalin Marinas wrote: > > As Ben said, I think we can set PG_dcache_clean in the > > clear/copy_user_page() functions. My doubt with these functions is the > > highmem cases where kunmap_atomic() only flushes the D-cache in one > > situation, the other just calling kunmap_high() which doesn't seem to do > > anything to the caches. > > In which case you're totally missing the point with these functions. > The copy_user_page and clear_user_page functions specifically do tricks > to ensure that they can avoid additional cache maintainence - or any > cache maintainence at all. > > For instance, on aliasing VIPT, they will map the user page in using > the same colour as the ultimate userspace address, ensuring that any > cache lines created will be visible to the userspace application. I was more thinking for the non-aliasing VIPT case where we could defer the flushing until update_mmu_cache(). But I'm fine with just setting PG_dcache_clean in these functions to avoid checks on non-aliasing vs. aliasing VIPT. > So what kunmap_atomic() does with caches is not really relevant to the > coherency issue. The relevant part is that if highmem is enabled, copy_user_page() does not flush the D-cache, leaving it to kunmap_atomic(). Does this latter function flush the D-cache in all the relevant situations? -- Catalin -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists