aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/usb/chipidea/otg_fsm.c4
-rw-r--r--drivers/usb/gadget/udc/core.c8
-rw-r--r--drivers/usb/phy/phy-mv-usb.c4
-rw-r--r--drivers/usb/serial/ftdi_sio.c4
-rw-r--r--drivers/usb/usbip/stub_dev.c4
-rw-r--r--drivers/usb/usbip/vhci_sysfs.c8
-rw-r--r--drivers/usb/usbip/vudc_sysfs.c4
7 files changed, 18 insertions, 18 deletions
diff --git a/drivers/usb/chipidea/otg_fsm.c b/drivers/usb/chipidea/otg_fsm.c
index d076cfa22fdf..6ed4b00dba96 100644
--- a/drivers/usb/chipidea/otg_fsm.c
+++ b/drivers/usb/chipidea/otg_fsm.c
@@ -162,7 +162,7 @@ b_bus_req_store(struct device *dev, struct device_attribute *attr,
162static DEVICE_ATTR_RW(b_bus_req); 162static DEVICE_ATTR_RW(b_bus_req);
163 163
164static ssize_t 164static ssize_t
165set_a_clr_err(struct device *dev, struct device_attribute *attr, 165a_clr_err_store(struct device *dev, struct device_attribute *attr,
166 const char *buf, size_t count) 166 const char *buf, size_t count)
167{ 167{
168 struct ci_hdrc *ci = dev_get_drvdata(dev); 168 struct ci_hdrc *ci = dev_get_drvdata(dev);
@@ -179,7 +179,7 @@ set_a_clr_err(struct device *dev, struct device_attribute *attr,
179 179
180 return count; 180 return count;
181} 181}
182static DEVICE_ATTR(a_clr_err, S_IWUSR, NULL, set_a_clr_err); 182static DEVICE_ATTR_WO(a_clr_err);
183 183
184static struct attribute *inputs_attrs[] = { 184static struct attribute *inputs_attrs[] = {
185 &dev_attr_a_bus_req.attr, 185 &dev_attr_a_bus_req.attr,
diff --git a/drivers/usb/gadget/udc/core.c b/drivers/usb/gadget/udc/core.c
index ac0541529499..859d5b11ba4c 100644
--- a/drivers/usb/gadget/udc/core.c
+++ b/drivers/usb/gadget/udc/core.c
@@ -1417,7 +1417,7 @@ EXPORT_SYMBOL_GPL(usb_gadget_unregister_driver);
1417 1417
1418/* ------------------------------------------------------------------------- */ 1418/* ------------------------------------------------------------------------- */
1419 1419
1420static ssize_t usb_udc_srp_store(struct device *dev, 1420static ssize_t srp_store(struct device *dev,
1421 struct device_attribute *attr, const char *buf, size_t n) 1421 struct device_attribute *attr, const char *buf, size_t n)
1422{ 1422{
1423 struct usb_udc *udc = container_of(dev, struct usb_udc, dev); 1423 struct usb_udc *udc = container_of(dev, struct usb_udc, dev);
@@ -1427,9 +1427,9 @@ static ssize_t usb_udc_srp_store(struct device *dev,
1427 1427
1428 return n; 1428 return n;
1429} 1429}
1430static DEVICE_ATTR(srp, S_IWUSR, NULL, usb_udc_srp_store); 1430static DEVICE_ATTR_WO(srp);
1431 1431
1432static ssize_t usb_udc_softconn_store(struct device *dev, 1432static ssize_t soft_connect_store(struct device *dev,
1433 struct device_attribute *attr, const char *buf, size_t n) 1433 struct device_attribute *attr, const char *buf, size_t n)
1434{ 1434{
1435 struct usb_udc *udc = container_of(dev, struct usb_udc, dev); 1435 struct usb_udc *udc = container_of(dev, struct usb_udc, dev);
@@ -1453,7 +1453,7 @@ static ssize_t usb_udc_softconn_store(struct device *dev,
1453 1453
1454 return n; 1454 return n;
1455} 1455}
1456static DEVICE_ATTR(soft_connect, S_IWUSR, NULL, usb_udc_softconn_store); 1456static DEVICE_ATTR_WO(soft_connect);
1457 1457
1458static ssize_t state_show(struct device *dev, struct device_attribute *attr, 1458static ssize_t state_show(struct device *dev, struct device_attribute *attr,
1459 char *buf) 1459 char *buf)
diff --git a/drivers/usb/phy/phy-mv-usb.c b/drivers/usb/phy/phy-mv-usb.c
index 49a4dd88c301..cfd9add10bf4 100644
--- a/drivers/usb/phy/phy-mv-usb.c
+++ b/drivers/usb/phy/phy-mv-usb.c
@@ -562,7 +562,7 @@ a_bus_req_store(struct device *dev, struct device_attribute *attr,
562static DEVICE_ATTR_RW(a_bus_req); 562static DEVICE_ATTR_RW(a_bus_req);
563 563
564static ssize_t 564static ssize_t
565set_a_clr_err(struct device *dev, struct device_attribute *attr, 565a_clr_err_store(struct device *dev, struct device_attribute *attr,
566 const char *buf, size_t count) 566 const char *buf, size_t count)
567{ 567{
568 struct mv_otg *mvotg = dev_get_drvdata(dev); 568 struct mv_otg *mvotg = dev_get_drvdata(dev);
@@ -586,7 +586,7 @@ set_a_clr_err(struct device *dev, struct device_attribute *attr,
586 return count; 586 return count;
587} 587}
588 588
589static DEVICE_ATTR(a_clr_err, S_IWUSR, NULL, set_a_clr_err); 589static DEVICE_ATTR_WO(a_clr_err);
590 590
591static ssize_t 591static ssize_t
592a_bus_drop_show(struct device *dev, struct device_attribute *attr, 592a_bus_drop_show(struct device *dev, struct device_attribute *attr,
diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c
index fc68952c994a..f58c4ff6b387 100644
--- a/drivers/usb/serial/ftdi_sio.c
+++ b/drivers/usb/serial/ftdi_sio.c
@@ -1691,7 +1691,7 @@ static DEVICE_ATTR_RW(latency_timer);
1691 1691
1692/* Write an event character directly to the FTDI register. The ASCII 1692/* Write an event character directly to the FTDI register. The ASCII
1693 value is in the low 8 bits, with the enable bit in the 9th bit. */ 1693 value is in the low 8 bits, with the enable bit in the 9th bit. */
1694static ssize_t store_event_char(struct device *dev, 1694static ssize_t event_char_store(struct device *dev,
1695 struct device_attribute *attr, const char *valbuf, size_t count) 1695 struct device_attribute *attr, const char *valbuf, size_t count)
1696{ 1696{
1697 struct usb_serial_port *port = to_usb_serial_port(dev); 1697 struct usb_serial_port *port = to_usb_serial_port(dev);
@@ -1718,7 +1718,7 @@ static ssize_t store_event_char(struct device *dev,
1718 1718
1719 return count; 1719 return count;
1720} 1720}
1721static DEVICE_ATTR(event_char, S_IWUSR, NULL, store_event_char); 1721static DEVICE_ATTR_WO(event_char);
1722 1722
1723static int create_sysfs_attrs(struct usb_serial_port *port) 1723static int create_sysfs_attrs(struct usb_serial_port *port)
1724{ 1724{
diff --git a/drivers/usb/usbip/stub_dev.c b/drivers/usb/usbip/stub_dev.c
index e31a6f204397..49e552472c3f 100644
--- a/drivers/usb/usbip/stub_dev.c
+++ b/drivers/usb/usbip/stub_dev.c
@@ -39,7 +39,7 @@ static DEVICE_ATTR_RO(usbip_status);
39 * is used to transfer usbip requests by kernel threads. -1 is a magic number 39 * is used to transfer usbip requests by kernel threads. -1 is a magic number
40 * by which usbip connection is finished. 40 * by which usbip connection is finished.
41 */ 41 */
42static ssize_t store_sockfd(struct device *dev, struct device_attribute *attr, 42static ssize_t usbip_sockfd_store(struct device *dev, struct device_attribute *attr,
43 const char *buf, size_t count) 43 const char *buf, size_t count)
44{ 44{
45 struct stub_device *sdev = dev_get_drvdata(dev); 45 struct stub_device *sdev = dev_get_drvdata(dev);
@@ -103,7 +103,7 @@ err:
103 spin_unlock_irq(&sdev->ud.lock); 103 spin_unlock_irq(&sdev->ud.lock);
104 return -EINVAL; 104 return -EINVAL;
105} 105}
106static DEVICE_ATTR(usbip_sockfd, S_IWUSR, NULL, store_sockfd); 106static DEVICE_ATTR_WO(usbip_sockfd);
107 107
108static int stub_add_files(struct device *dev) 108static int stub_add_files(struct device *dev)
109{ 109{
diff --git a/drivers/usb/usbip/vhci_sysfs.c b/drivers/usb/usbip/vhci_sysfs.c
index a9de15cab2ec..48808388ec33 100644
--- a/drivers/usb/usbip/vhci_sysfs.c
+++ b/drivers/usb/usbip/vhci_sysfs.c
@@ -218,7 +218,7 @@ static int valid_port(__u32 pdev_nr, __u32 rhport)
218 return 1; 218 return 1;
219} 219}
220 220
221static ssize_t store_detach(struct device *dev, struct device_attribute *attr, 221static ssize_t detach_store(struct device *dev, struct device_attribute *attr,
222 const char *buf, size_t count) 222 const char *buf, size_t count)
223{ 223{
224 __u32 port = 0, pdev_nr = 0, rhport = 0; 224 __u32 port = 0, pdev_nr = 0, rhport = 0;
@@ -256,7 +256,7 @@ static ssize_t store_detach(struct device *dev, struct device_attribute *attr,
256 256
257 return count; 257 return count;
258} 258}
259static DEVICE_ATTR(detach, S_IWUSR, NULL, store_detach); 259static DEVICE_ATTR_WO(detach);
260 260
261static int valid_args(__u32 pdev_nr, __u32 rhport, enum usb_device_speed speed) 261static int valid_args(__u32 pdev_nr, __u32 rhport, enum usb_device_speed speed)
262{ 262{
@@ -292,7 +292,7 @@ static int valid_args(__u32 pdev_nr, __u32 rhport, enum usb_device_speed speed)
292 * 292 *
293 * write() returns 0 on success, else negative errno. 293 * write() returns 0 on success, else negative errno.
294 */ 294 */
295static ssize_t store_attach(struct device *dev, struct device_attribute *attr, 295static ssize_t attach_store(struct device *dev, struct device_attribute *attr,
296 const char *buf, size_t count) 296 const char *buf, size_t count)
297{ 297{
298 struct socket *socket; 298 struct socket *socket;
@@ -387,7 +387,7 @@ static ssize_t store_attach(struct device *dev, struct device_attribute *attr,
387 387
388 return count; 388 return count;
389} 389}
390static DEVICE_ATTR(attach, S_IWUSR, NULL, store_attach); 390static DEVICE_ATTR_WO(attach);
391 391
392#define MAX_STATUS_NAME 16 392#define MAX_STATUS_NAME 16
393 393
diff --git a/drivers/usb/usbip/vudc_sysfs.c b/drivers/usb/usbip/vudc_sysfs.c
index 1adc8af292ec..d86f72bbbb91 100644
--- a/drivers/usb/usbip/vudc_sysfs.c
+++ b/drivers/usb/usbip/vudc_sysfs.c
@@ -90,7 +90,7 @@ unlock:
90} 90}
91static BIN_ATTR_RO(dev_desc, sizeof(struct usb_device_descriptor)); 91static BIN_ATTR_RO(dev_desc, sizeof(struct usb_device_descriptor));
92 92
93static ssize_t store_sockfd(struct device *dev, struct device_attribute *attr, 93static ssize_t usbip_sockfd_store(struct device *dev, struct device_attribute *attr,
94 const char *in, size_t count) 94 const char *in, size_t count)
95{ 95{
96 struct vudc *udc = (struct vudc *) dev_get_drvdata(dev); 96 struct vudc *udc = (struct vudc *) dev_get_drvdata(dev);
@@ -180,7 +180,7 @@ unlock:
180 180
181 return ret; 181 return ret;
182} 182}
183static DEVICE_ATTR(usbip_sockfd, S_IWUSR, NULL, store_sockfd); 183static DEVICE_ATTR_WO(usbip_sockfd);
184 184
185static ssize_t usbip_status_show(struct device *dev, 185static ssize_t usbip_status_show(struct device *dev,
186 struct device_attribute *attr, char *out) 186 struct device_attribute *attr, char *out)