mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-26 18:43:33 -05:00
Revert "scsi: libfc: Add WARN_ON() when deleting rports"
This reverts commit bbc0f8bd88
.
It added a warning whose intent was to check whether the rport was still
linked into the peer list. It doesn't work as intended and gives false
positive warnings for two reasons:
1) If the rport is never linked into the peer list it will not be
considered empty since the list_head is never initialized.
2) If the rport is deleted from the peer list using list_del_rcu(), then
the list_head is in an undefined state and it is not considered empty.
Signed-off-by: Ross Lagerwall <ross.lagerwall@citrix.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
parent
88fc41c407
commit
d8f6382a7d
1 changed files with 0 additions and 1 deletions
|
@ -184,7 +184,6 @@ void fc_rport_destroy(struct kref *kref)
|
||||||
struct fc_rport_priv *rdata;
|
struct fc_rport_priv *rdata;
|
||||||
|
|
||||||
rdata = container_of(kref, struct fc_rport_priv, kref);
|
rdata = container_of(kref, struct fc_rport_priv, kref);
|
||||||
WARN_ON(!list_empty(&rdata->peers));
|
|
||||||
kfree_rcu(rdata, rcu);
|
kfree_rcu(rdata, rcu);
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL(fc_rport_destroy);
|
EXPORT_SYMBOL(fc_rport_destroy);
|
||||||
|
|
Loading…
Add table
Reference in a new issue