Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1274391
| From | Kees Cook <keescook@chromium.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [RFC PATCH] restrict /dev/mem to idle io memory ranges |
| Date | 2015-11-20 21:10 +0100 |
| Message-ID | <qx0al-3x6-5@gated-at.bofh.it> (permalink) |
| References | <qwXPc-1Rb-1@gated-at.bofh.it> <qx0al-3x6-7@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, Nov 20, 2015 at 12:00 PM, Arnd Bergmann <arnd@arndb.de> wrote: > On Friday 20 November 2015 09:31:33 Dan Williams wrote: >> This effectively promotes IORESOURCE_BUSY to IORESOURCE_EXCLUSIVE >> semantics by default. If userspace really believes it is safe to access >> the memory region it can also perform the extra step of disabling an >> active driver. This protects device address ranges with read side >> effects and otherwise directs userspace to use the driver. >> >> Persistent memory presents a large "mistake surface" to /dev/mem as now >> accidental writes can corrupt a filesystem. >> >> Cc: Kees Cook <keescook@chromium.org> >> Cc: Russell King <linux@arm.linux.org.uk> >> Cc: Catalin Marinas <catalin.marinas@arm.com> >> Cc: Will Deacon <will.deacon@arm.com> >> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> >> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> >> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> >> Cc: Thomas Gleixner <tglx@linutronix.de> >> Cc: Ingo Molnar <mingo@redhat.com> >> Cc: "H. Peter Anvin" <hpa@zytor.com> >> Cc: Andrew Morton <akpm@linux-foundation.org> >> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> >> Signed-off-by: Dan Williams <dan.j.williams@intel.com> >> > > I like the idea. Yes please! I was always surprised that IORESOURCE_BUSY was allowed under STRICT_DEVMEM. > Maybe split the change up into two patches, where the first one > just does the trivial move of the Kconfig option, and the second > one that changes behavior is small? Agreed: consolidate the per-arch Kconfigs first. > There is also a question of whether we actually need two options > or if we can safely make the existing option stricter. Right -- what actually breaks if we add _BUSY to getting blocked? -Kees -- Kees Cook Chrome OS Security -- 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/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[RFC PATCH] restrict /dev/mem to idle io memory ranges Dan Williams <dan.j.williams@intel.com> - 2015-11-20 18:40 +0100
Re: [RFC PATCH] restrict /dev/mem to idle io memory ranges Kees Cook <keescook@chromium.org> - 2015-11-20 21:10 +0100
Re: [RFC PATCH] restrict /dev/mem to idle io memory ranges Arnd Bergmann <arnd@arndb.de> - 2015-11-20 21:10 +0100
Re: [RFC PATCH] restrict /dev/mem to idle io memory ranges Russell King - ARM Linux <linux@arm.linux.org.uk> - 2015-11-20 21:20 +0100
Re: [RFC PATCH] restrict /dev/mem to idle io memory ranges Dan Williams <dan.j.williams@intel.com> - 2015-11-20 21:30 +0100
Re: [RFC PATCH] restrict /dev/mem to idle io memory ranges Kees Cook <keescook@chromium.org> - 2015-11-20 21:50 +0100
Re: [RFC PATCH] restrict /dev/mem to idle io memory ranges Ingo Molnar <mingo@kernel.org> - 2015-11-23 10:40 +0100
csiph-web