blob: 7c1ed8e35a3f6e3acedf9ae185802eb64dc5a71d [file] [log] [blame]
Simon Glassc53fc492013-02-10 17:00:38 -08001/*
2 * This file is part of the flashrom project.
3 *
4 * Copyright (C) 2013 Google Inc.
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 */
19
20#ifndef FLASHMAP_LIB_LAYOUT_H__
21#define FLASHMAP_LIB_LAYOUT_H__
22
23typedef struct romlayout {
24 unsigned int start;
25 unsigned int end;
26 unsigned int included;
27 char name[256];
28 char file[256]; /* file[0]=='\0' means not specified. */
29} romlayout_t;
30
Simon Glass9ad06c12013-07-03 22:08:17 +090031/**
32 * Extract regions to current directory
33 *
34 * @flash: Information about flash chip to access
35 * @return 0 if OK, non-zero on error
36 */
Souvik Ghoshd75cd672016-06-17 14:21:39 -070037int extract_regions(struct flashctx *flash);
Simon Glass9ad06c12013-07-03 22:08:17 +090038
David Hendricksc36685a2016-09-12 20:41:05 -070039int fill_romentry(romlayout_t *entry, int n);
40
Simon Glassc53fc492013-02-10 17:00:38 -080041#endif