Replace the explicit "if (val != NULL)" with if (val).
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/rtl8712/rtl8712_xmit.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/rtl8712/rtl8712_xmit.c
b/drivers/staging/rtl8712/rtl8
On Mon, May 23, 2016 at 04:26:37PM -0400, Boris Ostrovsky wrote:
> On 05/21/2016 09:09 AM, Muhammad Falak R Wani wrote:
> > Replace explicit computation of vma page count by a call to
> > vma_pages()
> >
>
> Can you combine all three patches into a single one?
>
Replace explicit computation of vma page count by a call to
vma_pages().
Signed-off-by: Muhammad Falak R Wani
---
drivers/xen/gntalloc.c | 2 +-
drivers/xen/gntdev.c | 2 +-
drivers/xen/privcmd.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/xen/gntalloc.c b
Replace explicit computation of vma page count by a call to
vma_pages().
Also, include
Signed-off-by: Muhammad Falak R Wani
---
drivers/dma-buf/dma-buf.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c
index
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/base/dma-coherent.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/base/dma-coherent.c b/drivers/base/dma-coherent.c
index bdf28f7..db122a0
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/dma-buf/dma-buf.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c
index 4a2c07e..b0317ec
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/base/dma-mapping.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/base/dma-mapping.c b/drivers/base/dma-mapping.c
index d799662..1d82f7e 100644
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/gma500/framebuffer.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/gma500/framebuffer.c
b/drivers/gpu/drm/gma500/framebuffer.c
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/hsi/clients/cmt_speech.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hsi/clients/cmt_speech.c b/drivers/hsi/clients/cmt_speech.c
index 95638df
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/misc/mic/scif/scif_mmap.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/misc/mic/scif/scif_mmap.c
b/drivers/misc/mic/scif/scif_mmap.c
index
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/xen/privcmd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/xen/privcmd.c b/drivers/xen/privcmd.c
index df2e6f7..702040f 100644
--- a/drivers
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/xen/gntdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c
index 6793957..bb95212 100644
--- a/drivers/xen
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani
---
drivers/xen/gntalloc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/xen/gntalloc.c b/drivers/xen/gntalloc.c
index 4547a91..7a47c4c 100644
--- a/drivers
Use memdup_user_nul to duplicate a memory region from user-space
to kernel-space and terminate with a NULL, instead of open coding
using kmalloc + copy_from_user and explicitly NULL terminating.
Signed-off-by: Muhammad Falak R Wani
---
drivers/s390/char/keyboard.c | 11 +++
1 file
On Fri, May 20, 2016 at 03:03:25PM +0200, Heiko Carstens wrote:
> On Fri, May 20, 2016 at 05:52:16PM +0530, Muhammad Falak R Wani wrote:
> > Use memdup_user to duplicate a memory region from user-space to
> > kernel-space, instead of open coding using kmalloc & copy_from_user.
Use memdup_user to duplicate a memory region from user-space to
kernel-space, instead of open coding using kmalloc & copy_from_user.
Signed-off-by: Muhammad Falak R Wani
---
drivers/tty/vt/keyboard.c | 14 --
1 file changed, 4 insertions(+), 10 deletions(-)
diff --git a/drivers
Use memdup_user to duplicate a memory region from user-space to
kernel-space, instead of open coding using kmalloc & copy_from_user.
Signed-off-by: Muhammad Falak R Wani
---
drivers/s390/char/keyboard.c | 10 +++---
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/drivers/
Use memdup_user to duplicate a memory region from user-space to
kernel-space, instead of open coding using kmalloc & copy_from_user.
Signed-off-by: Muhammad Falak R Wani
---
drivers/ptp/ptp_chardev.c | 11 +++
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/drivers
Use memdup_user to duplicate a memory region from user-space to
kernel-space, instead of open coding using kmalloc & copy_from_user.
Signed-off-by: Muhammad Falak R Wani
---
drivers/net/wan/cosa.c | 11 +++
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/drivers/net
Use memdup_user to duplicate a memory region from user-space to
kernel-space, instead of open coding using kmalloc & copy_from_user.
Signed-off-by: Muhammad Falak R Wani
---
drivers/misc/vmw_vmci/vmci_host.c | 14 --
1 file changed, 4 insertions(+), 10 deletions(-)
diff --g
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/scsi/aacraid/commctrl.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/scsi/aic7xxx/aic7xxx_core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/scsi/aic7xxx/aic79xx_core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/usb/serial/cp210x.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c | 3 +--
1 file changed, 1
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/net/usb/ch9200.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/net/ethernet/toshiba/ps3_gelic_wireless.c | 4 ++--
1 file changed, 2 insertions(+), 2
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/net/ethernet/cavium/liquidio/octeon_device.c | 4 +---
1 file changed, 1 insertion
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/message/fusion/mptbase.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/memstick/core/mspro_block.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/vmwgfx/vmwgfx_mob.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions
On Thu, May 19, 2016 at 01:18:10PM +0200, Christian König wrote:
> Am 19.05.2016 um 13:11 schrieb Muhammad Falak R Wani:
> >Use kmemdup when some other buffer is immediately copied into allocated
> >region. It replaces call to allocation followed by memcpy, by a single
>
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 6 +++---
1 file changed, 3 insertions
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 6 +++---
1 file changed, 3 insertions
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 6 +++---
1 file changed, 3 insertions
Use kmemdup when some other buffer is immediately copied into allocated
region. It replaces call to allocation followed by memcpy, by a single
call to kmemdup.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions
Remove unused variable 'ret', and directly return 0.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/amdgpu/iceland_ih.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/iceland_ih.c
b/drivers/gpu/drm/amd/amdgpu/iceland_
Remove unused variable 'ret', and directly return 0.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/amdgpu/tonga_ih.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/tonga_ih.c
b/drivers/gpu/drm/amd/amdgpu/tonga_ih.c
ind
Remove unused variable 'ret' from functions where it
was not used anyway, and directly return 0.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/amdgpu/cz_dpm.c | 13 -
1 file changed, 4 insertions(+), 9 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/c
Remove unused variable 'ret', and directly return 0.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/amdgpu/cz_ih.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/cz_ih.c
b/drivers/gpu/drm/amd/amdgpu/cz_ih.c
index 23bd91
Remove unused variable 'ret', and directly return 0.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/amdgpu/cik_ih.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/cik_ih.c
b/drivers/gpu/drm/amd/amdgpu/cik_ih.c
ind
On Mon, May 16, 2016 at 04:53:50PM +0100, Eric Engestrom wrote:
> On Fri, May 13, 2016 at 11:06:40PM +0530, Muhammad Falak R Wani wrote:
> > It is preferred to use ARRAY_SIZE() for size calculation, instead
> > using sizeof(array)/sizeof(*array). It makes the code more readable.
On Mon, May 16, 2016 at 07:27:25AM -0600, Shuah Khan wrote:
> On 05/13/2016 06:05 AM, Muhammad Falak R Wani wrote:
> > Add the macro _GNU_SOURCE, so that compilation does not terminate.
>
> What error are you seeing? Could you please send the compilation
> error log.
>
s a more efficient way to update the expire field of an
active timer (if the timer is inactive it will be activated).
Use setup_timer() and mod_timer() to setup and arm a timer, making the
code compact and aid readablity.
Signed-off-by: Muhammad Falak R Wani
---
net/hsr/hsr_device.c | 11 +++
s a more efficient way to update the expire field of an
active timer (if the timer is inactive it will be activated).
Use setup_timer() and mod_timer() to setup and arm a timer, making the
code compact and aid readablity.
Signed-off-by: Muhammad Falak R Wani
---
sound/oss/waveartist.c | 8 +++-
mer() and mod_timer() to setup and arm a timer, making the
code compact and easier to read.
Signed-off-by: Muhammad Falak R Wani
---
net/netfilter/ipset/ip_set_list_set.c | 7 ++-
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/net/netfilter/ipset/ip_set_list_set.c
b/net/netfil
mer() and mod_timer() to setup and arm a timer, making the
code compact and easier to read.
Signed-off-by: Muhammad Falak R Wani
---
net/netfilter/ipset/ip_set_bitmap_gen.h | 7 ++-
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/net/netfilter/ipset/ip_set_bitmap_gen.h
b/
mer() and mod_timer() to setup and arm a timer, making the
code compact and easier to read.
Signed-off-by: Muhammad Falak R Wani
---
net/netfilter/ipset/ip_set_hash_gen.h | 7 ++-
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/net/netfilter/ipset/ip_set_hash_gen.h
b/net/netfil
It is preferred to use ARRAY_SIZE() for size calculation, instead
using sizeof(array)/sizeof(*array). It makes the code more readable.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/powerplay/smumgr/cz_smumgr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a
On Thu, May 12, 2016 at 12:53:48PM +0300, Jani Nikula wrote:
> On Wed, 11 May 2016, Muhammad Falak R Wani wrote:
> > Use ARRAY_SIZE() for the size calculation of the array. Also move the
> > condition evaulation function out of the for loop.
> > Although, any respectable c-co
Add the macro _GNU_SOURCE, so that compilation does not terminate.
Signed-off-by: Muhammad Falak R Wani
---
tools/testing/selftests/intel_pstate/run.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/testing/selftests/intel_pstate/run.sh
b/tools/testing/selftests
Remove unused vairable, return 0 explicitly.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/nouveau/nouveau_bios.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_bios.c
b/drivers/gpu/drm/nouveau/nouveau_bios.c
index 4dca65a
Remove the unused variable ret, and return 0 explicitly.
Signed-off-by: Muhammad Falak R Wani
---
drivers/crypto/qat/qat_common/adf_ctl_drv.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/crypto/qat/qat_common/adf_ctl_drv.c
b/drivers/crypto/qat/qat_common
needs some hand holding.
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/powerplay/smumgr/cz_smumgr.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/powerplay/smumgr/cz_smumgr.c
b/drivers/gpu/drm/amd/powerplay/smumgr/cz_smumgr.c
index
Use the macro ARRAY_SIZE() to calculate the size of an array, enhancing
readability and compactnes.
Signed-off-by: Muhammad Falak R Wani
---
drivers/block/skd_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/block/skd_main.c b/drivers/block/skd_main.c
index
Use setup_timer() for initializing the timer, instead of structure
assignments.
This is the preferred/standard way.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/lustre/lnet/lnet/net_fault.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/staging/lustre
mer and mod_timer to setup and arm a timer, to make the code
cleaner and easier to read.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/i4l/pcbit/drv.c | 16 +---
1 file changed, 5 insertions(+), 11 deletions(-)
diff --git a/drivers/staging/i4l/pcbit/drv.c b/drivers/staging/
mer and mod_timer to setup and arm a timer, to make the code
cleaner and easier to read.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/i4l/pcbit/edss1.c | 7 ++-
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/i4l/pcbit/edss1.c
b/drivers/staging/i4l/pc
mer and mod_timer to setup and arm a timer, to make the code
cleaner and easier to read.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/i4l/pcbit/layer2.c | 8 +++-
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/i4l/pcbit/layer2.c
b/drivers/staging/
mer and mod_timer to setup and arm a timer, to make the code
cleaner and easier to read.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/i4l/icn/icn.c | 19 +--
1 file changed, 9 insertions(+), 10 deletions(-)
diff --git a/drivers/staging/i4l/icn/icn.c b/drivers/staging/
Commit-ID: 8c5e95548d41a48b1eb2be741107a259251ebd86
Gitweb: http://git.kernel.org/tip/8c5e95548d41a48b1eb2be741107a259251ebd86
Author: Muhammad Falak R Wani
AuthorDate: Thu, 5 May 2016 15:21:19 +0530
Committer: Ingo Molnar
CommitDate: Mon, 9 May 2016 08:39:52 +0200
sched/core: Remove
The function setup_timer combines the initialization of a timer with
the initialization of the timer's function and data fields.
The multiline code for timer initialization is now replaced
with function setup_timer.
Signed-off-by: Muhammad Falak R Wani
---
drivers/watchdog/shwdt.c | 4 +-
The function setup_timer combines the initialization of a timer with
the initialization of the timer's function and data fields.
The multiline code for timer initialization is now replaced
with function setup_timer.
Signed-off-by: Muhammad Falak R Wani
---
drivers/watchdog/cpwd.c | 4 +-
On Thu, May 05, 2016 at 11:31:19AM -0700, Christoph Hellwig wrote:
> On Thu, May 05, 2016 at 11:24:06PM +0530, Muhammad Falak R Wani wrote:
> > It is safe to use RCU_INIT_POINTER() to NULL, instead of
> > rcu_assign_pointer().
> > This results in slightly smaller/faster code
It is safe to use RCU_INIT_POINTER() to NULL, instead of
rcu_assign_pointer().
This results in slightly smaller/faster code.
Signed-off-by: Muhammad Falak R Wani
---
block/partition-generic.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/block/partition-generic.c b
Remove unused variable ret, and directly return 0.
Signed-off-by: Muhammad Falak R Wani
---
kernel/sched/core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 8b489fc..1e4f727 100644
--- a/kernel/sched/core.c
+++ b/kernel
Never use sg++, always use sg = sg_next(sg). Scatterlist entries can
be combined if the memory is contiguous but sg++ won't know about
that. It sure would run on the slower side.
But regardless, sg++ should never be used, only sg_next is safe.
Signed-off-by: Muhammad Falak R Wani
---
c
It is safe to use RCU_INIT_POINTER() to NULL, instead of
rcu_assign_pointer().
This results in slightly smaller/faster code.
The follwoing semantic patch was used:
@@
@@
- rcu_assign_pointer
+ RCU_INIT_POINTER
(..., NULL)
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/nouveau
It is safe to use RCU_INIT_POINTER() to NULL, instead of
rcu_assign_pointer().
This results in slightly smaller/faster code.
The follwoing semantic patch was used:
@@
@@
- rcu_assign_pointer
+ RCU_INIT_POINTER
(..., NULL)
Signed-off-by: Muhammad Falak R Wani
---
drivers/target
It is safe to use RCU_INIT_POINTER() to NULL, instead of
rcu_assign_pointer().
This results in slightly smaller/faster code.
Signed-off-by: Muhammad Falak R Wani
---
drivers/target/target_core_tpg.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/target
It is safe to use RCU_INIT_POINTER() to NULL a pointer, instead of
rcu_assign_pointer().
This results in slightly smaller/faster code.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/rdma/hfi1/init.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging
It is safe to use RCU_INIT_POINTER() to NULL a pointer, instead of
rcu_assign_pointer().
This results in slightly smaller/faster code.
Signed-off-by: Muhammad Falak R Wani
---
drivers/input/input.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/input/input.c b
It is safe to use RCU_INIT_POINTER() to NULL a pointer, instead of
rcu_assign_pointer().
This results in slightly smaller/faster code.
Signed-off-by: Muhammad Falak R Wani
---
drivers/input/evdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/input/evdev.c b
It is always safe to use RCU_INIT_POINTER to NULL a pointer. This
results in slightly smaller/faster code.
The following semantic patch used:
@@
@@
- rcu_assign_pointer
+ RCU_INIT_POINTER
(..., NULL)
Signed-off-by: Muhammad Falak R Wani
---
fs/file.c | 6 +++---
1 file changed, 3
patch was used:
@@
@@
- rcu_assign_pointer
+ RCU_INIT_POINTER
(..., NULL)
Signed-off-by: Muhammad Falak R Wani
---
drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c
b/drivers/gpu/drm/amd
Remove unneeded variable ret, directly return 0.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/rdma/ipath/ipath_file_ops.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/staging/rdma/ipath/ipath_file_ops.c
b/drivers/staging/rdma/ipath/ipath_file_ops.c
>> On Sun, Oct 25, 2015 at 12:17 PM, Muhammad Falak R Wani
>> >> wrote:
>> >> Please follow standard naming convention for the patches.
>> >> It should be [PATCH v2 1/4] and not [PATCH 1/4 v2].
>> >
>> > Does this matter? It's in a t
Dereference was modified to dereferenced, as it made more sense.
Signed-off-by: Muhammad Falak R Wani
---
scripts/coccinelle/null/deref_null.cocci | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/coccinelle/null/deref_null.cocci
b/scripts/coccinelle/null
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
Signed-off-by: Muhammad Falak R Wani
---
v2 changes
->make subject line more specific
drivers/staging/rdma/hfi1/sdma.c | 6 ++
1 file changed, 2 insertions(+), 4 deleti
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
Signed-off-by: Muhammad Falak R Wani
---
v2 changes:
-> Change the subject line to a be more specific
mfrw
drivers/staging/rdma/ipath/ipath_verbs.c | 5 ++---
1 file changed
ata = e2;
Signed-off-by: Muhammad Falak R Wani
---
v2 changes:
-> Change the subject line to a be more specific
-> Add details about coccinelle in the commit log
mfrw
drivers/staging/rdma/ipath/ipath_driver.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Falak R Wani
---
v2 changes:
-> Change the subject line to a be more specific
mfrw
drivers/staging/rdma/ipath/ipath_init_chip.c | 18 +++---
1 file changed, 7 insertions(+), 11 deletions(-)
diff --gi
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
Signed-off-by: Muhammad Falak R Wani
---
v2 changes:
-> Change the subject line to a be more specific
mfrw
drivers/staging/rdma/ipath/ipath_sdma.c | 6 +++---
1 file changed
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/rdma/ipath/ipath_verbs.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/rdma/ipath
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/rdma/ipath/ipath_sdma.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/rdma/ipath
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Use the timer API function setup_timer instead of init_timer, removing
the structure field assignments.
@timer@
expression e1,e2,e3,fn_ptr;
@@
-init_timer(&e1);
+setup_timer(&e1, fn_ptr, e2);
... when != fn_ptr = e3
-e1.function = fn_ptr;
-e1.data = e2;
Signed-off-by: Muhammad Fala
Remove boilerplate code by using macro module_pci_driver.
For drivers whose __init and __exit paths only register and
unregister to the pci API, it is preferred to use this macro.
Signed-off-by: Muhammad Falak R Wani
---
drivers/scsi/wd719x.c | 13 +
1 file changed, 1 insertion
Use struct pci_device_id instead of DEFINE_PCI_DEVICE_TABLE with
the goal of getting rid of this macro completely, as this macro
is deprecated.
Signed-off-by: Muhammad Falak R Wani
---
drivers/scsi/wd719x.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/scsi
Use timer API function setup_timer instead of init_timer to
initialize the timer.
Signed-off-by: Muhammad Falak R Wani
---
drivers/uwb/rsv.c | 9 +++--
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/uwb/rsv.c b/drivers/uwb/rsv.c
index 536ad42..f5e2724 100644
--- a
Use timer API function setup_timer instead of init_timer to
initialize the timer.
Signed-off-by: Muhammad Falak R Wani
---
drivers/uwb/neh.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/uwb/neh.c b/drivers/uwb/neh.c
index 8cb71bb..36b5cb6 100644
--- a/drivers
Use timer API function setup_timer instead of init_timer to
initialize a kernel timer.
Signed-off-by: Muhammad Falak R Wani
---
drivers/uwb/drp.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/uwb/drp.c b/drivers/uwb/drp.c
index 8fc1b78..38d0504 100644
--- a
Use timer API function setup_timer instead of init_timer to
initialize the timer.
Signed-off-by: Muhammad Falak R Wani
---
drivers/i2c/busses/i2c-pnx.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-pnx.c b/drivers/i2c/busses/i2c-pnx.c
index
Remove the explicit NULL comparison and rewrite in a compact form.
Signed-off-by: Muhammad Falak R Wani
---
drivers/staging/octeon/ethernet-tx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/octeon/ethernet-tx.c
b/drivers/staging/octeon/ethernet-tx.c
index
1 - 100 of 118 matches
Mail list logo