aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2011-07-28md/raid1: Handle write errors by updating badblock log.NeilBrown2-24/+147
When we get a write error (in the data area, not in metadata), update the badblock log rather than failing the whole device. As the write may well be many blocks, we trying writing each block individually and only log the ones which fail. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-28md/raid1: store behind-write pages in bi_vecs.NeilBrown2-17/+18
When performing write-behind we allocate pages to store the data during write. Previously we just keep a list of pages. Now we keep a list of bi_vec which includes offset and size. This means that the r1bio has complete information to create a new bio which will be needed for retrying after write errors. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-28md/raid1: clear bad-block record when write succeeds.NeilBrown2-12/+80
If we succeed in writing to a block that was recorded as being bad, we clear the bad-block record. This requires some delayed handling as the bad-block-list update has to happen in process-context. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-28md/raid1: avoid writing to known-bad blocks on known-bad drives.NeilBrown1-38/+115
If we have seen any write error on a drive, then don't write to any known-bad blocks on that drive. If necessary, we divide the write request up into pieces just like we do for reads, so each piece is either all written or all not written to any given drive. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-28md: update documentation for md/rdev/state sysfs interfaceNamhyung Kim1-5/+9
Previous patches in the bad block series extended behavior of rdev's 'state' interface but lacked documentation update. Fix it. Signed-off-by: Namhyung Kim <[email protected]> Signed-off-by: NeilBrown <[email protected]>
2011-07-28md: make it easier to wait for bad blocks to be acknowledged.NeilBrown5-27/+85
It is only safe to choose not to write to a bad block if that bad block is safely recorded in metadata - i.e. if it has been 'acknowledged'. If it hasn't we need to wait for the acknowledgement. We support that using rdev->blocked wait and md_wait_for_blocked_rdev by introducing a new device flag 'BlockedBadBlock'. This flag is only advisory. It is cleared whenever we acknowledge a bad block, so that a waiter can re-check the particular bad blocks that it is interested it. It should be set by a caller when they find they need to wait. This (set after test) is inherently racy, but as md_wait_for_blocked_rdev already has a timeout, losing the race will have minimal impact. When we clear "Blocked" was also clear "BlockedBadBlocks" incase it was set incorrectly (see above race). We also modify the way we manage 'Blocked' to fit better with the new handling of 'BlockedBadBlocks' and to make it consistent between externally managed and internally managed metadata. This requires that each raidXd loop checks if the metadata needs to be written and triggers a write (md_check_recovery) if needed. Otherwise a queued write request might cause raidXd to wait for the metadata to write, and only that thread can write it. Before writing metadata, we set FaultRecorded for all devices that are Faulty, then after writing the metadata we clear Blocked for any device for which the Fault was certainly Recorded. The 'faulty' device flag now appears in sysfs if the device is faulty *or* it has unacknowledged bad blocks. So user-space which does not understand bad blocks can continue to function correctly. User space which does, should not assume a device is faulty until it sees the 'faulty' flag, and then sees the list of unacknowledged bad blocks is empty. Signed-off-by: NeilBrown <[email protected]>
2011-07-28md: add 'write_error' flag to component devices.NeilBrown2-0/+15
If a device has ever seen a write error, we will want to handle known-bad-blocks differently. So create an appropriate state flag and export it via sysfs. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-28md/raid1: avoid reading known bad blocks during resyncNeilBrown1-22/+75
When performing resync/etc, keep the size of the request small enough that it doesn't overlap any known bad blocks. Devices with badblocks at the start of the request are completely excluded. If there is nowhere to read from due to bad blocks, record a bad block on each target device. Now that we never read from known-bad-blocks we can allow devices with known-bad-blocks into a RAID1. Signed-off-by: NeilBrown <[email protected]>
2011-07-28md/raid1: avoid reading from known bad blocks.NeilBrown4-29/+233
Now that we have a bad block list, we should not read from those blocks. There are several main parts to this: 1/ read_balance needs to check for bad blocks, and return not only the chosen device, but also how many good blocks are available there. 2/ fix_read_error needs to avoid trying to read from bad blocks. 3/ read submission must be ready to issue multiple reads to different devices as different bad blocks on different devices could mean that a single large read cannot be served by any one device, but can still be served by the array. This requires keeping count of the number of outstanding requests per bio. This count is stored in 'bi_phys_segments' 4/ retrying a read needs to also be ready to submit a smaller read and queue another request for the rest. This does not yet handle bad blocks when reading to perform resync, recovery, or check. 'md_trim_bio' will also be used for RAID10, so put it in md.c and export it. Signed-off-by: NeilBrown <[email protected]>
2011-07-28md: Disable bad blocks and v0.90 metadata.NeilBrown1-0/+4
v0.90 metadata cannot record bad blocks, so when loading metadata for such a device, set shift to -1. Signed-off-by: NeilBrown <[email protected]>
2011-07-28md: load/store badblock list from v1.x metadataNeilBrown3-11/+116
Space must have been allocated when array was created. A feature flag is set when the badblock list is non-empty, to ensure old kernels don't load and trust the whole device. We only update the on-disk badblocklist when it has changed. If the badblocklist (or other metadata) is stored on a bad block, we don't cope very well. If metadata has no room for bad block, flag bad-blocks as disabled, and do the same for 0.90 metadata. Signed-off-by: NeilBrown <[email protected]>
2011-07-28md: don't allow arrays to contain devices with bad blocks.NeilBrown3-0/+22
As no personality understand bad block lists yet, we must reject any device that is known to contain bad blocks. As the personalities get taught, these tests can be removed. This only applies to raid1/raid5/raid10. For linear/raid0/multipath/faulty the whole concept of bad blocks doesn't mean anything so there is no point adding the checks. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-28md: add documentation for bad block logNamhyung Kim1-1/+14
Previous patch in the bad block series added new sysfs interfaces ([unacknowledged_]bad_blocks) for each rdev without documentation. Add it. Signed-off-by: Namhyung Kim <[email protected]> Signed-off-by: NeilBrown <[email protected]>
2011-07-28md/bad-block-log: add sysfs interface for accessing bad-block-log.NeilBrown1-0/+123
This can show the log (providing it fits in one page) and allows bad blocks to be 'acknowledged' meaning that they have safely been recorded in metadata. Clearing bad blocks is not allowed via sysfs (except for code testing). A bad block can only be cleared when a write to the block succeeds. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-28md: beginnings of bad block management.NeilBrown2-4/+459
This the first step in allowing md to track bad-blocks per-device so that we can fail individual blocks rather than the whole device. This patch just adds a data structure for recording bad blocks, with routines to add, remove, search the list. Signed-off-by: NeilBrown <[email protected]> Reviewed-by: Namhyung Kim <[email protected]>
2011-07-27Merge branch 'for-linus' of ↵Linus Torvalds23-1010/+965
git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable: Btrfs: make sure reserve_metadata_bytes doesn't leak out strange errors Btrfs: use the commit_root for reading free_space_inode crcs Btrfs: reduce extent_state lock contention for metadata Btrfs: remove lockdep magic from btrfs_next_leaf Btrfs: make a lockdep class for each root Btrfs: switch the btrfs tree locks to reader/writer Btrfs: fix deadlock when throttling transactions Btrfs: stop using highmem for extent_buffers Btrfs: fix BUG_ON() caused by ENOSPC when relocating space Btrfs: tag pages for writeback in sync Btrfs: fix enospc problems with delalloc Btrfs: don't flush delalloc arbitrarily Btrfs: use find_or_create_page instead of grab_cache_page Btrfs: use a worker thread to do caching Btrfs: fix how we merge extent states and deal with cached states Btrfs: use the normal checksumming infrastructure for free space cache Btrfs: serialize flushers in reserve_metadata_bytes Btrfs: do transaction space reservation before joining the transaction Btrfs: try to only do one btrfs_search_slot in do_setxattr
2011-07-28md: remove suspicious size_of()NeilBrown1-1/+2
When calling bioset_create we pass the size of the front_pad as sizeof(mddev) which looks suspicious as mddev is a pointer and so it looks like a common mistake where sizeof(*mddev) was intended. The size is actually correct as we want to store a pointer in the front padding of the bios created by the bioset, so make the intent more explicit by using sizeof(mddev_t *) Reported-by: Zdenek Kabelac <[email protected]> Signed-off-by: NeilBrown <[email protected]>
2011-07-27[media] v4l: mt9v032: Fix Bayer patternLaurent Pinchart1-10/+10
Compute crop rectangle boundaries to ensure a GRBG Bayer pattern. Signed-off-by: Laurent Pinchart <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: mt9m111: rewrite set_pixfmtMichael Grzeschik1-106/+69
added new bit offset defines, more supported BE colour formats and also support BGR565 swapped pixel formats removed pixfmt helper functions and option flags setting the configuration register directly in set_pixfmt added reg_mask function reg_mask is basically the same as clearing & setting registers, but it is more convenient and faster (saves one rw cycle). Signed-off-by: Michael Grzeschik <[email protected]> Signed-off-by: Philipp Wiesner <[email protected]> Acked-by: Robert Jarzmik <[email protected]> [[email protected]: remove Bayer swap, forward-port, rename macros] Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: mt9m111: fix missing return value check mt9m111_reg_clearMichael Grzeschik1-1/+3
Signed-off-by: Michael Grzeschik <[email protected]> Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: initial driver for ov5642 CMOS sensorBastian Hecht4-0/+1019
This is an initial driver release for the Omnivision 5642 CMOS sensor. Signed-off-by: Bastian Hecht <[email protected]> Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: sh_mobile_ceu_camera: fix Oops when USERPTR mapping failsGuennadi Liakhovetski1-2/+6
If vb2_dma_contig_get_userptr() fails on a videobuffer, driver's .buf_init() method will not be called and the list will not be initialised. Trying to remove an uninitialised element from a list leads to a NULL-dereference. Signed-off-by: Guennadi Liakhovetski <[email protected]> Tested-by: Bastian Hecht <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: soc-camera: remove soc-camera bus and devices on itGuennadi Liakhovetski24-462/+337
Now that v4l2 subdevices have got their own device objects, having one more device in soc-camera clients became redundant and confusing. This patch removes those devices and the soc-camera bus, they used to reside on. Signed-off-by: Guennadi Liakhovetski <[email protected]> Acked-by: Paul Mundt <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: soc-camera: un-export the soc-camera busGuennadi Liakhovetski2-7/+4
The soc-camera bus is now completely local again. Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: sh_mobile_csi2: switch away from using the soc-camera bus notifierGuennadi Liakhovetski5-102/+180
This moves us one more step closer to eliminating the soc-camera bus and devices on it. Besides, as a side effect, CSI-2 runtime PM on sh-mobile secomes finer grained now: we only have to power on the interface, when the device nodes are open. Signed-off-by: Guennadi Liakhovetski <[email protected]> Acked-by: Paul Mundt <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: add media bus configuration subdev operationsGuennadi Liakhovetski2-0/+73
Add media bus configuration types and two subdev operations to get supported mediabus configurations and to set a specific configuration. Subdevs can support several configurations, e.g., they can send video data on 1 or several lanes, can be configured to use a specific CSI-2 channel, in such cases subdevice drivers return bitmasks with all respective bits set. When a set-configuration operation is called, it has to specify a non-ambiguous configuration. Signed-off-by: Stanimir Varbanov <[email protected]> Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: soc-camera: group struct field initialisations togetherGuennadi Liakhovetski1-2/+1
Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: soc-camera: remove now unused soc-camera specific PM hooksGuennadi Liakhovetski2-28/+0
soc-camera host drivers shall be implementing their PM, using standard kernel methods, soc-camera specific hooks can die. Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L: pxa-camera: switch to using standard PM hooksGuennadi Liakhovetski1-8/+12
The pxa-camera driver doesn't need soc-camera specific PM callbacks, switch it to using the standard PM hooks instead. Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] NetUP Dual DVB-T/C CI RF: force card hardware revision by module paramAbylay Ospan1-0/+7
Currently available two hardware revision: 0x1 firmware filename: dvb-netup-altera-01.fw 0x4 firmware filename: dvb-netup-altera-04.fw Signed-off-by: Abylay Ospan <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] Don't OOPS if videobuf_dvb_get_frontend return NULLAbylay Ospan1-1/+1
Signed-off-by: Abylay Ospan <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] NetUP Dual DVB-T/C CI RF: load firmware according card revisionAbylay Ospan1-0/+14
Currently available two hardware revision: 0x1 firmware filename: dvb-netup-altera-01.fw 0x4 firmware filename: dvb-netup-altera-04.fw Signed-off-by: Abylay Ospan <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] omap3isp: Support configurable HS/VS polaritiesLaurent Pinchart2-2/+8
Add two fields to the ISP parallel platform data to set the HS and VS signals polarities. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Sakari Ailus <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] OMAP3: RX-51: define vdds_csib regulator supplyKalle Jokiniemi1-0/+5
The RX-51 uses the CSIb IO complex for camera operation. The board file is missing definition for the regulator supplying the CSIb complex, so this is added for better power management. Signed-off-by: Kalle Jokiniemi <[email protected]> Acked-by: Laurent Pinchart <[email protected]> Acked-by: Sakari Ailus <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] OMAP3: ISP: Add regulator control for omap34xxKalle Jokiniemi2-2/+26
The current omap3isp driver is missing regulator handling for CSIb complex in omap34xx based devices. This patch adds a mechanism for this to the omap3isp driver. Signed-off-by: Kalle Jokiniemi <[email protected]> Acked-by: Laurent Pinchart <[email protected]> Acked-by: Sakari Ailus <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4l2: OMAP: VOUT: Minor Cleanup, removing the unnecessary codeAmber Jain1-6/+0
Minor changes to remove the unused code from omap_vout driver. Signed-off-by: Amber Jain <[email protected]> Signed-off-by: Samreen <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L2: OMAP: VOUT: dma map and unmap v4l2 buffers in qbuf and dqbufAmber Jain1-2/+27
Add support to map the buffer using dma_map_single during qbuf which inturn calls cache flush and unmap the same during dqbuf. This is done to prevent the artifacts seen because of cache-coherency issues on OMAP4 Signed-off-by: Amber Jain <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L2: OMAP: VOUT: isr handling extended for DPI and HDMI interfaceAmber Jain1-7/+19
Extending the omap vout isr handling for: - HDMI interface. These are the new interfaces added to OMAP4 DSS. Signed-off-by: Amber Jain <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] OMAP_VOUT: Create separate file for VRFB related API'sarchit taneja6-372/+537
Introduce omap_vout_vrfb.c and omap_vout_vrfb.h, for all VRFB related API's, making OMAP_VOUT driver independent from VRFB. This is required for OMAP4 DSS, since OMAP4 doesn't have VRFB block. Added new enum vout_rotation_type and "rotation_type" member to omapvideo_info, this is initialized based on the arch type in omap_vout_probe. The rotation_type var is now used to choose between vrfb and non-vrfb calls. Signed-off-by: Archit Taneja <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] OMAP_VOUT: CLEANUP: Make rotation related helper functions more ↵archit taneja2-15/+15
descriptive Rename rotation_enabled() and rotate_90_or_270() to is_rotation_enabled() and is_rotation_90_or_270() to make them more descriptive. Signed-off-by: Archit Taneja <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] OMAP_VOUT: CLEANUP: Move generic functions and macros to common filesarchit taneja4-118/+119
Move the inline functions rotate_90_or_270(), rotation_enabled(), and calc_rotation() from omap_vout.c to omap_voutdef.h. Move the independent functions omap_vout_alloc_buffer() and omap_vout_free_buffer() to omap_voutlib.c. Remove extern identifier from function definitions in omap_voutlib.h Add static identifier to functions that are used locally in omap_vout.c Signed-off-by: Archit Taneja <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] OMAP2: V4L2: Remove GFP_DMA allocation as ZONE_DMA is not configured ↵Amber Jain1-2/+2
on OMAP Remove GFP_DMA from the __get_free_pages() call from omap24xxcam as ZONE_DMA is not configured on OMAP. Earlier the page allocator used to return a page from ZONE_NORMAL even when GFP_DMA is passed and CONFIG_ZONE_DMA is disabled. As a result of commit a197b59ae6e8bee56fcef37ea2482dc08414e2ac, page allocator returns null in such a scenario with a warning emitted to kernel log. Signed-off-by: Amber Jain <[email protected]> Acked-by: Sakari Ailus <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] V4L2: omap_vout: Remove GFP_DMA allocation as ZONE_DMA is not ↵Amber Jain1-1/+1
configured on OMAP Remove GFP_DMA from the __get_free_pages() call from omap_vout as ZONE_DMA is not configured on OMAP. Earlier the page allocator used to return a page from ZONE_NORMAL even when GFP_DMA is passed and CONFIG_ZONE_DMA is disabled. As a result of commit a197b59ae6e8bee56fcef37ea2482dc08414e2ac, page allocator returns null in such a scenario with a warning emitted to kernel log. Signed-off-by: Amber Jain <[email protected]> Signed-off-by: Vaibhav Hiremath <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] uvcvideo: Add FIX_BANDWIDTH quirk to HP Webcam on HP Mini 5103 netbookKirill Smelkov1-0/+9
The camera there identifies itself as being manufactured by Cheng Uei Precision Industry Co., Ltd (Foxlink), and product is titled as "HP Webcam [2 MP Fixed]". I was trying to get 2 USB video capture devices to work simultaneously, and noticed that the above mentioned webcam always requires packet size = 3072 bytes per micro frame (~= 23.4 MB/s isoc bandwidth), which is far more than enough to get standard NTSC 640x480x2x30 = ~17.6 MB/s isoc bandwidth. As there are alt interfaces with smaller MxPS T: Bus=01 Lev=01 Prnt=01 Port=03 Cnt=01 Dev#= 2 Spd=480 MxCh= 0 D: Ver= 2.00 Cls=ef(misc ) Sub=02 Prot=01 MxPS=64 #Cfgs= 1 P: Vendor=05c8 ProdID=0403 Rev= 1.06 S: Manufacturer=Foxlink S: Product=HP Webcam [2 MP Fixed] S: SerialNumber=200909240102 C:* #Ifs= 2 Cfg#= 1 Atr=80 MxPwr=500mA A: FirstIf#= 0 IfCount= 2 Cls=0e(video) Sub=03 Prot=00 I:* If#= 0 Alt= 0 #EPs= 1 Cls=0e(video) Sub=01 Prot=00 Driver=uvcvideo E: Ad=83(I) Atr=03(Int.) MxPS= 16 Ivl=4ms I:* If#= 1 Alt= 0 #EPs= 0 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo I: If#= 1 Alt= 1 #EPs= 1 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo E: Ad=81(I) Atr=05(Isoc) MxPS= 128 Ivl=125us I: If#= 1 Alt= 2 #EPs= 1 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo E: Ad=81(I) Atr=05(Isoc) MxPS= 512 Ivl=125us I: If#= 1 Alt= 3 #EPs= 1 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo E: Ad=81(I) Atr=05(Isoc) MxPS=1024 Ivl=125us I: If#= 1 Alt= 4 #EPs= 1 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo E: Ad=81(I) Atr=05(Isoc) MxPS=1536 Ivl=125us I: If#= 1 Alt= 5 #EPs= 1 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo E: Ad=81(I) Atr=05(Isoc) MxPS=2048 Ivl=125us I: If#= 1 Alt= 6 #EPs= 1 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo E: Ad=81(I) Atr=05(Isoc) MxPS=2688 Ivl=125us I: If#= 1 Alt= 7 #EPs= 1 Cls=0e(video) Sub=02 Prot=00 Driver=uvcvideo E: Ad=81(I) Atr=05(Isoc) MxPS=3072 Ivl=125us UVC_QUIRK_FIX_BANDWIDTH helps here and NTSC video can be served with MxPS=2688 i.e. 20.5 MB/s isoc bandwidth. In terms of microframe time allocation, before the quirk NTSC video required 60 usecs / microframe and 53 usecs / microframe after. Acked-by: Laurent Pinchart <[email protected]> Signed-off-by: Kirill Smelkov <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] au8522: set signal field to 100% when signal presentDevin Heitmueller1-1/+1
The signal state field in G_TUNER is typically scaled from 0-100%. Since we don't know the signal level, we really would prefer the field to contain 100% than 1/256, which in many utilities (such as v4l2-ctl) rounds to 0% even when a signal is actually present. This patch makes the behavior consistent with other drivers. Signed-off-by: Devin Heitmueller <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] cx231xx: Provide signal lock status in G_INPUTDevin Heitmueller1-1/+14
Make use of the signal state registers to properly populate the signal lock registers in the cx231xx driver. This allows applications to know whether there is a signal present even in devices which lack a tuner (since such apps typically won't call G_TUNER if no tuner is present). [[email protected]: Fix CodingStyle: don't use {} for one-line if's] Signed-off-by: Devin Heitmueller <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] cx231xx: Fix power ramping issueDevin Heitmueller1-1/+1
On platforms that have CONFIG_HZ set to 100, the power ramp time effectively ends up being 10ms. However, on those that have a higher CONFIG_HZ, the time ends up *actually* being 5ms, which doesn't allow enough time for the hardware to be fully powered up before attempting to address it via i2c. Change the constant to 10ms, which is long enough for the hardware to power up, and won't really be anymore time than it was previously on platforms with CONFIG_HZ being 100. Credit goes to Mauro Carvalho Chehab and Gerd Hoffmann who previously investigated this issue. Tested with the Hauppauge USBLive 2, with which the problem was readily reproducible after setting CONFIG_HZ to 1000. Signed-off-by: Devin Heitmueller <[email protected]> Cc: Mauro Carvalho Chehab <[email protected]> Cc: Gerd Hoffmann <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] Fix regression introduced which broke the Hauppauge USBLive 2Devin Heitmueller1-0/+1
The following patch addresses the regression introduced in the cx231xx driver which stopped the Hauppauge USBLive2 from working. Confirmed working by both myself and the user who reported the issue on the KernelLabs blog (Robert DeLuca). At some point during refactoring of the cx231xx driver, the USBLive 2 device became broken. This patch results in the device working again. Thanks to Robert DeLuca for sponsoring this work. Signed-off-by: Devin Heitmueller <[email protected]> Cc: Robert DeLuca <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] uvcvideo: Fix control mapping for devices with multiple chainsStephan Lachowsky1-2/+2
The search for matching extension units fails to take account of the current chain. In the case where you have two distinct video chains, both containing an XU with the same GUID but different unit ids, you will be unable to perform a mapping on the second chain because entity on the first chain will always be found first Fix this by only searching the current chain when performing a control mapping. This is analogous to the search used by uvc_find_control(), and is the correct behaviour. Signed-off-by: Stephan Lachowsky <[email protected]> Acked-by: Laurent Pinchart <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
2011-07-27[media] bt8xx: use pci_dev->subsystem_{vendor|device}Sergei Shtylyov1-5/+2
The driver reads PCI subsystem IDs from the PCI configuration registers while they are already stored by the PCI subsystem in the 'subsystem_{vendor|device}' fields of 'struct pci_dev'... Signed-off-by: Sergei Shtylyov <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>