Re: [PATCH 1/7] USB: UHCI: Remove PCI dependencies from uhci-hub

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

 



Hello.

On 05-05-2011 0:22, Jan Andersson wrote:

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

uhci-hub.c contained two PCI vendor checks for silicon quirks. Move
these checks into uhci-hcd.c and use bits in uhci_hcd structure to
mark that we need to use the quirks.

This patch is followed by other patches that will remove PCI
dependencies from uhci-hcd.c as well.

Signed-off-by: Jan Andersson<jan@xxxxxxxxxxx>
[...]

diff --git a/drivers/usb/host/uhci-hcd.c b/drivers/usb/host/uhci-hcd.c
index 83344d6..0b7e6e1 100644
--- a/drivers/usb/host/uhci-hcd.c
+++ b/drivers/usb/host/uhci-hcd.c
@@ -546,6 +546,18 @@ static int uhci_init(struct usb_hcd *hcd)
  	}
  	uhci->rh_numports = port;

+	/* Intel controllers report the OverCurrent bit active on.
+	 * VIA controllers report it active off, so we'll adjust the
+	 * bit value.  (It's not standardized in the UHCI spec.)
+	 */
+	if (to_pci_dev(hcd->self.controller)->vendor == PCI_VENDOR_ID_VIA)
+		uhci->oc_low = 1;
+
+	/* HP's server management chip requires
+	 * a longer delay. */

     Would be good to have the same style of comment as above...

Do you mean a more elaborate comment?

   No, the same (preferred) style:

/*
 * bla
 * bla
 */

I'm thinking that I should just make it to one line.

   That's also an option.

Best regards,
   Jan

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