1/********************************************************************************
2Copyright (C) 2016 Marvell International Ltd.
3
4Marvell BSD License Option
5
6If you received this File from Marvell, you may opt to use, redistribute and/or
7modify this File under the following licensing terms.
8Redistribution and use in source and binary forms, with or without modification,
9are permitted provided that the following conditions are met:
10
11* Redistributions of source code must retain the above copyright notice,
12  this list of conditions and the following disclaimer.
13
14* Redistributions in binary form must reproduce the above copyright
15  notice, this list of conditions and the following disclaimer in the
16  documentation and/or other materials provided with the distribution.
17
18* Neither the name of Marvell nor the names of its contributors may be
19  used to endorse or promote products derived from this software without
20  specific prior written permission.
21
22THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
23ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
24WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
25DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
26ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
27(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
28LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
29ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
31SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32
33*******************************************************************************/
34
35#ifndef __MARVELL_EEPROM_H__
36#define __MARVELL_EEPROM_H__
37
38#define MARVELL_EEPROM_PROTOCOL_GUID { 0x71954bda, 0x60d3, 0x4ef8, { 0x8e, 0x3c, 0x0e, 0x33, 0x9f, 0x3b, 0xc2, 0x2b }}
39
40typedef struct _MARVELL_EEPROM_PROTOCOL MARVELL_EEPROM_PROTOCOL;
41
42#define EEPROM_READ   0x1
43#define EEPROM_WRITE  0x0
44typedef
45EFI_STATUS
46(EFIAPI *EFI_EEPROM_TRANSFER) (
47  IN CONST MARVELL_EEPROM_PROTOCOL *This,
48  IN UINT16 Address,
49  IN UINT32 Length,
50  IN UINT8 *Buffer,
51  IN UINT8 Operation
52  );
53
54struct _MARVELL_EEPROM_PROTOCOL {
55  EFI_EEPROM_TRANSFER Transfer;
56  UINT32 Identifier;
57};
58
59extern EFI_GUID gMarvellEepromProtocolGuid;
60#endif
61