summaryrefslogtreecommitdiffstats
path: root/tests/libusb_wraps.h
Commit message (Collapse)AuthorAgeFilesLines
* tests: add more wrappers for libusb funcsAlexander Goncharov2022-11-291-0/+9
| | | | | | | | | | | The patch adds wrappers for libusb functions that are used in the ch341a programmer and have not yet been introduced. Change-Id: Ic11efb9fd746cb91911dbe87e1c0028759f5bb0b Signed-off-by: Alexander Goncharov <chat@joursoir.net> Reviewed-on: https://review.coreboot.org/c/flashrom/+/69872 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Anastasia Klimchuk <aklm@chromium.org>
* tests: Add wrappers for libusb_(attach|detach)_kernel_driverThomas Heijligen2022-09-071-0/+2
| | | | | | | | | Change-Id: Ia463824a209db65e82ccfbf320368b2ce82eb36f Signed-off-by: Thomas Heijligen <thomas.heijligen@secunet.com> Reviewed-on: https://review.coreboot.org/c/flashrom/+/67079 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: Edward O'Callaghan <quasisec@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
* tests: Make libusb conditional dependency for unit testsAnastasia Klimchuk2022-07-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Unit tests had an unconditional dependency on libusb and this was a) strictly speaking not needed, b) blocking one build system effort. This patch is a temporary solution to unblock one build system effort, specifically CB:63724. It creates a condition so that libusb is only included when it is required, not always. This workaround is based on the fact that at the moment only 2 lifecycle unit tests are using libusb symbols: dediprog and raiden_debug. BUG=b:237606255 TEST=the following scenarios run tests successfully 1) dediprog and raiden_debug programmers enabled, libusb.h present result: all test run and pass 2) dediprog disabled, libusb.h present result: dediprog test skipped, all other tests run and pass 3) dediprog and raiden_debug both disabled, libusb.h changed to libusbabcd.h result: dediprog and raiden_debug tests are skipped, all other tests run and pass Change-Id: Iec8a1826951fd6ae586e90fde1a55170e7de41a8 Signed-off-by: Anastasia Klimchuk <aklm@chromium.org> Reviewed-on: https://review.coreboot.org/c/flashrom/+/65627 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Felix Singer <felixsinger@posteo.net> Reviewed-by: Thomas Heijligen <src@posteo.de>
* tests: Add and include headers with function prototypesAnastasia Klimchuk2022-04-291-0/+46
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. TEST=running the following produces no warnings: meson setup --wipe (to clean build directory) ninja test Change-Id: Ia1ff22deb2354569f277649c6575ef2d5ffbb6e0 Signed-off-by: Anastasia Klimchuk <aklm@chromium.org> Reviewed-on: https://review.coreboot.org/c/flashrom/+/63489 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Thomas Heijligen <src@posteo.de> Reviewed-by: Felix Singer <felixsinger@posteo.net> Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>