[CRIU] [PATCH v2 07/15] sk-queue: Allow to dump a skb sender

Kirill Tkhai ktkhai at virtuozzo.com
Mon May 30 05:36:06 PDT 2016



On 30.05.2016 14:45, Pavel Emelyanov wrote:
> On 05/27/2016 04:06 PM, Kirill Tkhai wrote:
>> Add a possibility to dump a packet sender using a method get_sender,
>> passed by caller.
>>
>> If there is the only sender of all pending socket's packets, its inode
>> is returned as result in (*sender_ino). Otherwise, 0 is there (inode 0
>> can't exist in real world).
> 
> And what does this set do in case of a socket with several senders in queue?

If there are several senders in queue, get_sender method return 0,
so we dump this socket as has_sender_ino == false, and use this information
on restore.
 
>> @@ -52,6 +52,8 @@
>>  #define USK_SERVICE	(1 << 1)
>>  #define USK_CALLBACK	(1 << 2)
>>  #define USK_INHERIT	(1 << 3)
>> +#define USK_EMPTY_Q	(1 << 4)
> 
> Why is this bit needed?

Empty queue is one of likely cases. This just should speed-up restore stage.
 
>> +#define USK_NONAME_SND	(1 << 5)
>>  
>>  typedef struct {
>>  	char			*dir;
> 


More information about the CRIU mailing list