vhost-user-server test: Use features constant
Add an associated const to MockVhostBackend that reflects the feature bits it supports, so we can easily verify this value in other places. Signed-off-by: Hanna Czenczek <hreitz@redhat.com>
This commit is contained in:
parent
72379ea0e1
commit
ff08ca095c
1 changed files with 3 additions and 1 deletions
|
|
@ -26,6 +26,8 @@ struct MockVhostBackend {
|
|||
}
|
||||
|
||||
impl MockVhostBackend {
|
||||
const SUPPORTED_FEATURES: u64 = 0xffff_ffff_ffff_ffff;
|
||||
|
||||
fn new() -> Self {
|
||||
MockVhostBackend {
|
||||
events: 0,
|
||||
|
|
@ -48,7 +50,7 @@ impl VhostUserBackendMut for MockVhostBackend {
|
|||
}
|
||||
|
||||
fn features(&self) -> u64 {
|
||||
0xffff_ffff_ffff_ffff
|
||||
Self::SUPPORTED_FEATURES
|
||||
}
|
||||
|
||||
fn acked_features(&mut self, features: u64) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue