From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f194.google.com ([209.85.128.194]:35542 "EHLO mail-wr0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751966AbdLVQx5 (ORCPT ); Fri, 22 Dec 2017 11:53:57 -0500 Received: by mail-wr0-f194.google.com with SMTP id l19so16048334wrc.2 for ; Fri, 22 Dec 2017 08:53:56 -0800 (PST) Date: Fri, 22 Dec 2017 09:53:52 -0700 From: Jason Gunthorpe To: Dennis Dalessandro Cc: dledford@redhat.com, linux-rdma@vger.kernel.org, "Michael J. Ruhl" , Mike Marciniszyn , stable@vger.kernel.org Subject: Re: [PATCH for-rc] IB/hfi: Only read capability registers if the capability exists Message-ID: <20171222165352.GD30884@ziepe.ca> References: <20171222164717.31842.12554.stgit@scvm10.sc.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171222164717.31842.12554.stgit@scvm10.sc.intel.com> Sender: stable-owner@vger.kernel.org List-ID: On Fri, Dec 22, 2017 at 08:47:20AM -0800, Dennis Dalessandro wrote: > From: Michael J. Ruhl > > During driver init, various registers are saved to allow restoration > after an FLR or gen3 bump. Some of these registers are not available > in some circumstances (i.e. Virtual machines). > > Delete unnecessary register read/write, and only access register if > the capability exists. > > Cc: # 4.14.x > Fixes: a618b7e40af2 ("IB/hfi1: Move saving PCI values to a separate function") > Reviewed-by: Mike Marciniszyn > Signed-off-by: Michael J. Ruhl > Signed-off-by: Dennis Dalessandro > drivers/infiniband/hw/hfi1/hfi.h | 1 - > drivers/infiniband/hw/hfi1/pcie.c | 30 ++++++++++++------------------ > 2 files changed, 12 insertions(+), 19 deletions(-) Since we are getting late in the RC cycle can you help me clarify the user visible bug here? No need to resend I'm guessing when hfi1 is used in a virtual machine with passthrough (SRIOV?) it fails in ?? way? Jason