From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-171.mta1.migadu.com (out-171.mta1.migadu.com [95.215.58.171]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 700B72989B5 for ; Mon, 6 Apr 2026 18:09:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.171 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775498995; cv=none; b=aAayaFtOAovPtevwVDwxX51WMN/qvHy7IOJXYVmt0cJVj/j82V4+HHIyIAWl5xd55m2gYg9jsmYqgWXMZ1UhewJRnWsbbRViuABFwRgy2UGYwCaTSJIaz3ZF8N/T1eA4lrDc1GUMj++juvIt8vILegztr1csnBarssLj+DkoGUM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775498995; c=relaxed/simple; bh=lACdRiktp8MRpKGUYxGcgD19C0bqmXpZNFtvU5fyNw8=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=rtOIj7V4SEv2F7NCes0D3RSFsg0xSI05pxV8tXa5j84to0VAv/Yxbl4oRdgjV584AU9UZI+skcSyScVMReUQSsp8A3fOgKBr+1rfgtUYK8xGbHSFIuhiF7OO3rAbG61b4pEdisjgiJFO+iRGVFDhFV7JeYWLQbPA3tO3422xXT4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=HrKy4i01; arc=none smtp.client-ip=95.215.58.171 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="HrKy4i01" Message-ID: <1c5fd907-f610-48e4-89cc-4040aaef2674@linux.dev> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1775498991; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=85/sv/Jd+nnLebgu7yOJ82/6JMUXxVcSgRKO3WW/KJM=; b=HrKy4i01v27KUFcXt/1w2kf+yZsl5MXCFBmMdpuBla2c4B2kFG8UdHSH93UsEojRTPjWIJ RVbUZS7qtBOUTvf1Fe92L2hJ6/CpkB4KYvevqVhozqjWCBottlm/LzMr5DomESqDJznrrj NsvzlhYZFx9aBwmc2y/0M9aHDJw9o8k= Date: Mon, 6 Apr 2026 11:09:37 -0700 Precedence: bulk X-Mailing-List: linux-doc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Subject: Re: [PATCH v3 02/24] PCI: Add API to track PCI devices preserved across Live Update To: David Matlack , Zhu Yanjun Cc: Alex Williamson , Bjorn Helgaas , Adithya Jayachandran , Alexander Graf , Alex Mastro , Andrew Morton , Ankit Agrawal , Arnd Bergmann , Askar Safin , "Borislav Petkov (AMD)" , Chris Li , Dapeng Mi , David Rientjes , Feng Tang , Jacob Pan , Jason Gunthorpe , Jason Gunthorpe , Jonathan Corbet , Josh Hilke , Kees Cook , Kevin Tian , kexec@lists.infradead.org, kvm@vger.kernel.org, Leon Romanovsky , Leon Romanovsky , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-mm@kvack.org, linux-pci@vger.kernel.org, Li RongQing , Lukas Wunner , Marco Elver , =?UTF-8?Q?Micha=C5=82_Winiarski?= , Mike Rapoport , Parav Pandit , Pasha Tatashin , "Paul E. McKenney" , Pawan Gupta , "Peter Zijlstra (Intel)" , Pranjal Shrivastava , Pratyush Yadav , Raghavendra Rao Ananta , Randy Dunlap , Rodrigo Vivi , Saeed Mahameed , Samiullah Khawaja , Shuah Khan , Vipin Sharma , Vivek Kasireddy , William Tu , Yi Liu References: <20260323235817.1960573-1-dmatlack@google.com> <20260323235817.1960573-3-dmatlack@google.com> Content-Language: en-US X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: "Yanjun.Zhu" In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT On 4/6/26 9:06 AM, David Matlack wrote: > On Sun, Apr 5, 2026 at 9:56 AM Zhu Yanjun wrote: >> 在 2026/4/3 14:58, David Matlack 写道: >>> On Thu, Apr 2, 2026 at 2:29 PM Yanjun.Zhu wrote: >>>> On 3/23/26 4:57 PM, David Matlack wrote: >>>>> +config PCI_LIVEUPDATE >>>>> + bool "PCI Live Update Support (EXPERIMENTAL)" >>>>> + depends on PCI && LIVEUPDATE >>>>> + help >>>>> + Support for preserving PCI devices across a Live Update. This option >>>>> + should only be enabled by developers working on implementing this >>>>> + support. Once enough support as landed in the kernel, this option >>>>> + will no longer be marked EXPERIMENTAL. >>>>> + >>>>> + If unsure, say N. >>>> Currently, it only supports 'n' or 'y'. Is it possible to add 'm' >>>> (modular support)? >>>> >>>> This would allow the feature to be built as a kernel module. For >>>> development >>>> >>>> purposes, modularization means we only need to recompile a single module >>>> >>>> for testing, rather than rebuilding the entire kernel. Compiling a >>>> module should >>>> >>>> be significantly faster than a full kernel build. >>> I don't think it is possible for CONFIG_PCI_LIVEUPDATE to support 'm'. >>> pci_setup_device() (which is under CONFIG_PCI) needs to call >>> pci_liveupdate_setup_device(), and CONFIG_PCI cannot be built as a >>> module. This call is necessary so the PCI core knows whether a device >>> being enumerated was preserved across a previous Live Update. >> After the following changes, the liveupdate.ko can be generated >> successfully. > Sure but you've broken the feature. Now devices can be probed before > liveupdate.ko is loaded and the PCI core will have an incorrect view From this perspective, I think it makes sense. Zhu Yanjun > of which devices were preserved by the previous kernel.