1. 07 3月, 2018 1 次提交
    • T
      media: siano: Fix coherent memory allocation failure on arm64 · 564246fd
      Tomoki Sekiyama 提交于
      On some architectures such as arm64, siano chip based TV-tuner
      USB devices are not recognized correctly due to coherent memory
      allocation failure with the following error:
      
      [  663.556135] usbcore: deregistering interface driver smsusb
      [  683.624809] smsusb:smsusb_probe: board id=18, interface number 0
      [  683.633530] smsusb:smsusb_init_device: smscore_register_device(...) failed, rc -12
      [  683.641501] smsusb:smsusb_probe: Device initialized with return code -12
      [  683.652978] smsusb: probe of 1-1:1.0 failed with error -12
      
      This is caused by dma_alloc_coherent(NULL, ...) returning NULL in
      smscoreapi.c.
      
      To fix this error, allocate the buffer memory for the USB devices
      via kmalloc() and let the USB core do the DMA mapping and free.
      Signed-off-by: NTomoki Sekiyama <tomoki.sekiyama@gmail.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@s-opensource.com>
      564246fd
  2. 27 11月, 2017 1 次提交
  3. 23 9月, 2017 3 次提交
  4. 27 1月, 2017 1 次提交
    • S
      [media] media: Drop FSF's postal address from the source code files · bcb63314
      Sakari Ailus 提交于
      Drop the FSF's postal address from the source code files that typically
      contain mostly the license text. Of the 628 removed instances, 578 are
      outdated.
      
      The patch has been created with the following command without manual edits:
      
      git grep -l "675 Mass Ave\|59 Temple Place\|51 Franklin St" -- \
      	drivers/media/ include/media|while read i; do i=$i perl -e '
      open(F,"< $ENV{i}");
      $a=join("", <F>);
      $a =~ s/[ \t]*\*\n.*You should.*\n.*along with.*\n.*(\n.*USA.*$)?\n//m
      	&& $a =~ s/(^.*)Or, (point your browser to) /$1To obtain the license, $2\n$1/m;
      close(F);
      open(F, "> $ENV{i}");
      print F $a;
      close(F);'; done
      Signed-off-by: NSakari Ailus <sakari.ailus@linux.intel.com>
      bcb63314
  5. 16 2月, 2016 1 次提交
    • M
      [media] siano: firmware buffer is too small · 21cf734c
      Mauro Carvalho Chehab 提交于
      As pointed by KASAN:
      
      	BUG: KASAN: slab-out-of-bounds in memcpy+0x1d/0x40 at addr ffff880000038d8c
      	Read of size 128 by task systemd-udevd/2536
      	page:ffffea0000000800 count:1 mapcount:0 mapping:          (null) index:0x0 compound_mapcount: 0
      	flags: 0xffff8000004000(head)
      	page dumped because: kasan: bad access detected
      	CPU: 1 PID: 2536 Comm: systemd-udevd Not tainted 4.5.0-rc3+ #47
      	Hardware name:                  /NUC5i7RYB, BIOS RYBDWi35.86A.0350.2015.0812.1722 08/12/2015
      	  ffff880000038d8c ffff8803b0f1f1e8 ffffffff81933901 0000000000000080
      	  ffff8803b0f1f280 ffff8803b0f1f270 ffffffff815602c5 ffffffff8284cf93
      	  ffffffff822ddc00 0000000000000282 0000000000000001 ffff88009c7c6000
      	Call Trace:
      	  [<ffffffff81933901>] dump_stack+0x85/0xc4
      	  [<ffffffff815602c5>] kasan_report_error+0x525/0x550
      	  [<ffffffff815606e9>] kasan_report+0x39/0x40
      	  [<ffffffff8155f84d>] memcpy+0x1d/0x40
      	  [<ffffffffa120cb90>] smscore_set_device_mode+0xee0/0x2560 [smsmdtv]
      
      Such error happens at the memcpy code below:
      
      0x4bc0 is in smscore_set_device_mode (drivers/media/common/siano/smscoreapi.c:975).
      970					      sizeof(u32) + payload_size));
      971
      972			data_msg->mem_addr = mem_address;
      973			memcpy(data_msg->payload, payload, payload_size);
      974
      975			rc = smscore_sendrequest_and_wait(coredev, data_msg,
      976					data_msg->x_msg_header.msg_length,
      977					&coredev->data_download_done);
      978
      979			payload += payload_size;
      
      The problem is that the Siano driver uses a header to store the firmware,
      with requires a few more bytes than allocated.
      
      Tested with:
      	PCTV 77e (2013:0257)
      	Hauppauge WinTV MiniStick (2040:5510)
      Signed-off-by: NMauro Carvalho Chehab <mchehab@osg.samsung.com>
      21cf734c
  6. 26 2月, 2015 6 次提交
  7. 04 9月, 2014 1 次提交
  8. 17 10月, 2013 1 次提交
    • H
      [media] siano: fix sparse warnings · 1668844e
      Hans Verkuil 提交于
      drivers/media/common/siano/smsdvb-main.c:47:5: warning: symbol 'sms_to_guard_interval_table' was not declared. Should it be static?
      drivers/media/common/siano/smsdvb-main.c:54:5: warning: symbol 'sms_to_code_rate_table' was not declared. Should it be static?
      drivers/media/common/siano/smsdvb-main.c:63:5: warning: symbol 'sms_to_hierarchy_table' was not declared. Should it be static?
      drivers/media/common/siano/smsdvb-main.c:70:5: warning: symbol 'sms_to_modulation_table' was not declared. Should it be static?
      drivers/media/common/siano/smscoreapi.c:925:35: warning: cast to restricted __le32
      drivers/media/common/siano/smscoreapi.c:926:28: warning: cast to restricted __le32
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      1668844e
  9. 14 10月, 2013 1 次提交
  10. 13 6月, 2013 1 次提交
  11. 21 5月, 2013 1 次提交
  12. 05 4月, 2013 1 次提交
  13. 21 3月, 2013 21 次提交