summaryrefslogtreecommitdiffstats
path: root/drivers/net/cxgb3/cxgb3_offload.c
diff options
context:
space:
mode:
authorDivy Le Ray <divy@chelsio.com>2007-08-21 20:49:21 -0700
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 16:50:49 -0700
commite22bb45d772b5e5c850a6223c2a3245f520de641 (patch)
treeb386f5e9d7e3ee953ecfdc6997a9cfdfe33e2312 /drivers/net/cxgb3/cxgb3_offload.c
parent27186dc325c3bbb937a27a2467cefd64e2505158 (diff)
downloadblackbird-op-linux-e22bb45d772b5e5c850a6223c2a3245f520de641.tar.gz
blackbird-op-linux-e22bb45d772b5e5c850a6223c2a3245f520de641.zip
cxgb3 - Expose HW memory page info
A HW issue requires limiting the receive window size to 23 pages of internal memory. These pages can be configured to different sizes, thus the RDMA driver needs to know the page size to enforce the upper limit. Also assign explicit enum values. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/cxgb3/cxgb3_offload.c')
-rw-r--r--drivers/net/cxgb3/cxgb3_offload.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/cxgb3/cxgb3_offload.c b/drivers/net/cxgb3/cxgb3_offload.c
index bdff7baeb59d..bac9214170ae 100644
--- a/drivers/net/cxgb3/cxgb3_offload.c
+++ b/drivers/net/cxgb3/cxgb3_offload.c
@@ -317,6 +317,8 @@ static int cxgb_offload_ctl(struct t3cdev *tdev, unsigned int req, void *data)
struct iff_mac *iffmacp;
struct ddp_params *ddpp;
struct adap_ports *ports;
+ struct ofld_page_info *rx_page_info;
+ struct tp_params *tp = &adapter->params.tp;
int i;
switch (req) {
@@ -382,6 +384,11 @@ static int cxgb_offload_ctl(struct t3cdev *tdev, unsigned int req, void *data)
if (!offload_running(adapter))
return -EAGAIN;
return cxgb_rdma_ctl(adapter, req, data);
+ case GET_RX_PAGE_INFO:
+ rx_page_info = data;
+ rx_page_info->page_size = tp->rx_pg_size;
+ rx_page_info->num = tp->rx_num_pgs;
+ break;
default:
return -EOPNOTSUPP;
}
OpenPOWER on IntegriCloud