summaryrefslogtreecommitdiff
path: root/util/flashrom/flashrom.c
diff options
context:
space:
mode:
authorCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>2008-05-14 14:51:22 +0000
committerCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>2008-05-14 14:51:22 +0000
commit3f09561ec4697be3745c2c5f3318680323b08baf (patch)
treea26ab99e5bf4210a3280bc0c5b0a0d61393bc6fa /util/flashrom/flashrom.c
parent58a1cc1d3494daa1002bac617420373e097becee (diff)
Add more infrastructure for flashrom ICH9 support.
Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> Acked-by: Stefan Reinauer <stepan@coresystems.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3314 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'util/flashrom/flashrom.c')
-rw-r--r--util/flashrom/flashrom.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/util/flashrom/flashrom.c b/util/flashrom/flashrom.c
index dce303ed3f..842d473a1e 100644
--- a/util/flashrom/flashrom.c
+++ b/util/flashrom/flashrom.c
@@ -381,8 +381,8 @@ int main(int argc, char *argv[])
pci_init(pacc); /* Initialize the PCI library */
pci_scan_bus(pacc); /* We want to get the list of devices */
- /* Open the memory device. A lot of functions need it */
- if ((fd_mem = open(MEM_DEV, O_RDWR)) < 0) {
+ /* Open the memory device UNCACHED. That's important for MMIO. */
+ if ((fd_mem = open(MEM_DEV, O_RDWR|O_SYNC)) < 0) {
perror("Error: Can not access memory using " MEM_DEV
". You need to be root.");
exit(1);