[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [XEN PATCH 6/6] xen/pci: address violations of MISRA C:2012 Rule 8.2
Add missing parameter names to address violations of MISRA C:2012 Rule 8.2. Furthermore, use C standard types to comply with XEN coding style. No functional change. Signed-off-by: Federico Serafini <federico.serafini@xxxxxxxxxxx> --- xen/drivers/passthrough/pci.c | 8 ++++---- xen/include/xen/pci.h | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/xen/drivers/passthrough/pci.c b/xen/drivers/passthrough/pci.c index 04d00c7c37..28ed8ea817 100644 --- a/xen/drivers/passthrough/pci.c +++ b/xen/drivers/passthrough/pci.c @@ -104,9 +104,9 @@ static struct pci_seg *alloc_pseg(u16 seg) } static int pci_segments_iterate( - int (*handler)(struct pci_seg *, void *), void *arg) + int (*handler)(struct pci_seg *pseg, void *arg), void *arg) { - u16 seg = 0; + uint16_t seg = 0; int rc = 0; do { @@ -1077,7 +1077,7 @@ int __init scan_pci_devices(void) struct setup_hwdom { struct domain *d; - int (*handler)(u8 devfn, struct pci_dev *); + int (*handler)(uint8_t devfn, struct pci_dev *pdev); }; static void __hwdom_init setup_one_hwdom_device(const struct setup_hwdom *ctxt, @@ -1157,7 +1157,7 @@ static int __hwdom_init cf_check _setup_hwdom_pci_devices( } void __hwdom_init setup_hwdom_pci_devices( - struct domain *d, int (*handler)(u8 devfn, struct pci_dev *)) + struct domain *d, int (*handler)(uint8_t devfn, struct pci_dev *pdev)) { struct setup_hwdom ctxt = { .d = d, .handler = handler }; diff --git a/xen/include/xen/pci.h b/xen/include/xen/pci.h index 50d7dfb2a2..a3b7434818 100644 --- a/xen/include/xen/pci.h +++ b/xen/include/xen/pci.h @@ -178,7 +178,8 @@ enum pdev_type pdev_type(u16 seg, u8 bus, u8 devfn); int find_upstream_bridge(u16 seg, u8 *bus, u8 *devfn, u8 *secbus); void setup_hwdom_pci_devices(struct domain *d, - int (*handler)(u8 devfn, struct pci_dev *pdev)); + int (*handler)(uint8_t devfn, + struct pci_dev *pdev)); int pci_release_devices(struct domain *d); void pci_segments_init(void); int pci_add_segment(u16 seg); -- 2.34.1
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |