diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/ieee1394/eth1394.c | 27 |
1 files changed, 10 insertions, 17 deletions
diff --git a/drivers/ieee1394/eth1394.c b/drivers/ieee1394/eth1394.c index e2b84c9b83bb..63fca140ab90 100644 --- a/drivers/ieee1394/eth1394.c +++ b/drivers/ieee1394/eth1394.c | |||
@@ -655,24 +655,17 @@ out: | |||
655 | static void ether1394_remove_host (struct hpsb_host *host) | 655 | static void ether1394_remove_host (struct hpsb_host *host) |
656 | { | 656 | { |
657 | struct eth1394_host_info *hi; | 657 | struct eth1394_host_info *hi; |
658 | struct eth1394_priv *priv; | ||
658 | 659 | ||
659 | hi = hpsb_get_hostinfo(ð1394_highlevel, host); | 660 | hi = hpsb_get_hostinfo(ð1394_highlevel, host); |
660 | if (hi != NULL) { | 661 | if (!hi) |
661 | struct eth1394_priv *priv = netdev_priv(hi->dev); | 662 | return; |
662 | 663 | priv = netdev_priv(hi->dev); | |
663 | hpsb_unregister_addrspace(ð1394_highlevel, host, | 664 | hpsb_unregister_addrspace(ð1394_highlevel, host, priv->local_fifo); |
664 | priv->local_fifo); | 665 | if (priv->iso) |
665 | 666 | hpsb_iso_shutdown(priv->iso); | |
666 | if (priv->iso != NULL) | 667 | unregister_netdev(hi->dev); |
667 | hpsb_iso_shutdown(priv->iso); | 668 | free_netdev(hi->dev); |
668 | |||
669 | if (hi->dev) { | ||
670 | unregister_netdev (hi->dev); | ||
671 | free_netdev(hi->dev); | ||
672 | } | ||
673 | } | ||
674 | |||
675 | return; | ||
676 | } | 669 | } |
677 | 670 | ||
678 | /* A reset has just arisen */ | 671 | /* A reset has just arisen */ |
@@ -689,7 +682,7 @@ static void ether1394_host_reset (struct hpsb_host *host) | |||
689 | hi = hpsb_get_hostinfo(ð1394_highlevel, host); | 682 | hi = hpsb_get_hostinfo(ð1394_highlevel, host); |
690 | 683 | ||
691 | /* This can happen for hosts that we don't use */ | 684 | /* This can happen for hosts that we don't use */ |
692 | if (hi == NULL) | 685 | if (!hi) |
693 | return; | 686 | return; |
694 | 687 | ||
695 | dev = hi->dev; | 688 | dev = hi->dev; |