~ubuntu-branches/ubuntu/trusty/vboot-utils/trusty

« back to all changes in this revision

Viewing changes to firmware/arch/arm/include/biosincludes.h

  • Committer: Package Import Robot
  • Author(s): Antonio Terceiro
  • Date: 2012-12-16 11:03:40 UTC
  • Revision ID: package-import@ubuntu.com-20121216110340-f7wcseecbc9jed5l
Tags: upstream-0~20121212
ImportĀ upstreamĀ versionĀ 0~20121212

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
 
2
 * Use of this source code is governed by a BSD-style license that can be
 
3
 * found in the LICENSE file.
 
4
 *
 
5
 * ARM firmware platform-specific definitions
 
6
 */
 
7
 
 
8
#ifndef __ARCH_ARM_BIOSINCLUDES_H__
 
9
#define __ARCH_ARM_BIOSINCLUDES_H__
 
10
 
 
11
typedef unsigned char uint8_t;
 
12
typedef unsigned short uint16_t;
 
13
typedef unsigned int uint32_t;
 
14
typedef unsigned long long uint64_t;
 
15
typedef signed long long int64_t;
 
16
typedef unsigned int size_t;
 
17
 
 
18
#ifndef NULL
 
19
#define NULL ((void*) 0)
 
20
#endif
 
21
 
 
22
#define UINT32_C(x) ((uint32_t) x)
 
23
#define UINT64_C(x) ((uint64_t) x)
 
24
#define PRIu32 "u"
 
25
#define PRIu64 "llu"
 
26
extern void debug(const char *format, ...);
 
27
 
 
28
#define POSSIBLY_UNUSED __attribute__((unused))
 
29
 
 
30
#ifdef __STRICT_ANSI__
 
31
#define INLINE
 
32
#else
 
33
#define INLINE inline
 
34
#endif
 
35
 
 
36
#define UINT64_RSHIFT(v, shiftby) (((uint64_t)(v)) >> (shiftby))
 
37
#define UINT64_MULT32(v, multby)  (((uint64_t)(v)) * ((uint32_t)(multby)))
 
38
 
 
39
#ifndef UINT32_MAX
 
40
#define UINT32_MAX (UINT32_C(0xffffffffU))
 
41
#endif
 
42
 
 
43
#ifndef UINT64_MAX
 
44
#define UINT64_MAX (UINT64_C(0xffffffffffffffffULL))
 
45
#endif
 
46
 
 
47
/* This workaround applies to Kaen prototypes and is not expected to be needed
 
48
 * in the final products.  See crosbug.com/15759.
 
49
 */
 
50
#define TEGRA_SOFT_REBOOT_WORKAROUND
 
51
 
 
52
#endif /*__ARCH_ARM_BIOSINCLUDES_H__ */