aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/mon/mon_text.c
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2007-08-24 15:41:41 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2007-10-12 17:55:23 -0400
commit9347d51c52afcf1a77d2104f162cf8a085624c83 (patch)
treef128a00eeed69166f5f5a7196a8c1c45c5cc5d92 /drivers/usb/mon/mon_text.c
parent888fda47051716765175d0008450126c837adb32 (diff)
USB: reorganize urb->status use in usbmon
This patch (as978) reorganizes the way usbmon uses urb->status. It now accepts the status value as an argument. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Acked-by: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/mon/mon_text.c')
-rw-r--r--drivers/usb/mon/mon_text.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/usb/mon/mon_text.c b/drivers/usb/mon/mon_text.c
index 663a702a17dd..ebb04ac4857b 100644
--- a/drivers/usb/mon/mon_text.c
+++ b/drivers/usb/mon/mon_text.c
@@ -183,7 +183,7 @@ static inline unsigned int mon_get_timestamp(void)
183} 183}
184 184
185static void mon_text_event(struct mon_reader_text *rp, struct urb *urb, 185static void mon_text_event(struct mon_reader_text *rp, struct urb *urb,
186 char ev_type) 186 char ev_type, int status)
187{ 187{
188 struct mon_event_text *ep; 188 struct mon_event_text *ep;
189 unsigned int stamp; 189 unsigned int stamp;
@@ -210,7 +210,7 @@ static void mon_text_event(struct mon_reader_text *rp, struct urb *urb,
210 ep->length = (ev_type == 'S') ? 210 ep->length = (ev_type == 'S') ?
211 urb->transfer_buffer_length : urb->actual_length; 211 urb->transfer_buffer_length : urb->actual_length;
212 /* Collecting status makes debugging sense for submits, too */ 212 /* Collecting status makes debugging sense for submits, too */
213 ep->status = urb->status; 213 ep->status = status;
214 214
215 if (ep->xfertype == USB_ENDPOINT_XFER_INT) { 215 if (ep->xfertype == USB_ENDPOINT_XFER_INT) {
216 ep->interval = urb->interval; 216 ep->interval = urb->interval;
@@ -248,13 +248,13 @@ static void mon_text_event(struct mon_reader_text *rp, struct urb *urb,
248static void mon_text_submit(void *data, struct urb *urb) 248static void mon_text_submit(void *data, struct urb *urb)
249{ 249{
250 struct mon_reader_text *rp = data; 250 struct mon_reader_text *rp = data;
251 mon_text_event(rp, urb, 'S'); 251 mon_text_event(rp, urb, 'S', -EINPROGRESS);
252} 252}
253 253
254static void mon_text_complete(void *data, struct urb *urb) 254static void mon_text_complete(void *data, struct urb *urb, int status)
255{ 255{
256 struct mon_reader_text *rp = data; 256 struct mon_reader_text *rp = data;
257 mon_text_event(rp, urb, 'C'); 257 mon_text_event(rp, urb, 'C', status);
258} 258}
259 259
260static void mon_text_error(void *data, struct urb *urb, int error) 260static void mon_text_error(void *data, struct urb *urb, int error)