net/ice: change switch parser to support flexible mask