From patchwork Tue Mar 13 22:07:34 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jason Gunthorpe X-Patchwork-Id: 10281029 X-Patchwork-Delegate: sean.hefty@intel.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 40189602BD for ; Tue, 13 Mar 2018 22:07:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2A9DF2580E for ; Tue, 13 Mar 2018 22:07:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1F68128484; Tue, 13 Mar 2018 22:07:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B7FDF2580E for ; Tue, 13 Mar 2018 22:07:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752111AbeCMWHr (ORCPT ); Tue, 13 Mar 2018 18:07:47 -0400 Received: from mail-pf0-f194.google.com ([209.85.192.194]:46470 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752054AbeCMWHp (ORCPT ); Tue, 13 Mar 2018 18:07:45 -0400 Received: by mail-pf0-f194.google.com with SMTP id z10so490482pfh.13 for ; Tue, 13 Mar 2018 15:07:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=XtPjeM0caEwXCO1u0xiphoJ/D+UfoO2ZU+IEsjcIN74=; b=RjxNCOxtdCX01jZ8PuKoymubbRESglpCUWwaFN09+8qnwlKDZjDV9gwBPXkNtOzK0m FCY5i2qfnh3o/C6DAdd+1CZYQwJEN38xdF1wJSGqRTeSC4oxPPftdQwxeLdIX4sgQmVK h5Y7EzmP7PqTpenKyqFuDpFfeh1xSzGU+NEx7UFEeHsQSjjXI5VsJlN7kJyAaqeyEkKg YO4ZHFSz3b0m4lWLVMbD6VVVUdua7JEy/r+pMY4hVMB+WFhLB+SSfdW0ztuLMKk37DpC edW6WXRhbldWDsNh9giuVEArA4+E5NlFO5PkGAiTpnMcv3aTYPNqlNRpK/rzaNp4vemU SZHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=XtPjeM0caEwXCO1u0xiphoJ/D+UfoO2ZU+IEsjcIN74=; b=je8IAtsFhce7L4fancriXJuhGCP9FP9EVEEkJThze1PkfGtBq2mItGIpdEicwmuF4n vVDDeN/kPQop6pO0yuOmj1Ek5QVECq8NdsS3Ham9Ws3WcxRH5AXjESrN1HuRWt2In73O iydxMsV3VRIM/sgFuMBU/nDd8wAVkEIqhjGDH7W/te0YM/hju44maenWy02o615m4ANI jVKzTuMkQkgZIxRc9gmV1eYwz6upnW2Rn7MeLmD6+dRahw+1uRUVMkLuzruooulAd+pf dEeigAVlJLa6muzCm66w1OwZCl+4yTbQUc367/cxir+jnabWbXs2QZHwgjEndYyb+6JQ Kdgw== X-Gm-Message-State: AElRT7HgO+IzB/CGoJAyTjbhdZ47aObhSGXY6wRbt1xI7MlR/zAFf6qK TjLGh3WvBsEOIAMY0eHorFW5s0PSaLs= X-Google-Smtp-Source: AG47ELufr+Alxi5ZZFEkOpe+5HC9VCZv5BNYPNwlP4xjpen+Bhtcbq6P83EesW9zgZAVceCQsQQhxQ== X-Received: by 10.98.55.7 with SMTP id e7mr2095914pfa.112.1520978865121; Tue, 13 Mar 2018 15:07:45 -0700 (PDT) Received: from ziepe.ca (S010614cc2056d97f.ed.shawcable.net. [174.3.196.123]) by smtp.gmail.com with ESMTPSA id o3sm1665658pgp.18.2018.03.13.15.07.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 13 Mar 2018 15:07:42 -0700 (PDT) Received: from jgg by mlx.ziepe.ca with local (Exim 4.86_2) (envelope-from ) id 1evs57-0001Az-65; Tue, 13 Mar 2018 16:07:41 -0600 From: Jason Gunthorpe To: linux-rdma@vger.kernel.org Cc: Jason Gunthorpe Subject: [PATCH rdma-core 5/8] verbs: Remove bogus padding from ibv_dealloc_mw Date: Tue, 13 Mar 2018 16:07:34 -0600 Message-Id: <20180313220737.4336-6-jgg@ziepe.ca> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180313220737.4336-1-jgg@ziepe.ca> References: <20180313220737.4336-1-jgg@ziepe.ca> Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Jason Gunthorpe The kernel does not have this padding and totally ignores the structure length. There is no reason for userspace to be different, so drop it from here. Signed-off-by: Jason Gunthorpe --- libibverbs/cmd.c | 1 - libibverbs/kern-abi.h | 1 - 2 files changed, 2 deletions(-) diff --git a/libibverbs/cmd.c b/libibverbs/cmd.c index a036c893d70d11..5fd518d43ef232 100644 --- a/libibverbs/cmd.c +++ b/libibverbs/cmd.c @@ -478,7 +478,6 @@ int ibv_cmd_dealloc_mw(struct ibv_mw *mw, { IBV_INIT_CMD(cmd, cmd_size, DEALLOC_MW); cmd->mw_handle = mw->handle; - cmd->reserved = 0; if (write(mw->context->cmd_fd, cmd, cmd_size) != cmd_size) return errno; diff --git a/libibverbs/kern-abi.h b/libibverbs/kern-abi.h index ca5630e2d4f3c5..18563bfe38b427 100644 --- a/libibverbs/kern-abi.h +++ b/libibverbs/kern-abi.h @@ -160,7 +160,6 @@ struct ibv_alloc_mw { struct ibv_dealloc_mw { struct ib_uverbs_cmd_hdr hdr; __u32 mw_handle; - __u32 reserved; }; struct ibv_create_comp_channel {