Error codes for virtual port operations

Reviewer: @rlane