History log of /freebsd-11.0-release/sys/dev/cfi/cfi_core.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 303975 11-Aug-2016 gjb

Copy stable/11@r303970 to releng/11.0 as part of the 11.0-RELEASE
cycle.

Prune svn:mergeinfo from the new branch, and rename it to RC1.

Update __FreeBSD_version.

Use the quarterly branch for the default FreeBSD.conf pkg(8) repo and
the dvd1.iso packages population.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 302408 08-Jul-2016 gjb

Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle.
Prune svn:mergeinfo from the new branch, as nothing has been merged
here.

Additional commits post-branch will follow.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 295284 04-Feb-2016 adrian

Provide a workaround for setting the correct endianness when doing CFI on
a mips big-endian board.

This is (hopefully! ish!) a temporary change until a slightly better way
can be found to express this without a config option.

Tested:

* BUFFALO WZR-HP-G300NH 1stGen (by submitter)

Submitted by: Mori Hiroki <yamori813@yahoo.co.jp>


# 273174 16-Oct-2014 davide

Follow up to r225617. In order to maximize the re-usability of kernel code
in userland rename in-kernel getenv()/setenv() to kern_setenv()/kern_getenv().
This fixes a namespace collision with libc symbols.

Submitted by: kmacy
Tested by: make universe


# 256753 18-Oct-2013 brooks

MFP4: 1136252

Add an option ATSE_CFI_HACK to allow memory mapped CFI devices to have
their address range allocated sharable so that atse(4) can find it's
Ethernet address in the expected location.

We intend to remove this hack once the BERI platform has a loader.


# 255207 04-Sep-2013 brooks

MFP4 217312, 222008, 222052, 222053, 222673, 231484, 231491, 231565, 570643

Rework the timeout code to use actual time rather than a DELAY() loop and
to use both typical and maximum to allow logging of timeout failures.
Also correct the erase timeout, it is specified in milliseconds not
microseconds like the other timeouts. Do not invoke DELAY() between
status queries as this adds significant latency which in turn reduced
write performance substantially.

Sanity check timeout values from the hardware.

Implement support for buffered writes (only enabled on Intel/Sharp parts
for now). This yields an order of magnitude speedup on the 64MB Intel
StrataFlash parts we use.

When making a copy of the block to modify, also keep a clean copy around
until we are ready to commit the block and use it to avoid unnecessary
erases. In the non-buffer write case, also use it to avoid
unnecessary writes when the block has not been erased. This yields a
significant speedup when doing things like zeroing a block.

Sponsored by: DARPA, AFRL
Reviewed by: imp (previous version)


# 251118 30-May-2013 brooks

MFP4 @217311

Intel and Sharp flash power on with their blocks in a "locked" state.
Unlocked them before attempting to perform an erase or write action and
relock when the action is complete.


# 250115 30-Apr-2013 brooks

MFP4 change 222060:

On Intel devices, put the Factory PPR in kenv. On some FPGA boards it may
be the only software accessable unique ID.

Sponsored by: DARPA, AFRL


# 233553 27-Mar-2012 jchandra

CFI fixes for big endian archs.

The flash commands and responses are little-endian and have to be
byte swapped on big-endian systems. However the raw read of data
need not be swapped.

Make the cfi_read and cfi_write do the swapping, and provide a
cfi_read_raw which does not byte swap for reading data from
flash.


# 193936 10-Jun-2009 imp

Move from using devclass_find_free_unit(cfi_diskclass, 0) to -1, since
they have the same basic behavior.


# 189606 09-Mar-2009 sam

Add cfid, a disk interface to CFI flash devices; this enables construction
of flash-based filesystems.

Note this is not interlocked against the raw CFI device.


# 188332 08-Feb-2009 sam

fix typo

Submitted by: Christoph Mallon <christoph.mallon@gmx.de>


# 188268 07-Feb-2009 sam

fix building w/o CFI_ARMEDANDDANGEROUS


# 188267 07-Feb-2009 sam

expand CFI_ARMEDANDDANGEROUS to include writing the user segment
of the PR; this register is actually write-once so deserves the
safety-belt as much as the PLR


# 188156 05-Feb-2009 sam

Add support for frobbing Intel StrataFlash Protection Registers:
o add CFI_SUPPORT_STRATAFLASH compile option to enable support
o add new ioctls to get/set the factory and user/oem segments of the PR
and to get/set Protection Lock Register that fuses the user segment
o add #defines for bits in the status register
o update cfi_wait_ready to take an offset so it can be used to wait for
PR write completion and replace constants w/ symbolic names

Note: writing the user segment isn't correct; committing now to get review.

Sponsored by: Carlson Wireless
Reviewed by: imp, Chris Anderson


# 188087 03-Feb-2009 sam

honor any interface width (e.g. setup by the bus shim) and don't probe;
this is needed for the moment to workaround bus shim issues


# 184251 25-Oct-2008 marcel

Add a driver for flash memory that implements to the Common Flash
Memory Interface (CFI). The flash memory can be read and written
to through /dev/cfi# and an ioctl() exists so processes can read
the query information.
The driver supports the AMD and Intel command set, though only
the AMD command has been tested.

Obtained from: Juniper Networks, Inc.