summaryrefslogtreecommitdiffstats
path: root/test/Makefile.am.include
Commit message (Collapse)AuthorAgeFilesLines
* mboxd: Add backend DBus interface and commandline optionsAndrew Jeffery2019-03-191-1/+1
| | | | | | | | | | | | Also implement a backend commandline option to mboxctl: `mboxctl --backend ...`, to allow easy run-time switching of the backend from the commandline. Switching between VPNOR and file backends via mboxctl was tested on Witherspoon, and MTD and file backends on Romulus. Change-Id: Iaf0e27ecf1d5cdd9e3a31729fb179096bbc37408 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* mboxd: Add a backend abstraction layer to mboxd.Evan Lojewski2019-03-181-6/+13
| | | | | | | | | | | | | | | | | | | | | | Introduce a backend abstraction, enabling multiple implementations to be compiled in at once. This change formally abstracts the two existing backends, mtd and vpnor. With the backend abstraction in place, subsequent backends are easier to implement. This change is based of Evan's work and he retains authorship credit. I (AJ) have reworked the patch to pass the vpnor tests, refactored some parts to enable broader use of const structures and others to clarify the initialisation sequences. Due to the existing lack of abstraction the patch has unfortunately wide-ranging impacts. I've whittled it down as much as I consider reasonable. Change-Id: I29984a36dae4ea86ec00b853d2a756f0b9afb3ec Signed-off-by: Evan Lojewski <github@meklort.com> Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* flash: Introduce flash_validate()Andrew Jeffery2019-03-181-2/+1
| | | | | | | | | | Clean up the protocol_negotiate_version() mess. The existing approach came about due to viewing the vpnor implementation as an edge case in its own right. The code becomes much neater if we consider all backends as equal and afford them the callbacks necessary for correct behaviour. Change-Id: Ifaeee9da459818cf22b2f137ddc5b8d0356b9be9 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* test/flash_copy: Configure MTD device to avoid undefined behaviourAndrew Jeffery2019-03-151-1/+2
| | | | | | | | Otherwise we observe invalid memory accesses due to uninitialised variables. Change-Id: I8b9063ccc9a25b225a562ebe120f2a99a28788ca Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* test: Add windows_equally_evictableAndrew Jeffery2018-09-141-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tests for the condition where the minimum age is less than any window's current age, in which case we can get a NULL dereference if the windows_reset_all() implementation is broken. windows.c:409:23: runtime error: member access within null pointer of type 'struct window_context' ASAN:DEADLYSIGNAL ================================================================= ==31400==ERROR: AddressSanitizer: SEGV on unknown address 0x00000004 (pc 0x0002b658 bp 0x74c00270 sp 0x7eb7c678 T0) ==31400==The signal is caused by a WRITE memory access. ==31400==Hint: address points to the zero page. #0 0x2b657 in window_reset windows.c:410 #1 0x2cc9b in windows_create_map windows.c:572 #2 0x1f3f3 in protocol_v1_create_window protocol.c:167 #3 0x2121b in protocol_v2_create_window protocol.c:417 #4 0x24cd7f in generic_vpnor_create_window vpnor/protocol.cpp:51 #5 0x24d053 in protocol_v2_vpnor_create_window vpnor/protocol.cpp:63 #6 0x2663b in mbox_handle_create_window transport_mbox.c:282 #7 0x276db in handle_mbox_req transport_mbox.c:568 #8 0x276db in transport_mbox_dispatch transport_mbox.c:649 #9 0x17fcb in poll_loop mboxd.c:185 #10 0x17fcb in main mboxd.c:423 #11 0x46b68517 in __libc_start_main (/lib/libc.so.6+0x46b68517) AddressSanitizer can not provide additional info. SUMMARY: AddressSanitizer: SEGV windows.c:410 in window_reset ==31400==ABORTING Change-Id: I8161e2ea17953e196d4bb3ca90d19e44ec10c86d Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* vpnor: Hijack protocol rather than transportAndrew Jeffery2018-09-121-1/+2
| | | | | | | | | | | | By hijacking the transport the changes in behaviour were limited to the mailbox interface. Now that we have a DBus interface as well this would lead to inconsistent behaviour dependent on the transport. Instead of hooking the transport, push the hook down to the protocol level where we will achieve consistent behaviour across all transports. Change-Id: I437866a6dbda107149336c15a00ee1aa058f5875 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* protocol: Add get_infoAndrew Jeffery2018-09-121-1/+2
| | | | | Change-Id: Ie3338714813bb65f5d37fcd046dd5bebc0ba21f0 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* mboxd: Rename mboxd_msg to transport_mboxAndrew Jeffery2018-09-121-1/+1
| | | | | Change-Id: I0f4e206648c02a98fa938a7e582470c8d90904f1 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* mboxd: Rename windows filesAndrew Jeffery2018-09-051-1/+1
| | | | | Change-Id: I44e110906fd0f751f8f34b175f971e65896a7301 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* mboxd: Rename lpc source filesAndrew Jeffery2018-09-051-2/+2
| | | | | Change-Id: I289618c90b2df8911e362397b7eab99403c86c05 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* flash: Rename write_flash to flash_writeAndrew Jeffery2018-09-051-3/+3
| | | | | Change-Id: I4b41aac597299c93369d8998b03a7d3e2a128742 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* flash: Rename erase_flash to flash_eraseAndrew Jeffery2018-09-051-3/+3
| | | | | Change-Id: I417319aadb2fdbfa2d688bb26b5515d2f9265994 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* flash: Rename copy_flash to flash_copyAndrew Jeffery2018-09-051-3/+3
| | | | | Change-Id: If449889fca3370e25a65719d2f5c5ec90258d633 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* mboxd: Rename flash filesAndrew Jeffery2018-09-051-4/+4
| | | | | Change-Id: Icfe9d61775a198c5a0f8227bf5d6c4b7f11aeec3 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* tests: Ensure we don't disable assertsAndrew Jeffery2018-08-021-5/+0
| | | | | Change-Id: Ieede7bc3c7b9d7dadc48a41b54dbe6c2b474c555 Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* vpnor: Isolate relevant code in vpnor directoryAndrew Jeffery2018-04-041-5/+5
| | | | | | | | | | | | This is prepatory work for introducing more vpnor-specific behaviours to window handling. We will be introducing more objects to link, in order to hook some of the window command handlers. This change takes the opportunity to revert back to the upstream names for some of the original C files. Change-Id: I6b67ae466a2695054035e65ba752881be9c32d1a Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* test: Move related tests to vpnor directoryAndrew Jeffery2018-03-241-73/+27
| | | | | Change-Id: I5fe7f625ad642cef17fe53bd244dcde8fd99f3ad Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
* test: Move tests to a separate Makefile fragmentAndrew Jeffery2018-03-241-0/+178
Change-Id: I46d5b165ed668ace67ae237b16d65a24586dd87d Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
OpenPOWER on IntegriCloud