summaryrefslogtreecommitdiffstats
path: root/sys/dev/cfi/cfi_dev.c
Commit message (Collapse)AuthorAgeFilesLines
* MFP4 217312, 222008, 222052, 222053, 222673, 231484, 231491, 231565, 570643brooks2013-09-041-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | 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)
* CFI fixes for big endian archs.jchandra2012-03-271-2/+2
| | | | | | | | | | 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.
* Merge r221614,221696,221737,221840 from largeSMP project branch:attilio2011-05-221-1/+2
| | | | | | | | | | | | | | | | | | | Rewrite atomic operations for powerpc in order to achieve the following: - Produce a type-clean implementation (in terms of functions arguments and returned values) for the primitives. - Fix errors with _long() atomics where they ended up with the wrong arguments to be accepted. - Follow the sys/type.h specifics that define the numbered types starting from standard C types. - Let _ptr() version to not auto-magically cast arguments, but leave the burden on callers, as _ptr() atomic is intended to be used relatively rarely. Fix cfi in order to support the latest point. In collabouration with: bde Tested by: andreast, nwhitehorn, jceel MFC after: 2 weeks
* Add cfid, a disk interface to CFI flash devices; this enables constructionsam2009-03-091-2/+2
| | | | | | of flash-based filesystems. Note this is not interlocked against the raw CFI device.
* Add support for frobbing Intel StrataFlash Protection Registers:sam2009-02-051-2/+20
| | | | | | | | | | | | | | 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
* reorg ioctl code to simplify adding new requestssam2009-02-031-16/+21
|
* Add a driver for flash memory that implements to the Common Flashmarcel2008-10-251-0/+277
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.
OpenPOWER on IntegriCloud