Re: [PATCH v2] PCI: hv: Correct a comment

2025-02-21 Thread Wei Liu
On Fri, Feb 21, 2025 at 12:09:57AM +0900, Krzysztof WilczyƄski wrote: > Hello, > > > > The VF driver controls an endpoint attached to the pci-hyperv > > > controller. An invalidation sent by the PF driver in the host would be > > > delivered *to* the endpoint driver by the controller driver. > > >

[PATCH v3 1/3] hyperv: Convert hypercall statuses to linux error codes

2025-02-21 Thread Nuno Das Neves
Return linux-friendly error codes from hypercall helper functions, which allows them to be used more flexibly. Introduce hv_result_to_errno() for this purpose, which also handles the special value U64_MAX returned from hv_do_hypercall(). Signed-off-by: Nuno Das Neves Reviewed-by: Easwar Harihara

[PATCH v3 3/3] hyperv: Add CONFIG_MSHV_ROOT to gate root partition support

2025-02-21 Thread Nuno Das Neves
CONFIG_MSHV_ROOT allows kernels built to run as a normal Hyper-V guest to exclude the root partition code, which is expected to grow significantly over time. This option is a tristate so future driver code can be built as a (m)odule, allowing faster development iteration cycles. If CONFIG_MSHV_RO

[PATCH v2 0/3] Introduce CONFIG_MSHV_ROOT for root partition code

2025-02-21 Thread Nuno Das Neves
Running in the root partition is a unique and specialized case that requires additional code. CONFIG_MSHV_ROOT allows Hyper-V guest kernels to exclude this code, which is important since significant additional code specific to the root partition is expected to be added over time. To do this, chang

[PATCH v3 2/3] hyperv: Change hv_root_partition into a function

2025-02-21 Thread Nuno Das Neves
Introduce hv_curr_partition_type to store the partition type as an enum. Right now this is limited to guest or root partition, but there will be other kinds in future and the enum is easily extensible. Set up hv_curr_partition_type early in Hyper-V initialization with hv_identify_partition_type()

Re: [PATCH v2 0/3] Introduce CONFIG_MSHV_ROOT for root partition code

2025-02-21 Thread Nuno Das Neves
The subject line says v2 but this is actually v3! Nuno On 2/21/2025 11:56 AM, Nuno Das Neves wrote: > Running in the root partition is a unique and specialized case that > requires additional code. CONFIG_MSHV_ROOT allows Hyper-V guest kernels > to exclude this code, which is important since sign

Re: [PATCH v2 2/3] hyperv: Change hv_root_partition into a function

2025-02-21 Thread Easwar Hariharan
On 2/21/2025 10:10 AM, Nuno Das Neves wrote: > On 2/20/2025 2:59 PM, MUKESH RATHOR wrote: >> >> >> On 2/20/25 14:56, Easwar Hariharan wrote: >> > On 2/20/2025 1:59 PM, MUKESH RATHOR wrote: >> >> >> >> >> >> On 2/20/25 10:33, Nuno Das Neves wrote: >> >> > Introduce hv_current_partition_type t

Re: [PATCH v2 2/3] hyperv: Change hv_root_partition into a function

2025-02-21 Thread MUKESH RATHOR
On 2/21/25 10:10, Nuno Das Neves wrote: > On 2/20/2025 2:59 PM, MUKESH RATHOR wrote: >> >> >> On 2/20/25 14:56, Easwar Hariharan wrote: >> > On 2/20/2025 1:59 PM, MUKESH RATHOR wrote: >> >> >> >> >> >> On 2/20/25 10:33, Nuno Das Neves wrote: >> >> > Introduce hv_current_parti

RE: [PATCH v3 2/3] hyperv: Change hv_root_partition into a function

2025-02-21 Thread Michael Kelley
From: Nuno Das Neves Sent: Friday, February 21, 2025 11:57 AM > > Introduce hv_curr_partition_type to store the partition type > as an enum. > > Right now this is limited to guest or root partition, but there will > be other kinds in future and the enum is easily extensible. > > Set up hv_curr

RE: [PATCH v3 3/3] hyperv: Add CONFIG_MSHV_ROOT to gate root partition support

2025-02-21 Thread Michael Kelley
From: Nuno Das Neves Sent: Friday, February 21, 2025 11:57 AM > > CONFIG_MSHV_ROOT allows kernels built to run as a normal Hyper-V guest > to exclude the root partition code, which is expected to grow > significantly over time. > > This option is a tristate so future driver code can be built as

Re: [PATCH v2 2/3] hyperv: Change hv_root_partition into a function

2025-02-21 Thread Nuno Das Neves
On 2/20/2025 2:59 PM, MUKESH RATHOR wrote: > > > On 2/20/25 14:56, Easwar Hariharan wrote: > > On 2/20/2025 1:59 PM, MUKESH RATHOR wrote: > >> > >> > >> On 2/20/25 10:33, Nuno Das Neves wrote: > >> > Introduce hv_current_partition_type to store the partition type > >> > as an enum. > >

Re: [PATCH v2 0/3] Introduce CONFIG_MSHV_ROOT for root partition code

2025-02-21 Thread Easwar Hariharan
On 2/21/2025 12:01 PM, Nuno Das Neves wrote: > The subject line says v2 but this is actually v3! > > Nuno For the series, Reviewed-by: Easwar Hariharan

[PATCH v2] panic: call panic handlers before panic_other_cpus_shutdown()

2025-02-21 Thread Hamza Mahfooz
Since, the panic handlers may require certain cpus to be online to panic gracefully, we should call them before turning off SMP. Without this re-ordering, on Hyper-V hv_panic_vmbus_unload() times out, because the vmbus channel is bound to VMBUS_CONNECT_CPU and unless the crashing cpu is the same as

Re: [PATCH RFC] panic: call panic handlers before panic_other_cpus_shutdown()

2025-02-21 Thread Hamza Mahfooz
Hey Ryo, On Fri, Feb 21, 2025 at 11:23:28AM +0900, Ryo Takakura wrote: > Hi Hamza! > > On Thu, 20 Feb 2025 17:53:00 -0500, Hamza Mahfooz wrote: > >Since, the panic handlers may require certain cpus to be online to panic > >gracefully, we should call them before turning off SMP. Without this > >re

Re: [PATCH hyperv-next v2 0/2] x86/hyperv: VTL mode reboot fixes

2025-02-21 Thread Ingo Molnar
* Roman Kisel wrote: > Roman Kisel (2): > x86/hyperv: VTL mode emergency restart callback > x86/hyperv: VTL mode callback for restarting the system A: These two patch titles verbs. ... ... B: These two patch titles are missing verbs. Like me you prefer B too, right? If so, please add back

Re: [PATCH v3 2/3] hyperv: Change hv_root_partition into a function

2025-02-21 Thread Nuno Das Neves
On 2/21/2025 12:58 PM, Michael Kelley wrote: > From: Nuno Das Neves Sent: Friday, > February 21, 2025 11:57 AM >> >> Introduce hv_curr_partition_type to store the partition type >> as an enum. >> >> Right now this is limited to guest or root partition, but there will >> be other kinds in future a

Re: [PATCH v2 0/3] Introduce CONFIG_MSHV_ROOT for root partition code

2025-02-21 Thread Wei Liu
On Fri, Feb 21, 2025 at 11:56:32AM -0800, Nuno Das Neves wrote: > Running in the root partition is a unique and specialized case that > requires additional code. CONFIG_MSHV_ROOT allows Hyper-V guest kernels > to exclude this code, which is important since significant additional code > specific to

RE: [PATCH v2] panic: call panic handlers before panic_other_cpus_shutdown()

2025-02-21 Thread Michael Kelley
From: Hamza Mahfooz Sent: Friday, February 21, 2025 1:31 PM > > Since, the panic handlers may require certain cpus to be online to panic > gracefully, we should call them before turning off SMP. Without this > re-ordering, on Hyper-V hv_panic_vmbus_unload() times out, because the > vmbus channel

Re: [PATCH RFC] panic: call panic handlers before panic_other_cpus_shutdown()

2025-02-21 Thread Ryo Takakura
On Fri, 21 Feb 2025 16:23:07 -0500, Hamza Mahfooz wrote: >On Fri, Feb 21, 2025 at 11:23:28AM +0900, Ryo Takakura wrote: >> On Thu, 20 Feb 2025 17:53:00 -0500, Hamza Mahfooz wrote: >> >Since, the panic handlers may require certain cpus to be online to panic >> >gracefully, we should call them before