1. 23 3月, 2011 1 次提交
    • J
      [media] rc: interim support for 32-bit NEC-ish scancodes · 4be22b6a
      Jarod Wilson 提交于
      The Apple and TiVo remotes I've got use an NEC-ish protocol, but rather
      than a command/not_command pair, they have what appear to be vendor ID
      bytes. This change makes the NEC decoder warn if the command/not_command
      checksum fails, but then passes along a full 32-bit scancode for keymap
      lookup. This change should make no difference for existing keymaps,
      since they simply won't have 32-bit scancodes, but allows for a 32-bit
      keymap. At the moment, that'll have to be uploaded by the user, but I've
      got Apple and TiVo remote keymaps forthcoming.
      
      In the long run (2.6.40, hopefully), we should probably just always use
      all 32 bits for all NEC keymaps, but this should get us by for 2.6.39.
      
      (Note that a few of the TiVo keys actuallly *do* pass the command
      checksum, so for now, the keymap for this remote will have to be a mix
      of 24-bit and 32-bit scancodes, but so be it).
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      4be22b6a
  2. 31 12月, 2010 1 次提交
    • M
      [media] ir-nec-decoder: fix repeat key issue · 21d33014
      Mariusz Białończyk 提交于
      Fixing the problem with NEC protocol and repeating keys under the following
      circumstances. The problem occurs when there is a repeat code without
      properly decoded scancode. This leads to repeat the wrong (last decoded)
      scancode.
      
      An example from real life:
      I am pressing volume down, then several minutes later i am pressing
      volume up, but the real scancode is wrongly decoded and only a repeat
      event is emitted, so as a result volume is going down while i am holding
      volume up button.
      
      The patch fixes above problem using rc_keyup timeout (as pointed by Mauro).
      It just prevents key repeats if they appear after rc_keyup.
      Signed-off-by: NMariusz Białończyk <manio@skyboo.net>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      21d33014
  3. 29 12月, 2010 5 次提交
  4. 21 10月, 2010 1 次提交
  5. 09 8月, 2010 2 次提交
  6. 03 8月, 2010 3 次提交
    • D
      V4L/DVB: ir-core: move decoding state to ir_raw_event_ctrl · c216369e
      David Härdeman 提交于
      This patch moves the state from each raw decoder into the
      ir_raw_event_ctrl struct.
      
      This allows the removal of code like this:
      
              spin_lock(&decoder_lock);
              list_for_each_entry(data, &decoder_list, list) {
                      if (data->ir_dev == ir_dev)
                              break;
              }
              spin_unlock(&decoder_lock);
              return data;
      
      which is currently run for each decoder on each event in order
      to get the client-specific decoding state data.
      
      In addition, ir decoding modules and ir driver module load
      order is now independent. Centralizing the data also allows
      for a nice code reduction of about 30% per raw decoder as
      client lists and client registration callbacks are no longer
      necessary (but still kept around for the benefit of the lirc
      decoder).
      
      Out-of-tree modules can still use a similar trick to what
      the raw decoders did before this patch until they are merged.
      Signed-off-by: NDavid Härdeman <david@hardeman.nu>
      Acked-by: NJarod Wilson <jarod@redhat.com>
      Tested-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      c216369e
    • D
      V4L/DVB: ir-core: centralize sysfs raw decoder enabling/disabling · 667c9ebe
      David Härdeman 提交于
      With the current logic, each raw decoder needs to add a copy of the exact
      same sysfs code. This is both unnecessary and also means that (re)loading
      an IR driver after raw decoder modules have been loaded won't work as
      expected.
      
      This patch moves that logic into ir-raw-event and adds a single sysfs
      file per device.
      
      Reading that file returns something like:
      
      	"rc5 [rc6] nec jvc [sony]"
      
      (with enabled protocols in [] brackets)
      
      Writing either "+protocol" or "-protocol" to that file will
      enable or disable the according protocol decoder.
      
      An additional benefit is that the disabling of a decoder will be
      remembered across module removal/insertion so a previously
      disabled decoder won't suddenly be activated again. The default
      setting is to enable all decoders.
      
      This is also necessary for the next patch which moves even more decoder
      state into the central raw decoding structs.
      Signed-off-by: NDavid Härdeman <david@hardeman.nu>
      Acked-by: NJarod Wilson <jarod@redhat.com>
      Tested-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      667c9ebe
    • J
      V4L/DVB: IR: only initially registers protocol that matches loaded keymap · 7366646e
      Jarod Wilson 提交于
      Rather than registering all IR protocol decoders as enabled when bringing
      up a new device, only enable the IR protocol decoder that matches the
      keymap being loaded. Additional decoders can be enabled on the fly by
      those that need to, either by twiddling sysfs bits or by using the
      ir-keytable util from v4l-utils.
      
      Functional testing done with the mceusb driver, and it behaves as expected,
      only the rc6 decoder is enabled, keys are all handled properly, etc.
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      7366646e
  7. 19 5月, 2010 10 次提交
  8. 18 5月, 2010 6 次提交