[PATCH] ne2k-pci
[Sorry if this message is dup. I sent it to the list but did not see it, so I think this was a problem with my mailer or ISP] This is a port of the new 1.02 features of the ne2k-pci driver to kernel 2.2.18. Reviewed by Donald Becker, and tested on 2.2.18, 19-pre1 and pre2. New features: - module info - full duplex support in RealTek and Holtek cards. Must be activated on module load with full_duplex=1, (up to 6 cards). The patch does not use the pci stuff that D.Becker included in the scyld drivers ===> Question: is there any similar pci stuff in 2.2.18 and a driver to look at its use ? Thanks.ñ ==== patch-ne2k-pci --- linux/drivers/net/ne2k-pci.c.orgSun Dec 17 01:51:04 2000 +++ linux/drivers/net/ne2k-pci.cTue Dec 19 01:48:00 2000 @@ -12,19 +12,31 @@ This software may be used and distributed according to the terms of the GNU Public License, incorporated herein by reference. - The author may be reached as [EMAIL PROTECTED], or C/O - Center of Excellence in Space Data and Information Sciences - Code 930.5, Goddard Space Flight Center, Greenbelt MD 20771 + Drivers based on or derived from this code fall under the GPL and must + retain the authorship, copyright and license notice. This file is not + a complete program and may only be used when the entire operating + system is licensed under the GPL. + + The author may be reached as [EMAIL PROTECTED], or C/O + Scyld Computing Corporation + 410 Severn Ave., Suite 210 + Annapolis MD 21403 + Issues remaining: People are making PCI ne2000 clones! Oh the horror, the horror... + Limited full-duplex support. - Issues remaining: - No full-duplex support. + ChangeLog: + + 12/15/2000 Merged Scyld v1.02 into 2.2.18 + J.A. Magallon +<[EMAIL PROTECTED]> */ -/* Our copyright info must remain in the binary. */ -static const char *version = -"ne2k-pci.c:vpre-1.00e 5/27/99 D. Becker/P. Gortmaker http://cesdis.gsfc.nasa.gov/linux/drivers/ne2k-pci.html\n"; +/* These identify the driver base version and may not be removed. */ +static const char version1[] = +"ne2k-pci.c:v1.02 10/19/2000 D. Becker/P. Gortmaker\n"; +static const char version2[] = +" http://www.scyld.com/network/ne2k-pci.html\n"; #include #include @@ -49,7 +61,18 @@ #endif /* Set statically or when loading the driver module. */ -static int debug = 1; +static int debug = 1; /* 1 normal messages, 0 quiet .. 7 verbose. */ +/* More are supported, limit only on options */ +#define MAX_UNITS 6 +/* Used to pass the full-duplex flag, etc. */ +static int full_duplex[MAX_UNITS] = {0, }; +static int options[MAX_UNITS] = {0, }; + +MODULE_AUTHOR("Donald Becker / Paul Gortmaker"); +MODULE_DESCRIPTION("PCI NE2000 clone driver"); +MODULE_PARM(debug, "i"); +MODULE_PARM(options, "1-" __MODULE_STRING(MAX_UNITS) "i"); +MODULE_PARM(full_duplex, "1-" __MODULE_STRING(MAX_UNITS) "i"); /* Some defines that people can play with if so inclined. */ @@ -62,12 +85,13 @@ /* Do we have a non std. amount of memory? (in units of 256 byte pages) */ /* #define PACKETBUF_MEMSIZE 0x40 */ -#define ne2k_flags reg0/* Rename an existing field to store flags! */ - -/* Only the low 8 bits are usable for non-init-time flags! */ +/* Flags. We rename an existing ei_status field to store flags! */ +/* Thus only the low 8 bits are usable for non-init-time flags. */ +#define ne2k_flags reg0 enum { - HOLTEK_FDX=1, /* Full duplex -> set 0x80 at offset 0x20. */ - ONLY_16BIT_IO=2, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + ONLY_16BIT_IO=8, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + FORCE_FDX=0x20, /* User override. */ + REALTEK_FDX=0x40, HOLTEK_FDX=0x80, STOP_PG_0x60=0x100, }; @@ -79,18 +103,17 @@ int flags; } pci_clone_list[] __initdata = { - {0x10ec, 0x8029, "RealTek RTL-8029", 0}, - {0x1050, 0x0940, "Winbond 89C940", 0}, - {0x11f6, 0x1401, "Compex RL2000", 0}, - {0x8e2e, 0x3000, "KTI ET32P2", 0}, - {0x4a14, 0x5000, "NetVin NV5000SC", 0}, - {0x1106, 0x0926, "Via 86C926", ONLY_16BIT_IO}, - {0x10bd, 0x0e34, "SureCom NE34", 0}, - {0x1050, 0x5a5a, "Winbond", 0}, - {0x12c3, 0x0058, "Holtek HT80232", ONLY_16BIT_IO | HOLTEK_FDX}, - {0x12c3, 0x5598, "Holtek HT80229", -ONLY_32BIT_IO | HOLTEK_FDX | STOP_PG_0x60 }, - {0,} +{0x10ec, 0x8029, "RealTek RTL-8029", REALTEK_FDX}, +{0x1050, 0x0940, "Winbond 89C940", 0}, +{0x1050, 0x5a5a, "Winbond w89c940", 0}, +{0x8e2e,
[PATCH] ne2k-pci
[Sorry if this message is dup. I sent it to the list but did not see it, so I think this was a problem with my mailer or ISP] This is a port of the new 1.02 features of the ne2k-pci driver to kernel 2.2.18. Reviewed by Donald Becker, and tested on 2.2.18, 19-pre1 and pre2. New features: - module info - full duplex support in RealTek and Holtek cards. Must be activated on module load with full_duplex=1, (up to 6 cards). The patch does not use the pci stuff that D.Becker included in the scyld drivers === Question: is there any similar pci stuff in 2.2.18 and a driver to look at its use ? Thanks.ñ patch-ne2k-pci --- linux/drivers/net/ne2k-pci.c.orgSun Dec 17 01:51:04 2000 +++ linux/drivers/net/ne2k-pci.cTue Dec 19 01:48:00 2000 @@ -12,19 +12,31 @@ This software may be used and distributed according to the terms of the GNU Public License, incorporated herein by reference. - The author may be reached as [EMAIL PROTECTED], or C/O - Center of Excellence in Space Data and Information Sciences - Code 930.5, Goddard Space Flight Center, Greenbelt MD 20771 + Drivers based on or derived from this code fall under the GPL and must + retain the authorship, copyright and license notice. This file is not + a complete program and may only be used when the entire operating + system is licensed under the GPL. + + The author may be reached as [EMAIL PROTECTED], or C/O + Scyld Computing Corporation + 410 Severn Ave., Suite 210 + Annapolis MD 21403 + Issues remaining: People are making PCI ne2000 clones! Oh the horror, the horror... + Limited full-duplex support. - Issues remaining: - No full-duplex support. + ChangeLog: + + 12/15/2000 Merged Scyld v1.02 into 2.2.18 + J.A. Magallon +[EMAIL PROTECTED] */ -/* Our copyright info must remain in the binary. */ -static const char *version = -"ne2k-pci.c:vpre-1.00e 5/27/99 D. Becker/P. Gortmaker http://cesdis.gsfc.nasa.gov/linux/drivers/ne2k-pci.html\n"; +/* These identify the driver base version and may not be removed. */ +static const char version1[] = +"ne2k-pci.c:v1.02 10/19/2000 D. Becker/P. Gortmaker\n"; +static const char version2[] = +" http://www.scyld.com/network/ne2k-pci.html\n"; #include linux/module.h #include linux/kernel.h @@ -49,7 +61,18 @@ #endif /* Set statically or when loading the driver module. */ -static int debug = 1; +static int debug = 1; /* 1 normal messages, 0 quiet .. 7 verbose. */ +/* More are supported, limit only on options */ +#define MAX_UNITS 6 +/* Used to pass the full-duplex flag, etc. */ +static int full_duplex[MAX_UNITS] = {0, }; +static int options[MAX_UNITS] = {0, }; + +MODULE_AUTHOR("Donald Becker / Paul Gortmaker"); +MODULE_DESCRIPTION("PCI NE2000 clone driver"); +MODULE_PARM(debug, "i"); +MODULE_PARM(options, "1-" __MODULE_STRING(MAX_UNITS) "i"); +MODULE_PARM(full_duplex, "1-" __MODULE_STRING(MAX_UNITS) "i"); /* Some defines that people can play with if so inclined. */ @@ -62,12 +85,13 @@ /* Do we have a non std. amount of memory? (in units of 256 byte pages) */ /* #define PACKETBUF_MEMSIZE 0x40 */ -#define ne2k_flags reg0/* Rename an existing field to store flags! */ - -/* Only the low 8 bits are usable for non-init-time flags! */ +/* Flags. We rename an existing ei_status field to store flags! */ +/* Thus only the low 8 bits are usable for non-init-time flags. */ +#define ne2k_flags reg0 enum { - HOLTEK_FDX=1, /* Full duplex - set 0x80 at offset 0x20. */ - ONLY_16BIT_IO=2, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + ONLY_16BIT_IO=8, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + FORCE_FDX=0x20, /* User override. */ + REALTEK_FDX=0x40, HOLTEK_FDX=0x80, STOP_PG_0x60=0x100, }; @@ -79,18 +103,17 @@ int flags; } pci_clone_list[] __initdata = { - {0x10ec, 0x8029, "RealTek RTL-8029", 0}, - {0x1050, 0x0940, "Winbond 89C940", 0}, - {0x11f6, 0x1401, "Compex RL2000", 0}, - {0x8e2e, 0x3000, "KTI ET32P2", 0}, - {0x4a14, 0x5000, "NetVin NV5000SC", 0}, - {0x1106, 0x0926, "Via 86C926", ONLY_16BIT_IO}, - {0x10bd, 0x0e34, "SureCom NE34", 0}, - {0x1050, 0x5a5a, "Winbond", 0}, - {0x12c3, 0x0058, "Holtek HT80232", ONLY_16BIT_IO | HOLTEK_FDX}, - {0x12c3, 0x5598, "Holtek HT80229", -ONLY_32BIT_IO | HOLTEK_FDX | STOP_PG_0x60 }, - {0,} +{0x10ec, 0x8029, "RealTek RTL-8029", REALTEK_FDX}, +{0x1050, 0x0940, "Winbond 89C940", 0}, +{0x1050, 0x5a5a, "Winbond w89c940"
[PATCH] ne2k-pci update
Hi, everyone. Here is a patch to update the 2.2.18 driver for ne2k-pci cards to 1.02 version. Reviewed by Donald Becker, tried on 18, 19-pre1 and 19-pre2. Changes: - full duplex support on Realtek and Holtek cards, ignored on others. - module params debug=1 (0..7) full_duplex=1,0,1 ... (up to 6 supported cards) NOTE: full duplex is not active by default. Please apply for 19-preX... -- patch-ne2k-pci --- linux/drivers/net/ne2k-pci.c.orgSun Dec 17 01:51:04 2000 +++ linux/drivers/net/ne2k-pci.cSun Dec 17 01:55:22 2000 @@ -12,19 +12,31 @@ This software may be used and distributed according to the terms of the GNU Public License, incorporated herein by reference. - The author may be reached as [EMAIL PROTECTED], or C/O - Center of Excellence in Space Data and Information Sciences - Code 930.5, Goddard Space Flight Center, Greenbelt MD 20771 + Drivers based on or derived from this code fall under the GPL and must + retain the authorship, copyright and license notice. This file is not + a complete program and may only be used when the entire operating + system is licensed under the GPL. + + The author may be reached as [EMAIL PROTECTED], or C/O + Scyld Computing Corporation + 410 Severn Ave., Suite 210 + Annapolis MD 21403 + Issues remaining: People are making PCI ne2000 clones! Oh the horror, the horror... + Limited full-duplex support. - Issues remaining: - No full-duplex support. + ChangeLog: + + 12/15/2000 Merged Scyld v1.02 into 2.2.18 + J.A. Magallon +<[EMAIL PROTECTED]> */ -/* Our copyright info must remain in the binary. */ -static const char *version = -"ne2k-pci.c:vpre-1.00e 5/27/99 D. Becker/P. Gortmaker http://cesdis.gsfc.nasa.gov/linux/drivers/ne2k-pci.html\n"; +/* These identify the driver base version and may not be removed. */ +static const char version1[] = +"ne2k-pci.c:v1.02 10/19/2000 D. Becker/P. Gortmaker\n"; +static const char version2[] = +" http://www.scyld.com/network/ne2k-pci.html\n"; #include #include @@ -49,7 +61,18 @@ #endif /* Set statically or when loading the driver module. */ -static int debug = 1; +static int debug = 1; /* 1 normal messages, 0 quiet .. 7 verbose. */ +/* More are supported, limit only on options */ +#define MAX_UNITS 6 +/* Used to pass the full-duplex flag, etc. */ +static int full_duplex[MAX_UNITS] = {0, }; +static int options[MAX_UNITS] = {0, }; + +MODULE_AUTHOR("Donald Becker / Paul Gortmaker"); +MODULE_DESCRIPTION("PCI NE2000 clone driver"); +MODULE_PARM(debug, "i"); +MODULE_PARM(options, "1-" __MODULE_STRING(MAX_UNITS) "i"); +MODULE_PARM(full_duplex, "1-" __MODULE_STRING(MAX_UNITS) "i"); /* Some defines that people can play with if so inclined. */ @@ -62,12 +85,13 @@ /* Do we have a non std. amount of memory? (in units of 256 byte pages) */ /* #define PACKETBUF_MEMSIZE 0x40 */ -#define ne2k_flags reg0/* Rename an existing field to store flags! */ - -/* Only the low 8 bits are usable for non-init-time flags! */ +/* Flags. We rename an existing ei_status field to store flags! */ +/* Thus only the low 8 bits are usable for non-init-time flags. */ +#define ne2k_flags reg0 enum { - HOLTEK_FDX=1, /* Full duplex -> set 0x80 at offset 0x20. */ - ONLY_16BIT_IO=2, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + ONLY_16BIT_IO=8, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + FORCE_FDX=0x20, /* User override. */ + REALTEK_FDX=0x40, HOLTEK_FDX=0x80, STOP_PG_0x60=0x100, }; @@ -79,18 +103,17 @@ int flags; } pci_clone_list[] __initdata = { - {0x10ec, 0x8029, "RealTek RTL-8029", 0}, - {0x1050, 0x0940, "Winbond 89C940", 0}, - {0x11f6, 0x1401, "Compex RL2000", 0}, - {0x8e2e, 0x3000, "KTI ET32P2", 0}, - {0x4a14, 0x5000, "NetVin NV5000SC", 0}, - {0x1106, 0x0926, "Via 86C926", ONLY_16BIT_IO}, - {0x10bd, 0x0e34, "SureCom NE34", 0}, - {0x1050, 0x5a5a, "Winbond", 0}, - {0x12c3, 0x0058, "Holtek HT80232", ONLY_16BIT_IO | HOLTEK_FDX}, - {0x12c3, 0x5598, "Holtek HT80229", -ONLY_32BIT_IO | HOLTEK_FDX | STOP_PG_0x60 }, - {0,} +{0x10ec, 0x8029, "RealTek RTL-8029", REALTEK_FDX}, +{0x1050, 0x0940, "Winbond 89C940", 0}, +{0x1050, 0x5a5a, "Winbond w89c940", 0}, +{0x8e2e, 0x3000, "KTI ET32P2", 0}, +{0x4a14, 0x5000, "NetVin NV5000SC", 0}, +{0x1106, 0x0926, "Via 86C926", ONLY_16BIT_IO}, +{0x10bd, 0x0e34, "SureCom NE34", 0}, +{0x12c3, 0x0058, &quo
[PATCH] ne2k-pci update
Hi, everyone. Here is a patch to update the 2.2.18 driver for ne2k-pci cards to 1.02 version. Reviewed by Donald Becker, tried on 18, 19-pre1 and 19-pre2. Changes: - full duplex support on Realtek and Holtek cards, ignored on others. - module params debug=1 (0..7) full_duplex=1,0,1 ... (up to 6 supported cards) NOTE: full duplex is not active by default. Please apply for 19-preX... -- patch-ne2k-pci --- linux/drivers/net/ne2k-pci.c.orgSun Dec 17 01:51:04 2000 +++ linux/drivers/net/ne2k-pci.cSun Dec 17 01:55:22 2000 @@ -12,19 +12,31 @@ This software may be used and distributed according to the terms of the GNU Public License, incorporated herein by reference. - The author may be reached as [EMAIL PROTECTED], or C/O - Center of Excellence in Space Data and Information Sciences - Code 930.5, Goddard Space Flight Center, Greenbelt MD 20771 + Drivers based on or derived from this code fall under the GPL and must + retain the authorship, copyright and license notice. This file is not + a complete program and may only be used when the entire operating + system is licensed under the GPL. + + The author may be reached as [EMAIL PROTECTED], or C/O + Scyld Computing Corporation + 410 Severn Ave., Suite 210 + Annapolis MD 21403 + Issues remaining: People are making PCI ne2000 clones! Oh the horror, the horror... + Limited full-duplex support. - Issues remaining: - No full-duplex support. + ChangeLog: + + 12/15/2000 Merged Scyld v1.02 into 2.2.18 + J.A. Magallon +[EMAIL PROTECTED] */ -/* Our copyright info must remain in the binary. */ -static const char *version = -"ne2k-pci.c:vpre-1.00e 5/27/99 D. Becker/P. Gortmaker http://cesdis.gsfc.nasa.gov/linux/drivers/ne2k-pci.html\n"; +/* These identify the driver base version and may not be removed. */ +static const char version1[] = +"ne2k-pci.c:v1.02 10/19/2000 D. Becker/P. Gortmaker\n"; +static const char version2[] = +" http://www.scyld.com/network/ne2k-pci.html\n"; #include linux/module.h #include linux/kernel.h @@ -49,7 +61,18 @@ #endif /* Set statically or when loading the driver module. */ -static int debug = 1; +static int debug = 1; /* 1 normal messages, 0 quiet .. 7 verbose. */ +/* More are supported, limit only on options */ +#define MAX_UNITS 6 +/* Used to pass the full-duplex flag, etc. */ +static int full_duplex[MAX_UNITS] = {0, }; +static int options[MAX_UNITS] = {0, }; + +MODULE_AUTHOR("Donald Becker / Paul Gortmaker"); +MODULE_DESCRIPTION("PCI NE2000 clone driver"); +MODULE_PARM(debug, "i"); +MODULE_PARM(options, "1-" __MODULE_STRING(MAX_UNITS) "i"); +MODULE_PARM(full_duplex, "1-" __MODULE_STRING(MAX_UNITS) "i"); /* Some defines that people can play with if so inclined. */ @@ -62,12 +85,13 @@ /* Do we have a non std. amount of memory? (in units of 256 byte pages) */ /* #define PACKETBUF_MEMSIZE 0x40 */ -#define ne2k_flags reg0/* Rename an existing field to store flags! */ - -/* Only the low 8 bits are usable for non-init-time flags! */ +/* Flags. We rename an existing ei_status field to store flags! */ +/* Thus only the low 8 bits are usable for non-init-time flags. */ +#define ne2k_flags reg0 enum { - HOLTEK_FDX=1, /* Full duplex - set 0x80 at offset 0x20. */ - ONLY_16BIT_IO=2, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + ONLY_16BIT_IO=8, ONLY_32BIT_IO=4, /* Chip can do only 16/32-bit xfers. */ + FORCE_FDX=0x20, /* User override. */ + REALTEK_FDX=0x40, HOLTEK_FDX=0x80, STOP_PG_0x60=0x100, }; @@ -79,18 +103,17 @@ int flags; } pci_clone_list[] __initdata = { - {0x10ec, 0x8029, "RealTek RTL-8029", 0}, - {0x1050, 0x0940, "Winbond 89C940", 0}, - {0x11f6, 0x1401, "Compex RL2000", 0}, - {0x8e2e, 0x3000, "KTI ET32P2", 0}, - {0x4a14, 0x5000, "NetVin NV5000SC", 0}, - {0x1106, 0x0926, "Via 86C926", ONLY_16BIT_IO}, - {0x10bd, 0x0e34, "SureCom NE34", 0}, - {0x1050, 0x5a5a, "Winbond", 0}, - {0x12c3, 0x0058, "Holtek HT80232", ONLY_16BIT_IO | HOLTEK_FDX}, - {0x12c3, 0x5598, "Holtek HT80229", -ONLY_32BIT_IO | HOLTEK_FDX | STOP_PG_0x60 }, - {0,} +{0x10ec, 0x8029, "RealTek RTL-8029", REALTEK_FDX}, +{0x1050, 0x0940, "Winbond 89C940", 0}, +{0x1050, 0x5a5a, "Winbond w89c940", 0}, +{0x8e2e, 0x3000, "KTI ET32P2", 0}, +{0x4a14, 0x5000, "NetVin NV5000SC", 0}, +{0x1106, 0x0926, "Via 86C926", ONLY_16BIT_IO}, +{0x10bd, 0x0e34, "SureCom NE34", 0}, +{