Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1463913
| From | Tal Shorer <tal.shorer@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH v3 3/8] usb: dwc3: ulpi: use new api |
| Date | 2016-08-16 18:10 +0200 |
| Message-ID | <s6P6a-5fK-23@gated-at.bofh.it> (permalink) |
| References | <s6P69-5fK-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
The old read, write callbacks in struct ulpi_ops have been deprecated
in favor of new callbacks that pass the parent device directly.
Replace the used callbacks in dwc3's ulpi component with the new api.
Signed-off-by: Tal Shorer <tal.shorer@gmail.com>
---
drivers/usb/dwc3/ulpi.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/usb/dwc3/ulpi.c b/drivers/usb/dwc3/ulpi.c
index ec004c6..94eeb7a 100644
--- a/drivers/usb/dwc3/ulpi.c
+++ b/drivers/usb/dwc3/ulpi.c
@@ -35,9 +35,9 @@ static int dwc3_ulpi_busyloop(struct dwc3 *dwc)
return -ETIMEDOUT;
}
-static int dwc3_ulpi_read(struct ulpi_ops *ops, u8 addr)
+static int dwc3_ulpi_read(struct device *dev, u8 addr)
{
- struct dwc3 *dwc = dev_get_drvdata(ops->dev);
+ struct dwc3 *dwc = dev_get_drvdata(dev);
u32 reg;
int ret;
@@ -53,9 +53,9 @@ static int dwc3_ulpi_read(struct ulpi_ops *ops, u8 addr)
return DWC3_GUSB2PHYACC_DATA(reg);
}
-static int dwc3_ulpi_write(struct ulpi_ops *ops, u8 addr, u8 val)
+static int dwc3_ulpi_write(struct device *dev, u8 addr, u8 val)
{
- struct dwc3 *dwc = dev_get_drvdata(ops->dev);
+ struct dwc3 *dwc = dev_get_drvdata(dev);
u32 reg;
reg = DWC3_GUSB2PHYACC_NEWREGREQ | DWC3_ULPI_ADDR(addr);
@@ -66,8 +66,8 @@ static int dwc3_ulpi_write(struct ulpi_ops *ops, u8 addr, u8 val)
}
static struct ulpi_ops dwc3_ulpi_ops = {
- .read = dwc3_ulpi_read,
- .write = dwc3_ulpi_write,
+ .read_dev = dwc3_ulpi_read,
+ .write_dev = dwc3_ulpi_write,
};
int dwc3_ulpi_init(struct dwc3 *dwc)
--
2.7.4
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v3 0/8] usb: ulpi: remove "dev" field from struct ulpi_ops Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
[PATCH v3 1/8] usb: ulpi: move setting of ulpi->dev parent up in ulpi_register() Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
Re: [PATCH v3 1/8] usb: ulpi: move setting of ulpi->dev parent up in ulpi_register() Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2016-08-17 13:20 +0200
[PATCH v3 3/8] usb: dwc3: ulpi: use new api Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
Re: [PATCH v3 3/8] usb: dwc3: ulpi: use new api Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2016-08-17 13:20 +0200
[PATCH v3 5/8] usb: ulpi: rename operations {read|write}_dev to simply {read|write} Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
Re: [PATCH v3 5/8] usb: ulpi: rename operations {read|write}_dev to simply {read|write} Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2016-08-17 13:20 +0200
[PATCH v3 7/8] usb: ulpi: make ops struct constant Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
Re: [PATCH v3 7/8] usb: ulpi: make ops struct constant Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2016-08-17 13:20 +0200
[PATCH v3 4/8] usb: ulpi: remove calls to old api callbacks Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
Re: [PATCH v3 4/8] usb: ulpi: remove calls to old api callbacks Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2016-08-17 13:20 +0200
[PATCH v3 6/8] usb: ulpi: remove "dev" field from struct ulpi_ops Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
Re: [PATCH v3 6/8] usb: ulpi: remove "dev" field from struct ulpi_ops Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2016-08-17 13:20 +0200
[PATCH v3 8/8] usb: dwc3: ulpi: make dwc3_ulpi_ops constant Tal Shorer <tal.shorer@gmail.com> - 2016-08-16 18:10 +0200
Re: [PATCH v3 8/8] usb: dwc3: ulpi: make dwc3_ulpi_ops constant Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2016-08-17 13:20 +0200
csiph-web