cxgbe(4): Get Linux cxgb4vf working in bhyve VMs with VFs passed

through.

cxgb4vf doesn't own the buffer size list but still expects the first two
entries to be 4K and some power of 2 respectively.  The BSD cxgbe
doesn't care where its preferred buffer sizes are as long as they're in
the list somewhere, so just move its entries towards the end as a
workaround.

MFC after:	1 month
Sponsored by:	Chelsio Communicatons
This commit is contained in:
Navdeep Parhar 2018-12-06 21:33:08 +00:00
parent 407345752d
commit 9b11a65d1c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=341654

View File

@ -701,8 +701,10 @@ t4_tweak_chip_settings(struct adapter *sc)
KASSERT(nitems(sge_flbuf_sizes) <= SGE_FLBUF_SIZES,
("%s: hw buffer size table too big", __func__));
t4_write_reg(sc, A_SGE_FL_BUFFER_SIZE0, 4096);
t4_write_reg(sc, A_SGE_FL_BUFFER_SIZE1, 65536);
for (i = 0; i < min(nitems(sge_flbuf_sizes), SGE_FLBUF_SIZES); i++) {
t4_write_reg(sc, A_SGE_FL_BUFFER_SIZE0 + (4 * i),
t4_write_reg(sc, A_SGE_FL_BUFFER_SIZE15 - (4 * i),
sge_flbuf_sizes[i]);
}