Skip to contentSkip to conversation

virt: acrn: Use EPOLLIN instead of POLLIN

PATCH In review Yejune Deng 2 participants 2 messages Mar 10, 2021 Acrn hypervisor service module

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 virt: acrn: Use EPOLLIN instead of POLLIN

This fixes the following sparse warning:
"sparse warnings: (new ones prefixed by >>)"

Quoted 1 line
Quoted 1 line

drivers/virt/acrn/irqfd.c:163:13: sparse: sparse: restricted __poll_t

degrades to integer

Fixes 803c1aadecdb("virt: acrn: Use vfs_poll() instead of f_op->poll()")
---
 drivers/virt/acrn/irqfd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/virt/acrn/irqfd.c +1 -1
index 98d6e9b18f9e..df5184979b28 100644
@@ -160,7 +160,7 @@ static int acrn_irqfd_assign(struct acrn_vm *vm, struct acrn_irqfd *args)
 	/* Check the pending event in this stage */
 	events = vfs_poll(f.file, &irqfd->pt);
 
-	if (events & POLLIN)
+	if (events & EPOLLIN)
 		acrn_irqfd_inject(irqfd);
 
 	fdput(f);
Signature · 1 line
2.29.0
Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines · Yejune Deng

This fixes the following sparse warning:
"sparse warnings: (new ones prefixed by >>)"

Quoted 1 line
Quoted 1 line

drivers/virt/acrn/irqfd.c:163:13: sparse: sparse: restricted __poll_t

degrades to integer

Fixes 803c1aadecdb("virt: acrn: Use vfs_poll() instead of f_op->poll()")

Thanks for the patch.

Quoted 20 lines

---
drivers/virt/acrn/irqfd.c | 2 +-

1 file changed, 1 insertion(+), 1 deletion(-)
drivers/virt/acrn/irqfd.c +1 -1
index 98d6e9b18f9e..df5184979b28 100644
@@ -160,7 +160,7 @@ static int acrn_irqfd_assign(struct acrn_vm *vm, struct acrn_irqfd *args)
 	/* Check the pending event in this stage */
 	events = vfs_poll(f.file, &irqfd->pt);
 
-	if (events & POLLIN)
+	if (events & EPOLLIN)
 		acrn_irqfd_inject(irqfd);
 
 	fdput(f);
Signature · 1 line
2.29.0