msix: Follow CODING_STYLE
CC: Markus Armbruster <armbru@redhat.com> CC: Marcel Apfelbaum <marcel@redhat.com> CC: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Acked-by: Marcel Apfelbaum <marcel@redhat.com> Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
e987c37aee
commit
9348243687
|
@ -447,8 +447,10 @@ void msix_notify(PCIDevice *dev, unsigned vector)
|
||||||
{
|
{
|
||||||
MSIMessage msg;
|
MSIMessage msg;
|
||||||
|
|
||||||
if (vector >= dev->msix_entries_nr || !dev->msix_entry_used[vector])
|
if (vector >= dev->msix_entries_nr || !dev->msix_entry_used[vector]) {
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (msix_is_masked(dev, vector)) {
|
if (msix_is_masked(dev, vector)) {
|
||||||
msix_set_pending(dev, vector);
|
msix_set_pending(dev, vector);
|
||||||
return;
|
return;
|
||||||
|
@ -483,8 +485,10 @@ void msix_reset(PCIDevice *dev)
|
||||||
/* Mark vector as used. */
|
/* Mark vector as used. */
|
||||||
int msix_vector_use(PCIDevice *dev, unsigned vector)
|
int msix_vector_use(PCIDevice *dev, unsigned vector)
|
||||||
{
|
{
|
||||||
if (vector >= dev->msix_entries_nr)
|
if (vector >= dev->msix_entries_nr) {
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
dev->msix_entry_used[vector]++;
|
dev->msix_entry_used[vector]++;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue