[PATCH RESEND] scsi: fnic: Clean up redundant variables

2017-10-31 Thread Christos Gkekas
Remove variables that are set but not used. Signed-off-by: Christos Gkekas --- drivers/scsi/fnic/fnic_fcs.c | 9 - drivers/scsi/fnic/vnic_rq.c | 3 --- drivers/scsi/fnic/vnic_wq.c | 3 --- 3 files changed, 15 deletions(-) diff --git a/drivers/scsi/fnic/fnic_fcs.c b/drivers/scsi/fnic

[PATCH] csi: hpsa: Fix configured_logical_drive_countĀ·check

2017-10-16 Thread Christos Gkekas
Check whether configured_logical_drive_count is less than 255. Previous check was always evaluating to true as this variable is defined as u8. Signed-off-by: Christos Gkekas --- drivers/scsi/hpsa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/hpsa.c b/drivers

Re: [PATCH] scsi: hpsa: simplify hpsa_set_local_logical_count()

2017-10-16 Thread Christos Gkekas
On 16/10/17 18:55:11 +, Don Brace wrote: > > -Original Message- > > From: Christos Gkekas [mailto:chris.ge...@gmail.com] > > Sent: Sunday, October 15, 2017 2:35 PM > > To: Don Brace ; James E.J. Bottomley > > ; Martin K. Petersen > > ; esc.storage

Re: [PATCH] ceph: Delete unused variable in mds_client

2017-10-16 Thread Christos Gkekas
On 16/10/17 11:12:53 +0200, Ilya Dryomov wrote: > On Sat, Oct 14, 2017 at 12:01 PM, Christos Gkekas > wrote: > > Variable 'err' is set but never used, so should be removed. > > > > Signed-off-by: Christos Gkekas > > --- > > fs/ceph/mds_cl

[PATCH] drm/i915/gvt: Clean up dead code in cmd_parser

2017-10-15 Thread Christos Gkekas
Delete variables 'gma_bottom' that are set but never used. Signed-off-by: Christos Gkekas --- drivers/gpu/drm/i915/gvt/cmd_parser.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/i915/gvt/cmd_parser.c b/drivers/gpu/drm/i915/gvt/cmd_pars

[PATCH] drm/i915/gvt: Fix error handling bug in perform_bb_shadow

2017-10-15 Thread Christos Gkekas
Change the type of variable 'bb_size' from uint32_t to int to be able to hold error return values from find_bb_size(). This change seems to have been missed from previous commit 1e3197d6ad73. Signed-off-by: Christos Gkekas --- drivers/gpu/drm/i915/gvt/cmd_parser.c | 2 +- 1 file

[PATCH] scsi: hpsa: simplify hpsa_set_local_logical_count()

2017-10-15 Thread Christos Gkekas
Variable configured_logical_drive_count is defined as u8 and thus the nested if statement always evaluates to true. Remove it and simplify. Signed-off-by: Christos Gkekas --- drivers/scsi/hpsa.c | 9 + 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/drivers/scsi/hpsa.c b

[PATCH] scsi: fnic: Clean up redundant variables

2017-10-14 Thread Christos Gkekas
Remove variables that are set but not used. Signed-off-by: Christos Gkekas --- drivers/scsi/fnic/fnic_fcs.c | 9 - drivers/scsi/fnic/vnic_rq.c | 3 --- drivers/scsi/fnic/vnic_wq.c | 3 --- 3 files changed, 15 deletions(-) diff --git a/drivers/scsi/fnic/fnic_fcs.c b/drivers/scsi/fnic

[PATCH] scsi: qedi: Delete redundant variables

2017-10-14 Thread Christos Gkekas
Remove redundant variables in quedi_fw.c that are set but not used. Signed-off-by: Christos Gkekas --- drivers/scsi/qedi/qedi_fw.c | 17 + 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/drivers/scsi/qedi/qedi_fw.c b/drivers/scsi/qedi/qedi_fw.c index 93d54ac

[PATCH] [SCSI] sym53c8xx: Remove pointers scriptb0

2017-10-14 Thread Christos Gkekas
Pointers 'scriptb0' are set but never used, so need to be deleted. Signed-off-by: Christos Gkekas --- drivers/scsi/sym53c8xx_2/sym_fw.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/scsi/sym53c8xx_2/sym_fw.c b/drivers/scsi/sym53c8xx_2/sym_fw.c index 190770b..91db

[PATCH] usb: dwc3: ep0: Clean up unused variables

2017-10-14 Thread Christos Gkekas
Many variables in ep0 are set but never used, so should be removed. Signed-off-by: Christos Gkekas --- drivers/usb/dwc3/ep0.c | 20 1 file changed, 20 deletions(-) diff --git a/drivers/usb/dwc3/ep0.c b/drivers/usb/dwc3/ep0.c index 75e6cb0..a4dceae 100644 --- a/drivers/usb

[PATCH] hfs/hfsplus: Clean up unused variables in bnode.c

2017-10-14 Thread Christos Gkekas
Delete variables 'tree' and 'sb', which are set but never used. Signed-off-by: Christos Gkekas --- fs/hfs/bnode.c | 4 fs/hfsplus/bnode.c | 4 2 files changed, 8 deletions(-) diff --git a/fs/hfs/bnode.c b/fs/hfs/bnode.c index d77d844..8d618c9 100644 --- a/fs/

[PATCH] ceph: Delete unused variable in mds_client

2017-10-14 Thread Christos Gkekas
Variable 'err' is set but never used, so should be removed. Signed-off-by: Christos Gkekas --- fs/ceph/mds_client.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c index f23c820..7cd4fd9 100644 --- a/fs/ceph/mds_client.c +++

[PATCH] ath9k: debug: Remove redundant check

2017-10-14 Thread Christos Gkekas
Variable val is unsigned, so checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/net/wireless/ath/ath9k/debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath/ath9k

[PATCH] ath10k: spectral: Remove redundant check

2017-10-14 Thread Christos Gkekas
Variable val is unsigned, so checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/net/wireless/ath/ath10k/spectral.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/ath/ath10k/spectral.c b/drivers/net/wireless

Re: [PATCH] ceph: Delete unused variables in mds_client

2017-10-14 Thread Christos Gkekas
On 12/10/17 15:45:42 -0700, Gregory Farnum wrote: > On Thu, Oct 12, 2017 at 2:55 PM, Christos Gkekas > wrote: > > Remove variables in mds_client that are set but never used. > > Hmm, it looks like all the values removed here (except err) *are* used > and this patch

Re: [PATCH] ath9k: debug: Simplify error checking

2017-10-14 Thread Christos Gkekas
On 13/10/17 15:49:15 +0300, Kalle Valo wrote: > Christos Gkekas writes: > > > Variable val is unsigned so checking whether it is less than zero is > > redundant. > > > > Signed-off-by: Christos Gkekas > > --- > > drivers/net/wireless/ath/ath9k/debug.c

Re: [PATCH] ath10k: spectral: Simplify error checking

2017-10-14 Thread Christos Gkekas
On 13/10/17 12:28:50 +, Kalle Valo wrote: > Christos Gkekas writes: > > > Variable val is unsigned so checking whether it is less than zero is > > redundant. > > > > Signed-off-by: Christos Gkekas > > --- > > drivers/net/wireless/ath/ath10k/s

[PATCH] mtip32xx: Clean up unused variables

2017-10-12 Thread Christos Gkekas
Remove variables that are set but never used. Signed-off-by: Christos Gkekas --- drivers/block/mtip32xx/mtip32xx.c | 7 --- 1 file changed, 7 deletions(-) diff --git a/drivers/block/mtip32xx/mtip32xx.c b/drivers/block/mtip32xx/mtip32xx.c index 4a3cfc7..b8af735 100644 --- a/drivers/block

[PATCH] ceph: Delete unused variables in mds_client

2017-10-12 Thread Christos Gkekas
Remove variables in mds_client that are set but never used. Signed-off-by: Christos Gkekas --- fs/ceph/mds_client.c | 11 --- 1 file changed, 11 deletions(-) diff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c index f23c820..cadf9b6 100644 --- a/fs/ceph/mds_client.c +++ b/fs/ceph

[PATCH] btrfs: Clean up unused variables in free-space-tree.c

2017-10-12 Thread Christos Gkekas
Remove variables 'start' and 'end', which are set but never used. Signed-off-by: Christos Gkekas --- fs/btrfs/free-space-tree.c | 4 1 file changed, 4 deletions(-) diff --git a/fs/btrfs/free-space-tree.c b/fs/btrfs/free-space-tree.c index 684f122..fe5e032 100644 --- a

[PATCH] rtlwifi: Remove unused cur_rfstate variables

2017-10-11 Thread Christos Gkekas
Clean up unused cur_rfstate variables in rtl8188ee, rtl8723ae, rtl8723be and rtl8821ae. Signed-off-by: Christos Gkekas --- drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c | 4 +--- drivers/net/wireless/realtek/rtlwifi/rtl8723ae/hw.c | 4 +--- drivers/net/wireless/realtek/rtlwifi/rtl8723be

[PATCH] IB/hfil: Delete unused bypass flags

2017-10-11 Thread Christos Gkekas
Clean up unused bypass variables in verbs. Signed-off-by: Christos Gkekas --- drivers/infiniband/hw/hfi1/verbs.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/infiniband/hw/hfi1/verbs.c b/drivers/infiniband/hw/hfi1/verbs.c index e232f3c..62c3f4e 100644 --- a/drivers/infiniband

[PATCH] vxge: Clean up unused variables in vxge-traffic

2017-10-11 Thread Christos Gkekas
Delete unused channel variables in vxge-traffic. Signed-off-by: Christos Gkekas --- drivers/net/ethernet/neterion/vxge/vxge-traffic.c | 19 --- 1 file changed, 19 deletions(-) diff --git a/drivers/net/ethernet/neterion/vxge/vxge-traffic.c b/drivers/net/ethernet/neterion/vxge

Re: [PATCH] Input: atmel_mxt_ts - Remove unnecessary byte_offset check

2017-10-09 Thread Christos Gkekas
On 09/10/17 10:38:55 -0700, Dmitry Torokhov wrote: > On Sun, Oct 08, 2017 at 08:41:16PM +0100, Nick Dyer wrote: > > On Sun, Oct 08, 2017 at 07:44:18PM +0100, Christos Gkekas wrote: > > > Variable byte_offset is unsigned so checking whether it is greater or > > >

Re: [PATCH] intel-oaktrail: Clean up dead code

2017-10-09 Thread Christos Gkekas
On 09/10/17 13:21:17 +0300, Andy Shevchenko wrote: > On Mon, Oct 9, 2017 at 1:57 AM, Christos Gkekas wrote: > > A couple of macros are unused and need to be removed. > > Also variable percent is unsigned so checking whether it is less than > > zero is redundant. > > &

[PATCH] intel-oaktrail: Clean up dead code

2017-10-08 Thread Christos Gkekas
A couple of macros are unused and need to be removed. Also variable percent is unsigned so checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/platform/x86/intel_oaktrail.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers

[PATCH] qed: Delete redundant check on dcb_app priority

2017-10-08 Thread Christos Gkekas
dcb_app priority is unsigned thus checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/net/ethernet/qlogic/qed/qed_dcbx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/qlogic/qed/qed_dcbx.c b/drivers/net

[PATCH] iommu/vt-d: Delete unnecessary check

2017-10-08 Thread Christos Gkekas
Variable did_old is unsigned so checking whether it is greater or equal to zero is not necessary. Signed-off-by: Christos Gkekas --- drivers/iommu/intel-iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c index

[PATCH] Input: synaptics-rmi4: Clean up redundant check

2017-10-08 Thread Christos Gkekas
Variable size_presence_regĀ·is unsigned so checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/input/rmi4/rmi_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/rmi4/rmi_driver.c b/drivers/input/rmi4/rmi_driver.c

[PATCH] cklight: tps65217_bl: Remove unnecessary default brightness check

2017-10-08 Thread Christos Gkekas
Variable val holds the default brightness and is unsigned, therefore checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/video/backlight/tps65217_bl.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/video/backlight

[PATCH] scsi: eata: Remove unnecessary cpp_index check

2017-10-08 Thread Christos Gkekas
Variable spp->cpp_index is unsigned so checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/scsi/eata.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/eata.c b/drivers/scsi/eata.c index 6501c33..53a8fcd 100

[PATCH] ath9k: debug: Simplify error checking

2017-10-08 Thread Christos Gkekas
Variable val is unsigned so checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/net/wireless/ath/ath9k/debug.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath

[PATCH] ath10k: spectral: Simplify error checking

2017-10-08 Thread Christos Gkekas
Variable val is unsigned so checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/net/wireless/ath/ath10k/spectral.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/spectral.c b/drivers/net

[PATCH] net: ethernet: stmmac: Clean up dead code

2017-10-08 Thread Christos Gkekas
Many macros in dwmac-ipq806x are unused and should be removed. Moreover gmac->id is an unsigned variable and therefore checking whether it is less than zero is redundant. Signed-off-by: Christos Gkekas --- drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c | 14 +- 1 file chan

[PATCH] leds: tca6507: Remove unnecessary reg check

2017-10-08 Thread Christos Gkekas
Variable reg is unsigned so checking whether it is less than zero is not necessary. Signed-off-by: Christos Gkekas --- drivers/leds/leds-tca6507.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/leds/leds-tca6507.c b/drivers/leds/leds-tca6507.c index 45222a7..c12c16f

[PATCH] Input: atmel_mxt_ts - Remove unnecessary byte_offset check

2017-10-08 Thread Christos Gkekas
Variable byte_offset is unsigned so checking whether it is greater or equal to zero is redundant. Signed-off-by: Christos Gkekas --- drivers/input/touchscreen/atmel_mxt_ts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c b/drivers

[PATCH] ASoC: cygnus: Remove unnecessary active_slots check

2017-10-08 Thread Christos Gkekas
Variable active_slots is unsigned so checking whether it is less than zero is not necessary. Signed-off-by: Christos Gkekas --- sound/soc/bcm/cygnus-ssp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/bcm/cygnus-ssp.c b/sound/soc/bcm/cygnus-ssp.c index 15c438f

Re: [PATCH] vxge: Fix rts_mac_en config parameter check

2017-09-24 Thread Christos Gkekas
On 24/09/17 19:50:21 +0100, Christos Gkekas wrote: > Current checks return VXGE_HW_BADCFG_RTS_MAC_EN if rts_mac_en is not > equal to DISABLE *and* not equal to ENABLE. This condition is always > false and the check should change to *or* to properly verify the value. > > Signed-o

[PATCH] vxge: Fix rts_mac_en config parameter check

2017-09-24 Thread Christos Gkekas
Current checks return VXGE_HW_BADCFG_RTS_MAC_EN if rts_mac_en is not equal to DISABLE *and* not equal to ENABLE. This condition is always false and the check should change to *or* to properly verify the value. Signed-off-by: Christos Gkekas --- drivers/net/ethernet/neterion/vxge/vxge-config.c

[PATCH RESEND] cachefiles: Remove unnecessary comparisons in daemon.c

2017-09-24 Thread Christos Gkekas
Remove unnecessary comparisons of unsigned variables with zero. Signed-off-by: Christos Gkekas --- fs/cachefiles/daemon.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/cachefiles/daemon.c b/fs/cachefiles/daemon.c index 1ee54ff..ce072ce 100644 --- a/fs/cachefiles

[PATCH RESEND] fs/cachefiles: Remove unnecessary comparisons in bind.c

2017-09-24 Thread Christos Gkekas
cache->fstop_percent and cache->bstop_percent are unsigned so they are always >= 0. There is no point in asserting this. Signed-off-by: Christos Gkekas --- fs/cachefiles/bind.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/fs/cachefiles/bind.c b/fs/cachefil

[PATCH RESEND] ncpfs: ioctl: Delete unnecessary len variables

2017-09-24 Thread Christos Gkekas
Variables oldnamelen, oldprivatelen and oldlen are set but are never used, thus they need to be cleaned up. Signed-off-by: Christos Gkekas --- fs/ncpfs/ioctl.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/fs/ncpfs/ioctl.c b/fs/ncpfs/ioctl.c index 12550c2..85c6c60 100644 --- a/fs

Re: [PATCH] signal: remove unused variable

2017-09-14 Thread Christos Gkekas
new_ka.sa.sa_handler = compat_ptr(handler); > #ifdef __ARCH_HAS_SA_RESTORER > -- > 2.9.0 > Thanks, Acked-by: Christos Gkekas

[PATCH] spi: stm32: Fix logical error in stm32_spi_prepare_mbr()

2017-09-10 Thread Christos Gkekas
stm32_spi_prepare_mbr() is returning an error value when div is less than SPI_MBR_DIV_MIN *and* greater than SPI_MBR_DIV_MAX, which always evaluates to false. This should change to use *or*. Signed-off-by: Christos Gkekas --- drivers/spi/spi-stm32.c | 4 ++-- 1 file changed, 2 insertions(+), 2

[PATCH] bnx2i: Clean up unused pointers in bnx2i_hwi

2017-09-10 Thread Christos Gkekas
Pointers bnx2i_cmd are set but never used, so they can be removed. Signed-off-by: Christos Gkekas --- drivers/scsi/bnx2i/bnx2i_hwi.c | 10 -- 1 file changed, 10 deletions(-) diff --git a/drivers/scsi/bnx2i/bnx2i_hwi.c b/drivers/scsi/bnx2i/bnx2i_hwi.c index 42921db..e3f22cb 100644 --- a

[PATCH] fs/cachefiles: Remove unnecessary comparisons in bind.c

2017-09-09 Thread Christos Gkekas
cache->fstop_percent and cache->bstop_percent are unsigned so they are always >= 0. There is no point in asserting this. Signed-off-by: Christos Gkekas --- fs/cachefiles/bind.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/fs/cachefiles/bind.c b/fs/cachefil

[PATCH] ncpfs: ioctl: Delete unnecessary len variables

2017-09-09 Thread Christos Gkekas
Variables oldnamelen, oldprivatelen and oldlen are set but are never used, thus they need to be cleaned up. Signed-off-by: Christos Gkekas --- fs/ncpfs/ioctl.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/fs/ncpfs/ioctl.c b/fs/ncpfs/ioctl.c index 12550c2..85c6c60 100644 --- a/fs

[PATCH] btrfs: Clean up dead code in root-tree

2017-09-09 Thread Christos Gkekas
The value of variable 'can_recover' is never used after being set, thus it should be removed. Signed-off-by: Christos Gkekas --- fs/btrfs/root-tree.c | 4 1 file changed, 4 deletions(-) diff --git a/fs/btrfs/root-tree.c b/fs/btrfs/root-tree.c index 95bcc3c..3338407 100644 ---

[PATCH] tracing: Clean up unused variable 'ret' in trace_events_hist

2017-09-09 Thread Christos Gkekas
Variable 'ret' in trace_events_hist is unused and should be removed. Signed-off-by: Christos Gkekas --- kernel/trace/trace_events_hist.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/kernel/trace/trace_events_hist.c b/kernel/trace/trace_events_hist.c ind

[PATCH] cachefiles: Remove unnecessary comparisons in daemon.c

2017-09-09 Thread Christos Gkekas
Remove unnecessary comparisons of unsigned variables with zero. Signed-off-by: Christos Gkekas --- fs/cachefiles/daemon.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/cachefiles/daemon.c b/fs/cachefiles/daemon.c index 1ee54ff..ce072ce 100644 --- a/fs/cachefiles

[PATCH] cifs: Clean up unused variables in smb2pdu.c

2017-07-09 Thread Christos Gkekas
There are multiple unused variables struct TCP_Server_Info *server defined in many methods in smb2pdu.c. They should be removed and related logic simplified. Signed-off-by: Christos Gkekas --- fs/cifs/smb2pdu.c | 35 +++ 1 file changed, 7 insertions(+), 28

[PATCH] cachefiles: Remove unnecessary comparisons in daemon.c

2017-07-08 Thread Christos Gkekas
Remove unnecessary comparisons of unsigned variables with zero. Signed-off-by: Christos Gkekas --- fs/cachefiles/daemon.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/cachefiles/daemon.c b/fs/cachefiles/daemon.c index 1ee54ff..ce072ce 100644 --- a/fs/cachefiles

[PATCH] apparmor: Fix logical error in verify_header()

2017-07-08 Thread Christos Gkekas
verify_header() is currently checking whether interface version is less than 5 *and* greater than 7, which always evaluates to false. Instead it should check whether it is less than 5 *or* greater than 7. Signed-off-by: Christos Gkekas --- security/apparmor/policy_unpack.c | 2 +- 1 file

[PATCH RESEND] HID: wacom: Remove comparison of u8 mode with zero and simplify.

2017-07-08 Thread Christos Gkekas
Variable mode in method wacom_show_remote_mode() is defined as u8, thus statement (mode >= 0) is always true and should be removed, simplifying the logic. Signed-off-by: Christos Gkekas --- drivers/hid/wacom_sys.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/driv

[PATCH] HID: wacom: Remove comparison of u8 mode with zero and simplify.

2017-07-02 Thread Christos Gkekas
Variable mode in method wacom_show_remote_mode() is defined as u8, thus statement (mode >= 0) is always true and should be removed, simplifying the logic. Signed-off-by: Christos Gkekas --- drivers/hid/wacom_sys.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/driv

Re: [PATCH] HID: wacom: Remove comparison of u8 mode with zero and simplify.

2017-07-02 Thread Christos Gkekas
On 02/07/17 15:04:28 -0700, Joe Perches wrote: > On Sun, 2017-07-02 at 22:54 +0100, Christos Gkekas wrote: > > Variable mode in method wacom_show_remote_mode() is defined as u8, thus > > statement (mode >= 0) is always true and should be removed, simplifying > > the logi

[PATCH] netxen_nic: Remove unused pointer hdr in netxen_setup_minidump()

2017-07-02 Thread Christos Gkekas
Pointer hdr in netxen_setup_minidump() is set but never used, thus should be removed. Signed-off-by: Christos Gkekas --- drivers/net/ethernet/qlogic/netxen/netxen_nic_ctx.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/qlogic/netxen/netxen_nic_ctx.c b/drivers/net

[PATCH] HID: wacom: Remove comparison of u8 mode with zero and simplify.

2017-07-02 Thread Christos Gkekas
Variable mode in method wacom_show_remote_mode() is defined as u8, thus statement (mode >= 0) is always true and should be removed, simplifying the logic. Signed-off-by: Christos Gkekas --- drivers/hid/wacom_sys.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/driv

[PATCH] scsi: qedi: Remove comparison of u16 idx with zero.

2017-06-24 Thread Christos Gkekas
Variable idx is defined as u16 thus statement (idx < 0) is always false and should be removed. Signed-off-by: Christos Gkekas --- drivers/scsi/qedi/qedi_fw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/qedi/qedi_fw.c b/drivers/scsi/qedi/qedi_fw.c in

[PATCH] pptp: Remove unused variable in pptp_release()

2017-06-18 Thread Christos Gkekas
Variable opt in pptp_release() is set but never used, thus needs to be removed. Signed-off-by: Christos Gkekas --- drivers/net/ppp/pptp.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/net/ppp/pptp.c b/drivers/net/ppp/pptp.c index 1951b10..5b0fd89 100644 --- a/drivers/net/ppp