'Remove a specified port from the instance.
Return network information for the instance'

def deallocate_port_for_instance(self, context, instance, port_id):

    neutron = get_client(context)
    preexisting_ports = self._get_preexisting_port_ids(instance)
    if (port_id in preexisting_ports):
        self._unbind_ports(context, [port_id], neutron)
    else:
        self._delete_ports(neutron, instance, [port_id], raise_if_fail=True)
    vif = objects.VirtualInterface.get_by_uuid(context, port_id)
    if vif:
        if (('tag' in vif) and vif.tag):
            self._delete_nic_metadata(instance, vif)
        vif.destroy()
    else:
        LOG.debug('VirtualInterface    not    found    for    port:    %s', port_id, instance=instance)
    return self.get_instance_nw_info(context, instance)
