diff options
author | David Härdeman <david@hardeman.nu> | 2011-03-30 10:20:14 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-07-27 16:52:24 -0400 |
commit | b87f2eddfaa2e74b51978f7c8671f3f4777af3fe (patch) | |
tree | a298130e87208d29407c94acfd47a537522ca5d6 /drivers/media/rc/winbond-cir.c | |
parent | 7eb75715460026c82afd20e42ee51f4b30fe4bae (diff) |
[media] rc-core: fix winbond-cir issues
The conversion of winbond-cir to use rc-core seems to have missed a
a few bits and pieces which were in my local tree. Kudos to
Juan Jesús GarcÃa de Soria Lucena <skandalfo@gmail.com> for noticing.
[mchehab@redhat.com: fix two UTF-8 violations]
Signed-off-by: David Härdeman <david@hardeman.nu>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/rc/winbond-cir.c')
-rw-r--r-- | drivers/media/rc/winbond-cir.c | 22 |
1 files changed, 6 insertions, 16 deletions
diff --git a/drivers/media/rc/winbond-cir.c b/drivers/media/rc/winbond-cir.c index 5d06b899e859..18e70d104f80 100644 --- a/drivers/media/rc/winbond-cir.c +++ b/drivers/media/rc/winbond-cir.c | |||
@@ -6,8 +6,8 @@ | |||
6 | * could probably support others (Winbond WEC102X, NatSemi, etc) | 6 | * could probably support others (Winbond WEC102X, NatSemi, etc) |
7 | * with minor modifications. | 7 | * with minor modifications. |
8 | * | 8 | * |
9 | * Original Author: David Härdeman <david@hardeman.nu> | 9 | * Original Author: David Härdeman <david@hardeman.nu> |
10 | * Copyright (C) 2009 - 2010 David Härdeman <david@hardeman.nu> | 10 | * Copyright (C) 2009 - 2011 David Härdeman <david@hardeman.nu> |
11 | * | 11 | * |
12 | * Dedicated to my daughter Matilda, without whose loving attention this | 12 | * Dedicated to my daughter Matilda, without whose loving attention this |
13 | * driver would have been finished in half the time and with a fraction | 13 | * driver would have been finished in half the time and with a fraction |
@@ -876,18 +876,8 @@ wbcir_init_hw(struct wbcir_data *data) | |||
876 | /* prescaler 1.0, tx/rx fifo lvl 16 */ | 876 | /* prescaler 1.0, tx/rx fifo lvl 16 */ |
877 | outb(0x30, data->sbase + WBCIR_REG_SP3_EXCR2); | 877 | outb(0x30, data->sbase + WBCIR_REG_SP3_EXCR2); |
878 | 878 | ||
879 | /* Set baud divisor to generate one byte per bit/cell */ | 879 | /* Set baud divisor to sample every 10 us */ |
880 | switch (protocol) { | 880 | outb(0x0F, data->sbase + WBCIR_REG_SP3_BGDL); |
881 | case IR_PROTOCOL_RC5: | ||
882 | outb(0xA7, data->sbase + WBCIR_REG_SP3_BGDL); | ||
883 | break; | ||
884 | case IR_PROTOCOL_RC6: | ||
885 | outb(0x53, data->sbase + WBCIR_REG_SP3_BGDL); | ||
886 | break; | ||
887 | case IR_PROTOCOL_NEC: | ||
888 | outb(0x69, data->sbase + WBCIR_REG_SP3_BGDL); | ||
889 | break; | ||
890 | } | ||
891 | outb(0x00, data->sbase + WBCIR_REG_SP3_BGDH); | 881 | outb(0x00, data->sbase + WBCIR_REG_SP3_BGDH); |
892 | 882 | ||
893 | /* Set CEIR mode */ | 883 | /* Set CEIR mode */ |
@@ -896,9 +886,9 @@ wbcir_init_hw(struct wbcir_data *data) | |||
896 | inb(data->sbase + WBCIR_REG_SP3_LSR); /* Clear LSR */ | 886 | inb(data->sbase + WBCIR_REG_SP3_LSR); /* Clear LSR */ |
897 | inb(data->sbase + WBCIR_REG_SP3_MSR); /* Clear MSR */ | 887 | inb(data->sbase + WBCIR_REG_SP3_MSR); /* Clear MSR */ |
898 | 888 | ||
899 | /* Disable RX demod, run-length encoding/decoding, set freq span */ | 889 | /* Disable RX demod, enable run-length enc/dec, set freq span */ |
900 | wbcir_select_bank(data, WBCIR_BANK_7); | 890 | wbcir_select_bank(data, WBCIR_BANK_7); |
901 | outb(0x10, data->sbase + WBCIR_REG_SP3_RCCFG); | 891 | outb(0x90, data->sbase + WBCIR_REG_SP3_RCCFG); |
902 | 892 | ||
903 | /* Disable timer */ | 893 | /* Disable timer */ |
904 | wbcir_select_bank(data, WBCIR_BANK_4); | 894 | wbcir_select_bank(data, WBCIR_BANK_4); |