diff options
author | Andy Walls <awalls@radix.net> | 2008-09-28 20:46:02 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-10-12 07:37:14 -0400 |
commit | d267d85101c509020a12686b96cbd179deaf4ecd (patch) | |
tree | 1a016966d11efb400ca310cd5726478053cd00a0 /drivers/media/video/cx18/cx18-av-core.c | |
parent | 7f9876785276ac7f8606f8bf53a3dae4c10b8adb (diff) |
V4L/DVB (9110): cx18: Add default behavior of checking and retrying PCI MMIO accesses
cx18: Add default behavior of checking and retrying PCI MMIO accesses.
The concept of checking and retrying PCI MMIO accesses for better reliability
in older motherboards was suggested by Steve Toth <stoth@linuxtv.org>. This
change implements MMIO retries and the retry_mmio module parameter that is
enabled by default. Limited experiments have shown this is more reliable than
the mmio_ndelay parameter. mmio_ndelay has insignificant effect with retries
enabled.
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/cx18/cx18-av-core.c')
-rw-r--r-- | drivers/media/video/cx18/cx18-av-core.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/media/video/cx18/cx18-av-core.c b/drivers/media/video/cx18/cx18-av-core.c index d8626e35465..73f5141a42d 100644 --- a/drivers/media/video/cx18/cx18-av-core.c +++ b/drivers/media/video/cx18/cx18-av-core.c | |||
@@ -42,6 +42,12 @@ int cx18_av_write4(struct cx18 *cx, u16 addr, u32 value) | |||
42 | return 0; | 42 | return 0; |
43 | } | 43 | } |
44 | 44 | ||
45 | int cx18_av_write4_noretry(struct cx18 *cx, u16 addr, u32 value) | ||
46 | { | ||
47 | cx18_write_reg_noretry(cx, value, 0xc40000 + addr); | ||
48 | return 0; | ||
49 | } | ||
50 | |||
45 | u8 cx18_av_read(struct cx18 *cx, u16 addr) | 51 | u8 cx18_av_read(struct cx18 *cx, u16 addr) |
46 | { | 52 | { |
47 | u32 x = cx18_read_reg(cx, 0xc40000 + (addr & ~3)); | 53 | u32 x = cx18_read_reg(cx, 0xc40000 + (addr & ~3)); |
@@ -55,6 +61,11 @@ u32 cx18_av_read4(struct cx18 *cx, u16 addr) | |||
55 | return cx18_read_reg(cx, 0xc40000 + addr); | 61 | return cx18_read_reg(cx, 0xc40000 + addr); |
56 | } | 62 | } |
57 | 63 | ||
64 | u32 cx18_av_read4_noretry(struct cx18 *cx, u16 addr) | ||
65 | { | ||
66 | return cx18_read_reg_noretry(cx, 0xc40000 + addr); | ||
67 | } | ||
68 | |||
58 | int cx18_av_and_or(struct cx18 *cx, u16 addr, unsigned and_mask, | 69 | int cx18_av_and_or(struct cx18 *cx, u16 addr, unsigned and_mask, |
59 | u8 or_value) | 70 | u8 or_value) |
60 | { | 71 | { |