20 Aug, 2017

2 commits

  • RC_TYPE is confusing and it's just the protocol. So rename it.

    Suggested-by: Hans Verkuil
    Signed-off-by: Sean Young
    Acked-by: Hans Verkuil
    Signed-off-by: Mauro Carvalho Chehab

    Sean Young
     
  • When an ir-spi is registered, you get this message.

    rc rc0: Unspecified device as /devices/platform/soc/3f215080.spi/spi_master/spi32766/spi32766.128/rc/rc0

    "Unspecified device" refers to input_name, which makes no sense for IR
    TX only devices. So, rename to device_name.

    Also make driver_name const char* so that no casts are needed anywhere.

    Now ir-spi reports:

    rc rc0: IR SPI as /devices/platform/soc/3f215080.spi/spi_master/spi32766/spi32766.128/rc/rc0

    Signed-off-by: Sean Young
    Signed-off-by: Mauro Carvalho Chehab

    Sean Young
     

30 Jan, 2017

2 commits

  • The driver type can be assigned immediately when an RC device
    requests to the framework to allocate the device.

    This is an 'enum rc_driver_type' data type and specifies whether
    the device is a raw receiver or scancode receiver. The type will
    be given as parameter to the rc_allocate_device device.

    Change accordingly all the drivers calling rc_allocate_device()
    so that the device type is specified during the rc device
    allocation. Whenever the device type is not specified, it will be
    set as RC_DRIVER_SCANCODE which was the default '0' value.

    Suggested-by: Sean Young
    Signed-off-by: Andi Shyti
    Signed-off-by: Sean Young
    Signed-off-by: Mauro Carvalho Chehab

    Andi Shyti
     
  • unknown and other are for IR protocols for which we have no decoder,
    so the raw IR drivers have no chance of generating them. cec is not
    an IR protocol.

    Signed-off-by: Sean Young
    Cc: Jiri Kosina
    Cc: Benjamin Tissoires
    Cc: Bruno Prémont
    Signed-off-by: Mauro Carvalho Chehab

    Sean Young
     

29 Jun, 2015

1 commit


26 Jul, 2014

1 commit

  • The basic API of rc-core used to be:

    dev = rc_allocate_device();
    dev->x = a;
    dev->y = b;
    dev->z = c;
    rc_register_device();

    which is a pretty common pattern in the kernel, after the introduction of
    protocol arrays the API looks something like:

    dev = rc_allocate_device();
    dev->x = a;
    rc_set_allowed_protocols(dev, RC_BIT_X);
    dev->z = c;
    rc_register_device();

    There's no real need for the protocols to be an array, so change it
    back to be consistent (and in preparation for the following patches).

    [m.chehab@samsung.com: added missing changes at some files]
    Signed-off-by: David Härdeman
    Signed-off-by: Mauro Carvalho Chehab

    David Härdeman
     

12 Mar, 2014

1 commit

  • The allowed and enabled protocol masks need to be expanded to be per
    filter type in order to support wakeup filter protocol selection. To
    ease that process abstract access to the rc_dev::allowed_protos and
    rc_dev::enabled_protocols members with inline functions.

    Signed-off-by: James Hogan
    Reviewed-by: Antti Seppälä
    Signed-off-by: Mauro Carvalho Chehab

    James Hogan
     

02 Sep, 2013

1 commit

  • When picolcd is switched into bootloader mode (for FW flashing) make
    sure not to try to dereference NULL-pointers of feature-devices during
    unplug/unbind.

    This fixes following BUG:
    BUG: unable to handle kernel NULL pointer dereference at 00000298
    IP: [] picolcd_exit_framebuffer+0x1b/0x80 [hid_picolcd]
    *pde = 00000000
    Oops: 0000 [#1]
    Modules linked in: hid_picolcd syscopyarea sysfillrect sysimgblt fb_sys_fops
    CPU: 0 PID: 15 Comm: khubd Not tainted 3.11.0-rc7-00002-g50d62d4 #2
    EIP: 0060:[] EFLAGS: 00010292 CPU: 0
    EIP is at picolcd_exit_framebuffer+0x1b/0x80 [hid_picolcd]
    Call Trace:
    [] picolcd_remove+0xcb/0x120 [hid_picolcd]
    [] hid_device_remove+0x59/0xc0
    [] __device_release_driver+0x5a/0xb0
    [] device_release_driver+0x1f/0x30
    [] bus_remove_device+0x9d/0xd0
    [] device_del+0xd5/0x150
    [] hid_destroy_device+0x24/0x60
    [] usbhid_disconnect+0x1b/0x40
    ...

    Signed-off-by: Bruno Prémont
    Cc: stable@kernel.org
    Signed-off-by: Jiri Kosina

    Bruno Prémont
     

25 Feb, 2013

1 commit

  • This allows the hid drivers to be independent from the transport layer.

    The patch was constructed by replacing all occurences of
    usbhid_submit_report() by its hid_hw_request() counterpart.
    Then, drivers not requiring USB_HID anymore have their USB_HID
    dependency cleaned in the Kconfig file.

    Finally, few drivers still depends on USB_HID. Many of them
    are requiring the io wait callback. They are found in the next patch.

    Signed-off-by: Benjamin Tissoires
    Reviewed-by: Mika Westerberg

    For the sensor-hub part:
    Tested-by: Mika Westerberg
    Signed-off-by: Jiri Kosina

    Benjamin Tissoires
     

01 Nov, 2012

1 commit

  • Commit c003ab1bedf0 ("[media] rc-core: add separate defines for
    protocol bitmaps and numbers") overlooked hid-picolcd.
    This patch (against git.linuxtv.org/media_tree.git, branch
    staging/for_v3.8) fixes the compilation breakage.

    Signed-off-by: David Härdeman
    Signed-off-by: Mauro Carvalho Chehab

    David Härdeman
     

09 Sep, 2012

1 commit

  • Smatch complains that the NULL checking in this function is not
    consistent and could lead to a NULL dereference. The comments say that
    we should return here if rc_dev is NULL so I've changed the test to
    match the comment.

    Signed-off-by: Dan Carpenter
    Reviewed-by: Bruno Prémont
    Signed-off-by: Jiri Kosina

    Dan Carpenter
     

05 Sep, 2012

1 commit


15 Aug, 2012

1 commit