diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-11-13 12:04:48 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-11-13 12:04:48 -0500 |
commit | 31083eba370fbc5d544ac2fe67ca549c0aa2bdf7 (patch) | |
tree | 9531e720d8d3cd8d82b7a3e4d2a1c6c306e769b4 /drivers | |
parent | a7fe77161da48a74c60dc19fc4ca3a73ab761d37 (diff) | |
parent | 53756524e42a71011f5ae6410d6ac386bf3a9e7b (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (45 commits)
[NETFILTER]: xt_time should not assume CONFIG_KTIME_SCALAR
[NET]: Move unneeded data to initdata section.
[NET]: Cleanup pernet operation without CONFIG_NET_NS
[TEHUTI]: Fix incorrect usage of strncat in bdx_get_drvinfo()
[MYRI_SBUS]: Prevent that myri_do_handshake lies about ticks.
[NETFILTER]: bridge: fix double POSTROUTING hook invocation
[NETFILTER]: Consolidate nf_sockopt and compat_nf_sockopt
[NETFILTER]: nf_nat: fix memset error
[INET]: Use list_head-s in inetpeer.c
[IPVS]: Remove unused exports.
[NET]: Unexport sysctl_{r,w}mem_max.
[TG3]: Update version to 3.86
[TG3]: MII => TP
[TG3]: Add A1 revs
[TG3]: Increase the PCI MRRS
[TG3]: Prescaler fix
[TG3]: Limit 5784 / 5764 to MAC LED mode
[TG3]: Disable GPHY autopowerdown
[TG3]: CPMU adjustments for loopback tests
[TG3]: Fix nvram selftest failures
...
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/block/nbd.c | 3 | ||||
-rw-r--r-- | drivers/net/Kconfig | 199 | ||||
-rw-r--r-- | drivers/net/arcnet/Kconfig | 15 | ||||
-rw-r--r-- | drivers/net/loopback.c | 2 | ||||
-rw-r--r-- | drivers/net/myri_sbus.c | 2 | ||||
-rw-r--r-- | drivers/net/ppp_async.c | 34 | ||||
-rw-r--r-- | drivers/net/ppp_generic.c | 126 | ||||
-rw-r--r-- | drivers/net/ppp_synctty.c | 27 | ||||
-rw-r--r-- | drivers/net/sungem.c | 11 | ||||
-rw-r--r-- | drivers/net/tehuti.c | 8 | ||||
-rw-r--r-- | drivers/net/tg3.c | 186 | ||||
-rw-r--r-- | drivers/net/tg3.h | 44 | ||||
-rw-r--r-- | drivers/net/tulip/Kconfig | 21 |
13 files changed, 374 insertions, 304 deletions
diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c index 6332acad078c..b4c0888aedc3 100644 --- a/drivers/block/nbd.c +++ b/drivers/block/nbd.c | |||
@@ -28,6 +28,7 @@ | |||
28 | #include <linux/err.h> | 28 | #include <linux/err.h> |
29 | #include <linux/kernel.h> | 29 | #include <linux/kernel.h> |
30 | #include <net/sock.h> | 30 | #include <net/sock.h> |
31 | #include <linux/net.h> | ||
31 | 32 | ||
32 | #include <asm/uaccess.h> | 33 | #include <asm/uaccess.h> |
33 | #include <asm/system.h> | 34 | #include <asm/system.h> |
@@ -126,7 +127,7 @@ static void sock_shutdown(struct nbd_device *lo, int lock) | |||
126 | if (lo->sock) { | 127 | if (lo->sock) { |
127 | printk(KERN_WARNING "%s: shutting down socket\n", | 128 | printk(KERN_WARNING "%s: shutting down socket\n", |
128 | lo->disk->disk_name); | 129 | lo->disk->disk_name); |
129 | lo->sock->ops->shutdown(lo->sock, SEND_SHUTDOWN|RCV_SHUTDOWN); | 130 | kernel_sock_shutdown(lo->sock, SHUT_RDWR); |
130 | lo->sock = NULL; | 131 | lo->sock = NULL; |
131 | } | 132 | } |
132 | if (lock) | 133 | if (lock) |
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig index bf8890ebbc4c..e8d69b0adf90 100644 --- a/drivers/net/Kconfig +++ b/drivers/net/Kconfig | |||
@@ -366,8 +366,7 @@ config MAC89x0 | |||
366 | read the Ethernet-HOWTO, available from | 366 | read the Ethernet-HOWTO, available from |
367 | <http://www.tldp.org/docs.html#howto>. | 367 | <http://www.tldp.org/docs.html#howto>. |
368 | 368 | ||
369 | To compile this driver as a module, choose M here and read | 369 | To compile this driver as a module, choose M here. This module will |
370 | <file:Documentation/networking/net-modules.txt>. This module will | ||
371 | be called mac89x0. | 370 | be called mac89x0. |
372 | 371 | ||
373 | config MACSONIC | 372 | config MACSONIC |
@@ -380,8 +379,7 @@ config MACSONIC | |||
380 | one of these say Y and read the Ethernet-HOWTO, available from | 379 | one of these say Y and read the Ethernet-HOWTO, available from |
381 | <http://www.tldp.org/docs.html#howto>. | 380 | <http://www.tldp.org/docs.html#howto>. |
382 | 381 | ||
383 | To compile this driver as a module, choose M here and read | 382 | To compile this driver as a module, choose M here. This module will |
384 | <file:Documentation/networking/net-modules.txt>. This module will | ||
385 | be called macsonic. | 383 | be called macsonic. |
386 | 384 | ||
387 | config MACMACE | 385 | config MACMACE |
@@ -619,8 +617,7 @@ config EL1 | |||
619 | have problems. Some people suggest to ping ("man ping") a nearby | 617 | have problems. Some people suggest to ping ("man ping") a nearby |
620 | machine every minute ("man cron") when using this card. | 618 | machine every minute ("man cron") when using this card. |
621 | 619 | ||
622 | To compile this driver as a module, choose M here and read | 620 | To compile this driver as a module, choose M here. The module |
623 | <file:Documentation/networking/net-modules.txt>. The module | ||
624 | will be called 3c501. | 621 | will be called 3c501. |
625 | 622 | ||
626 | config EL2 | 623 | config EL2 |
@@ -632,8 +629,7 @@ config EL2 | |||
632 | the Ethernet-HOWTO, available from | 629 | the Ethernet-HOWTO, available from |
633 | <http://www.tldp.org/docs.html#howto>. | 630 | <http://www.tldp.org/docs.html#howto>. |
634 | 631 | ||
635 | To compile this driver as a module, choose M here and read | 632 | To compile this driver as a module, choose M here. The module |
636 | <file:Documentation/networking/net-modules.txt>. The module | ||
637 | will be called 3c503. | 633 | will be called 3c503. |
638 | 634 | ||
639 | config ELPLUS | 635 | config ELPLUS |
@@ -645,8 +641,7 @@ config ELPLUS | |||
645 | this type, say Y and read the Ethernet-HOWTO, available from | 641 | this type, say Y and read the Ethernet-HOWTO, available from |
646 | <http://www.tldp.org/docs.html#howto>. | 642 | <http://www.tldp.org/docs.html#howto>. |
647 | 643 | ||
648 | To compile this driver as a module, choose M here and read | 644 | To compile this driver as a module, choose M here. The module |
649 | <file:Documentation/networking/net-modules.txt>. The module | ||
650 | will be called 3c505. | 645 | will be called 3c505. |
651 | 646 | ||
652 | config EL16 | 647 | config EL16 |
@@ -657,8 +652,7 @@ config EL16 | |||
657 | the Ethernet-HOWTO, available from | 652 | the Ethernet-HOWTO, available from |
658 | <http://www.tldp.org/docs.html#howto>. | 653 | <http://www.tldp.org/docs.html#howto>. |
659 | 654 | ||
660 | To compile this driver as a module, choose M here and read | 655 | To compile this driver as a module, choose M here. The module |
661 | <file:Documentation/networking/net-modules.txt>. The module | ||
662 | will be called 3c507. | 656 | will be called 3c507. |
663 | 657 | ||
664 | config EL3 | 658 | config EL3 |
@@ -673,8 +667,7 @@ config EL3 | |||
673 | setup disk to disable Plug & Play mode, and to select the default | 667 | setup disk to disable Plug & Play mode, and to select the default |
674 | media type. | 668 | media type. |
675 | 669 | ||
676 | To compile this driver as a module, choose M here and read | 670 | To compile this driver as a module, choose M here. The module |
677 | <file:Documentation/networking/net-modules.txt>. The module | ||
678 | will be called 3c509. | 671 | will be called 3c509. |
679 | 672 | ||
680 | config 3C515 | 673 | config 3C515 |
@@ -685,8 +678,7 @@ config 3C515 | |||
685 | network card, say Y and read the Ethernet-HOWTO, available from | 678 | network card, say Y and read the Ethernet-HOWTO, available from |
686 | <http://www.tldp.org/docs.html#howto>. | 679 | <http://www.tldp.org/docs.html#howto>. |
687 | 680 | ||
688 | To compile this driver as a module, choose M here and read | 681 | To compile this driver as a module, choose M here. The module |
689 | <file:Documentation/networking/net-modules.txt>. The module | ||
690 | will be called 3c515. | 682 | will be called 3c515. |
691 | 683 | ||
692 | config ELMC | 684 | config ELMC |
@@ -697,8 +689,7 @@ config ELMC | |||
697 | the Ethernet-HOWTO, available from | 689 | the Ethernet-HOWTO, available from |
698 | <http://www.tldp.org/docs.html#howto>. | 690 | <http://www.tldp.org/docs.html#howto>. |
699 | 691 | ||
700 | To compile this driver as a module, choose M here and read | 692 | To compile this driver as a module, choose M here. The module |
701 | <file:Documentation/networking/net-modules.txt>. The module | ||
702 | will be called 3c523. | 693 | will be called 3c523. |
703 | 694 | ||
704 | config ELMC_II | 695 | config ELMC_II |
@@ -709,8 +700,7 @@ config ELMC_II | |||
709 | the Ethernet-HOWTO, available from | 700 | the Ethernet-HOWTO, available from |
710 | <http://www.tldp.org/docs.html#howto>. | 701 | <http://www.tldp.org/docs.html#howto>. |
711 | 702 | ||
712 | To compile this driver as a module, choose M here and read | 703 | To compile this driver as a module, choose M here. The module |
713 | <file:Documentation/networking/net-modules.txt>. The module | ||
714 | will be called 3c527. | 704 | will be called 3c527. |
715 | 705 | ||
716 | config VORTEX | 706 | config VORTEX |
@@ -733,8 +723,7 @@ config VORTEX | |||
733 | <file:Documentation/networking/vortex.txt> and in the comments at | 723 | <file:Documentation/networking/vortex.txt> and in the comments at |
734 | the beginning of <file:drivers/net/3c59x.c>. | 724 | the beginning of <file:drivers/net/3c59x.c>. |
735 | 725 | ||
736 | To compile this support as a module, choose M here and read | 726 | To compile this support as a module, choose M here. |
737 | <file:Documentation/networking/net-modules.txt>. | ||
738 | 727 | ||
739 | config TYPHOON | 728 | config TYPHOON |
740 | tristate "3cr990 series \"Typhoon\" support" | 729 | tristate "3cr990 series \"Typhoon\" support" |
@@ -751,8 +740,7 @@ config TYPHOON | |||
751 | the Ethernet-HOWTO, available from | 740 | the Ethernet-HOWTO, available from |
752 | <http://www.tldp.org/docs.html#howto>. | 741 | <http://www.tldp.org/docs.html#howto>. |
753 | 742 | ||
754 | To compile this driver as a module, choose M here and read | 743 | To compile this driver as a module, choose M here. The module |
755 | <file:Documentation/networking/net-modules.txt>. The module | ||
756 | will be called typhoon. | 744 | will be called typhoon. |
757 | 745 | ||
758 | config LANCE | 746 | config LANCE |
@@ -789,8 +777,7 @@ config WD80x3 | |||
789 | the Ethernet-HOWTO, available from | 777 | the Ethernet-HOWTO, available from |
790 | <http://www.tldp.org/docs.html#howto>. | 778 | <http://www.tldp.org/docs.html#howto>. |
791 | 779 | ||
792 | To compile this driver as a module, choose M here and read | 780 | To compile this driver as a module, choose M here. The module |
793 | <file:Documentation/networking/net-modules.txt>. The module | ||
794 | will be called wd. | 781 | will be called wd. |
795 | 782 | ||
796 | config ULTRAMCA | 783 | config ULTRAMCA |
@@ -802,8 +789,7 @@ config ULTRAMCA | |||
802 | an MCA based system (PS/2), say Y and read the Ethernet-HOWTO, | 789 | an MCA based system (PS/2), say Y and read the Ethernet-HOWTO, |
803 | available from <http://www.tldp.org/docs.html#howto>. | 790 | available from <http://www.tldp.org/docs.html#howto>. |
804 | 791 | ||
805 | To compile this driver as a module, choose M here and read | 792 | To compile this driver as a module, choose M here. The module |
806 | <file:Documentation/networking/net-modules.txt>. The module | ||
807 | will be called smc-mca. | 793 | will be called smc-mca. |
808 | 794 | ||
809 | config ULTRA | 795 | config ULTRA |
@@ -822,8 +808,7 @@ config ULTRA | |||
822 | this but keep it in mind if you have such a SCSI card and have | 808 | this but keep it in mind if you have such a SCSI card and have |
823 | problems. | 809 | problems. |
824 | 810 | ||
825 | To compile this driver as a module, choose M here and read | 811 | To compile this driver as a module, choose M here. The module |
826 | <file:Documentation/networking/net-modules.txt>. The module | ||
827 | will be called smc-ultra. | 812 | will be called smc-ultra. |
828 | 813 | ||
829 | config ULTRA32 | 814 | config ULTRA32 |
@@ -835,8 +820,7 @@ config ULTRA32 | |||
835 | the Ethernet-HOWTO, available from | 820 | the Ethernet-HOWTO, available from |
836 | <http://www.tldp.org/docs.html#howto>. | 821 | <http://www.tldp.org/docs.html#howto>. |
837 | 822 | ||
838 | To compile this driver as a module, choose M here and read | 823 | To compile this driver as a module, choose M here. The module |
839 | <file:Documentation/networking/net-modules.txt>. The module | ||
840 | will be called smc-ultra32. | 824 | will be called smc-ultra32. |
841 | 825 | ||
842 | config BFIN_MAC | 826 | config BFIN_MAC |
@@ -897,8 +881,7 @@ config SMC9194 | |||
897 | <file:Documentation/networking/smc9.txt> and the Ethernet-HOWTO, | 881 | <file:Documentation/networking/smc9.txt> and the Ethernet-HOWTO, |
898 | available from <http://www.tldp.org/docs.html#howto>. | 882 | available from <http://www.tldp.org/docs.html#howto>. |
899 | 883 | ||
900 | To compile this driver as a module, choose M here and read | 884 | To compile this driver as a module, choose M here. The module |
901 | <file:Documentation/networking/net-modules.txt>. The module | ||
902 | will be called smc9194. | 885 | will be called smc9194. |
903 | 886 | ||
904 | config SMC91X | 887 | config SMC91X |
@@ -916,8 +899,7 @@ config SMC91X | |||
916 | This driver is also available as a module ( = code which can be | 899 | This driver is also available as a module ( = code which can be |
917 | inserted in and removed from the running kernel whenever you want). | 900 | inserted in and removed from the running kernel whenever you want). |
918 | The module will be called smc91x. If you want to compile it as a | 901 | The module will be called smc91x. If you want to compile it as a |
919 | module, say M here and read <file:Documentation/kbuild/modules.txt> | 902 | module, say M here and read <file:Documentation/kbuild/modules.txt>. |
920 | as well as <file:Documentation/networking/net-modules.txt>. | ||
921 | 903 | ||
922 | config NET_NETX | 904 | config NET_NETX |
923 | tristate "NetX Ethernet support" | 905 | tristate "NetX Ethernet support" |
@@ -926,8 +908,7 @@ config NET_NETX | |||
926 | help | 908 | help |
927 | This is support for the Hilscher netX builtin Ethernet ports | 909 | This is support for the Hilscher netX builtin Ethernet ports |
928 | 910 | ||
929 | To compile this driver as a module, choose M here and read | 911 | To compile this driver as a module, choose M here. The module |
930 | <file:Documentation/networking/net-modules.txt>. The module | ||
931 | will be called netx-eth. | 912 | will be called netx-eth. |
932 | 913 | ||
933 | config DM9000 | 914 | config DM9000 |
@@ -938,9 +919,8 @@ config DM9000 | |||
938 | ---help--- | 919 | ---help--- |
939 | Support for DM9000 chipset. | 920 | Support for DM9000 chipset. |
940 | 921 | ||
941 | To compile this driver as a module, choose M here and read | 922 | To compile this driver as a module, choose M here. The module |
942 | <file:Documentation/networking/net-modules.txt>. The module will be | 923 | will be called dm9000. |
943 | called dm9000. | ||
944 | 924 | ||
945 | config SMC911X | 925 | config SMC911X |
946 | tristate "SMSC LAN911[5678] support" | 926 | tristate "SMSC LAN911[5678] support" |
@@ -980,8 +960,7 @@ config NI5010 | |||
980 | <http://www.tldp.org/docs.html#howto>. Note that this is still | 960 | <http://www.tldp.org/docs.html#howto>. Note that this is still |
981 | experimental code. | 961 | experimental code. |
982 | 962 | ||
983 | To compile this driver as a module, choose M here and read | 963 | To compile this driver as a module, choose M here. The module |
984 | <file:Documentation/networking/net-modules.txt>. The module | ||
985 | will be called ni5010. | 964 | will be called ni5010. |
986 | 965 | ||
987 | config NI52 | 966 | config NI52 |
@@ -992,8 +971,7 @@ config NI52 | |||
992 | the Ethernet-HOWTO, available from | 971 | the Ethernet-HOWTO, available from |
993 | <http://www.tldp.org/docs.html#howto>. | 972 | <http://www.tldp.org/docs.html#howto>. |
994 | 973 | ||
995 | To compile this driver as a module, choose M here and read | 974 | To compile this driver as a module, choose M here. The module |
996 | <file:Documentation/networking/net-modules.txt>. The module | ||
997 | will be called ni52. | 975 | will be called ni52. |
998 | 976 | ||
999 | config NI65 | 977 | config NI65 |
@@ -1004,8 +982,7 @@ config NI65 | |||
1004 | the Ethernet-HOWTO, available from | 982 | the Ethernet-HOWTO, available from |
1005 | <http://www.tldp.org/docs.html#howto>. | 983 | <http://www.tldp.org/docs.html#howto>. |
1006 | 984 | ||
1007 | To compile this driver as a module, choose M here and read | 985 | To compile this driver as a module, choose M here. The module |
1008 | <file:Documentation/networking/net-modules.txt>. The module | ||
1009 | will be called ni65. | 986 | will be called ni65. |
1010 | 987 | ||
1011 | source "drivers/net/tulip/Kconfig" | 988 | source "drivers/net/tulip/Kconfig" |
@@ -1019,8 +996,7 @@ config AT1700 | |||
1019 | the Ethernet-HOWTO, available from | 996 | the Ethernet-HOWTO, available from |
1020 | <http://www.tldp.org/docs.html#howto>. | 997 | <http://www.tldp.org/docs.html#howto>. |
1021 | 998 | ||
1022 | To compile this driver as a module, choose M here and read | 999 | To compile this driver as a module, choose M here. The module |
1023 | <file:Documentation/networking/net-modules.txt>. The module | ||
1024 | will be called at1700. | 1000 | will be called at1700. |
1025 | 1001 | ||
1026 | config DEPCA | 1002 | config DEPCA |
@@ -1033,8 +1009,7 @@ config DEPCA | |||
1033 | <http://www.tldp.org/docs.html#howto> as well as | 1009 | <http://www.tldp.org/docs.html#howto> as well as |
1034 | <file:drivers/net/depca.c>. | 1010 | <file:drivers/net/depca.c>. |
1035 | 1011 | ||
1036 | To compile this driver as a module, choose M here and read | 1012 | To compile this driver as a module, choose M here. The module |
1037 | <file:Documentation/networking/net-modules.txt>. The module | ||
1038 | will be called depca. | 1013 | will be called depca. |
1039 | 1014 | ||
1040 | config HP100 | 1015 | config HP100 |
@@ -1045,8 +1020,7 @@ config HP100 | |||
1045 | the Ethernet-HOWTO, available from | 1020 | the Ethernet-HOWTO, available from |
1046 | <http://www.tldp.org/docs.html#howto>. | 1021 | <http://www.tldp.org/docs.html#howto>. |
1047 | 1022 | ||
1048 | To compile this driver as a module, choose M here and read | 1023 | To compile this driver as a module, choose M here. The module |
1049 | <file:Documentation/networking/net-modules.txt>. The module | ||
1050 | will be called hp100. | 1024 | will be called hp100. |
1051 | 1025 | ||
1052 | config NET_ISA | 1026 | config NET_ISA |
@@ -1075,8 +1049,7 @@ config E2100 | |||
1075 | the Ethernet-HOWTO, available from | 1049 | the Ethernet-HOWTO, available from |
1076 | <http://www.tldp.org/docs.html#howto>. | 1050 | <http://www.tldp.org/docs.html#howto>. |
1077 | 1051 | ||
1078 | To compile this driver as a module, choose M here and read | 1052 | To compile this driver as a module, choose M here. The module |
1079 | <file:Documentation/networking/net-modules.txt>. The module | ||
1080 | will be called e2100. | 1053 | will be called e2100. |
1081 | 1054 | ||
1082 | config EWRK3 | 1055 | config EWRK3 |
@@ -1090,8 +1063,7 @@ config EWRK3 | |||
1090 | well as the Ethernet-HOWTO, available from | 1063 | well as the Ethernet-HOWTO, available from |
1091 | <http://www.tldp.org/docs.html#howto>. | 1064 | <http://www.tldp.org/docs.html#howto>. |
1092 | 1065 | ||
1093 | To compile this driver as a module, choose M here and read | 1066 | To compile this driver as a module, choose M here. The module |
1094 | <file:Documentation/networking/net-modules.txt>. The module | ||
1095 | will be called ewrk3. | 1067 | will be called ewrk3. |
1096 | 1068 | ||
1097 | config EEXPRESS | 1069 | config EEXPRESS |
@@ -1105,8 +1077,7 @@ config EEXPRESS | |||
1105 | because the driver was very unreliable. We now have a new driver | 1077 | because the driver was very unreliable. We now have a new driver |
1106 | that should do better. | 1078 | that should do better. |
1107 | 1079 | ||
1108 | To compile this driver as a module, choose M here and read | 1080 | To compile this driver as a module, choose M here. The module |
1109 | <file:Documentation/networking/net-modules.txt>. The module | ||
1110 | will be called eexpress. | 1081 | will be called eexpress. |
1111 | 1082 | ||
1112 | config EEXPRESS_PRO | 1083 | config EEXPRESS_PRO |
@@ -1119,8 +1090,7 @@ config EEXPRESS_PRO | |||
1119 | driver. Please read the Ethernet-HOWTO, available from | 1090 | driver. Please read the Ethernet-HOWTO, available from |
1120 | <http://www.tldp.org/docs.html#howto>. | 1091 | <http://www.tldp.org/docs.html#howto>. |
1121 | 1092 | ||
1122 | To compile this driver as a module, choose M here and read | 1093 | To compile this driver as a module, choose M here. The module |
1123 | <file:Documentation/networking/net-modules.txt>. The module | ||
1124 | will be called eepro. | 1094 | will be called eepro. |
1125 | 1095 | ||
1126 | config HPLAN_PLUS | 1096 | config HPLAN_PLUS |
@@ -1132,8 +1102,7 @@ config HPLAN_PLUS | |||
1132 | the Ethernet-HOWTO, available from | 1102 | the Ethernet-HOWTO, available from |
1133 | <http://www.tldp.org/docs.html#howto>. | 1103 | <http://www.tldp.org/docs.html#howto>. |
1134 | 1104 | ||
1135 | To compile this driver as a module, choose M here and read | 1105 | To compile this driver as a module, choose M here. The module |
1136 | <file:Documentation/networking/net-modules.txt>. The module | ||
1137 | will be called hp-plus. | 1106 | will be called hp-plus. |
1138 | 1107 | ||
1139 | config HPLAN | 1108 | config HPLAN |
@@ -1145,8 +1114,7 @@ config HPLAN | |||
1145 | the Ethernet-HOWTO, available from | 1114 | the Ethernet-HOWTO, available from |
1146 | <http://www.tldp.org/docs.html#howto>. | 1115 | <http://www.tldp.org/docs.html#howto>. |
1147 | 1116 | ||
1148 | To compile this driver as a module, choose M here and read | 1117 | To compile this driver as a module, choose M here. The module |
1149 | <file:Documentation/networking/net-modules.txt>. The module | ||
1150 | will be called hp. | 1118 | will be called hp. |
1151 | 1119 | ||
1152 | config LP486E | 1120 | config LP486E |
@@ -1165,8 +1133,7 @@ config ETH16I | |||
1165 | the Ethernet-HOWTO, available from | 1133 | the Ethernet-HOWTO, available from |
1166 | <http://www.tldp.org/docs.html#howto>. | 1134 | <http://www.tldp.org/docs.html#howto>. |
1167 | 1135 | ||
1168 | To compile this driver as a module, choose M here and read | 1136 | To compile this driver as a module, choose M here. The module |
1169 | <file:Documentation/networking/net-modules.txt>. The module | ||
1170 | will be called eth16i. | 1137 | will be called eth16i. |
1171 | 1138 | ||
1172 | config NE2000 | 1139 | config NE2000 |
@@ -1186,8 +1153,7 @@ config NE2000 | |||
1186 | laptops), say N here and Y to "NE/2 (ne2000 MCA version) support", | 1153 | laptops), say N here and Y to "NE/2 (ne2000 MCA version) support", |
1187 | below. | 1154 | below. |
1188 | 1155 | ||
1189 | To compile this driver as a module, choose M here and read | 1156 | To compile this driver as a module, choose M here. The module |
1190 | <file:Documentation/networking/net-modules.txt>. The module | ||
1191 | will be called ne. | 1157 | will be called ne. |
1192 | 1158 | ||
1193 | config ZNET | 1159 | config ZNET |
@@ -1208,8 +1174,7 @@ config SEEQ8005 | |||
1208 | is for you, read the Ethernet-HOWTO, available from | 1174 | is for you, read the Ethernet-HOWTO, available from |
1209 | <http://www.tldp.org/docs.html#howto>. | 1175 | <http://www.tldp.org/docs.html#howto>. |
1210 | 1176 | ||
1211 | To compile this driver as a module, choose M here and read | 1177 | To compile this driver as a module, choose M here. The module |
1212 | <file:Documentation/networking/net-modules.txt>. The module | ||
1213 | will be called seeq8005. | 1178 | will be called seeq8005. |
1214 | 1179 | ||
1215 | config NE2_MCA | 1180 | config NE2_MCA |
@@ -1221,8 +1186,7 @@ config NE2_MCA | |||
1221 | the Ethernet-HOWTO, available from | 1186 | the Ethernet-HOWTO, available from |
1222 | <http://www.tldp.org/docs.html#howto>. | 1187 | <http://www.tldp.org/docs.html#howto>. |
1223 | 1188 | ||
1224 | To compile this driver as a module, choose M here and read | 1189 | To compile this driver as a module, choose M here. The module |
1225 | <file:Documentation/networking/net-modules.txt>. The module | ||
1226 | will be called ne2. | 1190 | will be called ne2. |
1227 | 1191 | ||
1228 | config IBMLANA | 1192 | config IBMLANA |
@@ -1233,8 +1197,7 @@ config IBMLANA | |||
1233 | CONFIG_MCA to use this driver. It is both available as an in-kernel | 1197 | CONFIG_MCA to use this driver. It is both available as an in-kernel |
1234 | driver and as a module. | 1198 | driver and as a module. |
1235 | 1199 | ||
1236 | To compile this driver as a module, choose M here and read | 1200 | To compile this driver as a module, choose M here. The only |
1237 | <file:Documentation/networking/net-modules.txt>. The only | ||
1238 | currently supported card is the IBM LAN Adapter/A for Ethernet. It | 1201 | currently supported card is the IBM LAN Adapter/A for Ethernet. It |
1239 | will both support 16K and 32K memory windows, however a 32K window | 1202 | will both support 16K and 32K memory windows, however a 32K window |
1240 | gives a better security against packet losses. Usage of multiple | 1203 | gives a better security against packet losses. Usage of multiple |
@@ -1248,8 +1211,7 @@ config IBMVETH | |||
1248 | This driver supports virtual ethernet adapters on newer IBM iSeries | 1211 | This driver supports virtual ethernet adapters on newer IBM iSeries |
1249 | and pSeries systems. | 1212 | and pSeries systems. |
1250 | 1213 | ||
1251 | To compile this driver as a module, choose M here and read | 1214 | To compile this driver as a module, choose M here. The module will |
1252 | <file:Documentation/networking/net-modules.txt>. The module will | ||
1253 | be called ibmveth. | 1215 | be called ibmveth. |
1254 | 1216 | ||
1255 | source "drivers/net/ibm_emac/Kconfig" | 1217 | source "drivers/net/ibm_emac/Kconfig" |
@@ -1279,8 +1241,7 @@ config PCNET32 | |||
1279 | answer Y here and read the Ethernet-HOWTO, available from | 1241 | answer Y here and read the Ethernet-HOWTO, available from |
1280 | <http://www.tldp.org/docs.html#howto>. | 1242 | <http://www.tldp.org/docs.html#howto>. |
1281 | 1243 | ||
1282 | To compile this driver as a module, choose M here and read | 1244 | To compile this driver as a module, choose M here. The module |
1283 | <file:Documentation/networking/net-modules.txt>. The module | ||
1284 | will be called pcnet32. | 1245 | will be called pcnet32. |
1285 | 1246 | ||
1286 | config PCNET32_NAPI | 1247 | config PCNET32_NAPI |
@@ -1307,8 +1268,7 @@ config AMD8111_ETH | |||
1307 | answer Y here and read the Ethernet-HOWTO, available from | 1268 | answer Y here and read the Ethernet-HOWTO, available from |
1308 | <http://www.tldp.org/docs.html#howto>. | 1269 | <http://www.tldp.org/docs.html#howto>. |
1309 | 1270 | ||
1310 | To compile this driver as a module, choose M here and read | 1271 | To compile this driver as a module, choose M here. The module |
1311 | <file:Documentation/networking/net-modules.txt>. The module | ||
1312 | will be called amd8111e. | 1272 | will be called amd8111e. |
1313 | 1273 | ||
1314 | config AMD8111E_NAPI | 1274 | config AMD8111E_NAPI |
@@ -1362,8 +1322,7 @@ config AC3200 | |||
1362 | the Ethernet-HOWTO, available from | 1322 | the Ethernet-HOWTO, available from |
1363 | <http://www.tldp.org/docs.html#howto>. | 1323 | <http://www.tldp.org/docs.html#howto>. |
1364 | 1324 | ||
1365 | To compile this driver as a module, choose M here and read | 1325 | To compile this driver as a module, choose M here. The module |
1366 | <file:Documentation/networking/net-modules.txt>. The module | ||
1367 | will be called ac3200. | 1326 | will be called ac3200. |
1368 | 1327 | ||
1369 | config APRICOT | 1328 | config APRICOT |
@@ -1374,9 +1333,8 @@ config APRICOT | |||
1374 | read the Ethernet-HOWTO, available from | 1333 | read the Ethernet-HOWTO, available from |
1375 | <http://www.tldp.org/docs.html#howto>. | 1334 | <http://www.tldp.org/docs.html#howto>. |
1376 | 1335 | ||
1377 | To compile this driver as a module, choose M here and read | 1336 | To compile this driver as a module, choose M here. The module |
1378 | <file:Documentation/networking/net-modules.txt>. The module will be | 1337 | will be called apricot. |
1379 | called apricot. | ||
1380 | 1338 | ||
1381 | config B44 | 1339 | config B44 |
1382 | tristate "Broadcom 440x/47xx ethernet support" | 1340 | tristate "Broadcom 440x/47xx ethernet support" |
@@ -1388,9 +1346,8 @@ config B44 | |||
1388 | or M and read the Ethernet-HOWTO, available from | 1346 | or M and read the Ethernet-HOWTO, available from |
1389 | <http://www.tldp.org/docs.html#howto>. | 1347 | <http://www.tldp.org/docs.html#howto>. |
1390 | 1348 | ||
1391 | To compile this driver as a module, choose M here and read | 1349 | To compile this driver as a module, choose M here. The module |
1392 | <file:Documentation/networking/net-modules.txt>. The module will be | 1350 | will be called b44. |
1393 | called b44. | ||
1394 | 1351 | ||
1395 | # Auto-select SSB PCI-HOST support, if possible | 1352 | # Auto-select SSB PCI-HOST support, if possible |
1396 | config B44_PCI_AUTOSELECT | 1353 | config B44_PCI_AUTOSELECT |
@@ -1419,9 +1376,8 @@ config FORCEDETH | |||
1419 | read the Ethernet-HOWTO, available from | 1376 | read the Ethernet-HOWTO, available from |
1420 | <http://www.tldp.org/docs.html#howto>. | 1377 | <http://www.tldp.org/docs.html#howto>. |
1421 | 1378 | ||
1422 | To compile this driver as a module, choose M here and read | 1379 | To compile this driver as a module, choose M here. The module |
1423 | <file:Documentation/networking/net-modules.txt>. The module will be | 1380 | will be called forcedeth. |
1424 | called forcedeth. | ||
1425 | 1381 | ||
1426 | config FORCEDETH_NAPI | 1382 | config FORCEDETH_NAPI |
1427 | bool "Use Rx Polling (NAPI) (EXPERIMENTAL)" | 1383 | bool "Use Rx Polling (NAPI) (EXPERIMENTAL)" |
@@ -1447,9 +1403,8 @@ config CS89x0 | |||
1447 | <http://www.tldp.org/docs.html#howto> as well as | 1403 | <http://www.tldp.org/docs.html#howto> as well as |
1448 | <file:Documentation/networking/cs89x0.txt>. | 1404 | <file:Documentation/networking/cs89x0.txt>. |
1449 | 1405 | ||
1450 | To compile this driver as a module, choose M here and read | 1406 | To compile this driver as a module, choose M here. The module |
1451 | <file:Documentation/networking/net-modules.txt>. The module will be | 1407 | will be called cs89x0. |
1452 | called cs89x0. | ||
1453 | 1408 | ||
1454 | config TC35815 | 1409 | config TC35815 |
1455 | tristate "TOSHIBA TC35815 Ethernet support" | 1410 | tristate "TOSHIBA TC35815 Ethernet support" |
@@ -1465,8 +1420,7 @@ config EEPRO100 | |||
1465 | card, say Y and read the Ethernet-HOWTO, available from | 1420 | card, say Y and read the Ethernet-HOWTO, available from |
1466 | <http://www.tldp.org/docs.html#howto>. | 1421 | <http://www.tldp.org/docs.html#howto>. |
1467 | 1422 | ||
1468 | To compile this driver as a module, choose M here and read | 1423 | To compile this driver as a module, choose M here. The module |
1469 | <file:Documentation/networking/net-modules.txt>. The module | ||
1470 | will be called eepro100. | 1424 | will be called eepro100. |
1471 | 1425 | ||
1472 | 1426 | ||
@@ -1493,8 +1447,7 @@ config E100 | |||
1493 | More specific information on configuring the driver is in | 1447 | More specific information on configuring the driver is in |
1494 | <file:Documentation/networking/e100.txt>. | 1448 | <file:Documentation/networking/e100.txt>. |
1495 | 1449 | ||
1496 | To compile this driver as a module, choose M here and read | 1450 | To compile this driver as a module, choose M here. The module |
1497 | <file:Documentation/networking/net-modules.txt>. The module | ||
1498 | will be called e100. | 1451 | will be called e100. |
1499 | 1452 | ||
1500 | config LNE390 | 1453 | config LNE390 |
@@ -1506,8 +1459,7 @@ config LNE390 | |||
1506 | the Ethernet-HOWTO, available from | 1459 | the Ethernet-HOWTO, available from |
1507 | <http://www.tldp.org/docs.html#howto>. | 1460 | <http://www.tldp.org/docs.html#howto>. |
1508 | 1461 | ||
1509 | To compile this driver as a module, choose M here and read | 1462 | To compile this driver as a module, choose M here. The module |
1510 | <file:Documentation/networking/net-modules.txt>. The module | ||
1511 | will be called lne390. | 1463 | will be called lne390. |
1512 | 1464 | ||
1513 | config FEALNX | 1465 | config FEALNX |
@@ -1547,8 +1499,7 @@ config NE2K_PCI | |||
1547 | NetVin NV5000SC Via 86C926 SureCom NE34 Winbond | 1499 | NetVin NV5000SC Via 86C926 SureCom NE34 Winbond |
1548 | Holtek HT80232 Holtek HT80229 | 1500 | Holtek HT80232 Holtek HT80229 |
1549 | 1501 | ||
1550 | To compile this driver as a module, choose M here and read | 1502 | To compile this driver as a module, choose M here. The module |
1551 | <file:Documentation/networking/net-modules.txt>. The module | ||
1552 | will be called ne2k-pci. | 1503 | will be called ne2k-pci. |
1553 | 1504 | ||
1554 | config NE3210 | 1505 | config NE3210 |
@@ -1561,8 +1512,7 @@ config NE3210 | |||
1561 | <http://www.tldp.org/docs.html#howto>. Note that this driver | 1512 | <http://www.tldp.org/docs.html#howto>. Note that this driver |
1562 | will NOT WORK for NE3200 cards as they are completely different. | 1513 | will NOT WORK for NE3200 cards as they are completely different. |
1563 | 1514 | ||
1564 | To compile this driver as a module, choose M here and read | 1515 | To compile this driver as a module, choose M here. The module |
1565 | <file:Documentation/networking/net-modules.txt>. The module | ||
1566 | will be called ne3210. | 1516 | will be called ne3210. |
1567 | 1517 | ||
1568 | config ES3210 | 1518 | config ES3210 |
@@ -1574,8 +1524,7 @@ config ES3210 | |||
1574 | the Ethernet-HOWTO, available from | 1524 | the Ethernet-HOWTO, available from |
1575 | <http://www.tldp.org/docs.html#howto>. | 1525 | <http://www.tldp.org/docs.html#howto>. |
1576 | 1526 | ||
1577 | To compile this driver as a module, choose M here and read | 1527 | To compile this driver as a module, choose M here. The module |
1578 | <file:Documentation/networking/net-modules.txt>. The module | ||
1579 | will be called es3210. | 1528 | will be called es3210. |
1580 | 1529 | ||
1581 | config 8139CP | 1530 | config 8139CP |
@@ -1705,8 +1654,7 @@ config TLAN | |||
1705 | Compaq NetFlex and Olicom cards. Please read the file | 1654 | Compaq NetFlex and Olicom cards. Please read the file |
1706 | <file:Documentation/networking/tlan.txt> for more details. | 1655 | <file:Documentation/networking/tlan.txt> for more details. |
1707 | 1656 | ||
1708 | To compile this driver as a module, choose M here and read | 1657 | To compile this driver as a module, choose M here. The module |
1709 | <file:Documentation/networking/net-modules.txt>. The module | ||
1710 | will be called tlan. | 1658 | will be called tlan. |
1711 | 1659 | ||
1712 | Please email feedback to <torben.mathiasen@compaq.com>. | 1660 | Please email feedback to <torben.mathiasen@compaq.com>. |
@@ -1996,8 +1944,7 @@ config E1000 | |||
1996 | More specific information on configuring the driver is in | 1944 | More specific information on configuring the driver is in |
1997 | <file:Documentation/networking/e1000.txt>. | 1945 | <file:Documentation/networking/e1000.txt>. |
1998 | 1946 | ||
1999 | To compile this driver as a module, choose M here and read | 1947 | To compile this driver as a module, choose M here. The module |
2000 | <file:Documentation/networking/net-modules.txt>. The module | ||
2001 | will be called e1000. | 1948 | will be called e1000. |
2002 | 1949 | ||
2003 | config E1000_NAPI | 1950 | config E1000_NAPI |
@@ -2042,8 +1989,7 @@ config E1000E | |||
2042 | More specific information on configuring the driver is in | 1989 | More specific information on configuring the driver is in |
2043 | <file:Documentation/networking/e1000e.txt>. | 1990 | <file:Documentation/networking/e1000e.txt>. |
2044 | 1991 | ||
2045 | To compile this driver as a module, choose M here and read | 1992 | To compile this driver as a module, choose M here. The module |
2046 | <file:Documentation/networking/net-modules.txt>. The module | ||
2047 | will be called e1000e. | 1993 | will be called e1000e. |
2048 | 1994 | ||
2049 | source "drivers/net/ixp2000/Kconfig" | 1995 | source "drivers/net/ixp2000/Kconfig" |
@@ -2076,8 +2022,7 @@ config HAMACHI | |||
2076 | the Ethernet-HOWTO, available from | 2022 | the Ethernet-HOWTO, available from |
2077 | <http://www.tldp.org/docs.html#howto>. | 2023 | <http://www.tldp.org/docs.html#howto>. |
2078 | 2024 | ||
2079 | To compile this driver as a module, choose M here and read | 2025 | To compile this driver as a module, choose M here. The module will be |
2080 | <file:Documentation/networking/net-modules.txt>. The module will be | ||
2081 | called hamachi. | 2026 | called hamachi. |
2082 | 2027 | ||
2083 | config YELLOWFIN | 2028 | config YELLOWFIN |
@@ -2526,8 +2471,7 @@ config IXGBE | |||
2526 | More specific information on configuring the driver is in | 2471 | More specific information on configuring the driver is in |
2527 | <file:Documentation/networking/ixgbe.txt>. | 2472 | <file:Documentation/networking/ixgbe.txt>. |
2528 | 2473 | ||
2529 | To compile this driver as a module, choose M here and read | 2474 | To compile this driver as a module, choose M here. The module |
2530 | <file:Documentation/networking/net-modules.txt>. The module | ||
2531 | will be called ixgbe. | 2475 | will be called ixgbe. |
2532 | 2476 | ||
2533 | config IXGB | 2477 | config IXGB |
@@ -2549,8 +2493,7 @@ config IXGB | |||
2549 | More specific information on configuring the driver is in | 2493 | More specific information on configuring the driver is in |
2550 | <file:Documentation/networking/ixgb.txt>. | 2494 | <file:Documentation/networking/ixgb.txt>. |
2551 | 2495 | ||
2552 | To compile this driver as a module, choose M here and read | 2496 | To compile this driver as a module, choose M here. The module |
2553 | <file:Documentation/networking/net-modules.txt>. The module | ||
2554 | will be called ixgb. | 2497 | will be called ixgb. |
2555 | 2498 | ||
2556 | config IXGB_NAPI | 2499 | config IXGB_NAPI |
@@ -2603,8 +2546,7 @@ config MYRI10GE | |||
2603 | 2546 | ||
2604 | <http://www.myri.com/scs/download-Myri10GE.html> | 2547 | <http://www.myri.com/scs/download-Myri10GE.html> |
2605 | 2548 | ||
2606 | To compile this driver as a module, choose M here and read | 2549 | To compile this driver as a module, choose M here. The module |
2607 | <file:Documentation/networking/net-modules.txt>. The module | ||
2608 | will be called myri10ge. | 2550 | will be called myri10ge. |
2609 | 2551 | ||
2610 | config NETXEN_NIC | 2552 | config NETXEN_NIC |
@@ -2828,10 +2770,9 @@ config PLIP | |||
2828 | with the PLIP support in Linux versions 1.0.x. This option enlarges | 2770 | with the PLIP support in Linux versions 1.0.x. This option enlarges |
2829 | your kernel by about 8 KB. | 2771 | your kernel by about 8 KB. |
2830 | 2772 | ||
2831 | To compile this driver as a module, choose M here and read | 2773 | To compile this driver as a module, choose M here. The module |
2832 | <file:Documentation/networking/net-modules.txt>. The module will be | 2774 | will be called plip. If unsure, say Y or M, in case you buy |
2833 | called plip. If unsure, say Y or M, in case you buy a laptop | 2775 | a laptop later. |
2834 | later. | ||
2835 | 2776 | ||
2836 | config PPP | 2777 | config PPP |
2837 | tristate "PPP (point-to-point protocol) support" | 2778 | tristate "PPP (point-to-point protocol) support" |
@@ -2861,8 +2802,7 @@ config PPP | |||
2861 | If you said Y to "Version information on all symbols" above, then | 2802 | If you said Y to "Version information on all symbols" above, then |
2862 | you cannot compile the PPP driver into the kernel; you can then only | 2803 | you cannot compile the PPP driver into the kernel; you can then only |
2863 | compile it as a module. To compile this driver as a module, choose M | 2804 | compile it as a module. To compile this driver as a module, choose M |
2864 | here and read <file:Documentation/networking/net-modules.txt>. | 2805 | here. The module will be called ppp_generic. |
2865 | The module will be called ppp_generic. | ||
2866 | 2806 | ||
2867 | config PPP_MULTILINK | 2807 | config PPP_MULTILINK |
2868 | bool "PPP multilink support (EXPERIMENTAL)" | 2808 | bool "PPP multilink support (EXPERIMENTAL)" |
@@ -3023,9 +2963,8 @@ config SLIP | |||
3023 | <http://www.bart.nl/~patrickr/term-howto/Term-HOWTO.html>). SLIP | 2963 | <http://www.bart.nl/~patrickr/term-howto/Term-HOWTO.html>). SLIP |
3024 | support will enlarge your kernel by about 4 KB. If unsure, say N. | 2964 | support will enlarge your kernel by about 4 KB. If unsure, say N. |
3025 | 2965 | ||
3026 | To compile this driver as a module, choose M here and read | 2966 | To compile this driver as a module, choose M here. The module |
3027 | <file:Documentation/networking/net-modules.txt>. The module will be | 2967 | will be called slip. |
3028 | called slip. | ||
3029 | 2968 | ||
3030 | config SLIP_COMPRESSED | 2969 | config SLIP_COMPRESSED |
3031 | bool "CSLIP compressed headers" | 2970 | bool "CSLIP compressed headers" |
diff --git a/drivers/net/arcnet/Kconfig b/drivers/net/arcnet/Kconfig index 4030274fe788..3b2f7f115464 100644 --- a/drivers/net/arcnet/Kconfig +++ b/drivers/net/arcnet/Kconfig | |||
@@ -19,8 +19,7 @@ menuconfig ARCNET | |||
19 | from <http://www.tldp.org/docs.html#howto>(even though ARCnet | 19 | from <http://www.tldp.org/docs.html#howto>(even though ARCnet |
20 | is not really Ethernet). | 20 | is not really Ethernet). |
21 | 21 | ||
22 | To compile this driver as a module, choose M here and read | 22 | To compile this driver as a module, choose M here. The module will |
23 | <file:Documentation/networking/net-modules.txt>. The module will | ||
24 | be called arcnet. | 23 | be called arcnet. |
25 | 24 | ||
26 | if ARCNET | 25 | if ARCNET |
@@ -81,8 +80,7 @@ config ARCNET_COM90xx | |||
81 | have always used the old ARCnet driver without knowing what type of | 80 | have always used the old ARCnet driver without knowing what type of |
82 | card you had, this is probably the one for you. | 81 | card you had, this is probably the one for you. |
83 | 82 | ||
84 | To compile this driver as a module, choose M here and read | 83 | To compile this driver as a module, choose M here. The module will |
85 | <file:Documentation/networking/net-modules.txt>. The module will | ||
86 | be called com90xx. | 84 | be called com90xx. |
87 | 85 | ||
88 | config ARCNET_COM90xxIO | 86 | config ARCNET_COM90xxIO |
@@ -93,8 +91,7 @@ config ARCNET_COM90xxIO | |||
93 | the normal driver. Only use it if your card doesn't support shared | 91 | the normal driver. Only use it if your card doesn't support shared |
94 | memory. | 92 | memory. |
95 | 93 | ||
96 | To compile this driver as a module, choose M here and read | 94 | To compile this driver as a module, choose M here. The module will |
97 | <file:Documentation/networking/net-modules.txt>. The module will | ||
98 | be called com90io. | 95 | be called com90io. |
99 | 96 | ||
100 | config ARCNET_RIM_I | 97 | config ARCNET_RIM_I |
@@ -105,8 +102,7 @@ config ARCNET_RIM_I | |||
105 | driver is completely untested, so if you have one of these cards, | 102 | driver is completely untested, so if you have one of these cards, |
106 | please mail <dwmw2@infradead.org>, especially if it works! | 103 | please mail <dwmw2@infradead.org>, especially if it works! |
107 | 104 | ||
108 | To compile this driver as a module, choose M here and read | 105 | To compile this driver as a module, choose M here. The module will |
109 | <file:Documentation/networking/net-modules.txt>. The module will | ||
110 | be called arc-rimi. | 106 | be called arc-rimi. |
111 | 107 | ||
112 | config ARCNET_COM20020 | 108 | config ARCNET_COM20020 |
@@ -116,8 +112,7 @@ config ARCNET_COM20020 | |||
116 | things as promiscuous mode, so packet sniffing is possible, and | 112 | things as promiscuous mode, so packet sniffing is possible, and |
117 | extra diagnostic information. | 113 | extra diagnostic information. |
118 | 114 | ||
119 | To compile this driver as a module, choose M here and read | 115 | To compile this driver as a module, choose M here. The module will |
120 | <file:Documentation/networking/net-modules.txt>. The module will | ||
121 | be called com20020. | 116 | be called com20020. |
122 | 117 | ||
123 | config ARCNET_COM20020_ISA | 118 | config ARCNET_COM20020_ISA |
diff --git a/drivers/net/loopback.c b/drivers/net/loopback.c index 45f30a2974b8..662b8d16803c 100644 --- a/drivers/net/loopback.c +++ b/drivers/net/loopback.c | |||
@@ -284,7 +284,7 @@ static __net_exit void loopback_net_exit(struct net *net) | |||
284 | unregister_netdev(dev); | 284 | unregister_netdev(dev); |
285 | } | 285 | } |
286 | 286 | ||
287 | static struct pernet_operations loopback_net_ops = { | 287 | static struct pernet_operations __net_initdata loopback_net_ops = { |
288 | .init = loopback_net_init, | 288 | .init = loopback_net_init, |
289 | .exit = loopback_net_exit, | 289 | .exit = loopback_net_exit, |
290 | }; | 290 | }; |
diff --git a/drivers/net/myri_sbus.c b/drivers/net/myri_sbus.c index 8d29319cc5cb..656a260fc956 100644 --- a/drivers/net/myri_sbus.c +++ b/drivers/net/myri_sbus.c | |||
@@ -134,7 +134,7 @@ static int myri_do_handshake(struct myri_eth *mp) | |||
134 | 134 | ||
135 | myri_disable_irq(mp->lregs, cregs); | 135 | myri_disable_irq(mp->lregs, cregs); |
136 | 136 | ||
137 | while (tick++ <= 25) { | 137 | while (tick++ < 25) { |
138 | u32 softstate; | 138 | u32 softstate; |
139 | 139 | ||
140 | /* Wake it up. */ | 140 | /* Wake it up. */ |
diff --git a/drivers/net/ppp_async.c b/drivers/net/ppp_async.c index 8d278c87ba48..f023d5b67e6e 100644 --- a/drivers/net/ppp_async.c +++ b/drivers/net/ppp_async.c | |||
@@ -160,7 +160,7 @@ ppp_asynctty_open(struct tty_struct *tty) | |||
160 | 160 | ||
161 | err = -ENOMEM; | 161 | err = -ENOMEM; |
162 | ap = kzalloc(sizeof(*ap), GFP_KERNEL); | 162 | ap = kzalloc(sizeof(*ap), GFP_KERNEL); |
163 | if (ap == 0) | 163 | if (!ap) |
164 | goto out; | 164 | goto out; |
165 | 165 | ||
166 | /* initialize the asyncppp structure */ | 166 | /* initialize the asyncppp structure */ |
@@ -215,7 +215,7 @@ ppp_asynctty_close(struct tty_struct *tty) | |||
215 | ap = tty->disc_data; | 215 | ap = tty->disc_data; |
216 | tty->disc_data = NULL; | 216 | tty->disc_data = NULL; |
217 | write_unlock_irq(&disc_data_lock); | 217 | write_unlock_irq(&disc_data_lock); |
218 | if (ap == 0) | 218 | if (!ap) |
219 | return; | 219 | return; |
220 | 220 | ||
221 | /* | 221 | /* |
@@ -230,10 +230,10 @@ ppp_asynctty_close(struct tty_struct *tty) | |||
230 | tasklet_kill(&ap->tsk); | 230 | tasklet_kill(&ap->tsk); |
231 | 231 | ||
232 | ppp_unregister_channel(&ap->chan); | 232 | ppp_unregister_channel(&ap->chan); |
233 | if (ap->rpkt != 0) | 233 | if (ap->rpkt) |
234 | kfree_skb(ap->rpkt); | 234 | kfree_skb(ap->rpkt); |
235 | skb_queue_purge(&ap->rqueue); | 235 | skb_queue_purge(&ap->rqueue); |
236 | if (ap->tpkt != 0) | 236 | if (ap->tpkt) |
237 | kfree_skb(ap->tpkt); | 237 | kfree_skb(ap->tpkt); |
238 | kfree(ap); | 238 | kfree(ap); |
239 | } | 239 | } |
@@ -285,13 +285,13 @@ ppp_asynctty_ioctl(struct tty_struct *tty, struct file *file, | |||
285 | int err, val; | 285 | int err, val; |
286 | int __user *p = (int __user *)arg; | 286 | int __user *p = (int __user *)arg; |
287 | 287 | ||
288 | if (ap == 0) | 288 | if (!ap) |
289 | return -ENXIO; | 289 | return -ENXIO; |
290 | err = -EFAULT; | 290 | err = -EFAULT; |
291 | switch (cmd) { | 291 | switch (cmd) { |
292 | case PPPIOCGCHAN: | 292 | case PPPIOCGCHAN: |
293 | err = -ENXIO; | 293 | err = -ENXIO; |
294 | if (ap == 0) | 294 | if (!ap) |
295 | break; | 295 | break; |
296 | err = -EFAULT; | 296 | err = -EFAULT; |
297 | if (put_user(ppp_channel_index(&ap->chan), p)) | 297 | if (put_user(ppp_channel_index(&ap->chan), p)) |
@@ -301,7 +301,7 @@ ppp_asynctty_ioctl(struct tty_struct *tty, struct file *file, | |||
301 | 301 | ||
302 | case PPPIOCGUNIT: | 302 | case PPPIOCGUNIT: |
303 | err = -ENXIO; | 303 | err = -ENXIO; |
304 | if (ap == 0) | 304 | if (!ap) |
305 | break; | 305 | break; |
306 | err = -EFAULT; | 306 | err = -EFAULT; |
307 | if (put_user(ppp_unit_number(&ap->chan), p)) | 307 | if (put_user(ppp_unit_number(&ap->chan), p)) |
@@ -350,7 +350,7 @@ ppp_asynctty_receive(struct tty_struct *tty, const unsigned char *buf, | |||
350 | struct asyncppp *ap = ap_get(tty); | 350 | struct asyncppp *ap = ap_get(tty); |
351 | unsigned long flags; | 351 | unsigned long flags; |
352 | 352 | ||
353 | if (ap == 0) | 353 | if (!ap) |
354 | return; | 354 | return; |
355 | spin_lock_irqsave(&ap->recv_lock, flags); | 355 | spin_lock_irqsave(&ap->recv_lock, flags); |
356 | ppp_async_input(ap, buf, cflags, count); | 356 | ppp_async_input(ap, buf, cflags, count); |
@@ -369,7 +369,7 @@ ppp_asynctty_wakeup(struct tty_struct *tty) | |||
369 | struct asyncppp *ap = ap_get(tty); | 369 | struct asyncppp *ap = ap_get(tty); |
370 | 370 | ||
371 | clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); | 371 | clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); |
372 | if (ap == 0) | 372 | if (!ap) |
373 | return; | 373 | return; |
374 | set_bit(XMIT_WAKEUP, &ap->xmit_flags); | 374 | set_bit(XMIT_WAKEUP, &ap->xmit_flags); |
375 | tasklet_schedule(&ap->tsk); | 375 | tasklet_schedule(&ap->tsk); |
@@ -684,7 +684,7 @@ ppp_async_push(struct asyncppp *ap) | |||
684 | tty_stuffed = 1; | 684 | tty_stuffed = 1; |
685 | continue; | 685 | continue; |
686 | } | 686 | } |
687 | if (ap->optr >= ap->olim && ap->tpkt != 0) { | 687 | if (ap->optr >= ap->olim && ap->tpkt) { |
688 | if (ppp_async_encode(ap)) { | 688 | if (ppp_async_encode(ap)) { |
689 | /* finished processing ap->tpkt */ | 689 | /* finished processing ap->tpkt */ |
690 | clear_bit(XMIT_FULL, &ap->xmit_flags); | 690 | clear_bit(XMIT_FULL, &ap->xmit_flags); |
@@ -704,7 +704,7 @@ ppp_async_push(struct asyncppp *ap) | |||
704 | clear_bit(XMIT_BUSY, &ap->xmit_flags); | 704 | clear_bit(XMIT_BUSY, &ap->xmit_flags); |
705 | /* any more work to do? if not, exit the loop */ | 705 | /* any more work to do? if not, exit the loop */ |
706 | if (!(test_bit(XMIT_WAKEUP, &ap->xmit_flags) | 706 | if (!(test_bit(XMIT_WAKEUP, &ap->xmit_flags) |
707 | || (!tty_stuffed && ap->tpkt != 0))) | 707 | || (!tty_stuffed && ap->tpkt))) |
708 | break; | 708 | break; |
709 | /* more work to do, see if we can do it now */ | 709 | /* more work to do, see if we can do it now */ |
710 | if (test_and_set_bit(XMIT_BUSY, &ap->xmit_flags)) | 710 | if (test_and_set_bit(XMIT_BUSY, &ap->xmit_flags)) |
@@ -715,7 +715,7 @@ ppp_async_push(struct asyncppp *ap) | |||
715 | 715 | ||
716 | flush: | 716 | flush: |
717 | clear_bit(XMIT_BUSY, &ap->xmit_flags); | 717 | clear_bit(XMIT_BUSY, &ap->xmit_flags); |
718 | if (ap->tpkt != 0) { | 718 | if (ap->tpkt) { |
719 | kfree_skb(ap->tpkt); | 719 | kfree_skb(ap->tpkt); |
720 | ap->tpkt = NULL; | 720 | ap->tpkt = NULL; |
721 | clear_bit(XMIT_FULL, &ap->xmit_flags); | 721 | clear_bit(XMIT_FULL, &ap->xmit_flags); |
@@ -848,7 +848,7 @@ ppp_async_input(struct asyncppp *ap, const unsigned char *buf, | |||
848 | s = 0; | 848 | s = 0; |
849 | for (i = 0; i < count; ++i) { | 849 | for (i = 0; i < count; ++i) { |
850 | c = buf[i]; | 850 | c = buf[i]; |
851 | if (flags != 0 && flags[i] != 0) | 851 | if (flags && flags[i] != 0) |
852 | continue; | 852 | continue; |
853 | s |= (c & 0x80)? SC_RCV_B7_1: SC_RCV_B7_0; | 853 | s |= (c & 0x80)? SC_RCV_B7_1: SC_RCV_B7_0; |
854 | c = ((c >> 4) ^ c) & 0xf; | 854 | c = ((c >> 4) ^ c) & 0xf; |
@@ -865,7 +865,7 @@ ppp_async_input(struct asyncppp *ap, const unsigned char *buf, | |||
865 | n = scan_ordinary(ap, buf, count); | 865 | n = scan_ordinary(ap, buf, count); |
866 | 866 | ||
867 | f = 0; | 867 | f = 0; |
868 | if (flags != 0 && (ap->state & SC_TOSS) == 0) { | 868 | if (flags && (ap->state & SC_TOSS) == 0) { |
869 | /* check the flags to see if any char had an error */ | 869 | /* check the flags to see if any char had an error */ |
870 | for (j = 0; j < n; ++j) | 870 | for (j = 0; j < n; ++j) |
871 | if ((f = flags[j]) != 0) | 871 | if ((f = flags[j]) != 0) |
@@ -878,9 +878,9 @@ ppp_async_input(struct asyncppp *ap, const unsigned char *buf, | |||
878 | } else if (n > 0 && (ap->state & SC_TOSS) == 0) { | 878 | } else if (n > 0 && (ap->state & SC_TOSS) == 0) { |
879 | /* stuff the chars in the skb */ | 879 | /* stuff the chars in the skb */ |
880 | skb = ap->rpkt; | 880 | skb = ap->rpkt; |
881 | if (skb == 0) { | 881 | if (!skb) { |
882 | skb = dev_alloc_skb(ap->mru + PPP_HDRLEN + 2); | 882 | skb = dev_alloc_skb(ap->mru + PPP_HDRLEN + 2); |
883 | if (skb == 0) | 883 | if (!skb) |
884 | goto nomem; | 884 | goto nomem; |
885 | ap->rpkt = skb; | 885 | ap->rpkt = skb; |
886 | } | 886 | } |
@@ -927,7 +927,7 @@ ppp_async_input(struct asyncppp *ap, const unsigned char *buf, | |||
927 | ++n; | 927 | ++n; |
928 | 928 | ||
929 | buf += n; | 929 | buf += n; |
930 | if (flags != 0) | 930 | if (flags) |
931 | flags += n; | 931 | flags += n; |
932 | count -= n; | 932 | count -= n; |
933 | } | 933 | } |
diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c index 4b49d0e8c7eb..4f690378bb77 100644 --- a/drivers/net/ppp_generic.c +++ b/drivers/net/ppp_generic.c | |||
@@ -367,7 +367,7 @@ static int ppp_release(struct inode *inode, struct file *file) | |||
367 | struct ppp_file *pf = file->private_data; | 367 | struct ppp_file *pf = file->private_data; |
368 | struct ppp *ppp; | 368 | struct ppp *ppp; |
369 | 369 | ||
370 | if (pf != 0) { | 370 | if (pf) { |
371 | file->private_data = NULL; | 371 | file->private_data = NULL; |
372 | if (pf->kind == INTERFACE) { | 372 | if (pf->kind == INTERFACE) { |
373 | ppp = PF_TO_PPP(pf); | 373 | ppp = PF_TO_PPP(pf); |
@@ -398,7 +398,7 @@ static ssize_t ppp_read(struct file *file, char __user *buf, | |||
398 | 398 | ||
399 | ret = count; | 399 | ret = count; |
400 | 400 | ||
401 | if (pf == 0) | 401 | if (!pf) |
402 | return -ENXIO; | 402 | return -ENXIO; |
403 | add_wait_queue(&pf->rwait, &wait); | 403 | add_wait_queue(&pf->rwait, &wait); |
404 | for (;;) { | 404 | for (;;) { |
@@ -431,7 +431,7 @@ static ssize_t ppp_read(struct file *file, char __user *buf, | |||
431 | set_current_state(TASK_RUNNING); | 431 | set_current_state(TASK_RUNNING); |
432 | remove_wait_queue(&pf->rwait, &wait); | 432 | remove_wait_queue(&pf->rwait, &wait); |
433 | 433 | ||
434 | if (skb == 0) | 434 | if (!skb) |
435 | goto out; | 435 | goto out; |
436 | 436 | ||
437 | ret = -EOVERFLOW; | 437 | ret = -EOVERFLOW; |
@@ -455,11 +455,11 @@ static ssize_t ppp_write(struct file *file, const char __user *buf, | |||
455 | struct sk_buff *skb; | 455 | struct sk_buff *skb; |
456 | ssize_t ret; | 456 | ssize_t ret; |
457 | 457 | ||
458 | if (pf == 0) | 458 | if (!pf) |
459 | return -ENXIO; | 459 | return -ENXIO; |
460 | ret = -ENOMEM; | 460 | ret = -ENOMEM; |
461 | skb = alloc_skb(count + pf->hdrlen, GFP_KERNEL); | 461 | skb = alloc_skb(count + pf->hdrlen, GFP_KERNEL); |
462 | if (skb == 0) | 462 | if (!skb) |
463 | goto out; | 463 | goto out; |
464 | skb_reserve(skb, pf->hdrlen); | 464 | skb_reserve(skb, pf->hdrlen); |
465 | ret = -EFAULT; | 465 | ret = -EFAULT; |
@@ -491,11 +491,11 @@ static unsigned int ppp_poll(struct file *file, poll_table *wait) | |||
491 | struct ppp_file *pf = file->private_data; | 491 | struct ppp_file *pf = file->private_data; |
492 | unsigned int mask; | 492 | unsigned int mask; |
493 | 493 | ||
494 | if (pf == 0) | 494 | if (!pf) |
495 | return 0; | 495 | return 0; |
496 | poll_wait(file, &pf->rwait, wait); | 496 | poll_wait(file, &pf->rwait, wait); |
497 | mask = POLLOUT | POLLWRNORM; | 497 | mask = POLLOUT | POLLWRNORM; |
498 | if (skb_peek(&pf->rq) != 0) | 498 | if (skb_peek(&pf->rq)) |
499 | mask |= POLLIN | POLLRDNORM; | 499 | mask |= POLLIN | POLLRDNORM; |
500 | if (pf->dead) | 500 | if (pf->dead) |
501 | mask |= POLLHUP; | 501 | mask |= POLLHUP; |
@@ -559,7 +559,7 @@ static int ppp_ioctl(struct inode *inode, struct file *file, | |||
559 | void __user *argp = (void __user *)arg; | 559 | void __user *argp = (void __user *)arg; |
560 | int __user *p = argp; | 560 | int __user *p = argp; |
561 | 561 | ||
562 | if (pf == 0) | 562 | if (!pf) |
563 | return ppp_unattached_ioctl(pf, file, cmd, arg); | 563 | return ppp_unattached_ioctl(pf, file, cmd, arg); |
564 | 564 | ||
565 | if (cmd == PPPIOCDETACH) { | 565 | if (cmd == PPPIOCDETACH) { |
@@ -689,13 +689,13 @@ static int ppp_ioctl(struct inode *inode, struct file *file, | |||
689 | val &= 0xffff; | 689 | val &= 0xffff; |
690 | } | 690 | } |
691 | vj = slhc_init(val2+1, val+1); | 691 | vj = slhc_init(val2+1, val+1); |
692 | if (vj == 0) { | 692 | if (!vj) { |
693 | printk(KERN_ERR "PPP: no memory (VJ compressor)\n"); | 693 | printk(KERN_ERR "PPP: no memory (VJ compressor)\n"); |
694 | err = -ENOMEM; | 694 | err = -ENOMEM; |
695 | break; | 695 | break; |
696 | } | 696 | } |
697 | ppp_lock(ppp); | 697 | ppp_lock(ppp); |
698 | if (ppp->vj != 0) | 698 | if (ppp->vj) |
699 | slhc_free(ppp->vj); | 699 | slhc_free(ppp->vj); |
700 | ppp->vj = vj; | 700 | ppp->vj = vj; |
701 | ppp_unlock(ppp); | 701 | ppp_unlock(ppp); |
@@ -786,7 +786,7 @@ static int ppp_unattached_ioctl(struct ppp_file *pf, struct file *file, | |||
786 | if (get_user(unit, p)) | 786 | if (get_user(unit, p)) |
787 | break; | 787 | break; |
788 | ppp = ppp_create_interface(unit, &err); | 788 | ppp = ppp_create_interface(unit, &err); |
789 | if (ppp == 0) | 789 | if (!ppp) |
790 | break; | 790 | break; |
791 | file->private_data = &ppp->file; | 791 | file->private_data = &ppp->file; |
792 | ppp->owner = file; | 792 | ppp->owner = file; |
@@ -803,7 +803,7 @@ static int ppp_unattached_ioctl(struct ppp_file *pf, struct file *file, | |||
803 | mutex_lock(&all_ppp_mutex); | 803 | mutex_lock(&all_ppp_mutex); |
804 | err = -ENXIO; | 804 | err = -ENXIO; |
805 | ppp = ppp_find_unit(unit); | 805 | ppp = ppp_find_unit(unit); |
806 | if (ppp != 0) { | 806 | if (ppp) { |
807 | atomic_inc(&ppp->file.refcnt); | 807 | atomic_inc(&ppp->file.refcnt); |
808 | file->private_data = &ppp->file; | 808 | file->private_data = &ppp->file; |
809 | err = 0; | 809 | err = 0; |
@@ -817,7 +817,7 @@ static int ppp_unattached_ioctl(struct ppp_file *pf, struct file *file, | |||
817 | spin_lock_bh(&all_channels_lock); | 817 | spin_lock_bh(&all_channels_lock); |
818 | err = -ENXIO; | 818 | err = -ENXIO; |
819 | chan = ppp_find_channel(unit); | 819 | chan = ppp_find_channel(unit); |
820 | if (chan != 0) { | 820 | if (chan) { |
821 | atomic_inc(&chan->file.refcnt); | 821 | atomic_inc(&chan->file.refcnt); |
822 | file->private_data = &chan->file; | 822 | file->private_data = &chan->file; |
823 | err = 0; | 823 | err = 0; |
@@ -946,9 +946,9 @@ ppp_net_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) | |||
946 | 946 | ||
947 | case SIOCGPPPCSTATS: | 947 | case SIOCGPPPCSTATS: |
948 | memset(&cstats, 0, sizeof(cstats)); | 948 | memset(&cstats, 0, sizeof(cstats)); |
949 | if (ppp->xc_state != 0) | 949 | if (ppp->xc_state) |
950 | ppp->xcomp->comp_stat(ppp->xc_state, &cstats.c); | 950 | ppp->xcomp->comp_stat(ppp->xc_state, &cstats.c); |
951 | if (ppp->rc_state != 0) | 951 | if (ppp->rc_state) |
952 | ppp->rcomp->decomp_stat(ppp->rc_state, &cstats.d); | 952 | ppp->rcomp->decomp_stat(ppp->rc_state, &cstats.d); |
953 | if (copy_to_user(addr, &cstats, sizeof(cstats))) | 953 | if (copy_to_user(addr, &cstats, sizeof(cstats))) |
954 | break; | 954 | break; |
@@ -993,14 +993,14 @@ ppp_xmit_process(struct ppp *ppp) | |||
993 | struct sk_buff *skb; | 993 | struct sk_buff *skb; |
994 | 994 | ||
995 | ppp_xmit_lock(ppp); | 995 | ppp_xmit_lock(ppp); |
996 | if (ppp->dev != 0) { | 996 | if (ppp->dev) { |
997 | ppp_push(ppp); | 997 | ppp_push(ppp); |
998 | while (ppp->xmit_pending == 0 | 998 | while (!ppp->xmit_pending |
999 | && (skb = skb_dequeue(&ppp->file.xq)) != 0) | 999 | && (skb = skb_dequeue(&ppp->file.xq))) |
1000 | ppp_send_frame(ppp, skb); | 1000 | ppp_send_frame(ppp, skb); |
1001 | /* If there's no work left to do, tell the core net | 1001 | /* If there's no work left to do, tell the core net |
1002 | code that we can accept some more. */ | 1002 | code that we can accept some more. */ |
1003 | if (ppp->xmit_pending == 0 && skb_peek(&ppp->file.xq) == 0) | 1003 | if (!ppp->xmit_pending && !skb_peek(&ppp->file.xq)) |
1004 | netif_wake_queue(ppp->dev); | 1004 | netif_wake_queue(ppp->dev); |
1005 | } | 1005 | } |
1006 | ppp_xmit_unlock(ppp); | 1006 | ppp_xmit_unlock(ppp); |
@@ -1100,12 +1100,12 @@ ppp_send_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1100 | 1100 | ||
1101 | switch (proto) { | 1101 | switch (proto) { |
1102 | case PPP_IP: | 1102 | case PPP_IP: |
1103 | if (ppp->vj == 0 || (ppp->flags & SC_COMP_TCP) == 0) | 1103 | if (!ppp->vj || (ppp->flags & SC_COMP_TCP) == 0) |
1104 | break; | 1104 | break; |
1105 | /* try to do VJ TCP header compression */ | 1105 | /* try to do VJ TCP header compression */ |
1106 | new_skb = alloc_skb(skb->len + ppp->dev->hard_header_len - 2, | 1106 | new_skb = alloc_skb(skb->len + ppp->dev->hard_header_len - 2, |
1107 | GFP_ATOMIC); | 1107 | GFP_ATOMIC); |
1108 | if (new_skb == 0) { | 1108 | if (!new_skb) { |
1109 | printk(KERN_ERR "PPP: no memory (VJ comp pkt)\n"); | 1109 | printk(KERN_ERR "PPP: no memory (VJ comp pkt)\n"); |
1110 | goto drop; | 1110 | goto drop; |
1111 | } | 1111 | } |
@@ -1140,7 +1140,7 @@ ppp_send_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1140 | } | 1140 | } |
1141 | 1141 | ||
1142 | /* try to do packet compression */ | 1142 | /* try to do packet compression */ |
1143 | if ((ppp->xstate & SC_COMP_RUN) && ppp->xc_state != 0 | 1143 | if ((ppp->xstate & SC_COMP_RUN) && ppp->xc_state |
1144 | && proto != PPP_LCP && proto != PPP_CCP) { | 1144 | && proto != PPP_LCP && proto != PPP_CCP) { |
1145 | if (!(ppp->flags & SC_CCP_UP) && (ppp->flags & SC_MUST_COMP)) { | 1145 | if (!(ppp->flags & SC_CCP_UP) && (ppp->flags & SC_MUST_COMP)) { |
1146 | if (net_ratelimit()) | 1146 | if (net_ratelimit()) |
@@ -1185,7 +1185,7 @@ ppp_push(struct ppp *ppp) | |||
1185 | struct channel *pch; | 1185 | struct channel *pch; |
1186 | struct sk_buff *skb = ppp->xmit_pending; | 1186 | struct sk_buff *skb = ppp->xmit_pending; |
1187 | 1187 | ||
1188 | if (skb == 0) | 1188 | if (!skb) |
1189 | return; | 1189 | return; |
1190 | 1190 | ||
1191 | list = &ppp->channels; | 1191 | list = &ppp->channels; |
@@ -1355,7 +1355,7 @@ static int ppp_mp_explode(struct ppp *ppp, struct sk_buff *skb) | |||
1355 | if (flen == len && nfree == 0) | 1355 | if (flen == len && nfree == 0) |
1356 | bits |= E; | 1356 | bits |= E; |
1357 | frag = alloc_skb(flen + hdrlen + (flen == 0), GFP_ATOMIC); | 1357 | frag = alloc_skb(flen + hdrlen + (flen == 0), GFP_ATOMIC); |
1358 | if (frag == 0) | 1358 | if (!frag) |
1359 | goto noskb; | 1359 | goto noskb; |
1360 | q = skb_put(frag, flen + hdrlen); | 1360 | q = skb_put(frag, flen + hdrlen); |
1361 | 1361 | ||
@@ -1425,7 +1425,7 @@ ppp_channel_push(struct channel *pch) | |||
1425 | struct ppp *ppp; | 1425 | struct ppp *ppp; |
1426 | 1426 | ||
1427 | spin_lock_bh(&pch->downl); | 1427 | spin_lock_bh(&pch->downl); |
1428 | if (pch->chan != 0) { | 1428 | if (pch->chan) { |
1429 | while (!skb_queue_empty(&pch->file.xq)) { | 1429 | while (!skb_queue_empty(&pch->file.xq)) { |
1430 | skb = skb_dequeue(&pch->file.xq); | 1430 | skb = skb_dequeue(&pch->file.xq); |
1431 | if (!pch->chan->ops->start_xmit(pch->chan, skb)) { | 1431 | if (!pch->chan->ops->start_xmit(pch->chan, skb)) { |
@@ -1443,7 +1443,7 @@ ppp_channel_push(struct channel *pch) | |||
1443 | if (skb_queue_empty(&pch->file.xq)) { | 1443 | if (skb_queue_empty(&pch->file.xq)) { |
1444 | read_lock_bh(&pch->upl); | 1444 | read_lock_bh(&pch->upl); |
1445 | ppp = pch->ppp; | 1445 | ppp = pch->ppp; |
1446 | if (ppp != 0) | 1446 | if (ppp) |
1447 | ppp_xmit_process(ppp); | 1447 | ppp_xmit_process(ppp); |
1448 | read_unlock_bh(&pch->upl); | 1448 | read_unlock_bh(&pch->upl); |
1449 | } | 1449 | } |
@@ -1462,7 +1462,7 @@ ppp_do_recv(struct ppp *ppp, struct sk_buff *skb, struct channel *pch) | |||
1462 | { | 1462 | { |
1463 | ppp_recv_lock(ppp); | 1463 | ppp_recv_lock(ppp); |
1464 | /* ppp->dev == 0 means interface is closing down */ | 1464 | /* ppp->dev == 0 means interface is closing down */ |
1465 | if (ppp->dev != 0) | 1465 | if (ppp->dev) |
1466 | ppp_receive_frame(ppp, skb, pch); | 1466 | ppp_receive_frame(ppp, skb, pch); |
1467 | else | 1467 | else |
1468 | kfree_skb(skb); | 1468 | kfree_skb(skb); |
@@ -1475,19 +1475,19 @@ ppp_input(struct ppp_channel *chan, struct sk_buff *skb) | |||
1475 | struct channel *pch = chan->ppp; | 1475 | struct channel *pch = chan->ppp; |
1476 | int proto; | 1476 | int proto; |
1477 | 1477 | ||
1478 | if (pch == 0 || skb->len == 0) { | 1478 | if (!pch || skb->len == 0) { |
1479 | kfree_skb(skb); | 1479 | kfree_skb(skb); |
1480 | return; | 1480 | return; |
1481 | } | 1481 | } |
1482 | 1482 | ||
1483 | proto = PPP_PROTO(skb); | 1483 | proto = PPP_PROTO(skb); |
1484 | read_lock_bh(&pch->upl); | 1484 | read_lock_bh(&pch->upl); |
1485 | if (pch->ppp == 0 || proto >= 0xc000 || proto == PPP_CCPFRAG) { | 1485 | if (!pch->ppp || proto >= 0xc000 || proto == PPP_CCPFRAG) { |
1486 | /* put it on the channel queue */ | 1486 | /* put it on the channel queue */ |
1487 | skb_queue_tail(&pch->file.rq, skb); | 1487 | skb_queue_tail(&pch->file.rq, skb); |
1488 | /* drop old frames if queue too long */ | 1488 | /* drop old frames if queue too long */ |
1489 | while (pch->file.rq.qlen > PPP_MAX_RQLEN | 1489 | while (pch->file.rq.qlen > PPP_MAX_RQLEN |
1490 | && (skb = skb_dequeue(&pch->file.rq)) != 0) | 1490 | && (skb = skb_dequeue(&pch->file.rq))) |
1491 | kfree_skb(skb); | 1491 | kfree_skb(skb); |
1492 | wake_up_interruptible(&pch->file.rwait); | 1492 | wake_up_interruptible(&pch->file.rwait); |
1493 | } else { | 1493 | } else { |
@@ -1503,13 +1503,13 @@ ppp_input_error(struct ppp_channel *chan, int code) | |||
1503 | struct channel *pch = chan->ppp; | 1503 | struct channel *pch = chan->ppp; |
1504 | struct sk_buff *skb; | 1504 | struct sk_buff *skb; |
1505 | 1505 | ||
1506 | if (pch == 0) | 1506 | if (!pch) |
1507 | return; | 1507 | return; |
1508 | 1508 | ||
1509 | read_lock_bh(&pch->upl); | 1509 | read_lock_bh(&pch->upl); |
1510 | if (pch->ppp != 0) { | 1510 | if (pch->ppp) { |
1511 | skb = alloc_skb(0, GFP_ATOMIC); | 1511 | skb = alloc_skb(0, GFP_ATOMIC); |
1512 | if (skb != 0) { | 1512 | if (skb) { |
1513 | skb->len = 0; /* probably unnecessary */ | 1513 | skb->len = 0; /* probably unnecessary */ |
1514 | skb->cb[0] = code; | 1514 | skb->cb[0] = code; |
1515 | ppp_do_recv(pch->ppp, skb, pch); | 1515 | ppp_do_recv(pch->ppp, skb, pch); |
@@ -1548,7 +1548,7 @@ static void | |||
1548 | ppp_receive_error(struct ppp *ppp) | 1548 | ppp_receive_error(struct ppp *ppp) |
1549 | { | 1549 | { |
1550 | ++ppp->stats.rx_errors; | 1550 | ++ppp->stats.rx_errors; |
1551 | if (ppp->vj != 0) | 1551 | if (ppp->vj) |
1552 | slhc_toss(ppp->vj); | 1552 | slhc_toss(ppp->vj); |
1553 | } | 1553 | } |
1554 | 1554 | ||
@@ -1563,7 +1563,7 @@ ppp_receive_nonmp_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1563 | * Note that some decompressors need to see uncompressed frames | 1563 | * Note that some decompressors need to see uncompressed frames |
1564 | * that come in as well as compressed frames. | 1564 | * that come in as well as compressed frames. |
1565 | */ | 1565 | */ |
1566 | if (ppp->rc_state != 0 && (ppp->rstate & SC_DECOMP_RUN) | 1566 | if (ppp->rc_state && (ppp->rstate & SC_DECOMP_RUN) |
1567 | && (ppp->rstate & (SC_DC_FERROR | SC_DC_ERROR)) == 0) | 1567 | && (ppp->rstate & (SC_DC_FERROR | SC_DC_ERROR)) == 0) |
1568 | skb = ppp_decompress_frame(ppp, skb); | 1568 | skb = ppp_decompress_frame(ppp, skb); |
1569 | 1569 | ||
@@ -1574,13 +1574,13 @@ ppp_receive_nonmp_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1574 | switch (proto) { | 1574 | switch (proto) { |
1575 | case PPP_VJC_COMP: | 1575 | case PPP_VJC_COMP: |
1576 | /* decompress VJ compressed packets */ | 1576 | /* decompress VJ compressed packets */ |
1577 | if (ppp->vj == 0 || (ppp->flags & SC_REJ_COMP_TCP)) | 1577 | if (!ppp->vj || (ppp->flags & SC_REJ_COMP_TCP)) |
1578 | goto err; | 1578 | goto err; |
1579 | 1579 | ||
1580 | if (skb_tailroom(skb) < 124 || skb_cloned(skb)) { | 1580 | if (skb_tailroom(skb) < 124 || skb_cloned(skb)) { |
1581 | /* copy to a new sk_buff with more tailroom */ | 1581 | /* copy to a new sk_buff with more tailroom */ |
1582 | ns = dev_alloc_skb(skb->len + 128); | 1582 | ns = dev_alloc_skb(skb->len + 128); |
1583 | if (ns == 0) { | 1583 | if (!ns) { |
1584 | printk(KERN_ERR"PPP: no memory (VJ decomp)\n"); | 1584 | printk(KERN_ERR"PPP: no memory (VJ decomp)\n"); |
1585 | goto err; | 1585 | goto err; |
1586 | } | 1586 | } |
@@ -1606,7 +1606,7 @@ ppp_receive_nonmp_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1606 | break; | 1606 | break; |
1607 | 1607 | ||
1608 | case PPP_VJC_UNCOMP: | 1608 | case PPP_VJC_UNCOMP: |
1609 | if (ppp->vj == 0 || (ppp->flags & SC_REJ_COMP_TCP)) | 1609 | if (!ppp->vj || (ppp->flags & SC_REJ_COMP_TCP)) |
1610 | goto err; | 1610 | goto err; |
1611 | 1611 | ||
1612 | /* Until we fix the decompressor need to make sure | 1612 | /* Until we fix the decompressor need to make sure |
@@ -1636,7 +1636,7 @@ ppp_receive_nonmp_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1636 | skb_queue_tail(&ppp->file.rq, skb); | 1636 | skb_queue_tail(&ppp->file.rq, skb); |
1637 | /* limit queue length by dropping old frames */ | 1637 | /* limit queue length by dropping old frames */ |
1638 | while (ppp->file.rq.qlen > PPP_MAX_RQLEN | 1638 | while (ppp->file.rq.qlen > PPP_MAX_RQLEN |
1639 | && (skb = skb_dequeue(&ppp->file.rq)) != 0) | 1639 | && (skb = skb_dequeue(&ppp->file.rq))) |
1640 | kfree_skb(skb); | 1640 | kfree_skb(skb); |
1641 | /* wake up any process polling or blocking on read */ | 1641 | /* wake up any process polling or blocking on read */ |
1642 | wake_up_interruptible(&ppp->file.rwait); | 1642 | wake_up_interruptible(&ppp->file.rwait); |
@@ -1718,7 +1718,7 @@ ppp_decompress_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1718 | } | 1718 | } |
1719 | 1719 | ||
1720 | ns = dev_alloc_skb(obuff_size); | 1720 | ns = dev_alloc_skb(obuff_size); |
1721 | if (ns == 0) { | 1721 | if (!ns) { |
1722 | printk(KERN_ERR "ppp_decompress_frame: no memory\n"); | 1722 | printk(KERN_ERR "ppp_decompress_frame: no memory\n"); |
1723 | goto err; | 1723 | goto err; |
1724 | } | 1724 | } |
@@ -1836,7 +1836,7 @@ ppp_receive_mp_frame(struct ppp *ppp, struct sk_buff *skb, struct channel *pch) | |||
1836 | ppp->minseq = ppp->mrq.next->sequence; | 1836 | ppp->minseq = ppp->mrq.next->sequence; |
1837 | 1837 | ||
1838 | /* Pull completed packets off the queue and receive them. */ | 1838 | /* Pull completed packets off the queue and receive them. */ |
1839 | while ((skb = ppp_mp_reconstruct(ppp)) != 0) | 1839 | while ((skb = ppp_mp_reconstruct(ppp))) |
1840 | ppp_receive_nonmp_frame(ppp, skb); | 1840 | ppp_receive_nonmp_frame(ppp, skb); |
1841 | 1841 | ||
1842 | return; | 1842 | return; |
@@ -2002,7 +2002,7 @@ ppp_register_channel(struct ppp_channel *chan) | |||
2002 | struct channel *pch; | 2002 | struct channel *pch; |
2003 | 2003 | ||
2004 | pch = kzalloc(sizeof(struct channel), GFP_KERNEL); | 2004 | pch = kzalloc(sizeof(struct channel), GFP_KERNEL); |
2005 | if (pch == 0) | 2005 | if (!pch) |
2006 | return -ENOMEM; | 2006 | return -ENOMEM; |
2007 | pch->ppp = NULL; | 2007 | pch->ppp = NULL; |
2008 | pch->chan = chan; | 2008 | pch->chan = chan; |
@@ -2030,7 +2030,7 @@ int ppp_channel_index(struct ppp_channel *chan) | |||
2030 | { | 2030 | { |
2031 | struct channel *pch = chan->ppp; | 2031 | struct channel *pch = chan->ppp; |
2032 | 2032 | ||
2033 | if (pch != 0) | 2033 | if (pch) |
2034 | return pch->file.index; | 2034 | return pch->file.index; |
2035 | return -1; | 2035 | return -1; |
2036 | } | 2036 | } |
@@ -2043,9 +2043,9 @@ int ppp_unit_number(struct ppp_channel *chan) | |||
2043 | struct channel *pch = chan->ppp; | 2043 | struct channel *pch = chan->ppp; |
2044 | int unit = -1; | 2044 | int unit = -1; |
2045 | 2045 | ||
2046 | if (pch != 0) { | 2046 | if (pch) { |
2047 | read_lock_bh(&pch->upl); | 2047 | read_lock_bh(&pch->upl); |
2048 | if (pch->ppp != 0) | 2048 | if (pch->ppp) |
2049 | unit = pch->ppp->file.index; | 2049 | unit = pch->ppp->file.index; |
2050 | read_unlock_bh(&pch->upl); | 2050 | read_unlock_bh(&pch->upl); |
2051 | } | 2051 | } |
@@ -2061,7 +2061,7 @@ ppp_unregister_channel(struct ppp_channel *chan) | |||
2061 | { | 2061 | { |
2062 | struct channel *pch = chan->ppp; | 2062 | struct channel *pch = chan->ppp; |
2063 | 2063 | ||
2064 | if (pch == 0) | 2064 | if (!pch) |
2065 | return; /* should never happen */ | 2065 | return; /* should never happen */ |
2066 | chan->ppp = NULL; | 2066 | chan->ppp = NULL; |
2067 | 2067 | ||
@@ -2093,7 +2093,7 @@ ppp_output_wakeup(struct ppp_channel *chan) | |||
2093 | { | 2093 | { |
2094 | struct channel *pch = chan->ppp; | 2094 | struct channel *pch = chan->ppp; |
2095 | 2095 | ||
2096 | if (pch == 0) | 2096 | if (!pch) |
2097 | return; | 2097 | return; |
2098 | ppp_channel_push(pch); | 2098 | ppp_channel_push(pch); |
2099 | } | 2099 | } |
@@ -2124,18 +2124,18 @@ ppp_set_compress(struct ppp *ppp, unsigned long arg) | |||
2124 | 2124 | ||
2125 | cp = find_compressor(ccp_option[0]); | 2125 | cp = find_compressor(ccp_option[0]); |
2126 | #ifdef CONFIG_KMOD | 2126 | #ifdef CONFIG_KMOD |
2127 | if (cp == 0) { | 2127 | if (!cp) { |
2128 | request_module("ppp-compress-%d", ccp_option[0]); | 2128 | request_module("ppp-compress-%d", ccp_option[0]); |
2129 | cp = find_compressor(ccp_option[0]); | 2129 | cp = find_compressor(ccp_option[0]); |
2130 | } | 2130 | } |
2131 | #endif /* CONFIG_KMOD */ | 2131 | #endif /* CONFIG_KMOD */ |
2132 | if (cp == 0) | 2132 | if (!cp) |
2133 | goto out; | 2133 | goto out; |
2134 | 2134 | ||
2135 | err = -ENOBUFS; | 2135 | err = -ENOBUFS; |
2136 | if (data.transmit) { | 2136 | if (data.transmit) { |
2137 | state = cp->comp_alloc(ccp_option, data.length); | 2137 | state = cp->comp_alloc(ccp_option, data.length); |
2138 | if (state != 0) { | 2138 | if (state) { |
2139 | ppp_xmit_lock(ppp); | 2139 | ppp_xmit_lock(ppp); |
2140 | ppp->xstate &= ~SC_COMP_RUN; | 2140 | ppp->xstate &= ~SC_COMP_RUN; |
2141 | ocomp = ppp->xcomp; | 2141 | ocomp = ppp->xcomp; |
@@ -2143,7 +2143,7 @@ ppp_set_compress(struct ppp *ppp, unsigned long arg) | |||
2143 | ppp->xcomp = cp; | 2143 | ppp->xcomp = cp; |
2144 | ppp->xc_state = state; | 2144 | ppp->xc_state = state; |
2145 | ppp_xmit_unlock(ppp); | 2145 | ppp_xmit_unlock(ppp); |
2146 | if (ostate != 0) { | 2146 | if (ostate) { |
2147 | ocomp->comp_free(ostate); | 2147 | ocomp->comp_free(ostate); |
2148 | module_put(ocomp->owner); | 2148 | module_put(ocomp->owner); |
2149 | } | 2149 | } |
@@ -2153,7 +2153,7 @@ ppp_set_compress(struct ppp *ppp, unsigned long arg) | |||
2153 | 2153 | ||
2154 | } else { | 2154 | } else { |
2155 | state = cp->decomp_alloc(ccp_option, data.length); | 2155 | state = cp->decomp_alloc(ccp_option, data.length); |
2156 | if (state != 0) { | 2156 | if (state) { |
2157 | ppp_recv_lock(ppp); | 2157 | ppp_recv_lock(ppp); |
2158 | ppp->rstate &= ~SC_DECOMP_RUN; | 2158 | ppp->rstate &= ~SC_DECOMP_RUN; |
2159 | ocomp = ppp->rcomp; | 2159 | ocomp = ppp->rcomp; |
@@ -2161,7 +2161,7 @@ ppp_set_compress(struct ppp *ppp, unsigned long arg) | |||
2161 | ppp->rcomp = cp; | 2161 | ppp->rcomp = cp; |
2162 | ppp->rc_state = state; | 2162 | ppp->rc_state = state; |
2163 | ppp_recv_unlock(ppp); | 2163 | ppp_recv_unlock(ppp); |
2164 | if (ostate != 0) { | 2164 | if (ostate) { |
2165 | ocomp->decomp_free(ostate); | 2165 | ocomp->decomp_free(ostate); |
2166 | module_put(ocomp->owner); | 2166 | module_put(ocomp->owner); |
2167 | } | 2167 | } |
@@ -2228,7 +2228,7 @@ ppp_ccp_peek(struct ppp *ppp, struct sk_buff *skb, int inbound) | |||
2228 | break; | 2228 | break; |
2229 | if (inbound) { | 2229 | if (inbound) { |
2230 | /* we will start receiving compressed packets */ | 2230 | /* we will start receiving compressed packets */ |
2231 | if (ppp->rc_state == 0) | 2231 | if (!ppp->rc_state) |
2232 | break; | 2232 | break; |
2233 | if (ppp->rcomp->decomp_init(ppp->rc_state, dp, len, | 2233 | if (ppp->rcomp->decomp_init(ppp->rc_state, dp, len, |
2234 | ppp->file.index, 0, ppp->mru, ppp->debug)) { | 2234 | ppp->file.index, 0, ppp->mru, ppp->debug)) { |
@@ -2237,7 +2237,7 @@ ppp_ccp_peek(struct ppp *ppp, struct sk_buff *skb, int inbound) | |||
2237 | } | 2237 | } |
2238 | } else { | 2238 | } else { |
2239 | /* we will soon start sending compressed packets */ | 2239 | /* we will soon start sending compressed packets */ |
2240 | if (ppp->xc_state == 0) | 2240 | if (!ppp->xc_state) |
2241 | break; | 2241 | break; |
2242 | if (ppp->xcomp->comp_init(ppp->xc_state, dp, len, | 2242 | if (ppp->xcomp->comp_init(ppp->xc_state, dp, len, |
2243 | ppp->file.index, 0, ppp->debug)) | 2243 | ppp->file.index, 0, ppp->debug)) |
@@ -2320,11 +2320,11 @@ ppp_register_compressor(struct compressor *cp) | |||
2320 | int ret; | 2320 | int ret; |
2321 | spin_lock(&compressor_list_lock); | 2321 | spin_lock(&compressor_list_lock); |
2322 | ret = -EEXIST; | 2322 | ret = -EEXIST; |
2323 | if (find_comp_entry(cp->compress_proto) != 0) | 2323 | if (find_comp_entry(cp->compress_proto)) |
2324 | goto out; | 2324 | goto out; |
2325 | ret = -ENOMEM; | 2325 | ret = -ENOMEM; |
2326 | ce = kmalloc(sizeof(struct compressor_entry), GFP_ATOMIC); | 2326 | ce = kmalloc(sizeof(struct compressor_entry), GFP_ATOMIC); |
2327 | if (ce == 0) | 2327 | if (!ce) |
2328 | goto out; | 2328 | goto out; |
2329 | ret = 0; | 2329 | ret = 0; |
2330 | ce->comp = cp; | 2330 | ce->comp = cp; |
@@ -2342,7 +2342,7 @@ ppp_unregister_compressor(struct compressor *cp) | |||
2342 | 2342 | ||
2343 | spin_lock(&compressor_list_lock); | 2343 | spin_lock(&compressor_list_lock); |
2344 | ce = find_comp_entry(cp->compress_proto); | 2344 | ce = find_comp_entry(cp->compress_proto); |
2345 | if (ce != 0 && ce->comp == cp) { | 2345 | if (ce && ce->comp == cp) { |
2346 | list_del(&ce->list); | 2346 | list_del(&ce->list); |
2347 | kfree(ce); | 2347 | kfree(ce); |
2348 | } | 2348 | } |
@@ -2358,7 +2358,7 @@ find_compressor(int type) | |||
2358 | 2358 | ||
2359 | spin_lock(&compressor_list_lock); | 2359 | spin_lock(&compressor_list_lock); |
2360 | ce = find_comp_entry(type); | 2360 | ce = find_comp_entry(type); |
2361 | if (ce != 0) { | 2361 | if (ce) { |
2362 | cp = ce->comp; | 2362 | cp = ce->comp; |
2363 | if (!try_module_get(cp->owner)) | 2363 | if (!try_module_get(cp->owner)) |
2364 | cp = NULL; | 2364 | cp = NULL; |
@@ -2383,7 +2383,7 @@ ppp_get_stats(struct ppp *ppp, struct ppp_stats *st) | |||
2383 | st->p.ppp_opackets = ppp->stats.tx_packets; | 2383 | st->p.ppp_opackets = ppp->stats.tx_packets; |
2384 | st->p.ppp_oerrors = ppp->stats.tx_errors; | 2384 | st->p.ppp_oerrors = ppp->stats.tx_errors; |
2385 | st->p.ppp_obytes = ppp->stats.tx_bytes; | 2385 | st->p.ppp_obytes = ppp->stats.tx_bytes; |
2386 | if (vj == 0) | 2386 | if (!vj) |
2387 | return; | 2387 | return; |
2388 | st->vj.vjs_packets = vj->sls_o_compressed + vj->sls_o_uncompressed; | 2388 | st->vj.vjs_packets = vj->sls_o_compressed + vj->sls_o_uncompressed; |
2389 | st->vj.vjs_compressed = vj->sls_o_compressed; | 2389 | st->vj.vjs_compressed = vj->sls_o_compressed; |
@@ -2604,11 +2604,11 @@ ppp_connect_channel(struct channel *pch, int unit) | |||
2604 | 2604 | ||
2605 | mutex_lock(&all_ppp_mutex); | 2605 | mutex_lock(&all_ppp_mutex); |
2606 | ppp = ppp_find_unit(unit); | 2606 | ppp = ppp_find_unit(unit); |
2607 | if (ppp == 0) | 2607 | if (!ppp) |
2608 | goto out; | 2608 | goto out; |
2609 | write_lock_bh(&pch->upl); | 2609 | write_lock_bh(&pch->upl); |
2610 | ret = -EINVAL; | 2610 | ret = -EINVAL; |
2611 | if (pch->ppp != 0) | 2611 | if (pch->ppp) |
2612 | goto outl; | 2612 | goto outl; |
2613 | 2613 | ||
2614 | ppp_lock(ppp); | 2614 | ppp_lock(ppp); |
@@ -2644,7 +2644,7 @@ ppp_disconnect_channel(struct channel *pch) | |||
2644 | ppp = pch->ppp; | 2644 | ppp = pch->ppp; |
2645 | pch->ppp = NULL; | 2645 | pch->ppp = NULL; |
2646 | write_unlock_bh(&pch->upl); | 2646 | write_unlock_bh(&pch->upl); |
2647 | if (ppp != 0) { | 2647 | if (ppp) { |
2648 | /* remove it from the ppp unit's list */ | 2648 | /* remove it from the ppp unit's list */ |
2649 | ppp_lock(ppp); | 2649 | ppp_lock(ppp); |
2650 | list_del(&pch->clist); | 2650 | list_del(&pch->clist); |
diff --git a/drivers/net/ppp_synctty.c b/drivers/net/ppp_synctty.c index 00e2fb48b4ae..f0c6a1926a02 100644 --- a/drivers/net/ppp_synctty.c +++ b/drivers/net/ppp_synctty.c | |||
@@ -209,7 +209,7 @@ ppp_sync_open(struct tty_struct *tty) | |||
209 | 209 | ||
210 | ap = kzalloc(sizeof(*ap), GFP_KERNEL); | 210 | ap = kzalloc(sizeof(*ap), GFP_KERNEL); |
211 | err = -ENOMEM; | 211 | err = -ENOMEM; |
212 | if (ap == 0) | 212 | if (!ap) |
213 | goto out; | 213 | goto out; |
214 | 214 | ||
215 | /* initialize the syncppp structure */ | 215 | /* initialize the syncppp structure */ |
@@ -262,7 +262,7 @@ ppp_sync_close(struct tty_struct *tty) | |||
262 | ap = tty->disc_data; | 262 | ap = tty->disc_data; |
263 | tty->disc_data = NULL; | 263 | tty->disc_data = NULL; |
264 | write_unlock_irq(&disc_data_lock); | 264 | write_unlock_irq(&disc_data_lock); |
265 | if (ap == 0) | 265 | if (!ap) |
266 | return; | 266 | return; |
267 | 267 | ||
268 | /* | 268 | /* |
@@ -278,7 +278,7 @@ ppp_sync_close(struct tty_struct *tty) | |||
278 | 278 | ||
279 | ppp_unregister_channel(&ap->chan); | 279 | ppp_unregister_channel(&ap->chan); |
280 | skb_queue_purge(&ap->rqueue); | 280 | skb_queue_purge(&ap->rqueue); |
281 | if (ap->tpkt != 0) | 281 | if (ap->tpkt) |
282 | kfree_skb(ap->tpkt); | 282 | kfree_skb(ap->tpkt); |
283 | kfree(ap); | 283 | kfree(ap); |
284 | } | 284 | } |
@@ -325,13 +325,13 @@ ppp_synctty_ioctl(struct tty_struct *tty, struct file *file, | |||
325 | int __user *p = (int __user *)arg; | 325 | int __user *p = (int __user *)arg; |
326 | int err, val; | 326 | int err, val; |
327 | 327 | ||
328 | if (ap == 0) | 328 | if (!ap) |
329 | return -ENXIO; | 329 | return -ENXIO; |
330 | err = -EFAULT; | 330 | err = -EFAULT; |
331 | switch (cmd) { | 331 | switch (cmd) { |
332 | case PPPIOCGCHAN: | 332 | case PPPIOCGCHAN: |
333 | err = -ENXIO; | 333 | err = -ENXIO; |
334 | if (ap == 0) | 334 | if (!ap) |
335 | break; | 335 | break; |
336 | err = -EFAULT; | 336 | err = -EFAULT; |
337 | if (put_user(ppp_channel_index(&ap->chan), p)) | 337 | if (put_user(ppp_channel_index(&ap->chan), p)) |
@@ -341,7 +341,7 @@ ppp_synctty_ioctl(struct tty_struct *tty, struct file *file, | |||
341 | 341 | ||
342 | case PPPIOCGUNIT: | 342 | case PPPIOCGUNIT: |
343 | err = -ENXIO; | 343 | err = -ENXIO; |
344 | if (ap == 0) | 344 | if (!ap) |
345 | break; | 345 | break; |
346 | err = -EFAULT; | 346 | err = -EFAULT; |
347 | if (put_user(ppp_unit_number(&ap->chan), p)) | 347 | if (put_user(ppp_unit_number(&ap->chan), p)) |
@@ -390,7 +390,7 @@ ppp_sync_receive(struct tty_struct *tty, const unsigned char *buf, | |||
390 | struct syncppp *ap = sp_get(tty); | 390 | struct syncppp *ap = sp_get(tty); |
391 | unsigned long flags; | 391 | unsigned long flags; |
392 | 392 | ||
393 | if (ap == 0) | 393 | if (!ap) |
394 | return; | 394 | return; |
395 | spin_lock_irqsave(&ap->recv_lock, flags); | 395 | spin_lock_irqsave(&ap->recv_lock, flags); |
396 | ppp_sync_input(ap, buf, cflags, count); | 396 | ppp_sync_input(ap, buf, cflags, count); |
@@ -409,7 +409,7 @@ ppp_sync_wakeup(struct tty_struct *tty) | |||
409 | struct syncppp *ap = sp_get(tty); | 409 | struct syncppp *ap = sp_get(tty); |
410 | 410 | ||
411 | clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); | 411 | clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); |
412 | if (ap == 0) | 412 | if (!ap) |
413 | return; | 413 | return; |
414 | set_bit(XMIT_WAKEUP, &ap->xmit_flags); | 414 | set_bit(XMIT_WAKEUP, &ap->xmit_flags); |
415 | tasklet_schedule(&ap->tsk); | 415 | tasklet_schedule(&ap->tsk); |
@@ -651,7 +651,7 @@ ppp_sync_push(struct syncppp *ap) | |||
651 | for (;;) { | 651 | for (;;) { |
652 | if (test_and_clear_bit(XMIT_WAKEUP, &ap->xmit_flags)) | 652 | if (test_and_clear_bit(XMIT_WAKEUP, &ap->xmit_flags)) |
653 | tty_stuffed = 0; | 653 | tty_stuffed = 0; |
654 | if (!tty_stuffed && ap->tpkt != 0) { | 654 | if (!tty_stuffed && ap->tpkt) { |
655 | set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); | 655 | set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); |
656 | sent = tty->driver->write(tty, ap->tpkt->data, ap->tpkt->len); | 656 | sent = tty->driver->write(tty, ap->tpkt->data, ap->tpkt->len); |
657 | if (sent < 0) | 657 | if (sent < 0) |
@@ -669,7 +669,7 @@ ppp_sync_push(struct syncppp *ap) | |||
669 | /* haven't made any progress */ | 669 | /* haven't made any progress */ |
670 | spin_unlock_bh(&ap->xmit_lock); | 670 | spin_unlock_bh(&ap->xmit_lock); |
671 | if (!(test_bit(XMIT_WAKEUP, &ap->xmit_flags) | 671 | if (!(test_bit(XMIT_WAKEUP, &ap->xmit_flags) |
672 | || (!tty_stuffed && ap->tpkt != 0))) | 672 | || (!tty_stuffed && ap->tpkt))) |
673 | break; | 673 | break; |
674 | if (!spin_trylock_bh(&ap->xmit_lock)) | 674 | if (!spin_trylock_bh(&ap->xmit_lock)) |
675 | break; | 675 | break; |
@@ -677,7 +677,7 @@ ppp_sync_push(struct syncppp *ap) | |||
677 | return done; | 677 | return done; |
678 | 678 | ||
679 | flush: | 679 | flush: |
680 | if (ap->tpkt != 0) { | 680 | if (ap->tpkt) { |
681 | kfree_skb(ap->tpkt); | 681 | kfree_skb(ap->tpkt); |
682 | ap->tpkt = NULL; | 682 | ap->tpkt = NULL; |
683 | clear_bit(XMIT_FULL, &ap->xmit_flags); | 683 | clear_bit(XMIT_FULL, &ap->xmit_flags); |
@@ -732,7 +732,8 @@ ppp_sync_input(struct syncppp *ap, const unsigned char *buf, | |||
732 | ppp_print_buffer ("receive buffer", buf, count); | 732 | ppp_print_buffer ("receive buffer", buf, count); |
733 | 733 | ||
734 | /* stuff the chars in the skb */ | 734 | /* stuff the chars in the skb */ |
735 | if ((skb = dev_alloc_skb(ap->mru + PPP_HDRLEN + 2)) == 0) { | 735 | skb = dev_alloc_skb(ap->mru + PPP_HDRLEN + 2); |
736 | if (!skb) { | ||
736 | printk(KERN_ERR "PPPsync: no memory (input pkt)\n"); | 737 | printk(KERN_ERR "PPPsync: no memory (input pkt)\n"); |
737 | goto err; | 738 | goto err; |
738 | } | 739 | } |
@@ -740,7 +741,7 @@ ppp_sync_input(struct syncppp *ap, const unsigned char *buf, | |||
740 | if (buf[0] != PPP_ALLSTATIONS) | 741 | if (buf[0] != PPP_ALLSTATIONS) |
741 | skb_reserve(skb, 2 + (buf[0] & 1)); | 742 | skb_reserve(skb, 2 + (buf[0] & 1)); |
742 | 743 | ||
743 | if (flags != 0 && *flags) { | 744 | if (flags && *flags) { |
744 | /* error flag set, ignore frame */ | 745 | /* error flag set, ignore frame */ |
745 | goto err; | 746 | goto err; |
746 | } else if (count > skb_tailroom(skb)) { | 747 | } else if (count > skb_tailroom(skb)) { |
diff --git a/drivers/net/sungem.c b/drivers/net/sungem.c index 53b8344a68ef..f6fedcc32de1 100644 --- a/drivers/net/sungem.c +++ b/drivers/net/sungem.c | |||
@@ -2333,10 +2333,10 @@ static int gem_close(struct net_device *dev) | |||
2333 | { | 2333 | { |
2334 | struct gem *gp = dev->priv; | 2334 | struct gem *gp = dev->priv; |
2335 | 2335 | ||
2336 | napi_disable(&gp->napi); | ||
2337 | |||
2338 | mutex_lock(&gp->pm_mutex); | 2336 | mutex_lock(&gp->pm_mutex); |
2339 | 2337 | ||
2338 | napi_disable(&gp->napi); | ||
2339 | |||
2340 | gp->opened = 0; | 2340 | gp->opened = 0; |
2341 | if (!gp->asleep) | 2341 | if (!gp->asleep) |
2342 | gem_do_stop(dev, 0); | 2342 | gem_do_stop(dev, 0); |
@@ -2355,8 +2355,6 @@ static int gem_suspend(struct pci_dev *pdev, pm_message_t state) | |||
2355 | 2355 | ||
2356 | mutex_lock(&gp->pm_mutex); | 2356 | mutex_lock(&gp->pm_mutex); |
2357 | 2357 | ||
2358 | napi_disable(&gp->napi); | ||
2359 | |||
2360 | printk(KERN_INFO "%s: suspending, WakeOnLan %s\n", | 2358 | printk(KERN_INFO "%s: suspending, WakeOnLan %s\n", |
2361 | dev->name, | 2359 | dev->name, |
2362 | (gp->wake_on_lan && gp->opened) ? "enabled" : "disabled"); | 2360 | (gp->wake_on_lan && gp->opened) ? "enabled" : "disabled"); |
@@ -2370,6 +2368,8 @@ static int gem_suspend(struct pci_dev *pdev, pm_message_t state) | |||
2370 | 2368 | ||
2371 | /* If the driver is opened, we stop the MAC */ | 2369 | /* If the driver is opened, we stop the MAC */ |
2372 | if (gp->opened) { | 2370 | if (gp->opened) { |
2371 | napi_disable(&gp->napi); | ||
2372 | |||
2373 | /* Stop traffic, mark us closed */ | 2373 | /* Stop traffic, mark us closed */ |
2374 | netif_device_detach(dev); | 2374 | netif_device_detach(dev); |
2375 | 2375 | ||
@@ -2460,6 +2460,7 @@ static int gem_resume(struct pci_dev *pdev) | |||
2460 | /* Re-attach net device */ | 2460 | /* Re-attach net device */ |
2461 | netif_device_attach(dev); | 2461 | netif_device_attach(dev); |
2462 | 2462 | ||
2463 | napi_enable(&gp->napi); | ||
2463 | } | 2464 | } |
2464 | 2465 | ||
2465 | spin_lock_irqsave(&gp->lock, flags); | 2466 | spin_lock_irqsave(&gp->lock, flags); |
@@ -2479,8 +2480,6 @@ static int gem_resume(struct pci_dev *pdev) | |||
2479 | spin_unlock(&gp->tx_lock); | 2480 | spin_unlock(&gp->tx_lock); |
2480 | spin_unlock_irqrestore(&gp->lock, flags); | 2481 | spin_unlock_irqrestore(&gp->lock, flags); |
2481 | 2482 | ||
2482 | napi_enable(&gp->napi); | ||
2483 | |||
2484 | mutex_unlock(&gp->pm_mutex); | 2483 | mutex_unlock(&gp->pm_mutex); |
2485 | 2484 | ||
2486 | return 0; | 2485 | return 0; |
diff --git a/drivers/net/tehuti.c b/drivers/net/tehuti.c index 4e1b84e6d66a..21230c97b2a0 100644 --- a/drivers/net/tehuti.c +++ b/drivers/net/tehuti.c | |||
@@ -2168,10 +2168,10 @@ bdx_get_drvinfo(struct net_device *netdev, struct ethtool_drvinfo *drvinfo) | |||
2168 | { | 2168 | { |
2169 | struct bdx_priv *priv = netdev->priv; | 2169 | struct bdx_priv *priv = netdev->priv; |
2170 | 2170 | ||
2171 | strncat(drvinfo->driver, BDX_DRV_NAME, sizeof(drvinfo->driver)); | 2171 | strlcat(drvinfo->driver, BDX_DRV_NAME, sizeof(drvinfo->driver)); |
2172 | strncat(drvinfo->version, BDX_DRV_VERSION, sizeof(drvinfo->version)); | 2172 | strlcat(drvinfo->version, BDX_DRV_VERSION, sizeof(drvinfo->version)); |
2173 | strncat(drvinfo->fw_version, "N/A", sizeof(drvinfo->fw_version)); | 2173 | strlcat(drvinfo->fw_version, "N/A", sizeof(drvinfo->fw_version)); |
2174 | strncat(drvinfo->bus_info, pci_name(priv->pdev), | 2174 | strlcat(drvinfo->bus_info, pci_name(priv->pdev), |
2175 | sizeof(drvinfo->bus_info)); | 2175 | sizeof(drvinfo->bus_info)); |
2176 | 2176 | ||
2177 | drvinfo->n_stats = ((priv->stats_flag) ? | 2177 | drvinfo->n_stats = ((priv->stats_flag) ? |
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c index cad519910767..4942f7d18937 100644 --- a/drivers/net/tg3.c +++ b/drivers/net/tg3.c | |||
@@ -64,8 +64,8 @@ | |||
64 | 64 | ||
65 | #define DRV_MODULE_NAME "tg3" | 65 | #define DRV_MODULE_NAME "tg3" |
66 | #define PFX DRV_MODULE_NAME ": " | 66 | #define PFX DRV_MODULE_NAME ": " |
67 | #define DRV_MODULE_VERSION "3.85" | 67 | #define DRV_MODULE_VERSION "3.86" |
68 | #define DRV_MODULE_RELDATE "October 18, 2007" | 68 | #define DRV_MODULE_RELDATE "November 9, 2007" |
69 | 69 | ||
70 | #define TG3_DEF_MAC_MODE 0 | 70 | #define TG3_DEF_MAC_MODE 0 |
71 | #define TG3_DEF_RX_MODE 0 | 71 | #define TG3_DEF_RX_MODE 0 |
@@ -1106,6 +1106,24 @@ static int tg3_phy_reset(struct tg3 *tp) | |||
1106 | if (err) | 1106 | if (err) |
1107 | return err; | 1107 | return err; |
1108 | 1108 | ||
1109 | if (tp->tg3_flags3 & TG3_FLG3_5761_5784_AX_FIXES) { | ||
1110 | u32 val; | ||
1111 | |||
1112 | val = tr32(TG3_CPMU_LSPD_1000MB_CLK); | ||
1113 | if ((val & CPMU_LSPD_1000MB_MACCLK_MASK) == | ||
1114 | CPMU_LSPD_1000MB_MACCLK_12_5) { | ||
1115 | val &= ~CPMU_LSPD_1000MB_MACCLK_MASK; | ||
1116 | udelay(40); | ||
1117 | tw32_f(TG3_CPMU_LSPD_1000MB_CLK, val); | ||
1118 | } | ||
1119 | |||
1120 | /* Disable GPHY autopowerdown. */ | ||
1121 | tg3_writephy(tp, MII_TG3_MISC_SHDW, | ||
1122 | MII_TG3_MISC_SHDW_WREN | | ||
1123 | MII_TG3_MISC_SHDW_APD_SEL | | ||
1124 | MII_TG3_MISC_SHDW_APD_WKTM_84MS); | ||
1125 | } | ||
1126 | |||
1109 | out: | 1127 | out: |
1110 | if (tp->tg3_flags2 & TG3_FLG2_PHY_ADC_BUG) { | 1128 | if (tp->tg3_flags2 & TG3_FLG2_PHY_ADC_BUG) { |
1111 | tg3_writephy(tp, MII_TG3_AUX_CTRL, 0x0c00); | 1129 | tg3_writephy(tp, MII_TG3_AUX_CTRL, 0x0c00); |
@@ -1297,6 +1315,8 @@ static void tg3_nvram_unlock(struct tg3 *); | |||
1297 | 1315 | ||
1298 | static void tg3_power_down_phy(struct tg3 *tp) | 1316 | static void tg3_power_down_phy(struct tg3 *tp) |
1299 | { | 1317 | { |
1318 | u32 val; | ||
1319 | |||
1300 | if (tp->tg3_flags2 & TG3_FLG2_PHY_SERDES) { | 1320 | if (tp->tg3_flags2 & TG3_FLG2_PHY_SERDES) { |
1301 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5704) { | 1321 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5704) { |
1302 | u32 sg_dig_ctrl = tr32(SG_DIG_CTRL); | 1322 | u32 sg_dig_ctrl = tr32(SG_DIG_CTRL); |
@@ -1311,8 +1331,6 @@ static void tg3_power_down_phy(struct tg3 *tp) | |||
1311 | } | 1331 | } |
1312 | 1332 | ||
1313 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) { | 1333 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) { |
1314 | u32 val; | ||
1315 | |||
1316 | tg3_bmcr_reset(tp); | 1334 | tg3_bmcr_reset(tp); |
1317 | val = tr32(GRC_MISC_CFG); | 1335 | val = tr32(GRC_MISC_CFG); |
1318 | tw32_f(GRC_MISC_CFG, val | GRC_MISC_CFG_EPHY_IDDQ); | 1336 | tw32_f(GRC_MISC_CFG, val | GRC_MISC_CFG_EPHY_IDDQ); |
@@ -1332,6 +1350,14 @@ static void tg3_power_down_phy(struct tg3 *tp) | |||
1332 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5780 && | 1350 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5780 && |
1333 | (tp->tg3_flags2 & TG3_FLG2_MII_SERDES))) | 1351 | (tp->tg3_flags2 & TG3_FLG2_MII_SERDES))) |
1334 | return; | 1352 | return; |
1353 | |||
1354 | if (tp->tg3_flags3 & TG3_FLG3_5761_5784_AX_FIXES) { | ||
1355 | val = tr32(TG3_CPMU_LSPD_1000MB_CLK); | ||
1356 | val &= ~CPMU_LSPD_1000MB_MACCLK_MASK; | ||
1357 | val |= CPMU_LSPD_1000MB_MACCLK_12_5; | ||
1358 | tw32_f(TG3_CPMU_LSPD_1000MB_CLK, val); | ||
1359 | } | ||
1360 | |||
1335 | tg3_writephy(tp, MII_BMCR, BMCR_PDOWN); | 1361 | tg3_writephy(tp, MII_BMCR, BMCR_PDOWN); |
1336 | } | 1362 | } |
1337 | 1363 | ||
@@ -3126,6 +3152,23 @@ static int tg3_setup_phy(struct tg3 *tp, int force_reset) | |||
3126 | err = tg3_setup_copper_phy(tp, force_reset); | 3152 | err = tg3_setup_copper_phy(tp, force_reset); |
3127 | } | 3153 | } |
3128 | 3154 | ||
3155 | if (tp->pci_chip_rev_id == CHIPREV_ID_5784_A0 || | ||
3156 | tp->pci_chip_rev_id == CHIPREV_ID_5784_A1) { | ||
3157 | u32 val, scale; | ||
3158 | |||
3159 | val = tr32(TG3_CPMU_CLCK_STAT) & CPMU_CLCK_STAT_MAC_CLCK_MASK; | ||
3160 | if (val == CPMU_CLCK_STAT_MAC_CLCK_62_5) | ||
3161 | scale = 65; | ||
3162 | else if (val == CPMU_CLCK_STAT_MAC_CLCK_6_25) | ||
3163 | scale = 6; | ||
3164 | else | ||
3165 | scale = 12; | ||
3166 | |||
3167 | val = tr32(GRC_MISC_CFG) & ~GRC_MISC_CFG_PRESCALAR_MASK; | ||
3168 | val |= (scale << GRC_MISC_CFG_PRESCALAR_SHIFT); | ||
3169 | tw32(GRC_MISC_CFG, val); | ||
3170 | } | ||
3171 | |||
3129 | if (tp->link_config.active_speed == SPEED_1000 && | 3172 | if (tp->link_config.active_speed == SPEED_1000 && |
3130 | tp->link_config.active_duplex == DUPLEX_HALF) | 3173 | tp->link_config.active_duplex == DUPLEX_HALF) |
3131 | tw32(MAC_TX_LENGTHS, | 3174 | tw32(MAC_TX_LENGTHS, |
@@ -5054,12 +5097,15 @@ static void tg3_restore_pci_state(struct tg3 *tp) | |||
5054 | 5097 | ||
5055 | pci_write_config_word(tp->pdev, PCI_COMMAND, tp->pci_cmd); | 5098 | pci_write_config_word(tp->pdev, PCI_COMMAND, tp->pci_cmd); |
5056 | 5099 | ||
5057 | if (!(tp->tg3_flags2 & TG3_FLG2_PCI_EXPRESS)) { | 5100 | if (tp->tg3_flags2 & TG3_FLG2_PCI_EXPRESS) |
5101 | pcie_set_readrq(tp->pdev, 4096); | ||
5102 | else { | ||
5058 | pci_write_config_byte(tp->pdev, PCI_CACHE_LINE_SIZE, | 5103 | pci_write_config_byte(tp->pdev, PCI_CACHE_LINE_SIZE, |
5059 | tp->pci_cacheline_sz); | 5104 | tp->pci_cacheline_sz); |
5060 | pci_write_config_byte(tp->pdev, PCI_LATENCY_TIMER, | 5105 | pci_write_config_byte(tp->pdev, PCI_LATENCY_TIMER, |
5061 | tp->pci_lat_timer); | 5106 | tp->pci_lat_timer); |
5062 | } | 5107 | } |
5108 | |||
5063 | /* Make sure PCI-X relaxed ordering bit is clear. */ | 5109 | /* Make sure PCI-X relaxed ordering bit is clear. */ |
5064 | if (tp->pcix_cap) { | 5110 | if (tp->pcix_cap) { |
5065 | u16 pcix_cmd; | 5111 | u16 pcix_cmd; |
@@ -6343,10 +6389,26 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) | |||
6343 | 6389 | ||
6344 | tg3_write_sig_legacy(tp, RESET_KIND_INIT); | 6390 | tg3_write_sig_legacy(tp, RESET_KIND_INIT); |
6345 | 6391 | ||
6346 | if (tp->pci_chip_rev_id == CHIPREV_ID_5784_A0) { | 6392 | if (tp->pci_chip_rev_id == CHIPREV_ID_5784_A0 || |
6393 | tp->pci_chip_rev_id == CHIPREV_ID_5784_A1) { | ||
6347 | val = tr32(TG3_CPMU_CTRL); | 6394 | val = tr32(TG3_CPMU_CTRL); |
6348 | val &= ~(CPMU_CTRL_LINK_AWARE_MODE | CPMU_CTRL_LINK_IDLE_MODE); | 6395 | val &= ~(CPMU_CTRL_LINK_AWARE_MODE | CPMU_CTRL_LINK_IDLE_MODE); |
6349 | tw32(TG3_CPMU_CTRL, val); | 6396 | tw32(TG3_CPMU_CTRL, val); |
6397 | |||
6398 | val = tr32(TG3_CPMU_LSPD_10MB_CLK); | ||
6399 | val &= ~CPMU_LSPD_10MB_MACCLK_MASK; | ||
6400 | val |= CPMU_LSPD_10MB_MACCLK_6_25; | ||
6401 | tw32(TG3_CPMU_LSPD_10MB_CLK, val); | ||
6402 | |||
6403 | val = tr32(TG3_CPMU_LNK_AWARE_PWRMD); | ||
6404 | val &= ~CPMU_LNK_AWARE_MACCLK_MASK; | ||
6405 | val |= CPMU_LNK_AWARE_MACCLK_6_25; | ||
6406 | tw32(TG3_CPMU_LNK_AWARE_PWRMD, val); | ||
6407 | |||
6408 | val = tr32(TG3_CPMU_HST_ACC); | ||
6409 | val &= ~CPMU_HST_ACC_MACCLK_MASK; | ||
6410 | val |= CPMU_HST_ACC_MACCLK_6_25; | ||
6411 | tw32(TG3_CPMU_HST_ACC, val); | ||
6350 | } | 6412 | } |
6351 | 6413 | ||
6352 | /* This works around an issue with Athlon chipsets on | 6414 | /* This works around an issue with Athlon chipsets on |
@@ -8267,7 +8329,7 @@ static int tg3_get_settings(struct net_device *dev, struct ethtool_cmd *cmd) | |||
8267 | SUPPORTED_100baseT_Full | | 8329 | SUPPORTED_100baseT_Full | |
8268 | SUPPORTED_10baseT_Half | | 8330 | SUPPORTED_10baseT_Half | |
8269 | SUPPORTED_10baseT_Full | | 8331 | SUPPORTED_10baseT_Full | |
8270 | SUPPORTED_MII); | 8332 | SUPPORTED_TP); |
8271 | cmd->port = PORT_TP; | 8333 | cmd->port = PORT_TP; |
8272 | } else { | 8334 | } else { |
8273 | cmd->supported |= SUPPORTED_FIBRE; | 8335 | cmd->supported |= SUPPORTED_FIBRE; |
@@ -8664,7 +8726,9 @@ static void tg3_get_ethtool_stats (struct net_device *dev, | |||
8664 | } | 8726 | } |
8665 | 8727 | ||
8666 | #define NVRAM_TEST_SIZE 0x100 | 8728 | #define NVRAM_TEST_SIZE 0x100 |
8667 | #define NVRAM_SELFBOOT_FORMAT1_SIZE 0x14 | 8729 | #define NVRAM_SELFBOOT_FORMAT1_0_SIZE 0x14 |
8730 | #define NVRAM_SELFBOOT_FORMAT1_2_SIZE 0x18 | ||
8731 | #define NVRAM_SELFBOOT_FORMAT1_3_SIZE 0x1c | ||
8668 | #define NVRAM_SELFBOOT_HW_SIZE 0x20 | 8732 | #define NVRAM_SELFBOOT_HW_SIZE 0x20 |
8669 | #define NVRAM_SELFBOOT_DATA_SIZE 0x1c | 8733 | #define NVRAM_SELFBOOT_DATA_SIZE 0x1c |
8670 | 8734 | ||
@@ -8679,9 +8743,22 @@ static int tg3_test_nvram(struct tg3 *tp) | |||
8679 | if (magic == TG3_EEPROM_MAGIC) | 8743 | if (magic == TG3_EEPROM_MAGIC) |
8680 | size = NVRAM_TEST_SIZE; | 8744 | size = NVRAM_TEST_SIZE; |
8681 | else if ((magic & TG3_EEPROM_MAGIC_FW_MSK) == TG3_EEPROM_MAGIC_FW) { | 8745 | else if ((magic & TG3_EEPROM_MAGIC_FW_MSK) == TG3_EEPROM_MAGIC_FW) { |
8682 | if ((magic & 0xe00000) == 0x200000) | 8746 | if ((magic & TG3_EEPROM_SB_FORMAT_MASK) == |
8683 | size = NVRAM_SELFBOOT_FORMAT1_SIZE; | 8747 | TG3_EEPROM_SB_FORMAT_1) { |
8684 | else | 8748 | switch (magic & TG3_EEPROM_SB_REVISION_MASK) { |
8749 | case TG3_EEPROM_SB_REVISION_0: | ||
8750 | size = NVRAM_SELFBOOT_FORMAT1_0_SIZE; | ||
8751 | break; | ||
8752 | case TG3_EEPROM_SB_REVISION_2: | ||
8753 | size = NVRAM_SELFBOOT_FORMAT1_2_SIZE; | ||
8754 | break; | ||
8755 | case TG3_EEPROM_SB_REVISION_3: | ||
8756 | size = NVRAM_SELFBOOT_FORMAT1_3_SIZE; | ||
8757 | break; | ||
8758 | default: | ||
8759 | return 0; | ||
8760 | } | ||
8761 | } else | ||
8685 | return 0; | 8762 | return 0; |
8686 | } else if ((magic & TG3_EEPROM_MAGIC_HW_MSK) == TG3_EEPROM_MAGIC_HW) | 8763 | } else if ((magic & TG3_EEPROM_MAGIC_HW_MSK) == TG3_EEPROM_MAGIC_HW) |
8687 | size = NVRAM_SELFBOOT_HW_SIZE; | 8764 | size = NVRAM_SELFBOOT_HW_SIZE; |
@@ -8708,8 +8785,17 @@ static int tg3_test_nvram(struct tg3 *tp) | |||
8708 | TG3_EEPROM_MAGIC_FW) { | 8785 | TG3_EEPROM_MAGIC_FW) { |
8709 | u8 *buf8 = (u8 *) buf, csum8 = 0; | 8786 | u8 *buf8 = (u8 *) buf, csum8 = 0; |
8710 | 8787 | ||
8711 | for (i = 0; i < size; i++) | 8788 | if ((cpu_to_be32(buf[0]) & TG3_EEPROM_SB_REVISION_MASK) == |
8712 | csum8 += buf8[i]; | 8789 | TG3_EEPROM_SB_REVISION_2) { |
8790 | /* For rev 2, the csum doesn't include the MBA. */ | ||
8791 | for (i = 0; i < TG3_EEPROM_SB_F1R2_MBA_OFF; i++) | ||
8792 | csum8 += buf8[i]; | ||
8793 | for (i = TG3_EEPROM_SB_F1R2_MBA_OFF + 4; i < size; i++) | ||
8794 | csum8 += buf8[i]; | ||
8795 | } else { | ||
8796 | for (i = 0; i < size; i++) | ||
8797 | csum8 += buf8[i]; | ||
8798 | } | ||
8713 | 8799 | ||
8714 | if (csum8 == 0) { | 8800 | if (csum8 == 0) { |
8715 | err = 0; | 8801 | err = 0; |
@@ -9293,7 +9379,7 @@ static int tg3_test_loopback(struct tg3 *tp) | |||
9293 | if (err) | 9379 | if (err) |
9294 | return TG3_LOOPBACK_FAILED; | 9380 | return TG3_LOOPBACK_FAILED; |
9295 | 9381 | ||
9296 | if (tp->tg3_flags & TG3_FLAG_CPMU_PRESENT) { | 9382 | if (tp->tg3_flags3 & TG3_FLG3_5761_5784_AX_FIXES) { |
9297 | int i; | 9383 | int i; |
9298 | u32 status; | 9384 | u32 status; |
9299 | 9385 | ||
@@ -9310,17 +9396,17 @@ static int tg3_test_loopback(struct tg3 *tp) | |||
9310 | if (status != CPMU_MUTEX_GNT_DRIVER) | 9396 | if (status != CPMU_MUTEX_GNT_DRIVER) |
9311 | return TG3_LOOPBACK_FAILED; | 9397 | return TG3_LOOPBACK_FAILED; |
9312 | 9398 | ||
9313 | cpmuctrl = tr32(TG3_CPMU_CTRL); | ||
9314 | |||
9315 | /* Turn off power management based on link speed. */ | 9399 | /* Turn off power management based on link speed. */ |
9400 | cpmuctrl = tr32(TG3_CPMU_CTRL); | ||
9316 | tw32(TG3_CPMU_CTRL, | 9401 | tw32(TG3_CPMU_CTRL, |
9317 | cpmuctrl & ~CPMU_CTRL_LINK_SPEED_MODE); | 9402 | cpmuctrl & ~(CPMU_CTRL_LINK_SPEED_MODE | |
9403 | CPMU_CTRL_LINK_AWARE_MODE)); | ||
9318 | } | 9404 | } |
9319 | 9405 | ||
9320 | if (tg3_run_loopback(tp, TG3_MAC_LOOPBACK)) | 9406 | if (tg3_run_loopback(tp, TG3_MAC_LOOPBACK)) |
9321 | err |= TG3_MAC_LOOPBACK_FAILED; | 9407 | err |= TG3_MAC_LOOPBACK_FAILED; |
9322 | 9408 | ||
9323 | if (tp->tg3_flags & TG3_FLAG_CPMU_PRESENT) { | 9409 | if (tp->tg3_flags3 & TG3_FLG3_5761_5784_AX_FIXES) { |
9324 | tw32(TG3_CPMU_CTRL, cpmuctrl); | 9410 | tw32(TG3_CPMU_CTRL, cpmuctrl); |
9325 | 9411 | ||
9326 | /* Release the mutex */ | 9412 | /* Release the mutex */ |
@@ -10541,6 +10627,10 @@ static void __devinit tg3_get_eeprom_hw_cfg(struct tg3 *tp) | |||
10541 | tp->pdev->subsystem_vendor == PCI_VENDOR_ID_DELL) | 10627 | tp->pdev->subsystem_vendor == PCI_VENDOR_ID_DELL) |
10542 | tp->led_ctrl = LED_CTRL_MODE_PHY_2; | 10628 | tp->led_ctrl = LED_CTRL_MODE_PHY_2; |
10543 | 10629 | ||
10630 | if (tp->pci_chip_rev_id == CHIPREV_ID_5784_A0 || | ||
10631 | tp->pci_chip_rev_id == CHIPREV_ID_5784_A1) | ||
10632 | tp->led_ctrl = LED_CTRL_MODE_MAC; | ||
10633 | |||
10544 | if (nic_cfg & NIC_SRAM_DATA_CFG_EEPROM_WP) { | 10634 | if (nic_cfg & NIC_SRAM_DATA_CFG_EEPROM_WP) { |
10545 | tp->tg3_flags |= TG3_FLAG_EEPROM_WRITE_PROT; | 10635 | tp->tg3_flags |= TG3_FLAG_EEPROM_WRITE_PROT; |
10546 | if ((tp->pdev->subsystem_vendor == | 10636 | if ((tp->pdev->subsystem_vendor == |
@@ -10859,7 +10949,7 @@ static void __devinit tg3_read_fw_ver(struct tg3 *tp) | |||
10859 | } | 10949 | } |
10860 | 10950 | ||
10861 | if (!(tp->tg3_flags & TG3_FLAG_ENABLE_ASF) || | 10951 | if (!(tp->tg3_flags & TG3_FLAG_ENABLE_ASF) || |
10862 | (tp->tg3_flags & TG3_FLG3_ENABLE_APE)) | 10952 | (tp->tg3_flags3 & TG3_FLG3_ENABLE_APE)) |
10863 | return; | 10953 | return; |
10864 | 10954 | ||
10865 | for (offset = TG3_NVM_DIR_START; | 10955 | for (offset = TG3_NVM_DIR_START; |
@@ -11127,6 +11217,9 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
11127 | pcie_cap = pci_find_capability(tp->pdev, PCI_CAP_ID_EXP); | 11217 | pcie_cap = pci_find_capability(tp->pdev, PCI_CAP_ID_EXP); |
11128 | if (pcie_cap != 0) { | 11218 | if (pcie_cap != 0) { |
11129 | tp->tg3_flags2 |= TG3_FLG2_PCI_EXPRESS; | 11219 | tp->tg3_flags2 |= TG3_FLG2_PCI_EXPRESS; |
11220 | |||
11221 | pcie_set_readrq(tp->pdev, 4096); | ||
11222 | |||
11130 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) { | 11223 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) { |
11131 | u16 lnkctl; | 11224 | u16 lnkctl; |
11132 | 11225 | ||
@@ -11307,9 +11400,16 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
11307 | } | 11400 | } |
11308 | 11401 | ||
11309 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 11402 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
11310 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 11403 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) { |
11311 | tp->tg3_flags |= TG3_FLAG_CPMU_PRESENT; | 11404 | tp->tg3_flags |= TG3_FLAG_CPMU_PRESENT; |
11312 | 11405 | ||
11406 | if (tp->pci_chip_rev_id == CHIPREV_ID_5784_A0 || | ||
11407 | tp->pci_chip_rev_id == CHIPREV_ID_5784_A1 || | ||
11408 | tp->pci_chip_rev_id == CHIPREV_ID_5761_A0 || | ||
11409 | tp->pci_chip_rev_id == CHIPREV_ID_5761_A1) | ||
11410 | tp->tg3_flags3 |= TG3_FLG3_5761_5784_AX_FIXES; | ||
11411 | } | ||
11412 | |||
11313 | /* Set up tp->grc_local_ctrl before calling tg3_set_power_state(). | 11413 | /* Set up tp->grc_local_ctrl before calling tg3_set_power_state(). |
11314 | * GPIO1 driven high will bring 5700's external PHY out of reset. | 11414 | * GPIO1 driven high will bring 5700's external PHY out of reset. |
11315 | * It is also used as eeprom write protect on LOMs. | 11415 | * It is also used as eeprom write protect on LOMs. |
@@ -12464,6 +12564,28 @@ static int __devinit tg3_init_one(struct pci_dev *pdev, | |||
12464 | goto err_out_iounmap; | 12564 | goto err_out_iounmap; |
12465 | } | 12565 | } |
12466 | 12566 | ||
12567 | if (tp->tg3_flags3 & TG3_FLG3_ENABLE_APE) { | ||
12568 | if (!(pci_resource_flags(pdev, 2) & IORESOURCE_MEM)) { | ||
12569 | printk(KERN_ERR PFX "Cannot find proper PCI device " | ||
12570 | "base address for APE, aborting.\n"); | ||
12571 | err = -ENODEV; | ||
12572 | goto err_out_iounmap; | ||
12573 | } | ||
12574 | |||
12575 | tg3reg_base = pci_resource_start(pdev, 2); | ||
12576 | tg3reg_len = pci_resource_len(pdev, 2); | ||
12577 | |||
12578 | tp->aperegs = ioremap_nocache(tg3reg_base, tg3reg_len); | ||
12579 | if (tp->aperegs == 0UL) { | ||
12580 | printk(KERN_ERR PFX "Cannot map APE registers, " | ||
12581 | "aborting.\n"); | ||
12582 | err = -ENOMEM; | ||
12583 | goto err_out_iounmap; | ||
12584 | } | ||
12585 | |||
12586 | tg3_ape_lock_init(tp); | ||
12587 | } | ||
12588 | |||
12467 | /* | 12589 | /* |
12468 | * Reset chip in case UNDI or EFI driver did not shutdown | 12590 | * Reset chip in case UNDI or EFI driver did not shutdown |
12469 | * DMA self test will enable WDMAC and we'll see (spurious) | 12591 | * DMA self test will enable WDMAC and we'll see (spurious) |
@@ -12478,7 +12600,7 @@ static int __devinit tg3_init_one(struct pci_dev *pdev, | |||
12478 | err = tg3_test_dma(tp); | 12600 | err = tg3_test_dma(tp); |
12479 | if (err) { | 12601 | if (err) { |
12480 | printk(KERN_ERR PFX "DMA engine test failed, aborting.\n"); | 12602 | printk(KERN_ERR PFX "DMA engine test failed, aborting.\n"); |
12481 | goto err_out_iounmap; | 12603 | goto err_out_apeunmap; |
12482 | } | 12604 | } |
12483 | 12605 | ||
12484 | /* Tigon3 can do ipv4 only... and some chips have buggy | 12606 | /* Tigon3 can do ipv4 only... and some chips have buggy |
@@ -12501,28 +12623,6 @@ static int __devinit tg3_init_one(struct pci_dev *pdev, | |||
12501 | 12623 | ||
12502 | tg3_init_coal(tp); | 12624 | tg3_init_coal(tp); |
12503 | 12625 | ||
12504 | if (tp->tg3_flags3 & TG3_FLG3_ENABLE_APE) { | ||
12505 | if (!(pci_resource_flags(pdev, 2) & IORESOURCE_MEM)) { | ||
12506 | printk(KERN_ERR PFX "Cannot find proper PCI device " | ||
12507 | "base address for APE, aborting.\n"); | ||
12508 | err = -ENODEV; | ||
12509 | goto err_out_iounmap; | ||
12510 | } | ||
12511 | |||
12512 | tg3reg_base = pci_resource_start(pdev, 2); | ||
12513 | tg3reg_len = pci_resource_len(pdev, 2); | ||
12514 | |||
12515 | tp->aperegs = ioremap_nocache(tg3reg_base, tg3reg_len); | ||
12516 | if (tp->aperegs == 0UL) { | ||
12517 | printk(KERN_ERR PFX "Cannot map APE registers, " | ||
12518 | "aborting.\n"); | ||
12519 | err = -ENOMEM; | ||
12520 | goto err_out_iounmap; | ||
12521 | } | ||
12522 | |||
12523 | tg3_ape_lock_init(tp); | ||
12524 | } | ||
12525 | |||
12526 | pci_set_drvdata(pdev, dev); | 12626 | pci_set_drvdata(pdev, dev); |
12527 | 12627 | ||
12528 | err = register_netdev(dev); | 12628 | err = register_netdev(dev); |
diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h index 1d5b2a3dd29d..da18fb220712 100644 --- a/drivers/net/tg3.h +++ b/drivers/net/tg3.h | |||
@@ -109,6 +109,9 @@ | |||
109 | #define CHIPREV_ID_5714_A2 0x9002 | 109 | #define CHIPREV_ID_5714_A2 0x9002 |
110 | #define CHIPREV_ID_5906_A1 0xc001 | 110 | #define CHIPREV_ID_5906_A1 0xc001 |
111 | #define CHIPREV_ID_5784_A0 0x5784000 | 111 | #define CHIPREV_ID_5784_A0 0x5784000 |
112 | #define CHIPREV_ID_5784_A1 0x5784001 | ||
113 | #define CHIPREV_ID_5761_A0 0x5761000 | ||
114 | #define CHIPREV_ID_5761_A1 0x5761001 | ||
112 | #define GET_ASIC_REV(CHIP_REV_ID) ((CHIP_REV_ID) >> 12) | 115 | #define GET_ASIC_REV(CHIP_REV_ID) ((CHIP_REV_ID) >> 12) |
113 | #define ASIC_REV_5700 0x07 | 116 | #define ASIC_REV_5700 0x07 |
114 | #define ASIC_REV_5701 0x00 | 117 | #define ASIC_REV_5701 0x00 |
@@ -856,7 +859,31 @@ | |||
856 | #define CPMU_CTRL_LINK_IDLE_MODE 0x00000200 | 859 | #define CPMU_CTRL_LINK_IDLE_MODE 0x00000200 |
857 | #define CPMU_CTRL_LINK_AWARE_MODE 0x00000400 | 860 | #define CPMU_CTRL_LINK_AWARE_MODE 0x00000400 |
858 | #define CPMU_CTRL_LINK_SPEED_MODE 0x00004000 | 861 | #define CPMU_CTRL_LINK_SPEED_MODE 0x00004000 |
859 | /* 0x3604 --> 0x365c unused */ | 862 | #define TG3_CPMU_LSPD_10MB_CLK 0x00003604 |
863 | #define CPMU_LSPD_10MB_MACCLK_MASK 0x001f0000 | ||
864 | #define CPMU_LSPD_10MB_MACCLK_6_25 0x00130000 | ||
865 | /* 0x3608 --> 0x360c unused */ | ||
866 | |||
867 | #define TG3_CPMU_LSPD_1000MB_CLK 0x0000360c | ||
868 | #define CPMU_LSPD_1000MB_MACCLK_62_5 0x00000000 | ||
869 | #define CPMU_LSPD_1000MB_MACCLK_12_5 0x00110000 | ||
870 | #define CPMU_LSPD_1000MB_MACCLK_MASK 0x001f0000 | ||
871 | #define TG3_CPMU_LNK_AWARE_PWRMD 0x00003610 | ||
872 | #define CPMU_LNK_AWARE_MACCLK_MASK 0x001f0000 | ||
873 | #define CPMU_LNK_AWARE_MACCLK_6_25 0x00130000 | ||
874 | /* 0x3614 --> 0x361c unused */ | ||
875 | |||
876 | #define TG3_CPMU_HST_ACC 0x0000361c | ||
877 | #define CPMU_HST_ACC_MACCLK_MASK 0x001f0000 | ||
878 | #define CPMU_HST_ACC_MACCLK_6_25 0x00130000 | ||
879 | /* 0x3620 --> 0x3630 unused */ | ||
880 | |||
881 | #define TG3_CPMU_CLCK_STAT 0x00003630 | ||
882 | #define CPMU_CLCK_STAT_MAC_CLCK_MASK 0x001f0000 | ||
883 | #define CPMU_CLCK_STAT_MAC_CLCK_62_5 0x00000000 | ||
884 | #define CPMU_CLCK_STAT_MAC_CLCK_12_5 0x00110000 | ||
885 | #define CPMU_CLCK_STAT_MAC_CLCK_6_25 0x00130000 | ||
886 | /* 0x3634 --> 0x365c unused */ | ||
860 | 887 | ||
861 | #define TG3_CPMU_MUTEX_REQ 0x0000365c | 888 | #define TG3_CPMU_MUTEX_REQ 0x0000365c |
862 | #define CPMU_MUTEX_REQ_DRIVER 0x00001000 | 889 | #define CPMU_MUTEX_REQ_DRIVER 0x00001000 |
@@ -1537,6 +1564,12 @@ | |||
1537 | #define TG3_EEPROM_MAGIC 0x669955aa | 1564 | #define TG3_EEPROM_MAGIC 0x669955aa |
1538 | #define TG3_EEPROM_MAGIC_FW 0xa5000000 | 1565 | #define TG3_EEPROM_MAGIC_FW 0xa5000000 |
1539 | #define TG3_EEPROM_MAGIC_FW_MSK 0xff000000 | 1566 | #define TG3_EEPROM_MAGIC_FW_MSK 0xff000000 |
1567 | #define TG3_EEPROM_SB_FORMAT_MASK 0x00e00000 | ||
1568 | #define TG3_EEPROM_SB_FORMAT_1 0x00200000 | ||
1569 | #define TG3_EEPROM_SB_REVISION_MASK 0x001f0000 | ||
1570 | #define TG3_EEPROM_SB_REVISION_0 0x00000000 | ||
1571 | #define TG3_EEPROM_SB_REVISION_2 0x00020000 | ||
1572 | #define TG3_EEPROM_SB_REVISION_3 0x00030000 | ||
1540 | #define TG3_EEPROM_MAGIC_HW 0xabcd | 1573 | #define TG3_EEPROM_MAGIC_HW 0xabcd |
1541 | #define TG3_EEPROM_MAGIC_HW_MSK 0xffff | 1574 | #define TG3_EEPROM_MAGIC_HW_MSK 0xffff |
1542 | 1575 | ||
@@ -1691,6 +1724,12 @@ | |||
1691 | #define MII_TG3_ISTAT 0x1a /* IRQ status register */ | 1724 | #define MII_TG3_ISTAT 0x1a /* IRQ status register */ |
1692 | #define MII_TG3_IMASK 0x1b /* IRQ mask register */ | 1725 | #define MII_TG3_IMASK 0x1b /* IRQ mask register */ |
1693 | 1726 | ||
1727 | #define MII_TG3_MISC_SHDW 0x1c | ||
1728 | #define MII_TG3_MISC_SHDW_WREN 0x8000 | ||
1729 | #define MII_TG3_MISC_SHDW_APD_SEL 0x2800 | ||
1730 | |||
1731 | #define MII_TG3_MISC_SHDW_APD_WKTM_84MS 0x0001 | ||
1732 | |||
1694 | /* ISTAT/IMASK event bits */ | 1733 | /* ISTAT/IMASK event bits */ |
1695 | #define MII_TG3_INT_LINKCHG 0x0002 | 1734 | #define MII_TG3_INT_LINKCHG 0x0002 |
1696 | #define MII_TG3_INT_SPEEDCHG 0x0004 | 1735 | #define MII_TG3_INT_SPEEDCHG 0x0004 |
@@ -1747,6 +1786,8 @@ | |||
1747 | /* APE convenience enumerations. */ | 1786 | /* APE convenience enumerations. */ |
1748 | #define TG3_APE_LOCK_MEM 4 | 1787 | #define TG3_APE_LOCK_MEM 4 |
1749 | 1788 | ||
1789 | #define TG3_EEPROM_SB_F1R2_MBA_OFF 0x10 | ||
1790 | |||
1750 | 1791 | ||
1751 | /* There are two ways to manage the TX descriptors on the tigon3. | 1792 | /* There are two ways to manage the TX descriptors on the tigon3. |
1752 | * Either the descriptors are in host DMA'able memory, or they | 1793 | * Either the descriptors are in host DMA'able memory, or they |
@@ -2352,6 +2393,7 @@ struct tg3 { | |||
2352 | u32 tg3_flags3; | 2393 | u32 tg3_flags3; |
2353 | #define TG3_FLG3_NO_NVRAM_ADDR_TRANS 0x00000001 | 2394 | #define TG3_FLG3_NO_NVRAM_ADDR_TRANS 0x00000001 |
2354 | #define TG3_FLG3_ENABLE_APE 0x00000002 | 2395 | #define TG3_FLG3_ENABLE_APE 0x00000002 |
2396 | #define TG3_FLG3_5761_5784_AX_FIXES 0x00000004 | ||
2355 | 2397 | ||
2356 | struct timer_list timer; | 2398 | struct timer_list timer; |
2357 | u16 timer_counter; | 2399 | u16 timer_counter; |
diff --git a/drivers/net/tulip/Kconfig b/drivers/net/tulip/Kconfig index 49d7a290dbbc..20ac1503021e 100644 --- a/drivers/net/tulip/Kconfig +++ b/drivers/net/tulip/Kconfig | |||
@@ -24,8 +24,7 @@ config DE2104X | |||
24 | will say Y here.) Do read the Ethernet-HOWTO, available from | 24 | will say Y here.) Do read the Ethernet-HOWTO, available from |
25 | <http://www.tldp.org/docs.html#howto>. | 25 | <http://www.tldp.org/docs.html#howto>. |
26 | 26 | ||
27 | To compile this driver as a module, choose M here and read | 27 | To compile this driver as a module, choose M here. The module will |
28 | <file:Documentation/networking/net-modules.txt>. The module will | ||
29 | be called de2104x. | 28 | be called de2104x. |
30 | 29 | ||
31 | config TULIP | 30 | config TULIP |
@@ -42,8 +41,7 @@ config TULIP | |||
42 | will say Y here.) Do read the Ethernet-HOWTO, available from | 41 | will say Y here.) Do read the Ethernet-HOWTO, available from |
43 | <http://www.tldp.org/docs.html#howto>. | 42 | <http://www.tldp.org/docs.html#howto>. |
44 | 43 | ||
45 | To compile this driver as a module, choose M here and read | 44 | To compile this driver as a module, choose M here. The module will |
46 | <file:Documentation/networking/net-modules.txt>. The module will | ||
47 | be called tulip. | 45 | be called tulip. |
48 | 46 | ||
49 | config TULIP_MWI | 47 | config TULIP_MWI |
@@ -104,8 +102,7 @@ config DE4X5 | |||
104 | information is contained in | 102 | information is contained in |
105 | <file:Documentation/networking/de4x5.txt>. | 103 | <file:Documentation/networking/de4x5.txt>. |
106 | 104 | ||
107 | To compile this driver as a module, choose M here and read | 105 | To compile this driver as a module, choose M here. The module will |
108 | <file:Documentation/networking/net-modules.txt>. The module will | ||
109 | be called de4x5. | 106 | be called de4x5. |
110 | 107 | ||
111 | config WINBOND_840 | 108 | config WINBOND_840 |
@@ -129,8 +126,7 @@ config DM9102 | |||
129 | (Ethernet) card, say Y. Some information is contained in the file | 126 | (Ethernet) card, say Y. Some information is contained in the file |
130 | <file:Documentation/networking/dmfe.txt>. | 127 | <file:Documentation/networking/dmfe.txt>. |
131 | 128 | ||
132 | To compile this driver as a module, choose M here and read | 129 | To compile this driver as a module, choose M here. The module will |
133 | <file:Documentation/networking/net-modules.txt>. The module will | ||
134 | be called dmfe. | 130 | be called dmfe. |
135 | 131 | ||
136 | config ULI526X | 132 | config ULI526X |
@@ -141,8 +137,7 @@ config ULI526X | |||
141 | This driver is for ULi M5261/M5263 10/100M Ethernet Controller | 137 | This driver is for ULi M5261/M5263 10/100M Ethernet Controller |
142 | (<http://www.uli.com.tw/>). | 138 | (<http://www.uli.com.tw/>). |
143 | 139 | ||
144 | To compile this driver as a module, choose M here and read | 140 | To compile this driver as a module, choose M here. The module will |
145 | <file:Documentation/networking/net-modules.txt>. The module will | ||
146 | be called uli526x. | 141 | be called uli526x. |
147 | 142 | ||
148 | config PCMCIA_XIRCOM | 143 | config PCMCIA_XIRCOM |
@@ -154,8 +149,7 @@ config PCMCIA_XIRCOM | |||
154 | as with work-alike chips from Lite-On (PNIC) and Macronix (MXIC) and | 149 | as with work-alike chips from Lite-On (PNIC) and Macronix (MXIC) and |
155 | ASIX. | 150 | ASIX. |
156 | 151 | ||
157 | To compile this driver as a module, choose M here and read | 152 | To compile this driver as a module, choose M here. The module will |
158 | <file:Documentation/networking/net-modules.txt>. The module will | ||
159 | be called xircom_cb. If unsure, say N. | 153 | be called xircom_cb. If unsure, say N. |
160 | 154 | ||
161 | config PCMCIA_XIRTULIP | 155 | config PCMCIA_XIRTULIP |
@@ -168,8 +162,7 @@ config PCMCIA_XIRTULIP | |||
168 | as with work-alike chips from Lite-On (PNIC) and Macronix (MXIC) and | 162 | as with work-alike chips from Lite-On (PNIC) and Macronix (MXIC) and |
169 | ASIX. | 163 | ASIX. |
170 | 164 | ||
171 | To compile this driver as a module, choose M here and read | 165 | To compile this driver as a module, choose M here. The module will |
172 | <file:Documentation/networking/net-modules.txt>. The module will | ||
173 | be called xircom_tulip_cb. If unsure, say N. | 166 | be called xircom_tulip_cb. If unsure, say N. |
174 | 167 | ||
175 | endif # NET_TULIP | 168 | endif # NET_TULIP |