From: Roland Dreier Date: Thu, 30 Mar 2006 20:55:10 +0000 (-0800) Subject: [PATCH] PCI: fix sparse warning about pci_bus_flags X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e778272dd547d53dedf92240e8b3dbdee44b87b6;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git [PATCH] PCI: fix sparse warning about pci_bus_flags Sparse warns about casting to a __bitwise type. However, it's correct to do when defining the enum for pci_bus_flags_t, so add a __force to quiet the warnings. This will fix getting include/linux/pci.h:100:26: warning: cast to restricted type from sparse all over the build. Signed-off-by: Roland Dreier Signed-off-by: Greg Kroah-Hartman --- diff --git a/include/linux/pci.h b/include/linux/pci.h index 15e1675edef9..3a6a4e37a482 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -97,7 +97,7 @@ enum pci_channel_state { typedef unsigned short __bitwise pci_bus_flags_t; enum pci_bus_flags { - PCI_BUS_FLAGS_NO_MSI = (pci_bus_flags_t) 1, + PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1, }; struct pci_cap_saved_state {