Stefan Hajnoczi e2336043cc loader: add rom transaction API
Image file loaders may add a series of roms.  If an error occurs partway
through loading there is no easy way to drop previously added roms.

This patch adds a transaction mechanism that works like this:

  rom_transaction_begin();
  ...call rom_add_*()...
  rom_transaction_end(ok);

If ok is false then roms added in this transaction are dropped.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-id: 20180814162739.11814-5-stefanha@redhat.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-08-16 14:05:28 +01:00
..
2018-07-24 17:02:02 +01:00
2018-07-17 17:06:32 +01:00
2018-08-16 14:05:28 +01:00
2018-07-02 19:07:19 +01:00
2018-07-20 08:30:48 +08:00
2016-01-29 15:07:25 +00:00
2018-07-30 17:41:52 +02:00
2018-07-02 19:07:19 +01:00
2018-07-02 19:07:19 +01:00
2018-06-01 15:14:31 +02:00