Linux Kernel
3.7.1
|
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/eeprom_93cx6.h>
Go to the source code of this file.
Functions | |
MODULE_AUTHOR ("http://rt2x00.serialmonkey.com") | |
MODULE_VERSION ("1.0") | |
MODULE_DESCRIPTION ("EEPROM 93cx6 chip driver") | |
MODULE_LICENSE ("GPL") | |
void | eeprom_93cx6_read (struct eeprom_93cx6 *eeprom, const u8 word, u16 *data) |
EXPORT_SYMBOL_GPL (eeprom_93cx6_read) | |
void | eeprom_93cx6_multiread (struct eeprom_93cx6 *eeprom, const u8 word, __le16 *data, const u16 words) |
EXPORT_SYMBOL_GPL (eeprom_93cx6_multiread) | |
void | eeprom_93cx6_wren (struct eeprom_93cx6 *eeprom, bool enable) |
EXPORT_SYMBOL_GPL (eeprom_93cx6_wren) | |
void | eeprom_93cx6_write (struct eeprom_93cx6 *eeprom, u8 addr, u16 data) |
EXPORT_SYMBOL_GPL (eeprom_93cx6_write) | |
void eeprom_93cx6_multiread | ( | struct eeprom_93cx6 * | eeprom, |
const u8 | word, | ||
__le16 * | data, | ||
const u16 | words | ||
) |
eeprom_93cx6_multiread - Read multiple words from eeprom : Pointer to eeprom structure : Word index from where we should start reading : target pointer where the information will have to be stored : Number of words that should be read.
This function will read all requested words from the eeprom, this is done by calling eeprom_93cx6_read() multiple times. But with the additional change that while the eeprom_93cx6_read will return host ordered bytes, this method will return little endian words.
Definition at line 223 of file eeprom_93cx6.c.
eeprom_93cx6_read - Read multiple words from eeprom : Pointer to eeprom structure : Word index from where we should start reading : target pointer where the information will have to be stored
This function will read the eeprom data as host-endian word into the given data pointer.
Definition at line 181 of file eeprom_93cx6.c.
void eeprom_93cx6_wren | ( | struct eeprom_93cx6 * | eeprom, |
bool | enable | ||
) |
eeprom_93cx6_wren - set the write enable state : Pointer to eeprom structure : true to enable writes, otherwise disable writes
Set the EEPROM write enable state to either allow or deny writes depending on the value.
Definition at line 245 of file eeprom_93cx6.c.
void eeprom_93cx6_write | ( | struct eeprom_93cx6 * | eeprom, |
u8 | addr, | ||
u16 | data | ||
) |
eeprom_93cx6_write - write data to the EEPROM : Pointer to eeprom structure : Address to write data to. : The data to write to address .
Write the to the specified in the EEPROM and waiting for the device to finish writing.
Note, since we do not expect large number of write operations we delay in between parts of the operation to avoid using excessive amounts of CPU time busy waiting.
Definition at line 277 of file eeprom_93cx6.c.
EXPORT_SYMBOL_GPL | ( | eeprom_93cx6_read | ) |
EXPORT_SYMBOL_GPL | ( | eeprom_93cx6_multiread | ) |
EXPORT_SYMBOL_GPL | ( | eeprom_93cx6_wren | ) |
EXPORT_SYMBOL_GPL | ( | eeprom_93cx6_write | ) |
MODULE_AUTHOR | ( | "http://rt2x00.serialmonkey.com" | ) |
MODULE_DESCRIPTION | ( | "EEPROM 93cx6 chip driver" | ) |
MODULE_LICENSE | ( | "GPL" | ) |
MODULE_VERSION | ( | "1.0" | ) |