[PATCH] conf: Unify several paths in conf_ports()