Commit Graph
2 Commits
Author SHA1 Message Date
Peter Chen 0573f2c519 usb: core: of.c: fix defined but not declare warning
The helper usb_of_get_child_node is defined at of.c, but missing its
declare as a global function. Fix it by adding related header file
as well as compile it on conditional of CONFIG_OF.

Cc: Greg Kroah-Hartman <[email protected]>
Cc: Arnd Bergmann <[email protected]>
Cc: Alan Stern <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: Ben Dooks <[email protected]>
Cc: [email protected]

Signed-off-by: Peter Chen <[email protected]>
Reported-by: Ben Dooks <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
2016-08-09 16:16:13 +02:00
Peter Chen 69bec72598 USB: core: let USB device know device node
Although most of USB devices are hot-plug's, there are still some devices
are hard wired on the board, eg, for HSIC and SSIC interface USB devices.
If these kinds of USB devices are multiple functions, and they can supply
other interfaces like i2c, gpios for other devices, we may need to
describe these at device tree.

In this commit, it uses "reg" in dts as physical port number to match
the phyiscal port number decided by USB core, if they are the same,
then the device node is for the device we are creating for USB core.

Signed-off-by: Peter Chen <[email protected]>
Acked-by: Philipp Zabel <[email protected]>
Acked-by: Alan Stern <[email protected]>
Acked-by: Rob Herring <[email protected]>
Acked-by: Arnd Bergmann <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
2016-03-05 12:05:01 -08:00