net: pcnet: Remove CONFIG_PCNET_79C97x

These macros guard one switch-case statement, which grows mips malta
by some 20 bytes if debug is enabled, and even less if it is not. To
make the code simpler, just support all the NICs and be done with it.

Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Joe Hershberger <joe.hershberger@ni.com>
This commit is contained in:
Marek Vasut 2020-04-18 01:44:12 +02:00 committed by marex
parent f2c5564f75
commit 635a76b703
3 changed files with 0 additions and 11 deletions

View File

@ -21,10 +21,6 @@
#define PCNET_DEBUG2(fmt,args...) \ #define PCNET_DEBUG2(fmt,args...) \
debug_cond(PCNET_DEBUG_LEVEL > 1, fmt ,##args) debug_cond(PCNET_DEBUG_LEVEL > 1, fmt ,##args)
#if !defined(CONF_PCNET_79C973) && defined(CONF_PCNET_79C975)
#error "Macro for PCnet chip version is not defined!"
#endif
/* /*
* Set the number of Tx and Rx buffers, using Log_2(# buffers). * Set the number of Tx and Rx buffers, using Log_2(# buffers).
* Reasonable default values are 4 Tx buffers, and 16 Rx buffers. * Reasonable default values are 4 Tx buffers, and 16 Rx buffers.
@ -254,16 +250,12 @@ static int pcnet_probe(struct eth_device *dev, bd_t *bis, int dev_nr)
case 0x2621: case 0x2621:
chipname = "PCnet/PCI II 79C970A"; /* PCI */ chipname = "PCnet/PCI II 79C970A"; /* PCI */
break; break;
#ifdef CONFIG_PCNET_79C973
case 0x2625: case 0x2625:
chipname = "PCnet/FAST III 79C973"; /* PCI */ chipname = "PCnet/FAST III 79C973"; /* PCI */
break; break;
#endif
#ifdef CONFIG_PCNET_79C975
case 0x2627: case 0x2627:
chipname = "PCnet/FAST III 79C975"; /* PCI */ chipname = "PCnet/FAST III 79C975"; /* PCI */
break; break;
#endif
default: default:
printf("%s: PCnet version %#x not supported\n", printf("%s: PCnet version %#x not supported\n",
dev->name, chip_version); dev->name, chip_version);

View File

@ -16,7 +16,6 @@
#define CONFIG_PCI_GT64120 #define CONFIG_PCI_GT64120
#define CONFIG_PCI_MSC01 #define CONFIG_PCI_MSC01
#define CONFIG_PCNET #define CONFIG_PCNET
#define CONFIG_PCNET_79C973
#define PCNET_HAS_PROM #define PCNET_HAS_PROM
#define CONFIG_SYS_ISA_IO_BASE_ADDRESS 0 #define CONFIG_SYS_ISA_IO_BASE_ADDRESS 0

View File

@ -1292,8 +1292,6 @@ CONFIG_PCI_SYS_BUS
CONFIG_PCI_SYS_PHYS CONFIG_PCI_SYS_PHYS
CONFIG_PCI_SYS_SIZE CONFIG_PCI_SYS_SIZE
CONFIG_PCNET CONFIG_PCNET
CONFIG_PCNET_79C973
CONFIG_PCNET_79C975
CONFIG_PEN_ADDR_BIG_ENDIAN CONFIG_PEN_ADDR_BIG_ENDIAN
CONFIG_PERIF1_FREQ CONFIG_PERIF1_FREQ
CONFIG_PERIF2_FREQ CONFIG_PERIF2_FREQ