linux/drivers
Martin Michlmayr 0f6d93aa9d drivers/scsi/atp870u.c: fix bad use of udelay
The ACARD driver calls udelay() with a value > 2000, which leads to to
the following compilation error on ARM:

  ERROR: "__bad_udelay" [drivers/scsi/atp870u.ko] undefined!
  make[1]: *** [__modpost] Error 1

This is because udelay is defined on ARM, roughly speaking, as

	#define udelay(n) ((n) > 2000 ? __bad_udelay() : \
		__const_udelay((n) * ((2199023U*HZ)>>11)))

The argument to __const_udelay is the number of jiffies to wait divided
by 4, but this does not work unless the multiplication does not
overflow, and that is what the build error is designed to prevent.  The
intended behavior can be achieved by using mdelay to call udelay
multiple times in a loop.

[jrnieder@gmail.com: adding context]
Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-10-06 03:04:37 +09:00
..
accessibility
acpi Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2012-10-03 23:29:23 -07:00
amba
ata SCSI for-linus on 20121002 2012-10-02 19:01:32 -07:00
atm
auxdisplay
base firmware: use 'kernel_read()' to read firmware into kernel buffer 2012-10-04 09:19:02 -07:00
bcma bcma: change delays to follow timers-howto guide 2012-09-28 13:54:02 -04:00
block Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2012-10-02 11:11:09 -07:00
bluetooth Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2012-10-02 13:38:27 -07:00
bus drivers: bus: omap_l3: fixup merge conflict resolution 2012-10-01 19:39:48 -07:00
cdrom
char Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 2012-10-04 09:06:34 -07:00
clk spi: Updates for v3.7 2012-10-02 17:26:42 -07:00
clocksource Power management updates for 3.7-rc1 2012-10-02 18:32:35 -07:00
connector Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2012-10-02 13:38:27 -07:00
cpufreq Power management updates for 3.7-rc1 2012-10-02 18:32:35 -07:00
cpuidle
crypto Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 2012-10-04 09:06:34 -07:00
dca
devfreq
dio
dma drivers/dma/dmaengine.c: lower the priority of 'failed to get' dma channel message 2012-10-06 03:04:36 +09:00
edac Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
eisa
extcon Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
firewire firewire: addendum to address handler RCU conversion 2012-09-28 11:47:42 +02:00
firmware
gpio So this is the LW GPIO patch stack for v3.7: 2012-10-02 16:05:10 -07:00
gpu Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2012-10-03 23:29:23 -07:00
hid Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
hsi
hv
hwmon ARM: soc: multiplatform enablement 2012-10-01 19:11:38 -07:00
hwspinlock
i2c ARM: soc: multiplatform enablement 2012-10-01 19:11:38 -07:00
ide
idle
iio
infiniband Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2012-10-02 20:25:04 -07:00
input Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2012-10-02 17:16:10 -07:00
iommu PCI changes for the 3.7 merge window: 2012-10-01 12:05:36 -07:00
irqchip irqchip: fill in empty Kconfig 2012-09-24 10:07:40 -07:00
isdn Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2012-10-02 13:38:27 -07:00
leds Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
lguest
macintosh Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
md Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
media Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
memory memory: tegra{20,30}-mc: Fix reading incorrect register in mc_readl() 2012-09-26 14:04:09 -07:00
memstick
message
mfd Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
misc Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
mmc spi: Updates for v3.7 2012-10-02 17:26:42 -07:00
mtd The main change is the way we reserve eraseblocks for bad blocks 2012-10-02 20:49:15 -07:00
net Features: 2012-10-02 22:09:10 -07:00
nfc NFC: Fix missing mutex unlock in pn533_send_cmd_frame_async 2012-09-27 10:47:48 +02:00
nubus
of Devicetree updates for 3.7 2012-10-03 09:44:08 -07:00
oprofile
parisc
parport
pci Features: 2012-10-02 22:09:10 -07:00
pcmcia ARM: soc: multiplatform enablement 2012-10-01 19:11:38 -07:00
pinctrl These are the bulk pinctrl changes for kernel v3.7: 2012-10-02 16:20:20 -07:00
platform Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
pnp
power Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
pps
ps3
ptp
pwm
rapidio
regulator Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
remoteproc - Remoteproc Recovery - by Fernando Guzman Lugo - when a remote processor 2012-10-04 09:11:57 -07:00
rpmsg
rtc ARM: soc: device tree updates 2012-10-01 18:28:06 -07:00
s390 SCSI for-linus on 20121002 2012-10-02 19:01:32 -07:00
sbus
scsi drivers/scsi/atp870u.c: fix bad use of udelay 2012-10-06 03:04:37 +09:00
sfi
sh ARM: soc: multiplatform enablement 2012-10-01 19:11:38 -07:00
sn
spi Devicetree updates for 3.7 2012-10-03 09:44:08 -07:00
ssb
staging Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2012-10-03 23:29:23 -07:00
target Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2012-10-01 09:06:36 -07:00
tc
thermal
tty Features: 2012-10-02 22:09:10 -07:00
uio
usb Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2012-10-02 20:25:04 -07:00
uwb
vfio switch simple cases of fget_light to fdget 2012-09-26 22:20:08 -04:00
vhost vhost_set_vring(): turn pollstart/pollstop into bool 2012-09-26 21:10:12 -04:00
video Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2012-10-02 20:25:04 -07:00
virt
virtio
vlynq
vme
w1 char/misc driver merge for 3.7-rc1 2012-10-01 12:09:59 -07:00
watchdog ARM: soc: general cleanups 2012-10-01 18:19:05 -07:00
xen Features: 2012-10-02 22:09:10 -07:00
zorro
Kconfig ARM: soc: driver specific changes 2012-10-01 18:46:13 -07:00
Makefile Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2012-10-02 13:38:27 -07:00