From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-qk1-f180.google.com (mail-qk1-f180.google.com [209.85.222.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E752C3CD8A5 for ; Wed, 4 Mar 2026 17:45:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.222.180 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772646334; cv=none; b=a+czHGJkuZx1S+FDLgrpTTCQVvfwHo0GoLgYory6120nx0GZlJQWtfX6SY/RwiwzLhZ4xDLswO9gALsP3XOeM8MhdpOES9u4sjSCPBwsgkZawkXlYMKMTSN6m3phCvRo9cyJNVMRGO8FhNXwkt1HfscDuaDPbvyN3GZDq3/5jas= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772646334; c=relaxed/simple; bh=Z/NZQvcQCIgLMH/ylHiLwhG3hRbIZ3DJdjrycXHaYe8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=jq8NAHkqNPpsoGEKouP8Yt48gacToYLok+RBYQpos+KLAQhPhpCntE6qNElMSzuxWqcstwCAtEgOr01Oh12kTOPpY8XvsBkrKaxj5zw1G0X+feXT1zLNB2WVKKUkMTcbg9T99VBQaapwUXWKe5nSa+/wkzbbWbwZ0soxVHmp8R0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ziepe.ca; spf=pass smtp.mailfrom=ziepe.ca; dkim=pass (2048-bit key) header.d=ziepe.ca header.i=@ziepe.ca header.b=Ciuh2OlT; arc=none smtp.client-ip=209.85.222.180 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ziepe.ca Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ziepe.ca Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ziepe.ca header.i=@ziepe.ca header.b="Ciuh2OlT" Received: by mail-qk1-f180.google.com with SMTP id af79cd13be357-8cb420fbb5dso421481485a.3 for ; Wed, 04 Mar 2026 09:45:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; t=1772646332; x=1773251132; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=nSAtzjXqss+uxlpk1YxZqBQHrNvbCWRFoP2RW9VjGUc=; b=Ciuh2OlT5LbvGe2fLekjmWaFRmLjXcQ8+K3Q2RMQB08V72mMUT0d237S0cMP6/MXfw xOh94/jCUlZlk2z3AQAWmVtiXffk4ko/7txAqj5IN+gGXZlSvQHwcpHwxfY4sFJoIhAr k9CEkvEz/XaO/jKOZ3On01JDbOyBodBB/PafBIsJUHAXpcfODzDv15OBeNLanlFRmJlg DTA3dqlCpMRh1aDznm5plekJncXeDjPx5SzQi9XBjcy++ug5Qv9kMpuW2raKxItuExKP Sygl9M7ucBy54LbxYgn3kddbZhxLymSNrR89fDjKrpBekrPlT79wZ34Wf5QPYwzSK9m0 IIJg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772646332; x=1773251132; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=nSAtzjXqss+uxlpk1YxZqBQHrNvbCWRFoP2RW9VjGUc=; b=Lwh+D01G9bfqiWLR5rlglSJDdB2eGsn4qdnWgWsfXwDW02/6EJ1zs3coZkSiyhbL9S 4aJJce39rAG2qPxYrH6yM5Y6HBQpUrg4tucgA4ck3RVnys1vrKxlgbCUcgyi/87NNOIi 6rCDdvaVpXBtnMnBLyofWt1nCOI4WrJiQ3xT2ZJh0gmtX/DnJ7DM8cjcqErMIRnfEAqI HTKgUVwvvnwwE9ypU6vaJOTgHHW86fZV/mSbK7YXUHQqqKy1T8OmQePy6+XhdgLmOKZn V/uqHpSV7+5wmGwuvZdNNmUohxA0sN9JyDajKW2NczOeJ5CmV9B9I5/R0/DTuhhJvj5N 0I2g== X-Forwarded-Encrypted: i=1; AJvYcCV/kgE7AbvxSTIEBwjXX4h7hftZjob6Nf/Y24v7dDxL5Yrf4bEzQOYnx2F+TftXjVj7z9dVqi1Oeh2gfREpDw==@vger.kernel.org X-Gm-Message-State: AOJu0YyUo6r7IymLRgB98utPr3fBfcuNHhEp6l2emFCIwrPs+Zw6LcF2 3H8bHD050gK8IB3gdppZ+olEyKxd5NAg6IhpZfWy64AnaApg0QVsnWA+MDdD6cqWVkk= X-Gm-Gg: ATEYQzxWpkyYF+cfZmsAy6eJgDSN8/bOsBpSxrSs3yinIGadQFT7iBFcDyrxV5RCEKz xMWbQG43SaRKfSIwFfyk2LL9c7xUR5XVZMGsFEQz7n2A2AdJ0MJ1EK1YaSnJYm2Ta9LDYhPcICf 7dnx7tMYro4FRuLZZy84+0KajZs3+xgtDnbRK0Zwn1i6jWize0z+BOGK5CQmC9QlbfGG7ebfB49 cNh3yIIMw0jnccSZsnnxb2UNubryuphHgJ7IRvY3phutYemqCQp+RG5eBpQvKC5yX0zw5+AKldi 4JCrPFYD3MsdJkFrJrZO5MITeDV4cBw91xJaEDWChH2phvqTBikwE3THWyY4fUUdVhpRJvaO9z8 suGeCpwX+XJqF7plMoHjCZLKDz9yRfOpyNCWa53BRKWv/eVLpru5uVMwEGGcP+ZWqUJ9YV7tscT 84lCKL3DXTIGo6briNZVFMyQV43h0H5WSDzRC02b1ILj0c5yhl7IgbB8OHigQeBPiqp11w+HBti HSEiVvE X-Received: by 2002:a05:620a:4481:b0:8c6:ee09:5eae with SMTP id af79cd13be357-8cd5adb8d1cmr343907185a.0.1772646331749; Wed, 04 Mar 2026 09:45:31 -0800 (PST) Received: from ziepe.ca (hlfxns017vw-142-162-112-119.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.112.119]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-89a1fcb781fsm8074876d6.23.2026.03.04.09.45.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Mar 2026 09:45:31 -0800 (PST) Received: from jgg by wakko with local (Exim 4.97) (envelope-from ) id 1vxqHq-00000005ET5-2S2S; Wed, 04 Mar 2026 13:45:30 -0400 Date: Wed, 4 Mar 2026 13:45:30 -0400 From: Jason Gunthorpe To: Leon Romanovsky Cc: Danilo Krummrich , Peter Colberg , Bjorn Helgaas , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Miguel Ojeda , Alex Gaynor , Gary Guo , =?utf-8?B?QmrDtnJu?= Roy Baron , Benno Lossin , Andreas Hindborg , Alice Ryhl , Trevor Gross , Abdiel Janulgue , Daniel Almeida , Robin Murphy , Greg Kroah-Hartman , Dave Ertman , Ira Weiny , David Airlie , Simona Vetter , Jonathan Corbet , Xu Yilun , Tom Rix , Moritz Fischer , "Rafael J. Wysocki" , Boqun Feng , linux-pci@vger.kernel.org, rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org, Alexandre Courbot , Alistair Popple , Joel Fernandes , John Hubbard , Zhi Wang , nouveau@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-doc@vger.kernel.org, linux-fpga@vger.kernel.org, driver-core@lists.linux.dev Subject: Re: [PATCH v3 00/10] rust: pci: add abstractions for SR-IOV capability Message-ID: <20260304174530.GH964116@ziepe.ca> References: <20260303-rust-pci-sriov-v3-0-4443c35f0c88@redhat.com> <20260304084750.GW12611@unreal> <20260304141852.GF964116@ziepe.ca> <20260304142600.GB12611@unreal> <20260304162711.GI12611@unreal> <20260304164551.GG964116@ziepe.ca> <20260304170249.GJ12611@unreal> Precedence: bulk X-Mailing-List: rust-for-linux@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260304170249.GJ12611@unreal> On Wed, Mar 04, 2026 at 07:02:49PM +0200, Leon Romanovsky wrote: > > No, illegal, and it doesn't even work right. When VFIO FLRs the PF it > > will blow up the half baked SRIOV and break everything. > > The FLR can be disabled. For example, PCI_DEV_FLAGS_NO_FLR_RESET flag > will do it. Well that would break all the security properties of VFIO. > > VFIO already has its own sriov_config support, the right flow is to > > bind the PF to VFIO and then enable sriov and do your assignments. > > VFIO started to support SR-IOV in 137e5531351d ("vfio/pci: Add > sriov_configure support"), which was added 8 years after VFIO core was > added cba3345cc494 ("vfio: VFIO core"). Well, time to upgrade, I see no reason to allow Rust drivers to further propogate these mistakes. Jason