blob: 2da0232a20899d5b79f0919d2d9186f6d61a6914 [file] [log] [blame]
Kaushal Kumarf3b1a192012-07-03 19:48:41 +05301/*
2 * Copyright (c) 2012, Code Aurora Forum. All rights reserved.
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 and
6 * only version 2 as published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 */
14
15#ifndef __ARCH_ARM_MACH_MSM_SMEM_IFACE_H
16#define __ARCH_ARM_MACH_MSM_SMEM_IFACE_H
17
18#include <mach/msm_smsm.h>
19#include "smd_private.h"
20
21#define MAX_KEY_EVENTS 10
22#define MAX_SEC_KEY_PAYLOAD 32
23
24struct boot_shared_ssd_status_info {
25 uint32_t update_status; /* To check if process is successful or not */
26 uint32_t bl_error_code; /* To indicate error code in bootloader */
27};
28
29struct boot_symmetric_key_info {
30 uint32_t key_len; /* Encrypted Symmetric Key Length */
31 uint32_t iv_len; /* Initialization Vector Length */
32 uint8_t key[MAX_SEC_KEY_PAYLOAD]; /* Encrypted Symmetric Key */
33 uint8_t iv[MAX_SEC_KEY_PAYLOAD]; /* Initialization Vector */
34};
35
36struct cpr_info_type {
37 uint8_t ring_osc; /* CPR FUSE [0]: TURBO RO SEL BIT */
38 uint8_t turbo_quot; /* CPRFUSE[1:7] : TURBO QUOT*/
39 uint8_t pvs_fuse; /* TURBO PVS FUSE */
40};
41
42struct boot_info_for_apps {
43 uint32_t apps_image_start_addr; /* apps image start address */
44 uint32_t boot_flags; /* bit mask of upto 32 flags */
45 struct boot_shared_ssd_status_info ssd_status_info; /* SSD status */
46 struct boot_symmetric_key_info key_info;
47 uint16_t boot_keys_pressed[MAX_KEY_EVENTS]; /* Log of key presses */
48 uint32_t timetick; /* Modem tick timer value before apps out of reset */
49 struct cpr_info_type cpr_info;
50 uint8_t PAD[25];
51};
52
53void msm_smem_get_cpr_info(struct cpr_info_type *cpr_info);
54
55#endif /* __ARCH_ARM_MACH_MSM_SMEM_IFACE_H */