u-boot-brain/include/linux
mario.six@gdsys.cc ca388143ce linux/compat.h: Properly implement ndelay fallback
Commit c68c62 ("i2c: mvtwsi: Make delay times frequency-dependent")
extensively used the ndelay function with a calculated parameter
which is dependant on the configured frequency of the I2C bus. If
standard speed is employed, the parameter is usually 10000 (10000ns
period length for 100kHz frequency).

But, since the arm architecture does not implement a proper version of
ndelay, the fallback default from include/linux/compat.h is used,
which defines every ndelay as udelay(1). This causes problems for
slower speeds on arm, since the delay time is now 9us too short for
the desired frequency, which leads to random failures of the I2C
interface.

To remedy this, we implement a proper, parameter-aware ndelay fallback
for architectures that don't implement a real ndelay function.

Reported-By: Jason Brown <Jason.brown@apcon.com>
To: Tom Rini <trini@konsulko.com>
To: Heiko Schocher <hs@denx.de>
Signed-off-by: Mario Six <mario.six@gdsys.cc>
2016-11-28 15:10:34 -05:00
..
byteorder
mtd treewide: replace #include <asm/errno.h> with <linux/errno.h> 2016-09-23 17:55:42 -04:00
unaligned
usb drivers: usb: xhci-fsl: Implement Erratum A-010151 for FSL USB3 controller 2016-09-27 23:30:49 +02:00
apm_bios.h
bch.h
bitops.h
bitrev.h
bug.h
compat.h linux/compat.h: Properly implement ndelay fallback 2016-11-28 15:10:34 -05:00
compiler-clang.h
compiler-gcc.h compiler*.h: sync include/linux/compiler*.h with Linux 4.5-rc6 2016-02-29 11:43:24 -05:00
compiler-intel.h compiler*.h: sync include/linux/compiler*.h with Linux 4.5-rc6 2016-02-29 11:43:24 -05:00
compiler.h compiler*.h: sync include/linux/compiler*.h with Linux 4.5-rc6 2016-02-29 11:43:24 -05:00
crc7.h
crc8.h lib/crc8: Add crc start value 2016-04-11 20:48:26 -04:00
crc32.h
ctype.h
drm_dp_helper.h
edd.h
err.h sf: Adopt flash table INFO macro from Linux 2016-11-18 13:04:52 +05:30
errno.h errno.h: sync error macros with linux 4.8-rc7 2016-09-23 22:25:43 -04:00
ethtool.h
fb.h Fix spelling of "occurred". 2016-05-02 18:37:09 -04:00
immap_qe.h
input.h
io.h linux/io.h: add generic ioremap()/iounmap() defines 2016-07-14 18:22:26 -04:00
ioctl.h
ioport.h
kbuild.h
kconfig.h
kernel.h
linkage.h Use correct spelling of "U-Boot" 2016-02-06 12:00:59 +01:00
linux_string.h
list_sort.h
list.h list: Add list_last_entry() to find the last entry 2016-10-11 11:55:33 +08:00
log2.h
lzo.h
math64.h
mbus.h
mc146818rtc.h
mdio.h
mii.h
netdevice.h
poison.h
posix_types.h
psci.h
rbtree_augmented.h
rbtree.h
screen_info.h
serial_reg.h
sizes.h
stat.h xtensa: add support for the xtensa processor architecture [1/2] 2016-08-15 18:46:38 -04:00
stddef.h
string.h Remove unneeded remnants of bcopy(). 2016-06-06 13:39:18 -04:00
stringify.h
time.h
types.h types.h: move and redefine resource_size_t 2016-07-14 18:22:24 -04:00