From patchwork Fri Oct 31 13:46:12 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Devesh Sharma X-Patchwork-Id: 5205041 Return-Path: X-Original-To: patchwork-linux-rdma@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id DB3949F30B for ; Fri, 31 Oct 2014 14:29:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E353E2015A for ; Fri, 31 Oct 2014 14:29:00 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0E6A520176 for ; Fri, 31 Oct 2014 14:28:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933149AbaJaO2z (ORCPT ); Fri, 31 Oct 2014 10:28:55 -0400 Received: from cmexedge2.emulex.com ([138.239.224.100]:6965 "EHLO CMEXEDGE2.ext.emulex.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932767AbaJaO2x (ORCPT ); Fri, 31 Oct 2014 10:28:53 -0400 Received: from CMEXHTCAS1.ad.emulex.com (138.239.115.217) by CMEXEDGE2.ext.emulex.com (138.239.224.100) with Microsoft SMTP Server (TLS) id 14.3.174.1; Fri, 31 Oct 2014 07:28:32 -0700 Received: from neo01-el64.lab.bg.emulex.com (10.192.204.8) by smtp.emulex.com (138.239.115.207) with Microsoft SMTP Server id 14.3.174.1; Fri, 31 Oct 2014 07:28:24 -0700 From: Devesh Sharma To: CC: Devesh Sharma Subject: [PATCH] RDMA/libocrdma: fix library stack curruption Date: Fri, 31 Oct 2014 19:16:12 +0530 X-Mailer: git-send-email 1.7.1 MIME-Version: 1.0 Message-ID: <774e14a2-8394-4cde-aeaa-369f270e75ef@CMEXHTCAS1.ad.emulex.com> Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The library abi structures are not matching with the upstream driver abi code. The mismatch is causing stack curruption on some platforms while running user application. This patch has a fix for stack curruption. Signed-off-by: Devesh Sharma --- src/ocrdma_abi.h | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/ocrdma_abi.h b/src/ocrdma_abi.h index 88498a9..ad7abd4 100644 --- a/src/ocrdma_abi.h +++ b/src/ocrdma_abi.h @@ -74,7 +74,7 @@ struct ocrdma_alloc_ucontext_resp { uint32_t ah_tbl_len; uint32_t rqe_size; uint8_t fw_ver[32]; - uint32_t rsvd1; + uint64_t rsvd1; uint64_t rsvd2; }; @@ -153,8 +153,7 @@ struct ocrdma_create_qp_uresp { uint32_t db_sq_offset; uint32_t db_rq_offset; uint32_t db_shift; - uint64_t rsvd2; - uint64_t rsvd3; + uint64_t rsvd[11]; /* 8*8 + 4*4 + 8 */ }; struct ocrdma_create_srq_cmd {