Hi, What is the correct sequence to register and deregister host/rport/scsi_devices at the scsi stack? ZFCP's sequence is like follows: scsi_add_host fc_remote_port_add (if port succesfully configured/opened in/by zfcp) scsi_add_device (if unit successfully configured/opened in/by zfcp) If a zfcp-adapter is set offline I do the following to get rid of the entries within /sys/class/fc_*: fc_remote_port_delete (for each rport registered for this adapter) fc_remove_host scsi_remove_host Setting zfcp adapters offline it happens that the entries target0:0:0 for the old host_id 0 are still present in /sys/class/fc_transport. The symlink "device" points to a non-existent directory ../../../devices/css0/0.0.000f/0.0.50d3/host0/rport-0:0-0/target0:0:0 of the removed host. I observed the same behaviour when trying to delete the SCSI device using its delete attribute before removing the host. Furthermore I put some printk into the release function for the SCSI device (scsi_device_dev_release in scsi_scan.c) but this funtion is never called -- neither if the delete attribute was used nor when the host was completely removed. Is there a problem with proper deregistration of kobjects for SCSI devices in the SCSI subsystem if fc_transport is used? Or is this obvious memory leak caused by a wrong usage of the scsi_transport_fc interface? Any thoughts about this problem? Regards, Andreas - : send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html