1. 14 12月, 2017 2 次提交
  2. 11 12月, 2017 1 次提交
  3. 05 10月, 2017 1 次提交
  4. 20 8月, 2017 3 次提交
  5. 14 6月, 2017 1 次提交
  6. 24 3月, 2017 1 次提交
  7. 30 1月, 2017 5 次提交
  8. 25 1月, 2016 1 次提交
    • H
      [media] media: rc: raw: improve FIFO handling · 464254e5
      Heiner Kallweit 提交于
      The FIFO is used for ir_raw_event records, however for some historic
      reason the FIFO is used on a per byte basis. IMHO this adds unneeded
      complexity. Therefore set up the FIFO for ir_raw_event records.
      
      This also allows to define the FIFO statically as part of
      ir_raw_event_ctrl instead of having to allocate the FIFO dynamically.
      In addition:
      
      - When writing into the FIFO and it's full return ENOSPC instead of
        ENOMEM thus making it easier to tell between "FIFO full" and
        "Dynamic memory allocation failed" when the error is propagated to
        a higher level.
        Also add an error message.
      
      - When reading from the FIFO check whether it's empty.
        This is not strictly needed here but kfifo_out is annotated
        "must check" anyway.
      
      Successfully tested it with the nuvoton-cir driver.
      Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@osg.samsung.com>
      464254e5
  9. 04 12月, 2015 1 次提交
  10. 19 11月, 2015 1 次提交
  11. 19 8月, 2015 3 次提交
  12. 15 5月, 2015 3 次提交
  13. 27 7月, 2014 1 次提交
  14. 26 7月, 2014 1 次提交
  15. 07 2月, 2014 1 次提交
  16. 06 2月, 2014 1 次提交
  17. 05 2月, 2014 1 次提交
  18. 23 3月, 2013 1 次提交
  19. 28 12月, 2012 1 次提交
  20. 08 3月, 2012 1 次提交
    • J
      [media] rc/ir-raw: use kfifo_rec_ptr_1 instead of kfifo · df1caa58
      James Hogan 提交于
      Raw IR events are passed to the raw event thread through a kfifo. The
      size of the event struct is 12 bytes, and space for 512 events is
      reserved in the kfifo (6144 bytes), however this is rounded down to 4096
      bytes (the next power of 2) by __kfifo_alloc().
      
      4096 bytes is not divisible by 12 therefore if the fifo fills up a third
      of a record will be written in the end of the kfifo by
      ir_raw_event_store() because the recsize of the fifo is 0 (it doesn't
      have records). When this is read by ir_raw_event_thread() a corrupted or
      partial record will be read, and in the case of a partial record the
      BUG_ON(retval != sizeof(ev)) gets hit too.
      
      According to samples/kfifo/record-example.c struct kfifo_rec_ptr_1 can
      handle records of a length between 0 and 255 bytes, so change struct
      ir_raw_event_ctrl to use that instead of struct kfifo.
      Signed-off-by: NJames Hogan <james.hogan@imgtec.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      df1caa58
  21. 24 11月, 2011 1 次提交
  22. 24 9月, 2011 1 次提交
    • P
      [media] media, rc: Use static inline functions to kill warnings · 600836cc
      Pekka Enberg 提交于
      This patch converts some ifdef'd wrapper functions from macros to static inline
      functions to kill the following warnings issued by GCC:
      
          CC [M]  drivers/media/rc/ir-raw.o
        drivers/media/rc/ir-raw.c: In function ‘init_decoders’:
        drivers/media/rc/ir-raw.c:353:2: warning: statement with no effect [-Wunused-value]
        drivers/media/rc/ir-raw.c:354:2: warning: statement with no effect [-Wunused-value]
        drivers/media/rc/ir-raw.c:355:2: warning: statement with no effect [-Wunused-value]
        drivers/media/rc/ir-raw.c:356:2: warning: statement with no effect [-Wunused-value]
        drivers/media/rc/ir-raw.c:357:2: warning: statement with no effect [-Wunused-value]
        drivers/media/rc/ir-raw.c:359:2: warning: statement with no effect [-Wunused-value]
      
      Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
      Cc: "David Härdeman" <david@hardeman.nu>
      Cc: Jarod Wilson <jarod@redhat.com>
      Cc: <linux-media@vger.kernel.org>
      Signed-off-by: NPekka Enberg <penberg@kernel.org>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      600836cc
  23. 28 7月, 2011 1 次提交
    • J
      [media] rc-core support for Microsoft IR keyboard/mouse · f5f2cc64
      Jarod Wilson 提交于
      This is a custom IR protocol decoder, for the RC-6-ish protocol used by
      the Microsoft Remote Keyboard, apparently developed internally at
      Microsoft, and officially dubbed MCIR-2, per their March 2011 remote and
      transceiver requirements and specifications document, which also touches
      on this IR keyboard/mouse device.
      
      Its a standard keyboard with embedded thumb stick mouse pointer and
      mouse buttons, along with a number of media keys. The media keys are
      standard RC-6, identical to the signals from the stock MCE remotes, and
      will be handled as such. The keyboard and mouse signals will be decoded
      and delivered to the system by an input device registered specifically
      by this driver.
      
      Successfully tested with multiple mceusb-driven transceivers, as well as
      with fintek-cir and redrat3 hardware. Essentially, any raw IR hardware
      with enough sampling resolution should be able to use this decoder,
      nothing about it is at all receiver-hardware-specific.
      
      This work is inspired by lirc_mod_mce:
      
      The documentation there and code aided in understanding and decoding the
      protocol, but the bulk of the code is actually borrowed more from the
      existing in-kernel decoders than anything. I did recycle the keyboard
      keycode table, a few defines, and some of the keyboard and mouse data
      parsing bits from lirc_mod_mce though.
      
      Special thanks to James Meyer for providing the hardware, and being
      patient with me as I took forever to get around to writing this.
      
      callback routine to ensure we don't get any stuck keys, and used
      symbolic names for the keytable. Also cc'ing Florian this time, who I
      believe is the original mod-mce author...
      
      CC: Florian Demski <fdemski@users.sourceforge.net>
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      f5f2cc64
  24. 29 12月, 2010 6 次提交