down_write(&port->mutex);  port->ib_dev = NULL;  list_for_each_entry(file, &port->file_list, port_list) for (id = 0; id < IB_UMAD_MAX_AGENTS; ++id) { if (!file->agent[id]) continue; ib_dereg_mr(file->mr[id]); ib_unregister_mad_agent(file->agent[id]); file->agent[id] = NULL; }  up_write(&port->mutex);  
static void ib_umad_kill_port(struct ib_umad_port *port){	class_set_devdata(port->class_dev,    NULL);	class_set_devdata(port->sm_class_dev, NULL);	class_device_destroy(umad_class, port->dev->dev);	class_device_destroy(umad_class, port->sm_dev->dev);	cdev_del(port->dev);	cdev_del(port->sm_dev);	spin_lock(&port_lock);	umad_port[port->dev_num] = NULL;	spin_unlock(&port_lock);	clear_bit(port->dev_num, dev_map);}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/0c99cb6d5fe77872c5a32cff837c05f70158ce15/user_mad.c/clean/drivers/infiniband/core/user_mad.c