Re: [PATCH V2 3/7] USB: UHCI: Move PCI specific functions to uhci-pci.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

Jan Andersson wrote:

This patch is part of a series that extend the UHCI HCD to support
non-PCI controllers.

This patch moves PCI specific functions to uhci-pci.c and includes
this file in uhci-hcd.c. It also renames the function uhci_init to
uhci_pci_init.

uhci_init/uhci_pci_init is modified so that the port-detection logic
is kept in a new separate function uhci_count_ports() in uhci-hcd.c.

The patch has the following checkpatch error/warnings:

ERROR: switch and case should be at the same indent
+	switch (to_pci_dev(uhci_dev(uhci))->vendor) {
+	    default:
[...]
+	    case PCI_VENDOR_ID_GENESYS:
[...]
+	    case PCI_VENDOR_ID_INTEL:

WARNING: static char array declaration should probably be static const char
+	static char bad_Asus_board[] = "A7V8X";

WARNING: braces {} are not necessary for single statement blocks
+	else {
+		check_and_reset_hc(uhci);
+	}

(false positive)

WARNING: Use DEFINE_PCI_DEVICE_TABLE for struct pci_device_id
+static const struct pci_device_id uhci_pci_ids[] = { {

total: 1 errors, 3 warnings, 688 lines checked

These warnings come from code moved from uhci-hcd.c to uhci-pci.c. The
valid warnings are fixed in the next patch of this series.

You could have avoided these errors/warnings (and the above text) if you fixed them in the original code before moving it to the new file.

WBR, Sergei
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux