Linux Kernel
3.7.1
|
#include <linux/err.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/errno.h>
#include <linux/kernel.h>
#include <linux/clk.h>
#include <linux/platform_device.h>
#include <linux/scatterlist.h>
#include <linux/dma-mapping.h>
#include <linux/io.h>
#include <linux/crypto.h>
#include <linux/interrupt.h>
#include <crypto/scatterwalk.h>
#include <crypto/aes.h>
#include <plat/cpu.h>
#include <plat/dma.h>
Go to the source code of this file.
Data Structures | |
struct | omap_aes_ctx |
struct | omap_aes_reqctx |
struct | omap_aes_dev |
Macros | |
#define | pr_fmt(fmt) "%s: " fmt, __func__ |
#define | FLD_MASK(start, end) (((1 << ((start) - (end) + 1)) - 1) << (end)) |
#define | FLD_VAL(val, start, end) (((val) << (end)) & FLD_MASK(start, end)) |
#define | AES_REG_KEY(x) (0x1C - ((x ^ 0x01) * 0x04)) |
#define | AES_REG_IV(x) (0x20 + ((x) * 0x04)) |
#define | AES_REG_CTRL 0x30 |
#define | AES_REG_CTRL_CTR_WIDTH (1 << 7) |
#define | AES_REG_CTRL_CTR (1 << 6) |
#define | AES_REG_CTRL_CBC (1 << 5) |
#define | AES_REG_CTRL_KEY_SIZE (3 << 3) |
#define | AES_REG_CTRL_DIRECTION (1 << 2) |
#define | AES_REG_CTRL_INPUT_READY (1 << 1) |
#define | AES_REG_CTRL_OUTPUT_READY (1 << 0) |
#define | AES_REG_DATA 0x34 |
#define | AES_REG_DATA_N(x) (0x34 + ((x) * 0x04)) |
#define | AES_REG_REV 0x44 |
#define | AES_REG_REV_MAJOR 0xF0 |
#define | AES_REG_REV_MINOR 0x0F |
#define | AES_REG_MASK 0x48 |
#define | AES_REG_MASK_SIDLE (1 << 6) |
#define | AES_REG_MASK_START (1 << 5) |
#define | AES_REG_MASK_DMA_OUT_EN (1 << 3) |
#define | AES_REG_MASK_DMA_IN_EN (1 << 2) |
#define | AES_REG_MASK_SOFTRESET (1 << 1) |
#define | AES_REG_AUTOIDLE (1 << 0) |
#define | AES_REG_SYSSTATUS 0x4C |
#define | AES_REG_SYSSTATUS_RESETDONE (1 << 0) |
#define | DEFAULT_TIMEOUT (5*HZ) |
#define | FLAGS_MODE_MASK 0x000f |
#define | FLAGS_ENCRYPT BIT(0) |
#define | FLAGS_CBC BIT(1) |
#define | FLAGS_GIV BIT(2) |
#define | FLAGS_INIT BIT(4) |
#define | FLAGS_FAST BIT(5) |
#define | FLAGS_BUSY BIT(6) |
#define | OMAP_AES_QUEUE_LENGTH 1 |
#define | OMAP_AES_CACHE_SIZE 0 |
Functions | |
module_init (omap_aes_mod_init) | |
module_exit (omap_aes_mod_exit) | |
MODULE_DESCRIPTION ("OMAP AES hw acceleration support.") | |
MODULE_LICENSE ("GPL v2") | |
MODULE_AUTHOR ("Dmitry Kasatkin") | |
#define AES_REG_AUTOIDLE (1 << 0) |
Definition at line 65 of file omap-aes.c.
#define AES_REG_CTRL 0x30 |
Definition at line 43 of file omap-aes.c.
#define AES_REG_CTRL_CBC (1 << 5) |
Definition at line 46 of file omap-aes.c.
#define AES_REG_CTRL_CTR (1 << 6) |
Definition at line 45 of file omap-aes.c.
#define AES_REG_CTRL_CTR_WIDTH (1 << 7) |
Definition at line 44 of file omap-aes.c.
#define AES_REG_CTRL_DIRECTION (1 << 2) |
Definition at line 48 of file omap-aes.c.
#define AES_REG_CTRL_INPUT_READY (1 << 1) |
Definition at line 49 of file omap-aes.c.
#define AES_REG_CTRL_KEY_SIZE (3 << 3) |
Definition at line 47 of file omap-aes.c.
#define AES_REG_CTRL_OUTPUT_READY (1 << 0) |
Definition at line 50 of file omap-aes.c.
#define AES_REG_DATA 0x34 |
Definition at line 52 of file omap-aes.c.
#define AES_REG_DATA_N | ( | x | ) | (0x34 + ((x) * 0x04)) |
Definition at line 53 of file omap-aes.c.
#define AES_REG_IV | ( | x | ) | (0x20 + ((x) * 0x04)) |
Definition at line 41 of file omap-aes.c.
#define AES_REG_KEY | ( | x | ) | (0x1C - ((x ^ 0x01) * 0x04)) |
Definition at line 40 of file omap-aes.c.
#define AES_REG_MASK 0x48 |
Definition at line 59 of file omap-aes.c.
#define AES_REG_MASK_DMA_IN_EN (1 << 2) |
Definition at line 63 of file omap-aes.c.
#define AES_REG_MASK_DMA_OUT_EN (1 << 3) |
Definition at line 62 of file omap-aes.c.
#define AES_REG_MASK_SIDLE (1 << 6) |
Definition at line 60 of file omap-aes.c.
#define AES_REG_MASK_SOFTRESET (1 << 1) |
Definition at line 64 of file omap-aes.c.
#define AES_REG_MASK_START (1 << 5) |
Definition at line 61 of file omap-aes.c.
#define AES_REG_REV 0x44 |
Definition at line 55 of file omap-aes.c.
#define AES_REG_REV_MAJOR 0xF0 |
Definition at line 56 of file omap-aes.c.
#define AES_REG_REV_MINOR 0x0F |
Definition at line 57 of file omap-aes.c.
#define AES_REG_SYSSTATUS 0x4C |
Definition at line 67 of file omap-aes.c.
#define AES_REG_SYSSTATUS_RESETDONE (1 << 0) |
Definition at line 68 of file omap-aes.c.
#define DEFAULT_TIMEOUT (5*HZ) |
Definition at line 70 of file omap-aes.c.
#define FLAGS_BUSY BIT(6) |
Definition at line 79 of file omap-aes.c.
#define FLAGS_CBC BIT(1) |
Definition at line 74 of file omap-aes.c.
#define FLAGS_ENCRYPT BIT(0) |
Definition at line 73 of file omap-aes.c.
#define FLAGS_FAST BIT(5) |
Definition at line 78 of file omap-aes.c.
#define FLAGS_GIV BIT(2) |
Definition at line 75 of file omap-aes.c.
#define FLAGS_INIT BIT(4) |
Definition at line 77 of file omap-aes.c.
#define FLAGS_MODE_MASK 0x000f |
Definition at line 72 of file omap-aes.c.
Definition at line 37 of file omap-aes.c.
Definition at line 38 of file omap-aes.c.
#define OMAP_AES_CACHE_SIZE 0 |
Definition at line 94 of file omap-aes.c.
#define OMAP_AES_QUEUE_LENGTH 1 |
Definition at line 93 of file omap-aes.c.
#define pr_fmt | ( | fmt | ) | "%s: " fmt, __func__ |
Definition at line 15 of file omap-aes.c.
MODULE_AUTHOR | ( | "Dmitry Kasatkin" | ) |
MODULE_DESCRIPTION | ( | "OMAP AES hw acceleration support." | ) |
module_exit | ( | omap_aes_mod_exit | ) |
module_init | ( | omap_aes_mod_init | ) |
MODULE_LICENSE | ( | "GPL v2" | ) |