[Intel-gfx] [PATCH v7 1/8] PCI/VGA: Use unsigned type for the io_state variable
Sui Jingfeng
15330273260 at 189.cn
Tue Jun 13 03:01:44 UTC 2023
From: Sui Jingfeng <suijingfeng at loongson.cn>
The io_state variable in the vga_arb_write() function is declared with
unsigned int type, while the vga_str_to_iostate() function takes int *
type. To keep them consistent, replace the third argument of
vga_str_to_iostate() function with the unsigned int * type.
Cc: Bjorn Helgaas <bhelgaas at google.com>
Signed-off-by: Sui Jingfeng <suijingfeng at loongson.cn>
Reviewed-by: Andi Shyti <andi.shyti at linux.intel.com>
---
drivers/pci/vgaarb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/vgaarb.c b/drivers/pci/vgaarb.c
index 5a696078b382..c1bc6c983932 100644
--- a/drivers/pci/vgaarb.c
+++ b/drivers/pci/vgaarb.c
@@ -77,7 +77,7 @@ static const char *vga_iostate_to_str(unsigned int iostate)
return "none";
}
-static int vga_str_to_iostate(char *buf, int str_size, int *io_state)
+static int vga_str_to_iostate(char *buf, int str_size, unsigned int *io_state)
{
/* we could in theory hand out locks on IO and mem
* separately to userspace but it can cause deadlocks */
--
2.25.1
More information about the Intel-gfx
mailing list