summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/bt8xx/bttv-cards.c
diff options
context:
space:
mode:
Diffstat (limited to 'linux/drivers/media/video/bt8xx/bttv-cards.c')
-rw-r--r--linux/drivers/media/video/bt8xx/bttv-cards.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/linux/drivers/media/video/bt8xx/bttv-cards.c b/linux/drivers/media/video/bt8xx/bttv-cards.c
index aed55398d..6868de9bd 100644
--- a/linux/drivers/media/video/bt8xx/bttv-cards.c
+++ b/linux/drivers/media/video/bt8xx/bttv-cards.c
@@ -3744,7 +3744,11 @@ static void __devinit osprey_eeprom(struct bttv *btv, const u8 ee[256])
unsigned short type;
for (i = 4*16; i < 8*16; i += 16) {
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 20)
+ u16 checksum = ip_compute_csum((unsigned char *)(ee + i), 16);
+#else
u16 checksum = ip_compute_csum(ee + i, 16);
+#endif
if ((checksum&0xff) + (checksum>>8) == 0xff)
break;