Overcurrent behavior of linux usb stack

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

 



Hi All,

As per USB 2.0 specification(Section 11.12.5 Over-current Reporting
and Recovery):

When a hub experiences an over-current condition, it must place all
affected ports in the Powered-off state.

It does not specify whether this action is to be done by hardware or software.

I am working with controller where it expects port power off to be
done by software in case of overcurrent detection interrupt.

So , implementation would be something like:

			if (hubchange & HUB_CHANGE_OVERCURRENT) {
				dev_dbg (hub_dev, "overcurrent change\n");

hub_power_off(hub);
				msleep(500);	/* Cool down */
				clear_hub_feature(hdev, C_HUB_OVER_CURRENT);
                                                    	hub_power_on(hub, true);
			}

Is this implementation correct?

We are in the process to submit patches for the support of this
pltaform into main line linux.

Regards
Pratyush
--
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