[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] VT-d: Adjust diagnostics in set_msi_source_id()



On Fri, Mar 14, 2025 at 09:55:23AM +0000, Andrew Cooper wrote:
> Use %pd, and state what the unknown is.  As it's an enum, it's a signed type.
> 
> Also drop one piece of trailing whitespace.
> 
> Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

Acked-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>

> ---
> CC: Jan Beulich <JBeulich@xxxxxxxx>
> CC: Roger Pau Monné <roger.pau@xxxxxxxxxx>
> ---
>  xen/drivers/passthrough/vtd/intremap.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/xen/drivers/passthrough/vtd/intremap.c 
> b/xen/drivers/passthrough/vtd/intremap.c
> index 81394ef45299..9272a2511398 100644
> --- a/xen/drivers/passthrough/vtd/intremap.c
> +++ b/xen/drivers/passthrough/vtd/intremap.c
> @@ -485,15 +485,15 @@ static int set_msi_source_id(const struct pci_dev *pdev,
>          else
>          {
>              dprintk(XENLOG_WARNING VTDPREFIX,
> -                    "d%d: no upstream bridge for %pp\n",
> -                    pdev->domain->domain_id, &pdev->sbdf);
> +                    "%pd: no upstream bridge for %pp\n",
> +                    pdev->domain, &pdev->sbdf);
>              return -ENXIO;
>          }
>          break;
>  
>      default:
> -        dprintk(XENLOG_WARNING VTDPREFIX, "d%d: unknown(%u): %pp\n",
> -                pdev->domain->domain_id, pdev->type, &pdev->sbdf);
> +        dprintk(XENLOG_WARNING VTDPREFIX, "%pd: %pp unknown device type 
> %d\n",
> +                pdev->domain, &pdev->sbdf, pdev->type);

Would be nice to have a pdev_type_to_str() or similar helper.

Thanks, Roger.



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.