diff options
author | Ming Lei <tom.leiming@gmail.com> | 2008-02-24 05:41:47 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2008-04-25 00:16:55 -0400 |
commit | cdc97792289179974af6dda781c855696358d307 (patch) | |
tree | d633d7e5bd0b14b7581e20790c1a83baadfad80c /drivers/usb/serial/mos7840.c | |
parent | a5b6f60c5a30c494017c7a2d11c4067f90d3d0df (diff) |
USB: remove unnecessary type casting of urb->context
urb->context code cleanup
Signed-off-by: Ming Lei <tom.leiming@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/serial/mos7840.c')
-rw-r--r-- | drivers/usb/serial/mos7840.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c index 7823222570b6..6bcb82d3911a 100644 --- a/drivers/usb/serial/mos7840.c +++ b/drivers/usb/serial/mos7840.c | |||
@@ -449,7 +449,7 @@ static void mos7840_control_callback(struct urb *urb) | |||
449 | int result = 0; | 449 | int result = 0; |
450 | int status = urb->status; | 450 | int status = urb->status; |
451 | 451 | ||
452 | mos7840_port = (struct moschip_port *)urb->context; | 452 | mos7840_port = urb->context; |
453 | 453 | ||
454 | switch (status) { | 454 | switch (status) { |
455 | case 0: | 455 | case 0: |
@@ -554,7 +554,7 @@ static void mos7840_interrupt_callback(struct urb *urb) | |||
554 | length = urb->actual_length; | 554 | length = urb->actual_length; |
555 | data = urb->transfer_buffer; | 555 | data = urb->transfer_buffer; |
556 | 556 | ||
557 | serial = (struct usb_serial *)urb->context; | 557 | serial = urb->context; |
558 | 558 | ||
559 | /* Moschip get 5 bytes | 559 | /* Moschip get 5 bytes |
560 | * Byte 1 IIR Port 1 (port.number is 0) | 560 | * Byte 1 IIR Port 1 (port.number is 0) |
@@ -685,7 +685,7 @@ static void mos7840_bulk_in_callback(struct urb *urb) | |||
685 | return; | 685 | return; |
686 | } | 686 | } |
687 | 687 | ||
688 | mos7840_port = (struct moschip_port *)urb->context; | 688 | mos7840_port = urb->context; |
689 | if (!mos7840_port) { | 689 | if (!mos7840_port) { |
690 | dbg("%s", "NULL mos7840_port pointer \n"); | 690 | dbg("%s", "NULL mos7840_port pointer \n"); |
691 | return; | 691 | return; |
@@ -752,7 +752,7 @@ static void mos7840_bulk_out_data_callback(struct urb *urb) | |||
752 | int status = urb->status; | 752 | int status = urb->status; |
753 | int i; | 753 | int i; |
754 | 754 | ||
755 | mos7840_port = (struct moschip_port *)urb->context; | 755 | mos7840_port = urb->context; |
756 | spin_lock(&mos7840_port->pool_lock); | 756 | spin_lock(&mos7840_port->pool_lock); |
757 | for (i = 0; i < NUM_URBS; i++) { | 757 | for (i = 0; i < NUM_URBS; i++) { |
758 | if (urb == mos7840_port->write_urb_pool[i]) { | 758 | if (urb == mos7840_port->write_urb_pool[i]) { |