diff options
author | Steven Whitehouse <swhiteho@redhat.com> | 2006-03-20 12:47:40 -0500 |
---|---|---|
committer | Steven Whitehouse <swhiteho@redhat.com> | 2006-03-20 12:47:40 -0500 |
commit | 9a21247181d93fdf99255911845ecdb041d21583 (patch) | |
tree | 6d69be36f8a2bd8c76bf02ead2f0121a511c0a92 /drivers/sn/ioc3.c | |
parent | c752666c17f870fa8ae9f16804dd457e9e6daaec (diff) | |
parent | 7705a8792b0fc82fd7d4dd923724606bbfd9fb20 (diff) |
Merge branch 'master'
Diffstat (limited to 'drivers/sn/ioc3.c')
-rw-r--r-- | drivers/sn/ioc3.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/drivers/sn/ioc3.c b/drivers/sn/ioc3.c index 12357e1fa558..93449a1a0065 100644 --- a/drivers/sn/ioc3.c +++ b/drivers/sn/ioc3.c | |||
@@ -62,7 +62,7 @@ static int nic_reset(struct ioc3_driver_data *idd) | |||
62 | return presence; | 62 | return presence; |
63 | } | 63 | } |
64 | 64 | ||
65 | static inline int nic_read_bit(struct ioc3_driver_data *idd) | 65 | static int nic_read_bit(struct ioc3_driver_data *idd) |
66 | { | 66 | { |
67 | int result; | 67 | int result; |
68 | unsigned long flags; | 68 | unsigned long flags; |
@@ -77,7 +77,7 @@ static inline int nic_read_bit(struct ioc3_driver_data *idd) | |||
77 | return result; | 77 | return result; |
78 | } | 78 | } |
79 | 79 | ||
80 | static inline void nic_write_bit(struct ioc3_driver_data *idd, int bit) | 80 | static void nic_write_bit(struct ioc3_driver_data *idd, int bit) |
81 | { | 81 | { |
82 | if (bit) | 82 | if (bit) |
83 | writel(mcr_pack(6, 110), &idd->vma->mcr); | 83 | writel(mcr_pack(6, 110), &idd->vma->mcr); |
@@ -371,8 +371,7 @@ static void probe_nic(struct ioc3_driver_data *idd) | |||
371 | 371 | ||
372 | /* Interrupts */ | 372 | /* Interrupts */ |
373 | 373 | ||
374 | static inline void | 374 | static void write_ireg(struct ioc3_driver_data *idd, uint32_t val, int which) |
375 | write_ireg(struct ioc3_driver_data *idd, uint32_t val, int which) | ||
376 | { | 375 | { |
377 | unsigned long flags; | 376 | unsigned long flags; |
378 | 377 | ||
@@ -735,14 +734,12 @@ static int ioc3_probe(struct pci_dev *pdev, const struct pci_device_id *pci_id) | |||
735 | } | 734 | } |
736 | 735 | ||
737 | /* Add this IOC3 to all submodules */ | 736 | /* Add this IOC3 to all submodules */ |
738 | read_lock(&ioc3_submodules_lock); | ||
739 | for(id=0;id<IOC3_MAX_SUBMODULES;id++) | 737 | for(id=0;id<IOC3_MAX_SUBMODULES;id++) |
740 | if(ioc3_submodules[id] && ioc3_submodules[id]->probe) { | 738 | if(ioc3_submodules[id] && ioc3_submodules[id]->probe) { |
741 | idd->active[id] = 1; | 739 | idd->active[id] = 1; |
742 | idd->active[id] = !ioc3_submodules[id]->probe | 740 | idd->active[id] = !ioc3_submodules[id]->probe |
743 | (ioc3_submodules[id], idd); | 741 | (ioc3_submodules[id], idd); |
744 | } | 742 | } |
745 | read_unlock(&ioc3_submodules_lock); | ||
746 | 743 | ||
747 | printk(KERN_INFO "IOC3 Master Driver loaded for %s\n", pci_name(pdev)); | 744 | printk(KERN_INFO "IOC3 Master Driver loaded for %s\n", pci_name(pdev)); |
748 | 745 | ||
@@ -767,7 +764,6 @@ static void ioc3_remove(struct pci_dev *pdev) | |||
767 | idd = pci_get_drvdata(pdev); | 764 | idd = pci_get_drvdata(pdev); |
768 | 765 | ||
769 | /* Remove this IOC3 from all submodules */ | 766 | /* Remove this IOC3 from all submodules */ |
770 | read_lock(&ioc3_submodules_lock); | ||
771 | for(id=0;id<IOC3_MAX_SUBMODULES;id++) | 767 | for(id=0;id<IOC3_MAX_SUBMODULES;id++) |
772 | if(idd->active[id]) { | 768 | if(idd->active[id]) { |
773 | if(ioc3_submodules[id] && ioc3_submodules[id]->remove) | 769 | if(ioc3_submodules[id] && ioc3_submodules[id]->remove) |
@@ -781,7 +777,6 @@ static void ioc3_remove(struct pci_dev *pdev) | |||
781 | pci_name(pdev)); | 777 | pci_name(pdev)); |
782 | idd->active[id] = 0; | 778 | idd->active[id] = 0; |
783 | } | 779 | } |
784 | read_unlock(&ioc3_submodules_lock); | ||
785 | 780 | ||
786 | /* Clear and disable all IRQs */ | 781 | /* Clear and disable all IRQs */ |
787 | write_ireg(idd, ~0, IOC3_W_IEC); | 782 | write_ireg(idd, ~0, IOC3_W_IEC); |