net: Refactor in preparation for driver model