[PATCH 32/32] Staging/octeon-usb/octeon-hcd.c: Compression of lines for immediate return This patch compresses two lines in to a single line in file octeon-hcd.c
if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. It is done using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression ret; identifier f; @@ -ret = +return f(...); -return ret; Signed-off-by: Nadim Almas Acked-by: Julia Lawall --- Makefile| 2 +- drivers/staging/octeon-usb/octeon-hcd.c | 16 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index 4fb6bea..3d9d77a6 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ VERSION = 4 PATCHLEVEL = 7 SUBLEVEL = 0 -EXTRAVERSION = -rc4 +EXTRAVERSION = -eudyptula-rc4 NAME = Psychotic Stoned Sheep # *DOCUMENTATION* diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 17442b3..b801c8a 100644 --- a/drivers/staging/octeon-usb/octeon-hcd.c +++ b/drivers/staging/octeon-usb/octeon-hcd.c @@ -508,15 +508,15 @@ static int octeon_map_urb_for_dma(struct usb_hcd *hcd, struct urb *urb, { int ret; - ret = octeon_alloc_temp_buffer(urb, mem_flags); - if (ret) - return ret; + + if (octeon_alloc_temp_buffer(urb, mem_flags)) + return octeon_alloc_temp_buffer(urb, mem_flags); - ret = usb_hcd_map_urb_for_dma(hcd, urb, mem_flags); - if (ret) + + if (usb_hcd_map_urb_for_dma(hcd, urb, mem_flags)) octeon_free_temp_buffer(urb); - return ret; + return usb_hcd_map_urb_for_dma(hcd, urb, mem_flags); } /** @@ -542,8 +542,8 @@ static void octeon_unmap_urb_for_dma(struct usb_hcd *hcd, struct urb *urb) */ static inline u32 cvmx_usb_read_csr32(struct octeon_hcd *usb, u64 address) { - u32 result = cvmx_read64_uint32(address ^ 4); - return result; + + return cvmx_read64_uint32(address ^ 4); } /** -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 31/32] staging: android: ion: ion.c fixed a 80 character line limit coding style issue
From: sarique fixed a coding style issue. Signed-off-by: Nadim almas --- drivers/staging/android/ion/ion.c| 3 ++- drivers/staging/comedi/drivers/ssv_dnp.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index a2cf93b..52345df 100644 --- a/drivers/staging/android/ion/ion.c +++ b/drivers/staging/android/ion/ion.c @@ -1358,7 +1358,8 @@ static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) struct ion_handle *handle; mutex_lock(&client->lock); - handle = ion_handle_get_by_id_nolock(client, data.handle.handle); + handle = ion_handle_get_by_id_nolock(client, +data.handle.handle); if (IS_ERR(handle)) { mutex_unlock(&client->lock); return PTR_ERR(handle); diff --git a/drivers/staging/comedi/drivers/ssv_dnp.c b/drivers/staging/comedi/drivers/ssv_dnp.c index f9f634f..5674427 100644 --- a/drivers/staging/comedi/drivers/ssv_dnp.c +++ b/drivers/staging/comedi/drivers/ssv_dnp.c @@ -121,9 +121,9 @@ static int dnp_dio_insn_config(struct comedi_device *dev, } val = inb(CSCDR); - if (data[0] == COMEDI_OUTPUT) + if (data[0] == COMEDI_OUTPUT) val |= mask; - else +else val &= ~mask; outb(val, CSCDR); -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 33/33] Staging: android: ion: ion.c: Compression of lines for
This patch compresses two lines in to a single line in file rtw_android.c if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. It is done using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Nadim Almas --- drivers/staging/android/ion/ion.c | 8 +++- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index 52345df..271395b 100644 --- a/drivers/staging/android/ion/ion.c +++ b/drivers/staging/android/ion/ion.c @@ -391,9 +391,7 @@ static int ion_handle_put_nolock(struct ion_handle *handle) { int ret; - ret = kref_put(&handle->ref, ion_handle_destroy); - - return ret; +return kref_put(&handle->ref, ion_handle_destroy); } static int ion_handle_put(struct ion_handle *handle) @@ -597,8 +595,8 @@ int ion_phys(struct ion_client *client, struct ion_handle *handle, return -ENODEV; } mutex_unlock(&client->lock); - ret = buffer->heap->ops->phys(buffer->heap, buffer, addr, len); - return ret; + +return buffer->heap->ops->phys(buffer->heap, buffer, addr, len); } EXPORT_SYMBOL(ion_phys); ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 33/33] Staging: android: ion: ion.c: Compression of lines for
This patch compresses two lines in to a single line in file rtw_android.c if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. It is done using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Nadim Almas --- drivers/staging/android/ion/ion.c | 8 +++- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index 52345df..271395b 100644 --- a/drivers/staging/android/ion/ion.c +++ b/drivers/staging/android/ion/ion.c @@ -391,9 +391,7 @@ static int ion_handle_put_nolock(struct ion_handle *handle) { int ret; - ret = kref_put(&handle->ref, ion_handle_destroy); - - return ret; +return kref_put(&handle->ref, ion_handle_destroy); } static int ion_handle_put(struct ion_handle *handle) @@ -597,8 +595,8 @@ int ion_phys(struct ion_client *client, struct ion_handle *handle, return -ENODEV; } mutex_unlock(&client->lock); - ret = buffer->heap->ops->phys(buffer->heap, buffer, addr, len); - return ret; + +return buffer->heap->ops->phys(buffer->heap, buffer, addr, len); } EXPORT_SYMBOL(ion_phys); ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 33/33] Staging: android: ion: ion.c: Compression of lines for
This patch compresses two lines in to a single line in file rtw_android.c if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. It is done using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Nadim Almas --- drivers/staging/android/ion/ion.c | 8 +++- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index 52345df..271395b 100644 --- a/drivers/staging/android/ion/ion.c +++ b/drivers/staging/android/ion/ion.c @@ -391,9 +391,7 @@ static int ion_handle_put_nolock(struct ion_handle *handle) { - int ret; - ret = kref_put(&handle->ref, ion_handle_destroy); - - return ret; +return kref_put(&handle->ref, ion_handle_destroy); } static int ion_handle_put(struct ion_handle *handle) @@ -597,8 +595,8 @@ int ion_phys(struct ion_client *client, struct ion_handle *handle, return -ENODEV; } mutex_unlock(&client->lock); - ret = buffer->heap->ops->phys(buffer->heap, buffer, addr, len); - return ret; + +return buffer->heap->ops->phys(buffer->heap, buffer, addr, len); } EXPORT_SYMBOL(ion_phys); ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 33/33] Staging: android: ion: ion.c: Compression of lines for
This patch compresses two lines in to a single line in file rtw_android.c if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. It is done using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Nadim Almas --- drivers/staging/android/ion/ion.c | 8 +++- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index 52345df..271395b 100644 --- a/drivers/staging/android/ion/ion.c +++ b/drivers/staging/android/ion/ion.c @@ -391,9 +391,7 @@ static int ion_handle_put_nolock(struct ion_handle *handle) { - int ret; - ret = kref_put(&handle->ref, ion_handle_destroy); - - return ret; + return kref_put(&handle->ref, ion_handle_destroy); } static int ion_handle_put(struct ion_handle *handle) @@ -597,8 +595,8 @@ int ion_phys(struct ion_client *client, struct ion_handle *handle, return -ENODEV; } mutex_unlock(&client->lock); - ret = buffer->heap->ops->phys(buffer->heap, buffer, addr, len); - return ret; + return buffer->heap->ops->phys(buffer->heap, buffer, addr, len); } EXPORT_SYMBOL(ion_phys); ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 33/33] Staging: android: ion: ion.c: Compression of lines for
This patch compresses two lines in to a single line in file ion.c if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. It is done using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Nadim Almas --- drivers/staging/android/ion/ion.c | 8 +++- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index 52345df..271395b 100644 --- a/drivers/staging/android/ion/ion.c +++ b/drivers/staging/android/ion/ion.c @@ -391,9 +391,7 @@ static int ion_handle_put_nolock(struct ion_handle *handle) { - int ret; - ret = kref_put(&handle->ref, ion_handle_destroy); - - return ret; + return kref_put(&handle->ref, ion_handle_destroy); } static int ion_handle_put(struct ion_handle *handle) @@ -597,8 +595,8 @@ int ion_phys(struct ion_client *client, struct ion_handle *handle, return -ENODEV; } mutex_unlock(&client->lock); - ret = buffer->heap->ops->phys(buffer->heap, buffer, addr, len); - return ret; + return buffer->heap->ops->phys(buffer->heap, buffer, addr, len); } EXPORT_SYMBOL(ion_phys); ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 34/34] Staging: comedi: drivers: cd_pcidas: Compression of
This patch compresses two lines in to a single line in file cb_pcidas.c if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. It is done using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression e, ret; @@ -ret = +return e; -return ret Signed-off-by: Nadim Almas --- drivers/staging/comedi/drivers/cb_pcidas64.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/drivers/staging/comedi/drivers/cb_pcidas64.c b/drivers/staging/comedi/drivers/cb_pcidas64.c index 1f9c08a..d30cf3d 100644 --- a/drivers/staging/comedi/drivers/cb_pcidas64.c +++ b/drivers/staging/comedi/drivers/cb_pcidas64.c @@ -1408,9 +1408,7 @@ static int set_ai_fifo_size(struct comedi_device *dev, unsigned int num_samples) if (retval < 0) return retval; - num_samples = retval * fifo->num_segments * fifo->sample_packing_ratio; - - return num_samples; + return retval * fifo->num_segments * fifo->sample_packing_ratio; } /* query length of fifo */ -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging: android: ion: ion.c: Compression of lines for
This patch compresses two lines in to a single line in file ion.c if immediate return statement is found.It also removes variable ret as it is no longer needed. ne using script Coccinelle. And coccinelle uses following semantic patch for this compression function: @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Nadim Almas --- drivers/staging/android/ion/ion.c | 8 +++- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index 52345df..271395b 100644 --- a/drivers/staging/android/ion/ion.c +++ b/drivers/staging/android/ion/ion.c @@ -391,9 +391,7 @@ static int ion_handle_put_nolock(struct ion_handle *handle) { - int ret; - ret = kref_put(&handle->ref, ion_handle_destroy); - - return ret; + return kref_put(&handle->ref, ion_handle_destroy); } static int ion_handle_put(struct ion_handle *handle) @@ -597,8 +595,8 @@ int ion_phys(struct ion_client *client, struct ion_handle *handle, return -ENODEV; } mutex_unlock(&client->lock); - ret = buffer->heap->ops->phys(buffer->heap, buffer, addr, len); - return ret; + return buffer->heap->ops->phys(buffer->heap, buffer, addr, len); } EXPORT_SYMBOL(ion_phys); -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 1/1] Staging:dgnc:dgnc_neo: fixed 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- drivers/staging/dgnc/dgnc_neo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/dgnc/dgnc_neo.c b/drivers/staging/dgnc/dgnc_neo.c index 0974986..f07f69c 100644 --- a/drivers/staging/dgnc/dgnc_neo.c +++ b/drivers/staging/dgnc/dgnc_neo.c @@ -1463,8 +1463,8 @@ static void neo_copy_data_from_queue_to_uart(struct channel_t *ch) /* * If DTR Toggle mode is on, turn on DTR now if not already set, -* and make sure we get an event when the data transfer has completed. +* and make sure we get an event when the data transfer has com- +* -pleted. */ if (ch->ch_digi.digi_flags & DIGI_DTR_TOGGLE) { if (!(ch->ch_mostat & UART_MCR_DTR)) { -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:dgnc:dgnc_neo: fixed 80 character line limit coding style issue
Fixed coding style issue. Signed-off-by: Nadim Almas --- drivers/staging/dgnc/dgnc_neo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/dgnc/dgnc_neo.c b/drivers/staging/dgnc/dgnc_neo.c index e794056..bc15584 100644 --- a/drivers/staging/dgnc/dgnc_neo.c +++ b/drivers/staging/dgnc/dgnc_neo.c @@ -554,7 +554,8 @@ static inline void neo_parse_lsr(struct dgnc_board *brd, uint port) * Rx Oruns. Exar says that an orun will NOT corrupt * the FIFO. It will just replace the holding register * with this new data byte. So basically just ignore this. -* Probably we should eventually have an orun stat in our driver... +* Probably we should eventually have an orun stat in our +* driver... */ ch->ch_err_overrun++; } -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Fwd: [PATCH] Staging:dgnc:dgnc_neo: fixed 80 character line limit coding style issue
sir i am new in linux kernel hacking so I just want to start with something very simple ,so for sake of simplicity and learning I fixed only one of these warning ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: Fwd: [PATCH] Staging:dgnc:dgnc_neo: fixed 80 character line limit coding style issue
So my first patch is correct? On Sun, Oct 2, 2016 at 9:39 PM, Greg KH wrote: > On Sun, Oct 02, 2016 at 09:13:32PM +0530, Nadim Almas wrote: >> sir i am new in linux kernel hacking so I just want to start with >> something very simple ,so for sake of simplicity and learning I fixed >> only one of these warning > > That's great, but next time try to do a little bit more, just fixing a > single warning like that isn't all that useful overall, right? > > thanks, > > greg k-h ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:dgnc:dgnc_neo: fixed 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- drivers/staging/dgnc/dgnc_neo.h | 18 -- 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/drivers/staging/dgnc/dgnc_neo.h b/drivers/staging/dgnc/dgnc_neo.h index abddd48..65994e3 100644 --- a/drivers/staging/dgnc/dgnc_neo.h +++ b/drivers/staging/dgnc/dgnc_neo.h @@ -30,7 +30,8 @@ struct neo_uart_struct { u8 txrx;/* WR RHR/THR - Holding Reg */ u8 ier; /* WR IER - Interrupt Enable Reg */ - u8 isr_fcr; /* WR ISR/FCR - Interrupt Status Reg/Fifo Control Reg */ + u8 isr_fcr; /* WR ISR/FCR - Interrupt Status Reg/Fifo Control */ + /*Reg */ u8 lcr; /* WR LCR - Line Control Reg */ u8 mcr; /* WR MCR - Modem Control Reg */ u8 lsr; /* WR LSR - Line Status Reg */ @@ -108,7 +109,8 @@ struct neo_uart_struct { /* 17158 Extended IIR's */ #define UART_17158_IIR_RDI_TIMEOUT 0x0C/* Receiver data TIMEOUT */ #define UART_17158_IIR_XONXOFF 0x10/* Received an XON/XOFF char */ -#define UART_17158_IIR_HWFLOW_STATE_CHANGE 0x20/* CTS/DSR or RTS/DTR state change */ +#define UART_17158_IIR_HWFLOW_STATE_CHANGE 0x20/* CTS/DSR or RTS/DTR state */ + /* change */ #define UART_17158_IIR_FIFO_ENABLED0xC0/* 16550 FIFOs are Enabled */ /* @@ -119,8 +121,10 @@ struct neo_uart_struct { #define UART_17158_RXRDY_TIMEOUT 0x2 /* RX Ready Timeout */ #define UART_17158_TXRDY 0x3 /* TX Ready */ #define UART_17158_MSR 0x4 /* Modem State Change */ -#define UART_17158_TX_AND_FIFO_CLR 0x40/* Transmitter Holding Reg Empty */ -#define UART_17158_RX_FIFO_DATA_ERROR 0x80/* UART detected an RX FIFO Data error */ +#define UART_17158_TX_AND_FIFO_CLR 0x40/* Transmitter Holding Reg */ + /* Empty */ +#define UART_17158_RX_FIFO_DATA_ERROR 0x80/* UART detected an RX FIFO */ + /* Data error */ /* * These are the EXTENDED definitions for the 17C158's Interrupt @@ -132,8 +136,10 @@ struct neo_uart_struct { #define UART_17158_EFR_RTSDTR 0x40/* Auto RTS/DTR Flow Control Enable */ #define UART_17158_EFR_CTSDSR 0x80/* Auto CTS/DSR Flow COntrol Enable */ -#define UART_17158_XOFF_DETECT 0x1 /* Indicates whether chip saw an incoming XOFF char */ -#define UART_17158_XON_DETECT 0x2 /* Indicates whether chip saw an incoming XON char */ +#define UART_17158_XOFF_DETECT 0x1 /* Indicates whether chip saw an */ + /* incoming XOFF char */ +#define UART_17158_XON_DETECT 0x2 /* Indicates whether chip saw an */ + /* incoming XON char */ #define UART_17158_IER_RSVD1 0x10/* Reserved by Exar */ #define UART_17158_IER_XOFF0x20/* Xoff Interrupt Enable */ -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH] Staging:dgnc:dgnc_neo: fixed 80 character line limit coding style issue
May be it is not looking better than yours but it removed 6 warning of the file which is shown by running "perl scripts/checkpatch.pl -f drivers/staging/dgnc/* | less" commend On Thu, Oct 6, 2016 at 10:51 AM, Greg KH wrote: > On Wed, Oct 05, 2016 at 02:53:58PM -0700, Nadim Almas wrote: >> Fixed coding style issue >> >> Signed-off-by: Nadim Almas >> --- >> drivers/staging/dgnc/dgnc_neo.h | 18 -- >> 1 file changed, 12 insertions(+), 6 deletions(-) >> >> diff --git a/drivers/staging/dgnc/dgnc_neo.h >> b/drivers/staging/dgnc/dgnc_neo.h >> index abddd48..65994e3 100644 >> --- a/drivers/staging/dgnc/dgnc_neo.h >> +++ b/drivers/staging/dgnc/dgnc_neo.h >> @@ -30,7 +30,8 @@ >> struct neo_uart_struct { >> u8 txrx;/* WR RHR/THR - Holding Reg */ >> u8 ier; /* WR IER - Interrupt Enable Reg */ >> - u8 isr_fcr; /* WR ISR/FCR - Interrupt Status Reg/Fifo >> Control Reg */ >> + u8 isr_fcr; /* WR ISR/FCR - Interrupt Status Reg/Fifo Control */ >> + /*Reg >> */ > > Does that really look better now than it did before? > > I don't think so :( > > sorry, > > greg k-h ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH] Staging:dgnc:dgnc_neo: fixed 80 character line limit coding style issue
May be it is not looking better than it did before but it removed 6 warning of the file which is shown by running "perl scripts/checkpatch.pl -f drivers/staging/dgnc/* | less" commend than why it is not acceptable On Thu, Oct 6, 2016 at 1:52 PM, Nadim Almas wrote: > May be it is not looking better than yours but it removed 6 warning of > the file which is shown by running "perl scripts/checkpatch.pl -f > drivers/staging/dgnc/* | less" commend > > On Thu, Oct 6, 2016 at 10:51 AM, Greg KH wrote: >> On Wed, Oct 05, 2016 at 02:53:58PM -0700, Nadim Almas wrote: >>> Fixed coding style issue >>> >>> Signed-off-by: Nadim Almas >>> --- >>> drivers/staging/dgnc/dgnc_neo.h | 18 -- >>> 1 file changed, 12 insertions(+), 6 deletions(-) >>> >>> diff --git a/drivers/staging/dgnc/dgnc_neo.h >>> b/drivers/staging/dgnc/dgnc_neo.h >>> index abddd48..65994e3 100644 >>> --- a/drivers/staging/dgnc/dgnc_neo.h >>> +++ b/drivers/staging/dgnc/dgnc_neo.h >>> @@ -30,7 +30,8 @@ >>> struct neo_uart_struct { >>> u8 txrx;/* WR RHR/THR - Holding Reg */ >>> u8 ier; /* WR IER - Interrupt Enable Reg */ >>> - u8 isr_fcr; /* WR ISR/FCR - Interrupt Status Reg/Fifo >>> Control Reg */ >>> + u8 isr_fcr; /* WR ISR/FCR - Interrupt Status Reg/Fifo Control */ >>> + /*Reg >>> */ >> >> Does that really look better now than it did before? >> >> I don't think so :( >> >> sorry, >> >> greg k-h ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:fbtft/fb_s6d02a1.c: fixed 80 character line limit coding
style issue Fixed coding style issue Signed-off-by: Nadim Almas --- drivers/staging/fbtft/fb_s6d02a1.c | 30 -- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/drivers/staging/fbtft/fb_s6d02a1.c b/drivers/staging/fbtft/fb_s6d02a1.c index 774b0ff..bc0c48f 100644 --- a/drivers/staging/fbtft/fb_s6d02a1.c +++ b/drivers/staging/fbtft/fb_s6d02a1.c @@ -30,20 +30,27 @@ static int default_init_sequence[] = { -1, 0xfc, 0x5a, 0x5a, - -1, 0xfa, 0x02, 0x1f, 0x00, 0x10, 0x22, 0x30, 0x38, 0x3A, 0x3A, 0x3A, 0x3A, 0x3A, 0x3d, 0x02, 0x01, + -1, 0xfa, 0x02, 0x1f, 0x00, 0x10, 0x22, 0x30, 0x38, 0x3A, 0x3A, 0x3A, + 0x3A, 0x3A, 0x3d, 0x02, 0x01, - -1, 0xfb, 0x21, 0x00, 0x02, 0x04, 0x07, 0x0a, 0x0b, 0x0c, 0x0c, 0x16, 0x1e, 0x30, 0x3f, 0x01, 0x02, + -1, 0xfb, 0x21, 0x00, 0x02, 0x04, 0x07, 0x0a, 0x0b, 0x0c, 0x0c, 0x16, + 0x1e, 0x30, 0x3f, 0x01, 0x02, /* power setting sequence */ - -1, 0xfd, 0x00, 0x00, 0x00, 0x17, 0x10, 0x00, 0x01, 0x01, 0x00, 0x1f, 0x1f, + -1, 0xfd, 0x00, 0x00, 0x00, 0x17, 0x10, 0x00, 0x01, 0x01, 0x00, 0x1f, + 0x1f, - -1, 0xf4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x3f, 0x07, 0x00, 0x3C, 0x36, 0x00, 0x3C, 0x36, 0x00, + -1, 0xf4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x3f, 0x07, 0x00, 0x3C, + 0x36, 0x00, 0x3C, 0x36, 0x00, - -1, 0xf5, 0x00, 0x70, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6d, 0x66, 0x06, + -1, 0xf5, 0x00, 0x70, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x6d, 0x66, 0x06, - -1, 0xf6, 0x02, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x02, 0x00, 0x06, 0x01, 0x00, + -1, 0xf6, 0x02, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x02, 0x00, 0x06, 0x01, + 0x00, - -1, 0xf2, 0x00, 0x01, 0x03, 0x08, 0x08, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x04, 0x08, 0x08, + -1, 0xf2, 0x00, 0x01, 0x03, 0x08, 0x08, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x01, 0x00, 0x00, 0x04, 0x08, 0x08, -1, 0xf8, 0x11, @@ -63,7 +70,8 @@ static int default_init_sequence[] = { -1, 0xf3, 0x00, 0x0f, -2, 50, - -1, 0xf4, 0x00, 0x04, 0x00, 0x00, 0x00, 0x3f, 0x3f, 0x07, 0x00, 0x3C, 0x36, 0x00, 0x3C, 0x36, 0x00, + -1, 0xf4, 0x00, 0x04, 0x00, 0x00, 0x00, 0x3f, 0x3f, 0x07, + 0x00, 0x3C, 0x36, 0x00, 0x3C, 0x36, 0x00, -2, 50, -1, 0xf3, 0x00, 0x1f, @@ -74,9 +82,11 @@ static int default_init_sequence[] = { -1, 0xf3, 0x00, 0xff, -2, 50, - -1, 0xfd, 0x00, 0x00, 0x00, 0x17, 0x10, 0x00, 0x00, 0x01, 0x00, 0x16, 0x16, + -1, 0xfd, 0x00, 0x00, 0x00, 0x17, 0x10, 0x00, 0x00, 0x01, + 0x00, 0x16, 0x16, - -1, 0xf4, 0x00, 0x09, 0x00, 0x00, 0x00, 0x3f, 0x3f, 0x07, 0x00, 0x3C, 0x36, 0x00, 0x3C, 0x36, 0x00, + -1, 0xf4, 0x00, 0x09, 0x00, 0x00, 0x00, 0x3f, 0x3f, 0x07, 0x00, 0x3C, + 0x36, 0x00, 0x3C, 0x36, 0x00, /* initializing sequence */ -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH] Staging:fbtft/fb_s6d02a1.c: fixed 80 character line limit coding
why its seems worst to you i am just removing "80 character line limit coding style" for the last 3 months I am trying to submit my first patch but patch is not accepted by you by giving reason i can't able to understand please help me On Fri, Oct 7, 2016 at 10:37 PM, Greg KH wrote: > On Fri, Oct 07, 2016 at 08:43:02AM -0700, Nadim Almas wrote: >> style issue >> >> Fixed coding style issue > > This does not seem like valid sentances that mean much to me. Do they > to you? > >> >> Signed-off-by: Nadim Almas >> --- >> drivers/staging/fbtft/fb_s6d02a1.c | 30 -- >> 1 file changed, 20 insertions(+), 10 deletions(-) >> >> diff --git a/drivers/staging/fbtft/fb_s6d02a1.c >> b/drivers/staging/fbtft/fb_s6d02a1.c >> index 774b0ff..bc0c48f 100644 >> --- a/drivers/staging/fbtft/fb_s6d02a1.c >> +++ b/drivers/staging/fbtft/fb_s6d02a1.c >> @@ -30,20 +30,27 @@ static int default_init_sequence[] = { >> >> -1, 0xfc, 0x5a, 0x5a, >> >> - -1, 0xfa, 0x02, 0x1f, 0x00, 0x10, 0x22, 0x30, 0x38, 0x3A, 0x3A, 0x3A, >> 0x3A, 0x3A, 0x3d, 0x02, 0x01, >> + -1, 0xfa, 0x02, 0x1f, 0x00, 0x10, 0x22, 0x30, 0x38, 0x3A, 0x3A, 0x3A, >> + 0x3A, 0x3A, 0x3d, 0x02, 0x01, > > This looks worse to me now, remember, checkpatch.pl is a "hint", not a > hard-and-fast-rule. Use it wisely. > > greg k-h ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:greybus:arche-apb-ctrl: fix trailing */ Block comments and 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- drivers/staging/greybus/arche-apb-ctrl.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/drivers/staging/greybus/arche-apb-ctrl.c b/drivers/staging/greybus/arche-apb-ctrl.c index 70323aa..eeba912 100644 --- a/drivers/staging/greybus/arche-apb-ctrl.c +++ b/drivers/staging/greybus/arche-apb-ctrl.c @@ -168,7 +168,10 @@ static int standby_boot_seq(struct platform_device *pdev) if (apb->init_disabled) return 0; - /* Even if it is in OFF state, then we do not want to change the state */ + /* +*Even if it is in OFF state, +*then we do not want to change the state +*/ if (apb->state == ARCHE_PLATFORM_STATE_STANDBY || apb->state == ARCHE_PLATFORM_STATE_OFF) return 0; @@ -183,7 +186,7 @@ static int standby_boot_seq(struct platform_device *pdev) * Pasted from WDM spec, * - A falling edge on POWEROFF_L is detected (a) * - WDM enters standby mode, but no output signals are changed -* */ +*/ /* TODO: POWEROFF_L is input to WDM module */ apb->state = ARCHE_PLATFORM_STATE_STANDBY; @@ -286,7 +289,8 @@ static ssize_t state_store(struct device *dev, return count; /* First we want to make sure we power off everything -* and then enter FW flashing state */ +* and then enter FW flashing state +*/ poweroff_seq(pdev); ret = fw_flashing_seq(pdev); } else { -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH v2 1/2] Staging:greybus:arche-apb-ctrl: fix trailing */ Block comments and 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- Changes in v2: - Used space after leading * in block comments. drivers/staging/greybus/arche-apb-ctrl.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/drivers/staging/greybus/arche-apb-ctrl.c b/drivers/staging/greybus/arche-apb-ctrl.c index 70323aa..eeba912 100644 --- a/drivers/staging/greybus/arche-apb-ctrl.c +++ b/drivers/staging/greybus/arche-apb-ctrl.c @@ -168,7 +168,10 @@ static int standby_boot_seq(struct platform_device *pdev) if (apb->init_disabled) return 0; - /* Even if it is in OFF state, then we do not want to change the state */ + /* +* Even if it is in OFF state, +* then we do not want to change the state +*/ if (apb->state == ARCHE_PLATFORM_STATE_STANDBY || apb->state == ARCHE_PLATFORM_STATE_OFF) return 0; @@ -183,7 +186,7 @@ static int standby_boot_seq(struct platform_device *pdev) * Pasted from WDM spec, * - A falling edge on POWEROFF_L is detected (a) * - WDM enters standby mode, but no output signals are changed -* */ +*/ /* TODO: POWEROFF_L is input to WDM module */ apb->state = ARCHE_PLATFORM_STATE_STANDBY; @@ -286,7 +289,8 @@ static ssize_t state_store(struct device *dev, return count; /* First we want to make sure we power off everything -* and then enter FW flashing state */ +* and then enter FW flashing state +*/ poweroff_seq(pdev); ret = fw_flashing_seq(pdev); } else { -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:greybus:arche-apb-ctrl: fixed some coding style issue
fixed trailing */ Block comments and 80 character line limit coding style issue Signed-off-by: Nadim Almas --- drivers/staging/greybus/arche-apb-ctrl.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/drivers/staging/greybus/arche-apb-ctrl.c b/drivers/staging/greybus/arche-apb-ctrl.c index 70323aa..eeba912 100644 --- a/drivers/staging/greybus/arche-apb-ctrl.c +++ b/drivers/staging/greybus/arche-apb-ctrl.c @@ -168,7 +168,10 @@ static int standby_boot_seq(struct platform_device *pdev) if (apb->init_disabled) return 0; - /* Even if it is in OFF state, then we do not want to change the state */ + /* +* Even if it is in OFF state, +* then we do not want to change the state +*/ if (apb->state == ARCHE_PLATFORM_STATE_STANDBY || apb->state == ARCHE_PLATFORM_STATE_OFF) return 0; @@ -183,7 +186,7 @@ static int standby_boot_seq(struct platform_device *pdev) * Pasted from WDM spec, * - A falling edge on POWEROFF_L is detected (a) * - WDM enters standby mode, but no output signals are changed -* */ +*/ /* TODO: POWEROFF_L is input to WDM module */ apb->state = ARCHE_PLATFORM_STATE_STANDBY; @@ -286,7 +289,8 @@ static ssize_t state_store(struct device *dev, return count; /* First we want to make sure we power off everything -* and then enter FW flashing state */ +* and then enter FW flashing state +*/ poweroff_seq(pdev); ret = fw_flashing_seq(pdev); } else { -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH] Staging:greybus:arche-apb-ctrl: fixed some coding style issue
>Someone else already sent this same patch in before you, sorry But sir how can i come to know that Someone else already sent particular patch before sending that particular patch On Wed, Oct 12, 2016 at 6:55 PM, Greg KH wrote: > On Tue, Oct 11, 2016 at 12:49:54PM -0700, Nadim Almas wrote: >> fixed trailing */ Block comments and 80 character line limit coding style >> issue >> >> Signed-off-by: Nadim Almas >> --- > > Someone else already sent this same patch in before you, sorry :( ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:ks7010:eap_packet: fixed 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- drivers/staging/ks7010/eap_packet.h | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/staging/ks7010/eap_packet.h b/drivers/staging/ks7010/eap_packet.h index df7f760..90432ff 100644 --- a/drivers/staging/ks7010/eap_packet.h +++ b/drivers/staging/ks7010/eap_packet.h @@ -58,11 +58,13 @@ struct ieee802_1x_eapol_key { * encrypt the Key field; 64-bit NTP timestamp MAY be used here */ unsigned char replay_counter[IEEE8021X_REPLAY_COUNTER_LEN]; - unsigned char key_iv[IEEE8021X_KEY_IV_LEN]; /* cryptographically random number */ + unsigned char key_iv[IEEE8021X_KEY_IV_LEN]; + /* cryptographically random number */ unsigned char key_index;/* * key flag in the most significant bit: * 0 = broadcast (default key), -* 1 = unicast (key mapping key); key index is in the +* 1 = unicast (key mapping key); key +* index is in the * 7 least significant bits */ /* -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH v2] Staging:ks7010:eap_packet: fixed 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- Changes in v2: -Comment is taken from below line. drivers/staging/ks7010/eap_packet.h | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/staging/ks7010/eap_packet.h b/drivers/staging/ks7010/eap_packet.h index df7f760..90432ff 100644 --- a/drivers/staging/ks7010/eap_packet.h +++ b/drivers/staging/ks7010/eap_packet.h @@ -58,11 +58,13 @@ struct ieee802_1x_eapol_key { * encrypt the Key field; 64-bit NTP timestamp MAY be used here */ unsigned char replay_counter[IEEE8021X_REPLAY_COUNTER_LEN]; - unsigned char key_iv[IEEE8021X_KEY_IV_LEN]; /* cryptographically random number */ + unsigned char key_iv[IEEE8021X_KEY_IV_LEN]; + /* cryptographically random number */ unsigned char key_index;/* * key flag in the most significant bit: * 0 = broadcast (default key), -* 1 = unicast (key mapping key); key index is in the +* 1 = unicast (key mapping key); key +* index is in the * 7 least significant bits */ /* -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:wlan-ng:hfa384x: fixed 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- drivers/staging/wlan-ng/hfa384x.h | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/staging/wlan-ng/hfa384x.h b/drivers/staging/wlan-ng/hfa384x.h index 6337b1d..cca2652 100644 --- a/drivers/staging/wlan-ng/hfa384x.h +++ b/drivers/staging/wlan-ng/hfa384x.h @@ -1349,7 +1349,9 @@ struct hfa384x { * interface */ - struct hfa384x_caplevel cap_act_sta_mfi; /* sta f/w to modem interface */ + struct hfa384x_caplevel cap_act_sta_mfi; /* + * sta f/w to modem interface + */ struct hfa384x_caplevel cap_act_ap_cfi; /* * ap f/w to controller @@ -1371,7 +1373,9 @@ struct hfa384x { struct hfa384x_inf_frame *scanresults; - struct prism2sta_authlist authlist; /* Authenticated station list. */ + struct prism2sta_authlist authlist; /* +* Authenticated station list +*/ unsigned int accessmode;/* Access mode. */ struct prism2sta_accesslist allow; /* Allowed station list. */ struct prism2sta_accesslist deny; /* Denied station list. */ -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:wilc1000:host_interface: fixed 80 character line limit coding style issue
Fixed coding style issue Signed-off-by: Nadim Almas --- drivers/staging/wilc1000/host_interface.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c index 0c5dea7..6e6540f 100644 --- a/drivers/staging/wilc1000/host_interface.c +++ b/drivers/staging/wilc1000/host_interface.c @@ -497,10 +497,12 @@ static void handle_cfg_param(struct wilc_vif *vif, if (cfg_param_attr->flag & POWER_MANAGEMENT) { if (cfg_param_attr->power_mgmt_mode < 5) { wid_list[i].id = WID_POWER_MANAGEMENT; - wid_list[i].val = (s8 *)&cfg_param_attr->power_mgmt_mode; + wid_list[i].val = (s8 *)&cfg_param_attr-> + power_mgmt_mode; wid_list[i].type = WID_CHAR; wid_list[i].size = sizeof(char); - hif_drv->cfg_values.power_mgmt_mode = (u8)cfg_param_attr->power_mgmt_mode; + hif_drv->cfg_values.power_mgmt_mode = + (u8)cfg_param_attr->power_mgmt_mode; } else { netdev_err(vif->ndev, "Invalid power mode\n"); goto unlock; -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:vt6656:main_usb: fix Block comments should align the * on each line
Block comments should align the * on each line as reported by checkpatch.pl Signed-off-by: Nadim Almas --- drivers/staging/vt6656/main_usb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging/vt6656/main_usb.c index fe84da3..50d02d9 100644 --- a/drivers/staging/vt6656/main_usb.c +++ b/drivers/staging/vt6656/main_usb.c @@ -326,9 +326,9 @@ static int vnt_init_registers(struct vnt_private *priv) priv->current_net_addr); /* - * set BB and packet type at the same time - * set Short Slot Time, xIFS, and RSPINF - */ +* set BB and packet type at the same time +* set Short Slot Time, xIFS, and RSPINF +*/ if (priv->bb_type == BB_TYPE_11A) priv->short_slot_time = true; else -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:board:board: fix implicit declaration of function
implicit declaration of function ‘of_find_all_nodes’ reported by sparse Signed-off-by: Nadim Almas --- drivers/staging/board/board.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/board/board.c b/drivers/staging/board/board.c index 86dc411..6978db5 100644 --- a/drivers/staging/board/board.c +++ b/drivers/staging/board/board.c @@ -22,6 +22,7 @@ #include "board.h" +struct device_node *of_find_all_nodes(struct device_node *); static struct device_node *irqc_node __initdata; static unsigned int irqc_base __initdata; -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:board:board: fix Block comments should align the * on each line
Block comments should align the * on each line as reported by checkpatch.pl Signed-off-by: Nadim Almas --- drivers/staging/dgnc/dgnc_tty.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/staging/dgnc/dgnc_tty.c b/drivers/staging/dgnc/dgnc_tty.c index cf8aefd..94c4840 100644 --- a/drivers/staging/dgnc/dgnc_tty.c +++ b/drivers/staging/dgnc/dgnc_tty.c @@ -2707,7 +2707,7 @@ static int dgnc_tty_ioctl(struct tty_struct *tty, unsigned int cmd, uint loopback = 0; /* Let go of locks when accessing user space, * could sleep - */ +*/ spin_unlock_irqrestore(&ch->ch_lock, flags); rc = get_user(loopback, (unsigned int __user *)arg); if (rc) -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:fbtft: Replace decimal permissions with 4 digit octal
ERROR: Use 4 digit octal (0777) not decimal permissions This error was detected by checkpatch.pl Signed-off-by: Nadim Almas --- drivers/staging/fbtft/fb_ili9325.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/staging/fbtft/fb_ili9325.c b/drivers/staging/fbtft/fb_ili9325.c index 4ab4479..19e33ba 100644 --- a/drivers/staging/fbtft/fb_ili9325.c +++ b/drivers/staging/fbtft/fb_ili9325.c @@ -33,23 +33,23 @@ "04 16 2 7 6 3 2 1 7 7" static unsigned int bt = 6; /* VGL=Vci*4 , VGH=Vci*4 */ -module_param(bt, uint, 0); +module_param(bt, uint, ); MODULE_PARM_DESC(bt, "Sets the factor used in the step-up circuits"); static unsigned int vc = 0x03; /* Vci1=Vci*0.80 */ -module_param(vc, uint, 0); +module_param(vc, uint, ); MODULE_PARM_DESC(vc, "Sets the ratio factor of Vci to generate the reference voltages Vci1"); static unsigned int vrh = 0x0d; /* VREG1OUT=Vci*1.85 */ -module_param(vrh, uint, 0); +module_param(vrh, uint, ); MODULE_PARM_DESC(vrh, "Set the amplifying rate (1.6 ~ 1.9) of Vci applied to output the VREG1OUT"); static unsigned int vdv = 0x12; /* VCOMH amplitude=VREG1OUT*0.98 */ -module_param(vdv, uint, 0); +module_param(vdv, uint, ); MODULE_PARM_DESC(vdv, "Select the factor of VREG1OUT to set the amplitude of Vcom"); static unsigned int vcm = 0x0a; /* VCOMH=VREG1OUT*0.735 */ -module_param(vcm, uint, 0); +module_param(vcm, uint, ); MODULE_PARM_DESC(vcm, "Set the internal VcomH voltage"); /* -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH v2] Staging:dgnc:dgnc_tty: fix Block comments should align the * on each line
Block comments should align the * on each line as reported by checkpatch.pl Signed-off-by: Nadim Almas --- Changes in v2: - Made subject better drivers/staging/dgnc/dgnc_tty.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/staging/dgnc/dgnc_tty.c b/drivers/staging/dgnc/dgnc_tty.c index cf8aefd..94c4840 100644 --- a/drivers/staging/dgnc/dgnc_tty.c +++ b/drivers/staging/dgnc/dgnc_tty.c @@ -2707,7 +2707,7 @@ static int dgnc_tty_ioctl(struct tty_struct *tty, unsigned int cmd, uint loopback = 0; /* Let go of locks when accessing user space, * could sleep - */ +*/ spin_unlock_irqrestore(&ch->ch_lock, flags); rc = get_user(loopback, (unsigned int __user *)arg); if (rc) -- 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging:emxx_udc:emxx_udc: Compression of lines for immediate return
This patch compresses two lines into a single line if immediate return statement is found. Remove variable data as it is no longer needed. It is done using script Coccinelle. And coccinelle uses the following semantic patch for this compression function @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Nadim Almas --- drivers/staging/emxx_udc/emxx_udc.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/drivers/staging/emxx_udc/emxx_udc.c b/drivers/staging/emxx_udc/emxx_udc.c index abe2aaf..31f4206 100644 --- a/drivers/staging/emxx_udc/emxx_udc.c +++ b/drivers/staging/emxx_udc/emxx_udc.c @@ -2979,9 +2979,7 @@ static int nbu2ss_gad_get_frame(struct usb_gadget *pgadget) if (data == 0) return -EINVAL; - data = _nbu2ss_readl(&udc->p_regs->USB_ADDRESS) & FRAME; - - return data; + return _nbu2ss_readl(&udc->p_regs->USB_ADDRESS) & FRAME; } 2.7.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging: used dma_map_single in place of pci_map_single
pci_map_single is unneeded and can be replaced with dma_map_single to avoid inconcitent api usage. The Coccinelle semantic patch used to make this change is as follows: @@ expression E1,E2,E3; @@ - pci_map_single(E1, + dma_map_single(&E1->dev, E2, E3, ( - PCI_DMA_BIDIRECTIONAL + DMA_BIDIRCTIONAL | - PCI_DMA_TODEVICE + DMA_TO_DEVICE | - PCI_DMA_FROMDEVICE + DMA_FROM_DEVICE | - PCI_DMA_NONE + DMA_NONE_DEVICE ) ) Signed-off-by: Nadim Almas --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 10 ++ drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 12 ++-- drivers/staging/slicoss/slicoss.c | 12 ++-- 3 files changed, 18 insertions(+), 16 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c index 8d6bca6..a3c8c3a 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c @@ -1184,8 +1184,9 @@ void rtl92e_fill_tx_desc(struct net_device *dev, struct tx_desc *pdesc, struct cb_desc *cb_desc, struct sk_buff *skb) { struct r8192_priv *priv = rtllib_priv(dev); - dma_addr_t mapping = pci_map_single(priv->pdev, skb->data, skb->len, -PCI_DMA_TODEVICE); + dma_addr_t mapping = dma_map_single(&priv->pdev->dev, skb->data, + skb->len, + DMA_TO_DEVICE); struct tx_fwinfo_8190pci *pTxFwInfo; pTxFwInfo = (struct tx_fwinfo_8190pci *)skb->data; @@ -1292,8 +1293,9 @@ void rtl92e_fill_tx_cmd_desc(struct net_device *dev, struct tx_desc_cmd *entry, struct cb_desc *cb_desc, struct sk_buff *skb) { struct r8192_priv *priv = rtllib_priv(dev); - dma_addr_t mapping = pci_map_single(priv->pdev, skb->data, skb->len, -PCI_DMA_TODEVICE); + dma_addr_t mapping = dma_map_single(&priv->pdev->dev, skb->data, + skb->len, + DMA_TO_DEVICE); if (pci_dma_mapping_error(priv->pdev, mapping)) netdev_err(dev, "%s(): DMA Mapping error\n", __func__); diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c index f985d88..ddd6523 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c @@ -1826,10 +1826,10 @@ static short _rtl92e_alloc_rx_ring(struct net_device *dev) skb->dev = dev; priv->rx_buf[rx_queue_idx][i] = skb; mapping = (dma_addr_t *)skb->cb; - *mapping = pci_map_single(priv->pdev, + *mapping = dma_map_single(&priv->pdev->dev, skb_tail_pointer_rsl(skb), priv->rxbuffersize, - PCI_DMA_FROMDEVICE); + DMA_FROM_DEVICE); if (pci_dma_mapping_error(priv->pdev, *mapping)) { dev_kfree_skb_any(skb); return -1; @@ -2104,10 +2104,10 @@ static void _rtl92e_rx_normal(struct net_device *dev) priv->rx_buf[rx_queue_idx][priv->rx_idx[rx_queue_idx]] = skb; - *((dma_addr_t *) skb->cb) = pci_map_single(priv->pdev, - skb_tail_pointer_rsl(skb), - priv->rxbuffersize, - PCI_DMA_FROMDEVICE); + *((dma_addr_t *) skb->cb) = dma_map_single(&priv->pdev->dev, + skb_tail_pointer_rsl(skb), + priv->rxbuffersize, + DMA_FROM_DEVICE); if (pci_dma_mapping_error(priv->pdev, *((dma_addr_t *)skb->cb))) { dev_kfree_skb_any(skb); diff --git a/drivers/staging/slicoss/slicoss.c b/drivers/staging/slicoss/slicoss.c index 062307a..2d76bfd 100644 --- a/drivers/staging/slicoss/slicoss.c +++ b/drivers/staging/slicoss/slicoss.c @@ -1452,10 +1452,10 @@ static int slic_rcvqueue_fill(struct adapter *adapter) skb = alloc_skb(SLIC_RCVQ_RCVBUFSIZE, GFP_ATOMIC); if (skb) { paddr = (void *)(unsigned long) - pci_map_single(adapter->pcidev, +