Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934324AbcCPCIL (ORCPT ); Tue, 15 Mar 2016 22:08:11 -0400 Received: from mail-pf0-f177.google.com ([209.85.192.177]:36517 "EHLO mail-pf0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934262AbcCPCII (ORCPT ); Tue, 15 Mar 2016 22:08:08 -0400 Subject: Re: [RFC PATCH kernel] Revert "net/mlx4_core: Set UAR page size to 4KB regardless of system page size" To: Or Gerlitz , Huy Nguyen References: <1458037148-4475-1-git-send-email-aik@ozlabs.ru> Cc: Doug Ledford , Eugenia Emantayev , Hal Rosenstock , Sean Hefty , Yishai Hadas , Linux Kernel , "linux-rdma@vger.kernel.org" , Linux Netdev List , Paul Mackerras , Carol L Soto , Yevgeny Petrilin , Brian J King From: Alexey Kardashevskiy Message-ID: <56E8BFFE.9000803@ozlabs.ru> Date: Wed, 16 Mar 2016 13:07:58 +1100 User-Agent: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=koi8-r; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1607 Lines: 42 On 03/15/2016 09:40 PM, Or Gerlitz wrote: > On Tue, Mar 15, 2016 at 12:19 PM, Alexey Kardashevskiy wrote: >> This reverts commit 85743f1eb34548ba4b056d2f184a3d107a3b8917. >> >> Without this revert, POWER "pseries" KVM guests with a VF passed to a guest >> using VFIO fail to bring the driver up: >> >> mlx4_core: Mellanox ConnectX core driver v2.2-1 (Feb, 2014) >> mlx4_core: Initializing 0000:00:00.0 >> mlx4_core 0000:00:00.0: enabling device (0000 -> 0002) >> mlx4_core 0000:00:00.0: Detected virtual function - running in slave mode >> mlx4_core 0000:00:00.0: Sending reset >> mlx4_core 0000:00:00.0: Sending vhcr0 >> mlx4_core 0000:00:00.0: HCA minimum page size:512 >> mlx4_core 0000:00:00.0: UAR size:4096 != kernel PAGE_SIZE of 65536 >> mlx4_core 0000:00:00.0: Failed to obtain slave caps > >> Both host and guest use 64K system pages. >> >> How to fix this properly? Thanks. > > The commit message says: > > "[..] Regarding backward compatibility in SR-IOV, if hypervisor has > this new code, the virtual OS must be updated. [...]" So with v4.5 as a host, there is no actual distro available today to use as a guest in the next 6 months (or whatever it takes to backport this partucular patch back there). You could have added a module parameter to enforce the old behavoir, at least... And sorry but from the original commit log I could not understand why exactly all existing guests need to be broken. Could you please point me to a piece of documentation describing all this UAR bisuness (what is UAR, why 128 UARs are required and for what, etc). Thanks. -- Alexey