BACKPORT: tests: Add and include headers with function prototypes

Part 2 of fixing -Wmissing-prototypes warnings. This patch adds
headers with function prototypes and includes the headers into
source files. This fixes the warnings like this:

warning: no previous prototype for ‘function_name’
[-Wmissing-prototypes]

This patch is needed to sync compiler warning options between meson
and makefile.

BUG=none
BRANCH=none
TEST=running the following produces no warnings:
meson setup --wipe (to clean build directory)
ninja test

Original-Change-Id: Ia1ff22deb2354569f277649c6575ef2d5ffbb6e0
Original-Signed-off-by: Anastasia Klimchuk <aklm@chromium.org>
Original-Reviewed-on: https://review.coreboot.org/c/flashrom/+/63489
Original-Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Original-Reviewed-by: Thomas Heijligen <src@posteo.de>
Original-Reviewed-by: Felix Singer <felixsinger@posteo.net>
Original-Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
(cherry picked from commit c4784f1a9a491eab118bbec81808e2de1dec187f)

Change-Id: I139426ea8455fe508beddc7ccfda460497782d05
Signed-off-by: Edward O'Callaghan <quasisec@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/flashrom/+/3631547
Commit-Queue: Edward O'Callaghan <quasisec@chromium.org>
Reviewed-by: Nikolai Artemiev <nartemiev@google.com>
Tested-by: Edward O'Callaghan <quasisec@chromium.org>
10 files changed
tree: 77f413351941105dfefd56724ac090524368f538
  1. .github/
  2. Documentation/
  3. include/
  4. Makefile.d/
  5. platform/
  6. subprojects/
  7. tests/
  8. util/
  9. .gitattributes
  10. .gitignore
  11. 82802ab.c
  12. action_descriptor.c
  13. action_descriptor.h
  14. amd_imc.c
  15. at45db.c
  16. atahpt.c
  17. atapromise.c
  18. atavia.c
  19. big_lock.c
  20. big_lock.h
  21. bitbang_spi.c
  22. board_enable.c
  23. buspirate_spi.c
  24. cbtable.c
  25. ch341a_spi.c
  26. chipset_enable.c
  27. cli_classic.c
  28. cli_common.c
  29. cli_output.c
  30. COPYING
  31. cros_alias.c
  32. cros_ec.c
  33. cros_ec.h
  34. cros_ec_commands.h
  35. cros_ec_dev.c
  36. custom_baud.c
  37. custom_baud_linux.c
  38. dediprog.c
  39. dep_wp_statusreg.c
  40. dep_writeprotect.c
  41. dep_writeprotect.h
  42. developerbox_spi.c
  43. digilent_spi.c
  44. dmi.c
  45. drkaiser.c
  46. dummyflasher.c
  47. edi.c
  48. en29lv640b.c
  49. file_lock.c
  50. flashchips.c
  51. flashchips_crosbl.c
  52. flashrom.8.tmpl
  53. flashrom.c
  54. fmap.c
  55. ft2232_spi.c
  56. gfxnvidia.c
  57. helpers.c
  58. hwaccess_physmap.c
  59. hwaccess_x86_io.c
  60. hwaccess_x86_msr.c
  61. i2c_helper_linux.c
  62. ich_descriptors.c
  63. ichspi.c
  64. internal.c
  65. ipc_lock.h
  66. it8212.c
  67. it85spi.c
  68. it87spi.c
  69. jedec.c
  70. jlink_spi.c
  71. layout.c
  72. libflashrom.c
  73. libflashrom.map
  74. linux_mtd.c
  75. linux_spi.c
  76. lspcon_i2c_spi.c
  77. Makefile
  78. Makefile.include
  79. mcp6x_spi.c
  80. mediatek_i2c_spi.c
  81. meson.build
  82. meson_options.txt
  83. mstarddc_spi.c
  84. ni845x_spi.c
  85. nic3com.c
  86. nicintel.c
  87. nicintel_eeprom.c
  88. nicintel_spi.c
  89. nicnatsemi.c
  90. nicrealtek.c
  91. ogp_spi.c
  92. opaque.c
  93. OWNERS
  94. pcidev.c
  95. pickit2_spi.c
  96. pony_spi.c
  97. power.c
  98. power.h
  99. PRESUBMIT.cfg
  100. print.c
  101. print_wiki.c
  102. processor_enable.c
  103. programmer.c
  104. programmer_table.c
  105. raiden_debug_spi.c
  106. rayer_spi.c
  107. README
  108. README.chromiumos
  109. realtek_mst_i2c_spi.c
  110. s25f.c
  111. satamv.c
  112. satasii.c
  113. sb600spi.c
  114. serial.c
  115. serprog.c
  116. sfdp.c
  117. spi.c
  118. spi25.c
  119. spi25_statusreg.c
  120. spi95.c
  121. sst28sf040.c
  122. sst49lfxxxc.c
  123. sst_fwhub.c
  124. stlinkv3_spi.c
  125. stm50.c
  126. udelay.c
  127. usb_device.c
  128. usbblaster_spi.c
  129. usbdev.c
  130. w29ee011.c
  131. w39.c
  132. wbsio_spi.c
  133. writeprotect.c
  134. writeprotect_ranges.c