aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/misc/uss720.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-04-20 19:53:53 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-04-20 19:53:53 -0400
commitd2b1ff7104d86e1e3cc0ab02f6aa0d96aeb2cf86 (patch)
tree003790d5175fdf4d5fbd74b9f7f5e333c23ef419 /drivers/usb/misc/uss720.c
parentabd83e4bc8bd819117bc27ba75cb8e0d337ebadb (diff)
USB: uss720.c: remove err() usage
err() was a very old USB-specific macro that I thought had gone away. This patch removes it from being used in the driver and uses dev_err() instead. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/misc/uss720.c')
-rw-r--r--drivers/usb/misc/uss720.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/drivers/usb/misc/uss720.c b/drivers/usb/misc/uss720.c
index 8b1d94a76914..7f64147ea229 100644
--- a/drivers/usb/misc/uss720.c
+++ b/drivers/usb/misc/uss720.c
@@ -118,7 +118,8 @@ static void async_complete(struct urb *urb)
118 priv = rq->priv; 118 priv = rq->priv;
119 pp = priv->pp; 119 pp = priv->pp;
120 if (status) { 120 if (status) {
121 err("async_complete: urb error %d", status); 121 dev_err(&urb->dev->dev, "async_complete: urb error %d\n",
122 status);
122 } else if (rq->dr.bRequest == 3) { 123 } else if (rq->dr.bRequest == 3) {
123 memcpy(priv->reg, rq->reg, sizeof(priv->reg)); 124 memcpy(priv->reg, rq->reg, sizeof(priv->reg));
124#if 0 125#if 0
@@ -151,7 +152,7 @@ static struct uss720_async_request *submit_async_request(struct parport_uss720_p
151 return NULL; 152 return NULL;
152 rq = kmalloc(sizeof(struct uss720_async_request), mem_flags); 153 rq = kmalloc(sizeof(struct uss720_async_request), mem_flags);
153 if (!rq) { 154 if (!rq) {
154 err("submit_async_request out of memory"); 155 dev_err(&usbdev->dev, "submit_async_request out of memory\n");
155 return NULL; 156 return NULL;
156 } 157 }
157 kref_init(&rq->ref_count); 158 kref_init(&rq->ref_count);
@@ -162,7 +163,7 @@ static struct uss720_async_request *submit_async_request(struct parport_uss720_p
162 rq->urb = usb_alloc_urb(0, mem_flags); 163 rq->urb = usb_alloc_urb(0, mem_flags);
163 if (!rq->urb) { 164 if (!rq->urb) {
164 kref_put(&rq->ref_count, destroy_async); 165 kref_put(&rq->ref_count, destroy_async);
165 err("submit_async_request out of memory"); 166 dev_err(&usbdev->dev, "submit_async_request out of memory\n");
166 return NULL; 167 return NULL;
167 } 168 }
168 rq->dr.bRequestType = requesttype; 169 rq->dr.bRequestType = requesttype;
@@ -182,7 +183,7 @@ static struct uss720_async_request *submit_async_request(struct parport_uss720_p
182 if (!ret) 183 if (!ret)
183 return rq; 184 return rq;
184 destroy_async(&rq->ref_count); 185 destroy_async(&rq->ref_count);
185 err("submit_async_request submit_urb failed with %d", ret); 186 dev_err(&usbdev->dev, "submit_async_request submit_urb failed with %d\n", ret);
186 return NULL; 187 return NULL;
187} 188}
188 189
@@ -217,7 +218,8 @@ static int get_1284_register(struct parport *pp, unsigned char reg, unsigned cha
217 priv = pp->private_data; 218 priv = pp->private_data;
218 rq = submit_async_request(priv, 3, 0xc0, ((unsigned int)reg) << 8, 0, mem_flags); 219 rq = submit_async_request(priv, 3, 0xc0, ((unsigned int)reg) << 8, 0, mem_flags);
219 if (!rq) { 220 if (!rq) {
220 err("get_1284_register(%u) failed", (unsigned int)reg); 221 dev_err(&priv->usbdev->dev, "get_1284_register(%u) failed",
222 (unsigned int)reg);
221 return -EIO; 223 return -EIO;
222 } 224 }
223 if (!val) { 225 if (!val) {
@@ -248,7 +250,8 @@ static int set_1284_register(struct parport *pp, unsigned char reg, unsigned cha
248 priv = pp->private_data; 250 priv = pp->private_data;
249 rq = submit_async_request(priv, 4, 0x40, (((unsigned int)reg) << 8) | val, 0, mem_flags); 251 rq = submit_async_request(priv, 4, 0x40, (((unsigned int)reg) << 8) | val, 0, mem_flags);
250 if (!rq) { 252 if (!rq) {
251 err("set_1284_register(%u,%u) failed", (unsigned int)reg, (unsigned int)val); 253 dev_err(&priv->usbdev->dev, "set_1284_register(%u,%u) failed",
254 (unsigned int)reg, (unsigned int)val);
252 return -EIO; 255 return -EIO;
253 } 256 }
254 kref_put(&rq->ref_count, destroy_async); 257 kref_put(&rq->ref_count, destroy_async);