USB: EHCI: make ehci-platform use devm_request_and_ioremap helper
authorFlorian Fainelli <florian@openwrt.org>
Mon, 8 Oct 2012 13:11:45 +0000 (15:11 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 22 Oct 2012 18:30:26 +0000 (11:30 -0700)
commit61ff2745e53512adf22625f9194e83e471882523
treea09a5b9fa02ce6e23ef4cf132da11878adcb0670
parentac0e3c04eb7dbf093032b72020951f9b92ede3d7
USB: EHCI: make ehci-platform use devm_request_and_ioremap helper

This patch changes the ehci-platform driver to use the device managed helper
function for requesting memory region and ioremapping memory resources.
As a result the error path in the probe function is simplified, and the
platform driver remove callback does no longer need to release and iounmap
memory resources. devm_request_and_ioremap() will use either the ioremap()
or ioremap_nocache() handler depending on the resource's CACHEABLE flag, so
we are good with this change.

Signed-off-by: Florian Fainelli <florian@openwrt.org>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/ehci-platform.c