Move dev_id enum into user-space header

Additionally, some housekeeping.