| .. | .. |
|---|
| 3 | 3 | * Renesas USB driver R-Car Gen. 2 initialization and power control |
|---|
| 4 | 4 | * |
|---|
| 5 | 5 | * Copyright (C) 2014 Ulrich Hecht |
|---|
| 6 | + * Copyright (C) 2019 Renesas Electronics Corporation |
|---|
| 6 | 7 | */ |
|---|
| 7 | 8 | |
|---|
| 8 | | -#include <linux/gpio.h> |
|---|
| 9 | | -#include <linux/of_gpio.h> |
|---|
| 10 | 9 | #include <linux/phy/phy.h> |
|---|
| 11 | 10 | #include "common.h" |
|---|
| 12 | 11 | #include "rcar2.h" |
|---|
| .. | .. |
|---|
| 33 | 32 | struct usbhs_priv *priv = usbhs_pdev_to_priv(pdev); |
|---|
| 34 | 33 | |
|---|
| 35 | 34 | if (priv->phy) { |
|---|
| 36 | | - phy_put(priv->phy); |
|---|
| 35 | + phy_put(&pdev->dev, priv->phy); |
|---|
| 37 | 36 | priv->phy = NULL; |
|---|
| 38 | 37 | } |
|---|
| 39 | 38 | |
|---|
| .. | .. |
|---|
| 62 | 61 | return retval; |
|---|
| 63 | 62 | } |
|---|
| 64 | 63 | |
|---|
| 65 | | -static int usbhs_rcar2_get_id(struct platform_device *pdev) |
|---|
| 66 | | -{ |
|---|
| 67 | | - return USBHS_GADGET; |
|---|
| 68 | | -} |
|---|
| 69 | | - |
|---|
| 70 | | -const struct renesas_usbhs_platform_callback usbhs_rcar2_ops = { |
|---|
| 71 | | - .hardware_init = usbhs_rcar2_hardware_init, |
|---|
| 72 | | - .hardware_exit = usbhs_rcar2_hardware_exit, |
|---|
| 73 | | - .power_ctrl = usbhs_rcar2_power_ctrl, |
|---|
| 74 | | - .get_id = usbhs_rcar2_get_id, |
|---|
| 64 | +const struct renesas_usbhs_platform_info usbhs_rcar_gen2_plat_info = { |
|---|
| 65 | + .platform_callback = { |
|---|
| 66 | + .hardware_init = usbhs_rcar2_hardware_init, |
|---|
| 67 | + .hardware_exit = usbhs_rcar2_hardware_exit, |
|---|
| 68 | + .power_ctrl = usbhs_rcar2_power_ctrl, |
|---|
| 69 | + .get_id = usbhs_get_id_as_gadget, |
|---|
| 70 | + }, |
|---|
| 71 | + .driver_param = { |
|---|
| 72 | + .has_usb_dmac = 1, |
|---|
| 73 | + .has_new_pipe_configs = 1, |
|---|
| 74 | + }, |
|---|
| 75 | 75 | }; |
|---|