@@ -117,7 +117,7 @@ static int aircable_process_packet(struct usb_serial_port *port,
static void aircable_process_read_urb(struct urb *urb)
{
struct usb_serial_port *port = urb->context;
- char *data = (char *)urb->transfer_buffer;
+ char *data = urb->transfer_buffer;
int has_headers;
int count;
int len;
@@ -2584,7 +2584,7 @@ static void ftdi_process_read_urb(struct urb *urb)
{
struct usb_serial_port *port = urb->context;
struct ftdi_private *priv = usb_get_serial_port_data(port);
- char *data = (char *)urb->transfer_buffer;
+ char *data = urb->transfer_buffer;
int i;
int len;
int count = 0;
@@ -345,7 +345,7 @@ EXPORT_SYMBOL_GPL(usb_serial_generic_submit_read_urbs);
void usb_serial_generic_process_read_urb(struct urb *urb)
{
struct usb_serial_port *port = urb->context;
- char *ch = (char *)urb->transfer_buffer;
+ char *ch = urb->transfer_buffer;
int i;
if (!urb->actual_length)
@@ -2151,8 +2151,7 @@ static void option_instat_callback(struct urb *urb)
dev_dbg(dev, "%s: urb %p port %p has data %p\n", __func__, urb, port, portdata);
if (status == 0) {
- struct usb_ctrlrequest *req_pkt =
- (struct usb_ctrlrequest *)urb->transfer_buffer;
+ struct usb_ctrlrequest *req_pkt = urb->transfer_buffer;
if (!req_pkt) {
dev_dbg(dev, "%s: NULL req_pkt\n", __func__);
@@ -570,8 +570,7 @@ static void sierra_instat_callback(struct urb *urb)
urb, port, portdata);
if (status == 0) {
- struct usb_ctrlrequest *req_pkt =
- (struct usb_ctrlrequest *)urb->transfer_buffer;
+ struct usb_ctrlrequest *req_pkt = urb->transfer_buffer;
if (!req_pkt) {
dev_dbg(&port->dev, "%s: NULL req_pkt\n",
@@ -495,7 +495,7 @@ static void ssu100_update_lsr(struct usb_serial_port *port, u8 lsr,
static void ssu100_process_read_urb(struct urb *urb)
{
struct usb_serial_port *port = urb->context;
- char *packet = (char *)urb->transfer_buffer;
+ char *packet = urb->transfer_buffer;
char flag = TTY_NORMAL;
u32 len = urb->actual_length;
int i;
Drop redundant URB transfer-buffer casts. Signed-off-by: Johan Hovold <johan@kernel.org> --- drivers/usb/serial/aircable.c | 2 +- drivers/usb/serial/ftdi_sio.c | 2 +- drivers/usb/serial/generic.c | 2 +- drivers/usb/serial/option.c | 3 +-- drivers/usb/serial/sierra.c | 3 +-- drivers/usb/serial/ssu100.c | 2 +- 6 files changed, 6 insertions(+), 8 deletions(-)