twx-linux/drivers
Arnd Bergmann de8c36bba3 scsi: lpfc: avoid harmless comparison warning
When building with -Wextra, we get a lot of warnings for the lpfc driver
concerning expressions that are always true, starting with:

drivers/scsi/lpfc/lpfc_attr.c: In function 'lpfc_enable_npiv_init':
drivers/scsi/lpfc/lpfc_attr.c:2786:77: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
drivers/scsi/lpfc/lpfc_attr.c: In function 'lpfc_enable_rrq_init':
drivers/scsi/lpfc/lpfc_attr.c:2802:76: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
drivers/scsi/lpfc/lpfc_attr.c: In function 'lpfc_suppress_link_up_init':
drivers/scsi/lpfc/lpfc_attr.c:2812:2050: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]
drivers/scsi/lpfc/lpfc_attr.c: In function 'lpfc_log_verbose_init':
drivers/scsi/lpfc/lpfc_attr.c:3064:1930: error: comparison of unsigned expression >= 0 is always true [-Werror=type-limits]

The code works as intended, but it would be nice to shut up the warning
so we don't clutter up build logs with this. Using a separate inline
function for it makes it clear to the compiler that the comparison is
necessary in the caller but still lets it do the constant-folding.

[mkp: fix typo]

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Acked-by: James Smart <james.smart@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2016-07-20 19:53:07 -04:00
..
accessibility
acpi Merge branches 'acpica-fixes', 'acpi-pci-fixes' and 'acpi-debug-fixes' 2016-07-07 23:37:37 +02:00
amba
android
ata
atm
auxdisplay
base
bcma
block Merge branch 'for-linus' of git://git.kernel.dk/linux-block 2016-07-07 15:34:09 -07:00
bluetooth
bus
cdrom
char
clk
clocksource
connector
cpufreq
cpuidle cpuidle: Fix last_residency division 2016-07-04 14:17:34 +02:00
crypto
dax
dca
devfreq
dio
dma
dma-buf
edac
eisa
extcon
firewire
firmware
fmc
fpga
gpio Revert "gpio: gpiolib-of: Allow compile testing" 2016-07-05 19:03:04 +02:00
gpu Allwinner DRM driver fixes for 4.7, take 2 2016-07-08 13:29:11 +10:00
hid
hsi
hv
hwmon
hwspinlock
hwtracing
i2c
ide
idle
iio
infiniband
input
iommu iommu/amd: Fix unity mapping initialization race 2016-07-06 18:04:55 +02:00
ipack
irqchip irqchip/mips-gic: Match IPI IRQ domain by bus token only 2016-07-05 16:54:21 +02:00
isdn
leds
lguest
lightnvm
macintosh
mailbox
mcb
md
media
memory
memstick
message
mfd
misc
mmc
mtd
net cxgb4: update latest firmware version supported 2016-07-05 11:53:25 -07:00
nfc
ntb
nubus
nvdimm
nvme
nvmem
of
oprofile
parisc
parport
pci
pcmcia
perf
phy - Final patches fixing Reset API change 2016-07-01 15:17:16 -07:00
pinctrl
platform platform/chrome: cros_ec_dev - double fetch bug in ioctl 2016-07-05 14:01:52 -07:00
pnp
power
powercap
pps
ps3
ptp
pwm
rapidio
ras
regulator regulator: Fix qcom-smd list voltage issues for msm8974 2016-07-13 04:22:16 +09:00
remoteproc
reset
rpmsg
rtc
s390 qeth: delete napi struct when removing a qeth device 2016-07-04 23:32:08 -07:00
sbus
scsi scsi: lpfc: avoid harmless comparison warning 2016-07-20 19:53:07 -04:00
sfi
sh
sn
soc
spi Merge remote-tracking branches 'spi/fix/ep93xx', 'spi/fix/rockchip', 'spi/fix/sunxi' and 'spi/fix/ti-qspi' into spi-linus 2016-06-30 13:17:29 +01:00
spmi
ssb
staging
target
tc
thermal
thunderbolt
tty
uio
usb - Final patches fixing Reset API change 2016-07-01 15:17:16 -07:00
uwb
vfio
vhost
video
virt
virtio
vlynq
vme
w1
watchdog
xen xen/acpi: allow xen-acpi-processor driver to load on Xen 4.7 2016-07-08 14:53:13 +01:00
zorro
Kconfig
Makefile