summaryrefslogtreecommitdiff
path: root/util/flashrom/flash_rom.c
diff options
context:
space:
mode:
Diffstat (limited to 'util/flashrom/flash_rom.c')
-rw-r--r--util/flashrom/flash_rom.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/util/flashrom/flash_rom.c b/util/flashrom/flash_rom.c
index b1ca7b3466..ac530d08b6 100644
--- a/util/flashrom/flash_rom.c
+++ b/util/flashrom/flash_rom.c
@@ -52,8 +52,8 @@ struct flashchip *probe_flash(struct flashchip *flash)
volatile uint8_t *bios;
unsigned long size;
- if ((fd_mem = open("/dev/mem", O_RDWR)) < 0) {
- perror("Error: Can not open /dev/mem. You need to be root.");
+ if ((fd_mem = open(MEM_DEV, O_RDWR)) < 0) {
+ perror("Error: Can not access memory using " MEM_DEV ". You need to be root.");
exit(1);
}