summaryrefslogtreecommitdiffstats
path: root/ich_descriptors.h
diff options
context:
space:
mode:
authorNico Huber <nico.huber@secunet.com>2016-05-02 15:15:29 +0200
committerNico Huber <nico.h@gmx.de>2017-06-14 11:32:36 +0200
commitad18631b59d814b38bb6757df93fac17937a6bc9 (patch)
tree64a5fde5ab5bc0432fa74e3c263291e931330e3e /ich_descriptors.h
parent3828b39263d008fb6cc5ebdbe7fb49bc6f926566 (diff)
downloadflashrom-ad18631b59d814b38bb6757df93fac17937a6bc9.tar.gz
flashrom-ad18631b59d814b38bb6757df93fac17937a6bc9.tar.bz2
flashrom-ad18631b59d814b38bb6757df93fac17937a6bc9.zip
Make read_ich_descriptors_from_dump() available in flashrom
I didn't really know what I was doing and hope removing the #ifdefs doesn't have negative side effects. The idea is to make the functions generally available for external flashing (e.g. you might want to flash an Intel machine using an ARM device as programmer). Beware of big endian trouble, I guess. :-P Change-Id: Ib3d38a622a581afee87b49777e775942cc901fc8 Signed-off-by: Nico Huber <nico.huber@secunet.com> Reviewed-on: https://review.coreboot.org/17952 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'ich_descriptors.h')
-rw-r--r--ich_descriptors.h11
1 files changed, 0 insertions, 11 deletions
diff --git a/ich_descriptors.h b/ich_descriptors.h
index 2c21598f5..e355e54d8 100644
--- a/ich_descriptors.h
+++ b/ich_descriptors.h
@@ -19,7 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#if defined(__i386__) || defined(__x86_64__)
#ifndef __ICH_DESCRIPTORS_H__
#define __ICH_DESCRIPTORS_H__ 1
@@ -250,7 +249,6 @@ struct ich_desc_master {
};
};
-#ifdef ICH_DESCRIPTORS_FROM_DUMP
struct ich_desc_north_strap {
union {
uint32_t STRPs[1]; /* current maximum: ich8 */
@@ -561,18 +559,15 @@ struct ich_desc_upper_map {
};
} vscc_table[128];
};
-#endif /* ICH_DESCRIPTORS_FROM_DUMP */
struct ich_descriptors {
struct ich_desc_content content;
struct ich_desc_component component;
struct ich_desc_region region;
struct ich_desc_master master;
-#ifdef ICH_DESCRIPTORS_FROM_DUMP
struct ich_desc_north_strap north;
struct ich_desc_south_strap south;
struct ich_desc_upper_map upper;
-#endif /* ICH_DESCRIPTORS_FROM_DUMP */
};
void prettyprint_ich_descriptors(enum ich_chipset cs, const struct ich_descriptors *desc);
@@ -582,17 +577,11 @@ void prettyprint_ich_descriptor_component(enum ich_chipset cs, const struct ich_
void prettyprint_ich_descriptor_region(const struct ich_descriptors *desc);
void prettyprint_ich_descriptor_master(const struct ich_desc_master *master);
-#ifdef ICH_DESCRIPTORS_FROM_DUMP
-
void prettyprint_ich_descriptor_upper_map(const struct ich_desc_upper_map *umap);
void prettyprint_ich_descriptor_straps(enum ich_chipset cs, const struct ich_descriptors *desc);
int read_ich_descriptors_from_dump(const uint32_t *dump, unsigned int len, struct ich_descriptors *desc);
-#else /* ICH_DESCRIPTORS_FROM_DUMP */
-
int read_ich_descriptors_via_fdo(void *spibar, struct ich_descriptors *desc);
int getFCBA_component_density(enum ich_chipset cs, const struct ich_descriptors *desc, uint8_t idx);
-#endif /* ICH_DESCRIPTORS_FROM_DUMP */
#endif /* __ICH_DESCRIPTORS_H__ */
-#endif /* defined(__i386__) || defined(__x86_64__) */