Date: Wed, 26 Nov 2014 00:44:49 +0000 (UTC) From: Navdeep Parhar <np@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r275092 - in stable/10/sys/dev/cxgbe: . common Message-ID: <201411260044.sAQ0inxp089616@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: np Date: Wed Nov 26 00:44:48 2014 New Revision: 275092 URL: https://svnweb.freebsd.org/changeset/base/275092 Log: MFC r274724: cxgbe(4): figure out the max payload size and save it for later. Modified: stable/10/sys/dev/cxgbe/common/common.h stable/10/sys/dev/cxgbe/t4_main.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/cxgbe/common/common.h ============================================================================== --- stable/10/sys/dev/cxgbe/common/common.h Wed Nov 26 00:13:51 2014 (r275091) +++ stable/10/sys/dev/cxgbe/common/common.h Wed Nov 26 00:44:48 2014 (r275092) @@ -238,6 +238,7 @@ struct vpd_params { struct pci_params { unsigned int vpd_cap_addr; + unsigned int mps; unsigned short speed; unsigned short width; }; Modified: stable/10/sys/dev/cxgbe/t4_main.c ============================================================================== --- stable/10/sys/dev/cxgbe/t4_main.c Wed Nov 26 00:13:51 2014 (r275091) +++ stable/10/sys/dev/cxgbe/t4_main.c Wed Nov 26 00:44:48 2014 (r275092) @@ -590,6 +590,8 @@ t4_attach(device_t dev) v = pci_read_config(dev, i + PCIER_DEVICE_CTL, 2); v |= PCIEM_CTL_RELAXED_ORD_ENABLE; pci_write_config(dev, i + PCIER_DEVICE_CTL, v, 2); + + sc->params.pci.mps = 128 << ((v & PCIEM_CTL_MAX_PAYLOAD) >> 5); } sc->traceq = -1;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201411260044.sAQ0inxp089616>