Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

cxgb4: Export sge_host_page_size to ulds

Export the sge_host_page_size field to ULDs via cxgb4_lld_info, so that
iw_cxgb4 can make use of this in calculating the correct qp/cq mask.

Fixes: 2391b0030e24 ("cxgb4: Remove SGE_HOST_PAGE_SIZE dependency on page size")
Signed-off-by: Raju Rangoju <rajur@chelsio.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>

authored by

Raju Rangoju and committed by
Jason Gunthorpe
fc4144e7 48396e80

+2
+1
drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c
··· 660 660 lld->cclk_ps = 1000000000 / adap->params.vpd.cclk; 661 661 lld->udb_density = 1 << adap->params.sge.eq_qpp; 662 662 lld->ucq_density = 1 << adap->params.sge.iq_qpp; 663 + lld->sge_host_page_size = 1 << (adap->params.sge.hps + 10); 663 664 lld->filt_mode = adap->params.tp.vlan_pri_map; 664 665 /* MODQ_REQ_MAP sets queues 0-3 to chan 0-3 */ 665 666 for (i = 0; i < NCHAN; i++)
+1
drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.h
··· 336 336 unsigned int cclk_ps; /* Core clock period in psec */ 337 337 unsigned short udb_density; /* # of user DB/page */ 338 338 unsigned short ucq_density; /* # of user CQs/page */ 339 + unsigned int sge_host_page_size; /* SGE host page size */ 339 340 unsigned short filt_mode; /* filter optional components */ 340 341 unsigned short tx_modq[NCHAN]; /* maps each tx channel to a */ 341 342 /* scheduler queue */