From 50acd538c77a8bcf4826ddbc719a0c02cc1ba5fb Mon Sep 17 00:00:00 2001 From: Jason Wright Date: Sun, 23 Sep 2001 20:03:02 +0000 Subject: solve mtu problem a little more elegantly (ramdisk works on blade100 and u5 now). --- sys/dev/ic/gem.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'sys/dev/ic/gem.c') diff --git a/sys/dev/ic/gem.c b/sys/dev/ic/gem.c index 1291126b92f..a487bc5ed59 100644 --- a/sys/dev/ic/gem.c +++ b/sys/dev/ic/gem.c @@ -748,12 +748,8 @@ if (gem_opdebug) printf("in init\n"); /* step 4. TX MAC registers & counters */ gem_init_regs(sc); - v = ETHERMTU + sizeof(struct ether_header) + 50 + -#if NVLAN > 0 - EVL_ENCAPLEN + -#endif - 0; - bus_space_write_4(t, h, GEM_MAC_MAC_MAX_FRAME, (v) | (0x2000<<16)); + v = (GEM_MTU) | (0x2000 << 16) /* Burst size */; + bus_space_write_4(t, h, GEM_MAC_MAC_MAX_FRAME, v); /* step 5. RX MAC registers & counters */ gem_setladrf(sc); @@ -891,11 +887,7 @@ gem_init_regs(struct gem_softc *sc) bus_space_write_4(t, h, GEM_MAC_MAC_MIN_FRAME, ETHER_MIN_LEN); /* Max frame and max burst size */ - v = ((ETHERMTU + sizeof(struct ether_header) + 50 + -#if NVLAN > 0 - EVL_ENCAPLEN + -#endif - 0) | (0x2000<<16) /* Burst size */); + v = (GEM_MTU) | (0x2000 << 16) /* Burst size */; bus_space_write_4(t, h, GEM_MAC_MAC_MAX_FRAME, v); bus_space_write_4(t, h, GEM_MAC_PREAMBLE_LEN, 0x7); bus_space_write_4(t, h, GEM_MAC_JAM_SIZE, 0x4); -- cgit v1.2.3