File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
vm/devices/net/netvsp/src Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -3025,12 +3025,16 @@ enum OidError {
3025
3025
BadVersion ,
3026
3026
#[ error( "feature {0} not supported" ) ]
3027
3027
NotSupported ( & ' static str ) ,
3028
+ #[ error( "packet filter {0} not supported" ) ]
3029
+ UnsupportedFilter ( u32 ) ,
3028
3030
}
3029
3031
3030
3032
impl OidError {
3031
3033
fn as_status ( & self ) -> u32 {
3032
3034
match self {
3033
- OidError :: UnknownOid | OidError :: NotSupported ( _) => rndisprot:: STATUS_NOT_SUPPORTED ,
3035
+ OidError :: UnknownOid | OidError :: NotSupported ( _) | OidError :: UnsupportedFilter ( _) => {
3036
+ rndisprot:: STATUS_NOT_SUPPORTED
3037
+ }
3034
3038
OidError :: BadVersion => rndisprot:: STATUS_BAD_VERSION ,
3035
3039
OidError :: InvalidInput ( _) => rndisprot:: STATUS_INVALID_DATA ,
3036
3040
OidError :: Access ( _) => rndisprot:: STATUS_FAILURE ,
@@ -3410,8 +3414,7 @@ impl Adapter {
3410
3414
if filter != 0 {
3411
3415
// TODO:
3412
3416
// Maybe dont return error since previously we were not?
3413
- // Log the filter value with the error
3414
- return Err ( OidError :: NotSupported ( "unsupported filter" ) ) ;
3417
+ return Err ( OidError :: UnsupportedFilter ( filter) ) ;
3415
3418
}
3416
3419
primary. stop_rx = true ;
3417
3420
Ok ( primary. stop_rx )
You can’t perform that action at this time.
0 commit comments