mirror of
https://passt.top/passt
synced 2025-06-10 09:35:34 +02:00
Add interfaces and configuration bits for passt-repair
In vhost-user mode, by default, create a second UNIX domain socket accepting connections from passt-repair, with the usual listener socket. When we need to set or clear TCP_REPAIR on sockets, we'll send them via SCM_RIGHTS to passt-repair, who sets the socket option values we ask for. To that end, introduce batched functions to request TCP_REPAIR settings on sockets, so that we don't have to send a single message for each socket, on migration. When needed, repair_flush() will send the message and check for the reply. Co-authored-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:
parent
155cd0c41e
commit
b899141ad5
12 changed files with 381 additions and 73 deletions
|
@ -23,6 +23,7 @@
|
|||
#include "flow_table.h"
|
||||
|
||||
#include "migrate.h"
|
||||
#include "repair.h"
|
||||
|
||||
/* Magic identifier for migration data */
|
||||
#define MIGRATE_MAGIC 0xB1BB1D1B0BB1D1B0
|
||||
|
@ -232,7 +233,7 @@ void migrate_init(struct ctx *c)
|
|||
}
|
||||
|
||||
/**
|
||||
* migrate_close() - Close migration channel
|
||||
* migrate_close() - Close migration channel and connection to passt-repair
|
||||
* @c: Execution context
|
||||
*/
|
||||
void migrate_close(struct ctx *c)
|
||||
|
@ -243,6 +244,8 @@ void migrate_close(struct ctx *c)
|
|||
c->device_state_fd = -1;
|
||||
c->device_state_result = -1;
|
||||
}
|
||||
|
||||
repair_close(c);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue