summaryrefslogtreecommitdiff
path: root/drivers/infiniband/hw/ocrdma/ocrdma_sli.h
Commit message (Collapse)AuthorAgeFilesLines
* RDMA/ocrdma: Code clean-upDevesh Sharma2014-04-031-8/+8
| | | | | | | | Clean up code. Also modifying GSI QP to error during ocrdma_close is fixed. Signed-off-by: Devesh Sharma <devesh.sharma@emulex.com> Signed-off-by: Selvin Xavier <selvin.xavier@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Query controller informationSelvin Xavier2014-04-031-1/+232
| | | | | | | | | Issue mailbox commands to query ocrdma controller information and phy information and print them while adding ocrdma device. Signed-off-by: Selvin Xavier <selvin.xavier@emulex.com> Signed-off-by: Devesh Sharma <devesh.sharma@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Read ASIC_ID register to select asic_genDevesh Sharma2014-04-031-2/+15
| | | | | | | | | | ocrdma driver selects execution path based on sli_family and asic generation number. This introduces code to read the asic gen number from pci register instead of obtaining it from the Emulex NIC driver. Signed-off-by: Devesh Sharma <devesh.sharma@emulex.com> Signed-off-by: Selvin Xavier <selvin.xavier@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: SQ and RQ doorbell offset clean upDevesh Sharma2014-04-031-1/+4
| | | | | | | | Introducing new macros to define SQ and RQ doorbell offset. Signed-off-by: Devesh Sharma <devesh.sharma@emulex.com> Signed-off-by: Selvin Xavier <selvin.xavier@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Fix OCRDMA_GEN2_FAMILY macro definitionDevesh Sharma2014-01-131-1/+1
| | | | | | | OCRDMA_GEN2_FAMILY is wrongly defined as 0x02 -- it should be 0x0F. Signed-off-by: Devesh Sharma <devesh.sharma@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Fix AV_VALID bit positionDevesh Sharma2014-01-131-1/+1
| | | | | | | Fix ah->av->valid bit position and big endian portability. Signed-off-by: Devesh Sharma <devesh.sharma@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Fill PVID in UMC caseNaresh Gottumukkala2013-09-021-1/+17
| | | | | | | | In UMC case, driver needs to fill PVID in the address vector template for UD traffic. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Fix for displaying proper link speedNaresh Gottumukkala2013-09-021-0/+27
| | | | | Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Increase STAG array sizeNaresh Gottumukkala2013-09-021-1/+1
| | | | | | | | | | | 1) Increase STAG Array size. 2) Max inline data size should be set to the same value used during QP creation 3) Set max_sge_rd to zero since we dont support RD transport in our adapters. 4) Max cqes reported in ibv_devinfo should be from QUERY_CONFIG. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Dont use PD 0 for userpace CQ DBNaresh Gottumukkala2013-09-021-1/+3
| | | | | | | | | | | | | | | | | | | | | | | Create_CQ verb doesn't provide a PD pointer. So, until now we are creating all (both userspace and kernel) CQ DB regions from PD0. This will result in mmapping PD0 to applications. A rogue userspace application can mess things up. Also more serious issues is even the be2net NIC uses PD0. This patch addresses this problem by: 1) Create a PD page for every userspace application when the alloc_ucontext is called. This will be destroyed in dealloc_ucontext. 2) All CQs for that context will use the PD allocated in ucontext. 3) The first create_PD call from application will result in returning the PD address from its ucontext (no new PD will be created). 4) For subsecquent create_pd calls from application, we create new PDs for the application. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: FRMA code cleanupNaresh Gottumukkala2013-09-021-9/+7
| | | | | | | | | | 1) Fixed setting FR_MR bit for FRWR stag allocation 2) Access rights are passsed during FRWR stage and not during STAT allocation stage 3) FRWR WQE structure cleanup 4) Add QP level signaled bit. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: For ERX2 irrespective of Qid, num_posted offset is 24Naresh Gottumukkala2013-09-021-3/+2
| | | | | | | | | | 1) All RQ doorbells are handled by ERX2 and doorbell->num_posted offset is constant to bit offset 24 for ERX2 irrspective of Q id. 2) Fixed RESET to INIT state change (from ERR->RST->INIT->RTR case). Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Add support for fast register work requests (FRWR)Naresh Gottumukkala2013-09-021-0/+19
| | | | | | | Also get the max_srq value from query_config mailbox response. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Cache recv DB until QP moved to RTRNaresh Gottumukkala2013-08-121-1/+1
| | | | | | | | | | 1) In post recv, don't ring the DB doorbell if the QP is in RTR state. Cache the DB calls, until the QP is moved to RTS state. 2) Add max_rd_sge support to dev->attr. 3) Code cleanup in alloc_pd path. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Remove __packedNaresh Gottumukkala2013-08-121-66/+67
| | | | | | | | | 1) Remove __packed for structures. 2) Align and pad all ABI structure to 64 bit boundaries instead of using __packed. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Change macros to inline funtionsNaresh Gottumukkala2013-06-201-15/+0
| | | | | Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Use MCC_CREATE_EXT_V1 for MCC createNaresh Gottumukkala2013-06-201-18/+2
| | | | | | | Use MCC_CREATE_EXT_V1 to create MCC_queue to receive RoCE events. Signed-off-by: Naresh Gottumukkala <bgottumukkala@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Correct queue SGE calculationMahesh Vardhamanaiah2012-06-111-0/+3
| | | | | | | Fix max sge calculation for sq, rq, srq for all hardware types. Signed-off-by: Mahesh Vardhamanaiah <mahesh.vardhamanaiah@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Correct reported max queue sizesMahesh Vardhamanaiah2012-06-111-1/+1
| | | | | | | Fix code to read the max wqe and max rqe values from mailbox response. Signed-off-by: Mahesh Vardhamanaiah <mahesh.vardhamanaiah@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
* RDMA/ocrdma: Add driver for Emulex OneConnect IBoE RDMA adapterParav Pandit2012-05-081-0/+1672
Signed-off-by: Parav Pandit <parav.pandit@emulex.com> Signed-off-by: Roland Dreier <roland@purestorage.com>