schedule_timeout_* takes a timeout in jiffies but the code currently is
passing in a constant which makes this timeout HZ dependent, so pass it
through msecs_to_jiffies() to fix this up.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Problem found by coccinelle spatch
The current
schedule_timeout_* takes a timeout in jiffies but the code currently is
passing in a constant which makes this timeout HZ dependent, so pass it
through msecs_to_jiffies() to fix this up.
Fixes: commit b0d66369edcd ("liquidio VF error handling")
Signed-off-by: Nicholas Mc Guire <hof
The port assignment in the if case should be to AUX not MAIN.
Fixes: commit baa170229095 ("rtlwifi: btcoexist: Implement antenna selection")
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
problem located by coccinelle
in:
drivers/net/wireless/realtek/r
Hi !
in your commit f5b586909581 ("rtlwifi: btcoexist: Modify driver to support
BT coexistence in rtl8723be") you introduced a if/else where both branches
are the same but the comment in the else branch suggests that this might be
unintended.
from code review only I canĀ“t say what the
schedule_timeout_* takes a timeout in jiffies but the code currently is
passing in a constant which makes this timeout HZ dependent, so pass it
through msecs_to_jiffies() to fix this up.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Problem found by coccinelle script
The below
liquidio_set_rxcsum_command is a local function only, no need to expose it
outside of lio_main.c
so declare it static and make sparse happy.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Detected by sparse:
CHECK drivers/net/ethernet/cavium/liquidio/lio_main.c
drivers/net/et
liquidio_set_rxcsum_command is a local function only, no need to expose
it outside of lio_main.c so declare it static and make sparse happy.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
V2: forgot to fix up the checkpatch.pl warnings...
Detected by sparse:
CHECK drive
The spin_lock()/spin_unlock() is synchronizing on the adapter->work_lock
as the comment also suggests, which is equivalent to spin_unlock_wait()
but the later should be more efficient.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Problem located by coccinelle spatch
Patch wa
On Fri, Mar 18, 2016 at 03:35:18PM -0700, Joe Perches wrote:
> On Fri, 2016-03-18 at 17:37 -0400, David Miller wrote:
> > From: Nicholas Mc Guire <hof...@osadl.org>
> > > The spin_lock()/spin_unlock() is synchronizing on the adapter->work_lock
> > >
The spin_lock()/spin_unlock() is synchronizing on the
nf_conntrack_locks_all_lock which is equivalent to
spin_unlock_wait() but the later should be more efficient.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Patch was compile tested with: x86_64_defconfig (implies CONFIG_NET
local_bh_disable() + spin_lock() is equivalent to spin_lock_bh(), same for
the unlock/enable case, so replace the calls by the appropriate wrappers.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
net-next 3c8e43ba "sctp: remove macros sctp_spin_[un]lock" and
net-nex
On Tue, Dec 22, 2015 at 09:56:10AM +1100, Julian Calaby wrote:
> Hi,
>
> On Tue, Dec 22, 2015 at 3:47 AM, Nicholas Mc Guire <hof...@osadl.org> wrote:
> > This is an API consolidation only. The use of kmalloc + memset to 0
> > is equivalent to kzalloc.
> >
> >
This is an API consolidation only. The use of kmalloc + memset to 0
is equivalent to kzalloc.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Found by coccinelle script (relaxed version of
scripts/coccinelle/api/alloc/kzalloc-simple.cocci)
Patch was compile tested with: x86_64_def
This is an API consolidation only. The use of kmalloc + memset to 0
is equivalent to kcalloc in this case as it is allocating an array
of elements.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Found by coccinelle script (relaxed version of
scripts/coccinelle/api/alloc/k
This is an API consolidation only. The use of kmalloc + memset to 0
is equivalent to kzalloc.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Found by coccinelle script (relaxed version of
scripts/coccinelle/api/alloc/kzalloc-simple.cocci)
Patch was compile tested with: x86_64_def
This is an API consolidation only. Bool initializations should
use true and false thus bool tests don't need an explicit comparison.
Signed-off-by: Nicholas Mc Guire <hof...@osadl.org>
---
Found by coccinelle: scripts/coccinelle/misc/boolinit.cocci
Patch was compile
From: Nicholas Mc Guire hof...@osadl.org
scanning for trivial bug-patters with coccinelle spatches returned:
drivers/net/wireless/brcm80211/brcmsmac/phy/phy_lcn.c:3391
WARNING: condition with no effect (if branch == else)
added in 'commit
)' with dev_dbg/dev_err (though
with the same message) to differentiate severity and then in 'commit
acebe8c10a6e (mwifiex: change dbg print func to mwifiex_dbg)' all
dev_dbg,dev_warn and dev_err got converted to mwifiex_dbg which should
thus probably drop this if/else as well.
Signed-off-by: Nicholas Mc Guire
On Wed, 08 Jul 2015, Avinash Patil wrote:
Hi Nicholas,
On Wed, Jul 8, 2015 at 7:15 AM, Nicholas Mc Guire hof...@osadl.org wrote:
scanning for trivial bug-patters with coccinelle spatches returned:
./drivers/net/wireless/mwifiex/sta_cmdresp.c:895
WARNING: condition with no effect
On Mon, 15 Jun 2015, Stanislav Yakovlev wrote:
Hi Nicholas,
On 12 June 2015 at 20:58, Nicholas Mc Guire der.h...@hofr.at wrote:
Hi !
commit 2c86c275015c (Add ipw2100 wireless driver.) introduced
drivers/net/wireless/ipw2100.c - line-numbers are from next-20150511
1410 static int
commit: commit 2c86c275015c (Add ipw2100 wireless driver.) introduced
HW_PHY_OFF_LOOP_DELAY (HZ / 5000) which always evaluated to 0. Clarified
by Stanislav Yakovlev stas.yakov...@gmail.com that it should be 50
milliseconds thus fixed up to msecs_to_jiffies(50).
Signed-off-by: Nicholas Mc Guire
On Sun, 14 Jun 2015, Larry Finger wrote:
On 06/13/2015 05:43 AM, Nicholas Mc Guire wrote:
From: Nicholas Mc Guire hof...@osadl.org
scanning for trivial bug-patters with coccinelle spatches returned:
./drivers/net/wireless/rtlwifi/rtl8723be/dm.c:886
WARNING: condition with no effect
From: Nicholas Mc Guire hof...@osadl.org
scanning for trivial bug-patters with coccinelle spatches returned:
./drivers/net/irda/via-ircc.c:598
WARNING: condition with no effect (if branch == else)
This code was added prior to the transition to git
From: Nicholas Mc Guire hof...@osadl.org
scanning for trivial bug-patters with coccinelle spatches returned:
./drivers/net/wireless/rtlwifi/rtl8723be/dm.c:886
WARNING: condition with no effect (if branch == else)
Added in 'commit a619d1abe20c
Hi !
commit 2c86c275015c (Add ipw2100 wireless driver.) introduced
drivers/net/wireless/ipw2100.c - line-numbers are from next-20150511
1410 static int ipw2100_hw_phy_off(struct ipw2100_priv *priv)
1411 {
1412
1413 #define HW_PHY_OFF_LOOP_DELAY (HZ / 5000)
1414
and the assignments fixed up.
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
---
Patch was compile tested with x86_64_defconfig + CONFIG_ATH_CARD=y
CONFIG_ATH10K=m
Patch is against 4.1-rc7 (localversion-next is -next-20150611)
drivers/net/wireless/ath/ath10k/txrx.c |6 +++---
1 file changed
and the assignments fixed up.
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
---
Patch was compile tested with x86_64_defconfig + CONFIG_ATH_CARD=y
CONFIG_ATH10K=m
Patch is against 4.1-rc7 (localversion-next is -next-20150611)
drivers/net/wireless/ath/ath10k/mac.c | 10 +-
1 file
with msecs_to_jiffies()
As this driver was introduced in the early 2.3 series it is most
likely assuming HZ=100 so the constant 50 is converted to 500ms.
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
---
Patch was compile tested with i386_defconfig + CONFIG_ATM=y,
CONFIG_ATM_IA=m
Patch
dependent
Numeric constants passed to schedule_timeout_*() make the effective
timeout HZ dependent which does not seem to be the intent here.
Fixed up by converting the constant to jiffies with msecs_to_jiffies(),
passing 100ms (assuming HZ==100 in the original code).
Signed-off-by: Nicholas Mc Guire
On Sun, 07 Jun 2015, David Miller wrote:
From: Nicholas Mc Guire hof...@osadl.org
Date: Sat, 6 Jun 2015 10:41:06 +0200
API compliance scanning with coccinelle flagged:
./drivers/net/wan/dscc4.c:1036:1-33:
WARNING: timeout (10) seems HZ dependent
./drivers/net/wan/dscc4.c:554
On Sun, 07 Jun 2015, David Miller wrote:
From: Nicholas Mc Guire hof...@osadl.org
Date: Sat, 6 Jun 2015 09:51:51 +0200
@@ -517,7 +517,7 @@ static int cosa_probe(int base, int irq, int dma)
*/
set_current_state(TASK_INTERRUPTIBLE);
cosa_putstatus
the constant to jiffies with msecs_to_jiffies()
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
---
As the actually intended timeout is not documented and msecs_to_jiffies
timeouts can be a factor 10 different from the current effective timeout
As the original driver predates variable HZ (2.2.26 drivers
Fix:
drivers/net/wan/dscc4.c: In function 'dscc4_open':
drivers/net/wan/dscc4.c:1049:25: warning: variable 'ppriv' set but not used
[-Wunused-but-set-variable]
This has been in there unused since 1da177e4c3f (Linux-2.6.12-rc2) simply
remove it.
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
dependent
Numeric constants passed to schedule_timeout_*() make the effective
timeout HZ dependent which does not seem to be the intent here.
Fixed up by converting the constant to jiffies with msecs_to_jiffies()
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
---
As the intended timeout
is -next-20150527)
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
---
As there is no documentation of the intended timeout it might be wrong
to convert it with msecs_to_jiffies as this can reduces the actual
jiffies value by at least a factor of 10 - so someone that knows this
driver needs
msecs_to_jiffies(val) conversion is
correct in all cases. Further the () around the arithmetic expression
was dropped.
Patch was compile tested for x86_64_defconfig + CONFIG_IRDA=m
Patch is against 4.1-rc4 (localversion-next is -next-20150522)
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
On Sun, 24 May 2015, David Miller wrote:
From: Nicholas Mc Guire hof...@osadl.org
Date: Sat, 23 May 2015 15:43:36 +0200
API compliance scanning with coccinelle flagged:
./net/irda/timer.c:63:35-37: use of msecs_to_jiffies probably perferable
Converting milliseconds to jiffies by val
-20150522)
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
---
V2: the unnecessary () flagged by Joe Perches j...@perches.com
was removed - thanks (...once again...) !
drivers/net/irda/irda-usb.c |4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/net/irda/irda-usb.c
msecs_to_jiffies(val) conversion is
correct in all cases. Further the () around the arithmetic expression
was dropped.
Patch was compile tested for x86_64_defconfig + CONFIG_IRDA=m
Patch is against 4.1-rc4 (localversion-next is -next-20150522)
Signed-off-by: Nicholas Mc Guire hof...@osadl.org
39 matches
Mail list logo