Nico Huber has submitted this change. ( https://review.coreboot.org/c/flashrom/+/57797 )
Change subject: remove compile guards ......................................................................
remove compile guards
The build system handles the decision when to build a file. Extra compile guards for the source files are not necessary.
Change-Id: I76a76e05c7a7dd27637325ab1e9d8946fd5f9076 Signed-off-by: Thomas Heijligen thomas.heijligen@secunet.de Reviewed-on: https://review.coreboot.org/c/flashrom/+/57797 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Felix Singer felixsinger@posteo.net Reviewed-by: Angel Pons th3fanbus@gmail.com Reviewed-by: Nico Huber nico.h@gmx.de --- M amd_imc.c M atahpt.c M atapromise.c M ft2232_spi.c M ichspi.c M it85spi.c M it87spi.c M linux_spi.c M mcp6x_spi.c M mstarddc_spi.c M nic3com.c M nicnatsemi.c M nicrealtek.c M rayer_spi.c M satamv.c M sb600spi.c M usbblaster_spi.c M wbsio_spi.c 18 files changed, 0 insertions(+), 83 deletions(-)
Approvals: build bot (Jenkins): Verified Nico Huber: Looks good to me, approved Felix Singer: Looks good to me, approved Angel Pons: Looks good to me, approved
diff --git a/amd_imc.c b/amd_imc.c index 8b0bcf2..a3959e6 100644 --- a/amd_imc.c +++ b/amd_imc.c @@ -15,8 +15,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include "flash.h" #include "programmer.h" #include "hwaccess.h" @@ -151,5 +149,3 @@
return ret; } - -#endif diff --git a/atahpt.c b/atahpt.c index c627e0b..d9b56bc 100644 --- a/atahpt.c +++ b/atahpt.c @@ -14,8 +14,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <stdlib.h> #include <string.h> #include "flash.h" @@ -97,7 +95,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#else -#error PCI port I/O access is not supported on this architecture yet. -#endif diff --git a/atapromise.c b/atapromise.c index e3009e4..0c187e3 100644 --- a/atapromise.c +++ b/atapromise.c @@ -14,8 +14,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <string.h> #include <stdlib.h> #include "flash.h" @@ -170,7 +168,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#else -#error PCI port I/O access is not supported on this architecture yet. -#endif diff --git a/ft2232_spi.c b/ft2232_spi.c index 15837d9..0962f1c 100644 --- a/ft2232_spi.c +++ b/ft2232_spi.c @@ -14,8 +14,6 @@ * GNU General Public License for more details. */
-#if CONFIG_FT2232_SPI == 1 - #include <stdio.h> #include <strings.h> #include <string.h> @@ -599,4 +597,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; -#endif diff --git a/ichspi.c b/ichspi.c index 091e4e2..d345af2 100644 --- a/ichspi.c +++ b/ichspi.c @@ -19,8 +19,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <string.h> #include <stdlib.h> #include "flash.h" @@ -2113,5 +2111,3 @@
return 0; } - -#endif diff --git a/it85spi.c b/it85spi.c index dd0cb6c..17e4e10 100644 --- a/it85spi.c +++ b/it85spi.c @@ -20,8 +20,6 @@ * Contains the ITE IT85* SPI specific routines */
-#if defined(__i386__) || defined(__x86_64__) - #include <string.h> #include <stdio.h> #include <stdlib.h> @@ -362,5 +360,3 @@ /* Set this as SPI controller. */ return register_spi_master(&spi_master_it85xx, data); } - -#endif diff --git a/it87spi.c b/it87spi.c index 3e422d7..5f6fb65 100644 --- a/it87spi.c +++ b/it87spi.c @@ -19,8 +19,6 @@ * Contains the ITE IT87* SPI specific routines */
-#if defined(__i386__) || defined(__x86_64__) - #include <string.h> #include <stdlib.h> #include <errno.h> @@ -464,5 +462,3 @@ } return ret; } - -#endif /* defined(__i386__) || defined(__x86_64__) */ diff --git a/linux_spi.c b/linux_spi.c index bd9ffb3..27a9a0d 100644 --- a/linux_spi.c +++ b/linux_spi.c @@ -13,8 +13,6 @@ * GNU General Public License for more details. */
-#if CONFIG_LINUX_SPI == 1 - #include <stdio.h> #include <string.h> #include <stdlib.h> @@ -256,5 +254,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#endif // CONFIG_LINUX_SPI == 1 diff --git a/mcp6x_spi.c b/mcp6x_spi.c index fa309ca..29d2663 100644 --- a/mcp6x_spi.c +++ b/mcp6x_spi.c @@ -19,8 +19,6 @@ * created by Michael Karcher. */
-#if defined(__i386__) || defined(__x86_64__) - #include <stdlib.h> #include <ctype.h> #include "flash.h" @@ -192,5 +190,3 @@
return 0; } - -#endif diff --git a/mstarddc_spi.c b/mstarddc_spi.c index 8e2d5a8..71b02c0 100644 --- a/mstarddc_spi.c +++ b/mstarddc_spi.c @@ -13,8 +13,6 @@ * GNU General Public License for more details. */
-#if CONFIG_MSTARDDC_SPI == 1 - #include <stdio.h> #include <string.h> #include <stdlib.h> @@ -259,5 +257,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#endif diff --git a/nic3com.c b/nic3com.c index 2af0a52..79964ac 100644 --- a/nic3com.c +++ b/nic3com.c @@ -14,8 +14,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <stdlib.h> #include "flash.h" #include "programmer.h" @@ -173,7 +171,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#else -#error PCI port I/O access is not supported on this architecture yet. -#endif diff --git a/nicnatsemi.c b/nicnatsemi.c index b2f381a..6216728 100644 --- a/nicnatsemi.c +++ b/nicnatsemi.c @@ -14,8 +14,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <stdlib.h> #include "flash.h" #include "programmer.h" @@ -110,7 +108,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#else -#error PCI port I/O access is not supported on this architecture yet. -#endif diff --git a/nicrealtek.c b/nicrealtek.c index ec821b4..70daeec 100644 --- a/nicrealtek.c +++ b/nicrealtek.c @@ -14,8 +14,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <stdlib.h> #include "flash.h" #include "programmer.h" @@ -151,7 +149,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#else -#error PCI port I/O access is not supported on this architecture yet. -#endif diff --git a/rayer_spi.c b/rayer_spi.c index 1102ff1..e65eb78 100644 --- a/rayer_spi.c +++ b/rayer_spi.c @@ -22,7 +22,6 @@ * most OS parport drivers will perform many unnecessary accesses although * this driver just treats the parallel port as a GPIO set. */ -#if defined(__i386__) || defined(__x86_64__)
#include <stdlib.h> #include <strings.h> @@ -334,7 +333,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#else -#error PCI port I/O access is not supported on this architecture yet. -#endif diff --git a/satamv.c b/satamv.c index 32ac11a..cdd2f27 100644 --- a/satamv.c +++ b/satamv.c @@ -15,7 +15,6 @@ */
/* Datasheets are not public (yet?) */ -#if defined(__i386__) || defined(__x86_64__)
#include <stdlib.h> #include "flash.h" @@ -191,7 +190,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#else -#error PCI port I/O access is not supported on this architecture yet. -#endif diff --git a/sb600spi.c b/sb600spi.c index fe7920f..7fa01af 100644 --- a/sb600spi.c +++ b/sb600spi.c @@ -18,8 +18,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <string.h> #include <stdlib.h> #include "flash.h" @@ -799,5 +797,3 @@
return 0; } - -#endif diff --git a/usbblaster_spi.c b/usbblaster_spi.c index bd4b1c9..8957df8 100644 --- a/usbblaster_spi.c +++ b/usbblaster_spi.c @@ -30,8 +30,6 @@ * See also the USB-Blaster Download Cable User Guide: http://www.altera.com/literature/ug/ug_usb_blstr.pdf */
-#if CONFIG_USBBLASTER_SPI == 1 - #include <stdio.h> #include <string.h> #include <stdlib.h> @@ -237,5 +235,3 @@ .unmap_flash_region = fallback_unmap, .delay = internal_delay, }; - -#endif diff --git a/wbsio_spi.c b/wbsio_spi.c index a175b21..60b725f 100644 --- a/wbsio_spi.c +++ b/wbsio_spi.c @@ -14,8 +14,6 @@ * GNU General Public License for more details. */
-#if defined(__i386__) || defined(__x86_64__) - #include <stdlib.h>
#include "flash.h" @@ -217,5 +215,3 @@
return register_spi_master(&spi_master_wbsio, data); } - -#endif /* defined(__i386__) || defined(__x86_64__) */