Import switch daemon from trema/trema.