From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 53D6CC433EF for ; Wed, 29 Jun 2022 18:44:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229605AbiF2Sof (ORCPT ); Wed, 29 Jun 2022 14:44:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55706 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229480AbiF2Soe (ORCPT ); Wed, 29 Jun 2022 14:44:34 -0400 Received: from mail-qv1-xf29.google.com (mail-qv1-xf29.google.com [IPv6:2607:f8b0:4864:20::f29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2E3CB24BE7 for ; Wed, 29 Jun 2022 11:44:34 -0700 (PDT) Received: by mail-qv1-xf29.google.com with SMTP id c1so26138817qvi.11 for ; Wed, 29 Jun 2022 11:44:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=0UCjZD007QlM4Rkw1tIY/mdObNFKbEJd+O1drBuj5KQ=; b=SaSpHw4Xs1mtpOCDVdoS6JlHJHtUJKDFNmdz5YCfv5Pu3+2vBAaB95PN20ck8fL3N3 /B4Wk2ZlwlYSZ4tzOwZFknNEPqTwcWmeo/tOgQuKsLp4E53LDiSgalgJLU9QtZtQAdBz udJMmGr0H9iBhs7KWMum2SzIV8B8j5AByFyeRs2gMJYNQF0lqkob+sq3mVL1ivBRPfOb /Ui4TR4sJyba99/x8njMBPxS010We8NstNAUAemr3mYk5ebu3re0J93AeeIYIkX3RyHb NNaTo0h0ZTnhJEGYTb8vnpWWjWNjn/OP/kiaXdL4v110EIPckkcRmgaLu/+TaEH1Bc+X TiCg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=0UCjZD007QlM4Rkw1tIY/mdObNFKbEJd+O1drBuj5KQ=; b=ZRPzDtfrgvNkQz9q1NH6pj5He8GEhUDOD8G5sgwn+emGuxxF1mqCB8dBSP8+l4evSE E3EJgwxsAxbQJjAO9nsqGWB0CcMrdFUtxY9hmpSZGgLaetun06ibLelrt/HHK1aA23xo NsWoiokft0DeRsbGaNGbyOoo8nIID8Ltx/ZnnkQJZjlqDPRdmdxDoYuTs2NBRy48r95c 15ZrZXHTbkj8wNAiU+CKWxg3EyYXQBlgqIIv/YMdWZc+cbtgNKSYdYy5/+Y/9J2KlKda ay1uc1fb2CJi+Cv3nRJwMwVZl1xha5f+MMaUABHKYwCu+VWrgKoppI+RBb3RaXCP9o0u M+Vw== X-Gm-Message-State: AJIora/I9S7L+kNXrXMKaupGdckQO1SY0L+HlWQ/3KdZ7M98VAMHmzJ/ HqpASkzqzwFKwV/7Kmhbsnd1oA== X-Google-Smtp-Source: AGRyM1tptSPKAsOwTe+r9c9Uf0kuZlrCU1i6nZlp3AEuEpoNPWxYldjJVZf8Au5i63ZbzjUCAfBUFw== X-Received: by 2002:ac8:588f:0:b0:31b:f63e:c901 with SMTP id t15-20020ac8588f000000b0031bf63ec901mr3850664qta.679.1656528273380; Wed, 29 Jun 2022 11:44:33 -0700 (PDT) Received: from ziepe.ca (hlfxns017vw-142-162-113-129.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.113.129]) by smtp.gmail.com with ESMTPSA id dz8-20020a05620a2b8800b006b141dd9746sm1818713qkb.110.2022.06.29.11.44.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Jun 2022 11:44:32 -0700 (PDT) Received: from jgg by mlx with local (Exim 4.94) (envelope-from ) id 1o6cfw-003bqp-Ds; Wed, 29 Jun 2022 15:44:32 -0300 Date: Wed, 29 Jun 2022 15:44:32 -0300 From: Jason Gunthorpe To: "Pearson, Robert B" Cc: Md Haris Iqbal , "linux-rdma@vger.kernel.org" , "zyjzyj2000@gmail.com" , "aleksei.marov@ionos.com" , "leon@kernel.org" , "haris.iqbal@ionos.com" , "jinpu.wang@ionos.com" , "rpearsonhpe@gmail.com" Subject: Re: [PATCH] RDMA/rxe: For invalidate compare keys according to the MR access Message-ID: <20220629184432.GW23621@ziepe.ca> References: <20220629164946.521293-1-haris.phnx@gmail.com> <20220629183445.GV23621@ziepe.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org On Wed, Jun 29, 2022 at 06:40:07PM +0000, Pearson, Robert B wrote: > > > If the rkey's and lkeys are always the same why do we store them twice in the mr ? > > They are not always the same currently. If you request remote access they are the same if you don't rkey is set to zero. > You could, of course, check both the keys and the access bits but that is not the way it is written currently. Storing the rkey instead of checking the flags seems like a weird obfuscation to me.. Jason