Commit 8e90d90 1 parent ac42e08 commit 8e90d90 Copy full SHA for 8e90d90
File tree 2 files changed +4
-4
lines changed
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -534,7 +534,7 @@ def serialize(self) -> bytes:
534
534
('devclass' , self .devclass )))
535
535
536
536
properties += b' ' + DeviceSerializer .pack_property (
537
- 'backend_domain' , self .backend_domain . name )
537
+ 'backend_domain' , self .backend_name )
538
538
539
539
return properties
540
540
@@ -1252,12 +1252,12 @@ def _deserialize(
1252
1252
return cls (** properties )
1253
1253
1254
1254
def matches (self , device : VirtualDevice ) -> bool :
1255
+ if self .devclass != device .devclass :
1256
+ return False
1255
1257
if self .backend_domain != '*' and self .backend_domain != device .backend_domain :
1256
1258
return False
1257
1259
if self .port_id != '*' and self .port_id != device .port_id :
1258
1260
return False
1259
- if self .devclass != '*' and self .devclass != device .devclass :
1260
- return False
1261
1261
if self .device_id != '*' and self .device_id != device .device_id :
1262
1262
return False
1263
1263
return True
Original file line number Diff line number Diff line change @@ -223,7 +223,7 @@ def assign_device(args):
223
223
if args .only_port :
224
224
device .device_id = None
225
225
if args .only_device :
226
- device .port = None
226
+ device .port = Port ( None , None , device . devclass )
227
227
options = dict (opt .split ('=' , 1 ) for opt in args .option or [])
228
228
if args .ro :
229
229
options ['read-only' ] = 'yes'
You can’t perform that action at this time.
0 commit comments