[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3 17/46] ivshmem: improve debug messages
From: |
Marc-André Lureau |
Subject: |
Re: [Qemu-devel] [PATCH v3 17/46] ivshmem: improve debug messages |
Date: |
Wed, 23 Sep 2015 17:45:21 +0200 |
Hi
On Wed, Sep 23, 2015 at 2:10 PM, Claudio Fontana
<address@hidden> wrote:
>> Let's change it for IVSHMEM_DPRINTF("use msix, present: %d\n",
>> msix_present(d)); ok?
>>
>
> what about something like
>
> IVSHMEM_DPRINTF("%susing MSI-X\n", msix_present(d) ? "" : "not ");
>
> or just
>
> if (!msix_present(d) {
> IVSHMEM_DPRINTF("not using MSI-X");
> return;
> }
>
> IVSHMEM_DPRINTF("using MSI-X");
I find it more confusing. ivshmem_use_msix() is the place where
msix_vector_use() is called. However, ivshmem_has_feature(s,
IVSHMEM_MSI) may be true or not. Only MSIX is effectively enabled if
the guest has MSIX, which is what msix_present(d) says. So I would
rather keep the last debug Iine I proposed (again this is just for
debugging, when compiling with IVSHMEM_DEBUG, not a message that a
user will ever see).
thanks
--
Marc-André Lureau
- [Qemu-devel] [PATCH v3 16/46] ivshmem: remove max_peer field, (continued)
[Qemu-devel] [PATCH v3 20/46] ivshmem: simplify a bit the code, marcandre . lureau, 2015/09/15
[Qemu-devel] [PATCH v3 19/46] ivshmem: print error on invalid peer id, marcandre . lureau, 2015/09/15
[Qemu-devel] [PATCH v3 21/46] ivshmem: use common return, marcandre . lureau, 2015/09/15
[Qemu-devel] [PATCH v3 22/46] ivshmem: use common is_power_of_2(), marcandre . lureau, 2015/09/15