staging: lirc: fix coding style problems
Subsystems (2)
PATCH 1/1 staging: lirc: fix coding style problems
This patch fix some coding style problems.
Signed-off-by Raphaël Poggi <[email protected]>
--- drivers/staging/media/lirc/lirc_imon.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-)
drivers/staging/media/lirc/lirc_imon.c +5 -8
@@ -189,6 +189,7 @@ MODULE_PARM_DESC(debug, "Debug messages: 0=no, 1=yes(default: no)");static void free_imon_context (struct imon_context *context) {struct device *dev = context->driver->dev; +usb_free_urb (context->tx_urb);usb_free_urb (context->rx_urb);lirc_buffer_free (context->driver->rbuf);
@@ -481,8 +482,6 @@ static void usb_tx_callback(struct urb *urb)/* notify waiters that write has finished */ atomic_set (&context->tx.busy,0 );complete (&context->tx.finished); - -return ; }/**
@@ -547,7 +546,6 @@ static void ir_close(void *data) }mutex_unlock (&context->ctx_lock); -return ; }/**
@@ -572,7 +570,6 @@ static void submit_data(struct imon_context *context)lirc_buffer_write (context->driver->rbuf, buf);wake_up (&context->driver->rbuf->wait_poll); -return ; }static inline int tv2int (const struct timeval *a,const struct timeval *b)
@@ -626,8 +623,8 @@ static void imon_incoming_packet(struct imon_context *context,if (debug) {dev_info (dev,"raw packet: " );for (i =0 ; i < len; ++i) -printk ("%02x " , buf[i]); -printk ("\n" ); +dev_dbg (dev,"%02x " , buf[i]); +dev_dbg (dev,"\n" ); }/*
@@ -656,6 +653,7 @@ static void imon_incoming_packet(struct imon_context *context, mask =0x80 ;for (bit =0 ; bit <8 ; ++bit) {int curr_bit = !(buf[octet] & mask); +if (curr_bit != context->rx.prev_bit) {if (context->rx.count) {submit_data (context);
@@ -707,8 +705,6 @@ static void usb_rx_callback(struct urb *urb) }usb_submit_urb (context->rx_urb,GFP_ATOMIC ); - -return ; }/**
@@ -775,6 +771,7 @@ static int imon_probe(struct usb_interface *interface,struct usb_endpoint_descriptor *ep;int ep_dir;int ep_type; + ep = &iface_desc->endpoint[i].desc; ep_dir = ep->bEndpointAddress &USB_ENDPOINT_DIR_MASK ; ep_type = ep->bmAttributes &USB_ENDPOINT_XFERTYPE_MASK ;
Signature · 1 line
1.7.9.5
Greg KH
maintainerQuoted 1 line · Raphael Poggi
This patch fix some coding style problems.
What specific "coding style problems" are fixed? Why should they be fixed? Please be specific and don't do more than one type of "fix" per patch.
Care to redo this?
thanks,
greg k-h
Quoted 1 line · Raphael Poggi
This patch fix some coding style problems.
[]
drivers/staging/media/lirc/lirc_imon.c
Quoted 1 line
drivers/staging/media/lirc/lirc_imon.c +0
-0
[]
drivers/staging/media/lirc/lirc_imon.c static void imon_incoming_packet(struct imon_context *context, · line 627
Quoted 8 lines
drivers/staging/media/lirc/lirc_imon.c +2
-2@@ -626,8 +623,8 @@ static void imon_incoming_packet(struct imon_context *context,if (debug) {dev_info (dev,"raw packet: " );for (i =0 ; i < len; ++i) -printk ("%02x " , buf[i]); -printk ("\n" ); +dev_dbg (dev,"%02x " , buf[i]); +dev_dbg (dev,"\n" );
This chunk is not correct and causes output problems.
These printks should either use pr_cont or
you want to use something like print_hex_dump