[PATCH v2] bus/pci: fix legacy device IO port map in secondary process

Stephen Hemminger stephen at networkplumber.org
Mon Aug 21 04:53:10 CEST 2023


On Mon, 21 Aug 2023 09:27:07 +0800
Wenwu Ma <wenwux.ma at intel.com> wrote:

> +	struct vfio_device_info device_info = { .argsz = sizeof(device_info) };
> +	char pci_addr[PATH_MAX] = {0}

Not sure if some tools will complain about initializing chars as zero.
Anyway, why bother since you are using it with snprintf.

Also, the new variables that are only used in the secondary case
should be declared in that if() not for whole function.





More information about the stable mailing list