mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 00:03:54 -06:00
rng: move request queue from RngEgd to RngBackend
The 'requests' field now lives in the RngBackend parent class. There are no functional changes in this commit. Signed-off-by: Ladi Prosek <lprosek@redhat.com> Reviewed-by: Amit Shah <amit.shah@redhat.com> Message-Id: <1456994238-9585-3-git-send-email-lprosek@redhat.com> Signed-off-by: Amit Shah <amit.shah@redhat.com>
This commit is contained in:
parent
3c52ddcdc5
commit
74074e8a7c
2 changed files with 20 additions and 19 deletions
|
@ -24,6 +24,7 @@
|
|||
#define RNG_BACKEND_CLASS(klass) \
|
||||
OBJECT_CLASS_CHECK(RngBackendClass, (klass), TYPE_RNG_BACKEND)
|
||||
|
||||
typedef struct RngRequest RngRequest;
|
||||
typedef struct RngBackendClass RngBackendClass;
|
||||
typedef struct RngBackend RngBackend;
|
||||
|
||||
|
@ -31,6 +32,15 @@ typedef void (EntropyReceiveFunc)(void *opaque,
|
|||
const void *data,
|
||||
size_t size);
|
||||
|
||||
struct RngRequest
|
||||
{
|
||||
EntropyReceiveFunc *receive_entropy;
|
||||
uint8_t *data;
|
||||
void *opaque;
|
||||
size_t offset;
|
||||
size_t size;
|
||||
};
|
||||
|
||||
struct RngBackendClass
|
||||
{
|
||||
ObjectClass parent_class;
|
||||
|
@ -47,6 +57,7 @@ struct RngBackend
|
|||
|
||||
/*< protected >*/
|
||||
bool opened;
|
||||
GSList *requests;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue