mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-18 18:23:53 +08:00
USB: ohci-sh - use resource_size instead of defining its own resource_len macro
Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
4e5c353b3c
commit
39eb234874
@ -77,7 +77,6 @@ static const struct hc_driver ohci_sh_hc_driver = {
|
|||||||
|
|
||||||
/*-------------------------------------------------------------------------*/
|
/*-------------------------------------------------------------------------*/
|
||||||
|
|
||||||
#define resource_len(r) (((r)->end - (r)->start) + 1)
|
|
||||||
static int ohci_hcd_sh_probe(struct platform_device *pdev)
|
static int ohci_hcd_sh_probe(struct platform_device *pdev)
|
||||||
{
|
{
|
||||||
struct resource *res = NULL;
|
struct resource *res = NULL;
|
||||||
@ -109,7 +108,7 @@ static int ohci_hcd_sh_probe(struct platform_device *pdev)
|
|||||||
|
|
||||||
hcd->regs = (void __iomem *)res->start;
|
hcd->regs = (void __iomem *)res->start;
|
||||||
hcd->rsrc_start = res->start;
|
hcd->rsrc_start = res->start;
|
||||||
hcd->rsrc_len = resource_len(res);
|
hcd->rsrc_len = resource_size(res);
|
||||||
ret = usb_add_hcd(hcd, irq, IRQF_DISABLED);
|
ret = usb_add_hcd(hcd, irq, IRQF_DISABLED);
|
||||||
if (ret != 0) {
|
if (ret != 0) {
|
||||||
err("Failed to add hcd");
|
err("Failed to add hcd");
|
||||||
|
Loading…
Reference in New Issue
Block a user