Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci Use 12K for packet buffer for jumbo frame on PCH...



details:   https://anonhg.NetBSD.org/src/rev/c837c91af1ad
branches:  trunk
changeset: 955049:c837c91af1ad
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Wed Sep 16 15:04:57 2020 +0000

description:
Use 12K for packet buffer for jumbo frame on PCH2 and newer.

XXX Note that Linux Use 14K.

diffstat:

 sys/dev/pci/if_wm.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (28 lines):

diff -r edd332bef878 -r c837c91af1ad sys/dev/pci/if_wm.c
--- a/sys/dev/pci/if_wm.c       Wed Sep 16 15:04:01 2020 +0000
+++ b/sys/dev/pci/if_wm.c       Wed Sep 16 15:04:57 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_wm.c,v 1.688 2020/09/16 15:04:01 msaitoh Exp $      */
+/*     $NetBSD: if_wm.c,v 1.689 2020/09/16 15:04:57 msaitoh Exp $      */
 
 /*
  * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc.
@@ -82,7 +82,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.688 2020/09/16 15:04:01 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.689 2020/09/16 15:04:57 msaitoh Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_net_mpsafe.h"
@@ -4873,7 +4873,8 @@
        case WM_T_PCH_LPT:
        case WM_T_PCH_SPT:
        case WM_T_PCH_CNP:
-               sc->sc_pba = PBA_26K;
+               sc->sc_pba = sc->sc_ethercom.ec_if.if_mtu > 1500 ?
+                   PBA_12K : PBA_26K;
                break;
        default:
                sc->sc_pba = sc->sc_ethercom.ec_if.if_mtu > 8192 ?



Home | Main Index | Thread Index | Old Index