Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 15 Feb 2013 20:05:16 GMT
From:      Brooks Davis <brooks@FreeBSD.org>
To:        Perforce Change Reviews <perforce@FreeBSD.org>
Subject:   PERFORCE change 222076 for review
Message-ID:  <201302152005.r1FK5GOh063579@skunkworks.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://p4web.freebsd.org/@@222076?ac=10

Change 222076 by brooks@brooks_zenith on 2013/02/15 20:04:49

	Actually try to open /dev/cfi0 for read when /dev/isf0 isn't
	there.  Prefer /dev/cfi0 in error output since it is the future.

Affected files ...

.. //depot/projects/ctsrd/beribsd/src/ctsrd/atsectl/atsectl.c#4 edit

Differences ...

==== //depot/projects/ctsrd/beribsd/src/ctsrd/atsectl/atsectl.c#4 (text+ko) ====

@@ -100,11 +100,11 @@
 
 	fd = open(DEV_ISF0_PATH, O_RDONLY, 0);
 	if (fd == -1)
-		fd = open(DEV_ISF0_PATH, O_RDONLY, 0);
+		fd = open(DEV_CFI0_PATH, O_RDONLY, 0);
 	else
 		fdev = ISF;
 	if (fd == -1)
-		errx(1, "Failed to open " DEV_ISF0_PATH);
+		errx(1, "Failed to open " DEV_CFI0_PATH);
 	else
 		fdev = CFI;
 
@@ -148,7 +148,7 @@
 	if (fd == -1)
 		fd = open(DEV_CFI0_PATH, O_WRONLY, 0);
 	if (fd == -1)
-		errx(1, "Failed to open " DEV_ISF0_PATH);
+		errx(1, "Failed to open " DEV_CFI0_PATH);
 
 	if (write(fd, block, sizeof(block)) != ISF_ERASE_BLOCK)
 		errx(1, "Short write on %s", fdevs[fdev]);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201302152005.r1FK5GOh063579>