Nico Huber has uploaded this change for review. ( https://review.coreboot.org/c/flashrom/+/33297
Change subject: libflashrom: Add CPP guard to fix big-endian builds ......................................................................
libflashrom: Add CPP guard to fix big-endian builds
It's ugly but gets the job done. We should forbid endian-specific code in the future, I guess.
Change-Id: Id3f4a57e027f88cc469ed50312adddcc8af71a63 Signed-off-by: Nico Huber nico.h@gmx.de --- M libflashrom.c 1 file changed, 2 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/97/33297/1
diff --git a/libflashrom.c b/libflashrom.c index f90a22c..c327c62 100644 --- a/libflashrom.c +++ b/libflashrom.c @@ -383,6 +383,7 @@ #endif }
+#ifdef __FLASHROM_LITTLE_ENDIAN__ static int flashrom_layout_parse_fmap(struct flashrom_layout **layout, struct flashctx *const flashctx, const struct fmap *const fmap) { @@ -414,6 +415,7 @@ *layout = l; return 0; } +#endif /* __FLASHROM_LITTLE_ENDIAN__ */
/** * @brief Read a layout by searching the flash chip for fmap.
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/33297 )
Change subject: libflashrom: Add CPP guard to fix big-endian builds ......................................................................
Patch Set 1: Code-Review+2
Hello Patrick Rudolph, Angel Pons, Arthur Heymans, Thomas Heijligen, David Hendricks, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/flashrom/+/33297
to look at the new patch set (#2).
Change subject: libflashrom: Add CPP guard to fix big-endian builds ......................................................................
libflashrom: Add CPP guard to fix big-endian builds
Calm a compiler warning on big-endian builds about the unused static flashrom_layout_parse_fmap(). The guard is ugly but gets the job done. We should forbid endian-specific code in the future, I guess.
Change-Id: Id3f4a57e027f88cc469ed50312adddcc8af71a63 Signed-off-by: Nico Huber nico.h@gmx.de --- M libflashrom.c 1 file changed, 2 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/97/33297/2
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/33297 )
Change subject: libflashrom: Add CPP guard to fix big-endian builds ......................................................................
Patch Set 2: Verified+1
Nico Huber has submitted this change and it was merged. ( https://review.coreboot.org/c/flashrom/+/33297 )
Change subject: libflashrom: Add CPP guard to fix big-endian builds ......................................................................
libflashrom: Add CPP guard to fix big-endian builds
Calm a compiler warning on big-endian builds about the unused static flashrom_layout_parse_fmap(). The guard is ugly but gets the job done. We should forbid endian-specific code in the future, I guess.
Change-Id: Id3f4a57e027f88cc469ed50312adddcc8af71a63 Signed-off-by: Nico Huber nico.h@gmx.de Reviewed-on: https://review.coreboot.org/c/flashrom/+/33297 Reviewed-by: Angel Pons th3fanbus@gmail.com --- M libflashrom.c 1 file changed, 2 insertions(+), 0 deletions(-)
Approvals: Nico Huber: Verified Angel Pons: Looks good to me, approved
diff --git a/libflashrom.c b/libflashrom.c index f90a22c..c327c62 100644 --- a/libflashrom.c +++ b/libflashrom.c @@ -383,6 +383,7 @@ #endif }
+#ifdef __FLASHROM_LITTLE_ENDIAN__ static int flashrom_layout_parse_fmap(struct flashrom_layout **layout, struct flashctx *const flashctx, const struct fmap *const fmap) { @@ -414,6 +415,7 @@ *layout = l; return 0; } +#endif /* __FLASHROM_LITTLE_ENDIAN__ */
/** * @brief Read a layout by searching the flash chip for fmap.