omap4-v4l2-camera:sandusandus-omap4-v4l2-camera.git
6 years agomfd: twl6040: Add twl6040-gpio child
Sergio Aguirre [Fri, 4 May 2012 16:53:15 +0000 (11:53 -0500)]
mfd: twl6040: Add twl6040-gpio child

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agogpio: Add basic support for TWL6040 GPOs
Sergio Aguirre [Fri, 4 May 2012 16:52:39 +0000 (11:52 -0500)]
gpio: Add basic support for TWL6040 GPOs

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5650: Several resource handling fixes
Sergio Aguirre [Fri, 4 May 2012 22:16:41 +0000 (17:16 -0500)]
ov5650: Several resource handling fixes

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5640: Several resource handling fixes
Sergio Aguirre [Fri, 4 May 2012 22:16:34 +0000 (17:16 -0500)]
ov5640: Several resource handling fixes

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years ago4430sdp: camera: remove unneeded post_poweroff callback
Sergio Aguirre [Fri, 4 May 2012 19:55:07 +0000 (14:55 -0500)]
4430sdp: camera: remove unneeded post_poweroff callback

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5650: Use correct struct device and fix warning
Sergio Aguirre [Fri, 4 May 2012 15:40:37 +0000 (10:40 -0500)]
ov5650: Use correct struct device and fix warning

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5640: Use correct struct device and fix warning
Sergio Aguirre [Fri, 4 May 2012 15:39:54 +0000 (10:39 -0500)]
ov5640: Use correct struct device and fix warning

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years ago4430sdp: camera: Propagate twl_i2c_* return values
Sergio Aguirre [Fri, 4 May 2012 15:38:30 +0000 (10:38 -0500)]
4430sdp: camera: Propagate twl_i2c_* return values

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agopanda: camera: Adapt to new ov56x0 platform data
Sergio Aguirre [Fri, 4 May 2012 03:01:51 +0000 (22:01 -0500)]
panda: camera: Adapt to new ov56x0 platform data

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years ago4430sdp: camera: Adapt to new ov56x0 platform data
Sergio Aguirre [Fri, 4 May 2012 03:01:36 +0000 (22:01 -0500)]
4430sdp: camera: Adapt to new ov56x0 platform data

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5650: Implement power sequence in driver
Sergio Aguirre [Fri, 4 May 2012 02:59:38 +0000 (21:59 -0500)]
ov5650: Implement power sequence in driver

This is to keep power sequence generic and driver centric,
as well as prepare for device tree.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5640: Implement power sequence in driver
Sergio Aguirre [Fri, 4 May 2012 02:56:02 +0000 (21:56 -0500)]
ov5640: Implement power sequence in driver

This is to keep power sequence generic and driver centric,
as well as prepare for device tree.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoomap4iss: Adapt to pixel rate ctrl rename
Sergio Aguirre [Wed, 2 May 2012 13:46:20 +0000 (08:46 -0500)]
omap4iss: Adapt to pixel rate ctrl rename

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5640: Adapt to pixel rate ctrl rename
Sergio Aguirre [Wed, 2 May 2012 13:45:51 +0000 (08:45 -0500)]
ov5640: Adapt to pixel rate ctrl rename

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoov5650: Adapt to pixel rate ctrl rename
Sergio Aguirre [Wed, 2 May 2012 13:45:43 +0000 (08:45 -0500)]
ov5650: Adapt to pixel rate ctrl rename

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoomap4iss: csiphy: Fix break on cpu_is_xxxx
Sergio Aguirre [Wed, 2 May 2012 13:44:45 +0000 (08:44 -0500)]
omap4iss: csiphy: Fix break on cpu_is_xxxx

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoomap4iss: Move omap4_init_camera prototype to mach
Sergio Aguirre [Wed, 2 May 2012 13:43:03 +0000 (08:43 -0500)]
omap4iss: Move omap4_init_camera prototype to mach

It's only being used in mach-omap2 folder, so there's no point on
making it widely available to the kernel.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agov4l2-ctrls: Fix warning for missing struct file definition
Sergio Aguirre [Wed, 2 May 2012 13:41:53 +0000 (08:41 -0500)]
v4l2-ctrls: Fix warning for missing struct file definition

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoiommu/omap: Fix build error when IOMMU_API is not defined
Sergio Aguirre [Wed, 2 May 2012 13:40:09 +0000 (08:40 -0500)]
iommu/omap: Fix build error when IOMMU_API is not defined

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agorm680: camera: Add missing header for system_rev access
Sergio Aguirre [Wed, 2 May 2012 13:38:51 +0000 (08:38 -0500)]
rm680: camera: Add missing header for system_rev access

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoMerge branch 'master-fromSakari_v5' into devel
Sergio Aguirre [Wed, 2 May 2012 14:41:32 +0000 (09:41 -0500)]
Merge branch 'master-fromSakari_v5' into devel

6 years agoMerge branch 'master-CMAv24' into devel
Sergio Aguirre [Wed, 2 May 2012 14:36:54 +0000 (09:36 -0500)]
Merge branch 'master-CMAv24' into devel

6 years agoMerge commit 'v3.4-rc5' into devel
Sergio Aguirre [Wed, 2 May 2012 14:36:14 +0000 (09:36 -0500)]
Merge commit 'v3.4-rc5' into devel

Conflicts:
arch/arm/mach-omap2/devices.c
drivers/media/video/Kconfig

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoRemove all Sakari's v4l2 changes in one shot
Sergio Aguirre [Wed, 2 May 2012 14:35:10 +0000 (09:35 -0500)]
Remove all Sakari's v4l2 changes in one shot

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoARM: Samsung: use CMA for 2 memory banks for s5p-mfc device
Marek Szyprowski [Thu, 29 Dec 2011 12:09:51 +0000 (13:09 +0100)]
ARM: Samsung: use CMA for 2 memory banks for s5p-mfc device

Replace custom memory bank initialization using memblock_reserve and
dma_declare_coherent with a single call to CMA's dma_declare_contiguous.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
6 years agoARM: integrate CMA with DMA-mapping subsystem
Marek Szyprowski [Thu, 29 Dec 2011 12:09:51 +0000 (13:09 +0100)]
ARM: integrate CMA with DMA-mapping subsystem

This patch adds support for CMA to dma-mapping subsystem for ARM
architecture. By default a global CMA area is used, but specific devices
are allowed to have their private memory areas if required (they can be
created with dma_declare_contiguous() function during board
initialisation).

Contiguous memory areas reserved for DMA are remapped with 2-level page
tables on boot. Once a buffer is requested, a low memory kernel mapping
is updated to to match requested memory access type.

GFP_ATOMIC allocations are performed from special pool which is created
early during boot. This way remapping page attributes is not needed on
allocation time.

CMA has been enabled unconditionally for ARMv6+ systems.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Michal Nazarewicz <mina86@mina86.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agoX86: integrate CMA with DMA-mapping subsystem
Marek Szyprowski [Thu, 29 Dec 2011 12:09:51 +0000 (13:09 +0100)]
X86: integrate CMA with DMA-mapping subsystem

This patch adds support for CMA to dma-mapping subsystem for x86
architecture that uses common pci-dma/pci-nommu implementation. This
allows to test CMA on KVM/QEMU and a lot of common x86 boxes.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Michal Nazarewicz <mina86@mina86.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
6 years agodrivers: add Contiguous Memory Allocator
Marek Szyprowski [Thu, 29 Dec 2011 12:09:51 +0000 (13:09 +0100)]
drivers: add Contiguous Memory Allocator

The Contiguous Memory Allocator is a set of helper functions for DMA
mapping framework that improves allocations of contiguous memory chunks.

CMA grabs memory on system boot, marks it with MIGRATE_CMA migrate type
and gives back to the system. Kernel is allowed to allocate only movable
pages within CMA's managed memory so that it can be used for example for
page cache when DMA mapping do not use it. On
dma_alloc_from_contiguous() request such pages are migrated out of CMA
area to free required contiguous block and fulfill the request. This
allows to allocate large contiguous chunks of memory at any time
assuming that there is enough free memory available in the system.

This code is heavily based on earlier works by Michal Nazarewicz.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: trigger page reclaim in alloc_contig_range() to stabilise watermarks
Marek Szyprowski [Wed, 25 Jan 2012 11:49:24 +0000 (12:49 +0100)]
mm: trigger page reclaim in alloc_contig_range() to stabilise watermarks

alloc_contig_range() performs memory allocation so it also should keep
track on keeping the correct level of memory watermarks. This commit adds
a call to *_slowpath style reclaim to grab enough pages to make sure that
the final collection of contiguous pages from freelists will not starve
the system.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Michal Nazarewicz <mina86@mina86.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: extract reclaim code from __alloc_pages_direct_reclaim()
Marek Szyprowski [Wed, 25 Jan 2012 11:09:52 +0000 (12:09 +0100)]
mm: extract reclaim code from __alloc_pages_direct_reclaim()

This patch extracts common reclaim code from __alloc_pages_direct_reclaim()
function to separate function: __perform_reclaim() which can be later used
by alloc_contig_range().

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Michal Nazarewicz <mina86@mina86.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: Serialize access to min_free_kbytes
Mel Gorman [Mon, 25 Apr 2011 21:36:42 +0000 (21:36 +0000)]
mm: Serialize access to min_free_kbytes

There is a race between the min_free_kbytes sysctl, memory hotplug
and transparent hugepage support enablement.  Memory hotplug uses a
zonelists_mutex to avoid a race when building zonelists. Reuse it to
serialise watermark updates.

[a.p.zijlstra@chello.nl: Older patch fixed the race with spinlock]
Signed-off-by: Mel Gorman <mgorman@suse.de>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: page_isolation: MIGRATE_CMA isolation functions added
Michal Nazarewicz [Tue, 3 Apr 2012 13:06:15 +0000 (15:06 +0200)]
mm: page_isolation: MIGRATE_CMA isolation functions added

This commit changes various functions that change pages and
pageblocks migrate type between MIGRATE_ISOLATE and
MIGRATE_MOVABLE in such a way as to allow to work with
MIGRATE_CMA migrate type.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: mmzone: MIGRATE_CMA migration type added
Michal Nazarewicz [Thu, 29 Dec 2011 12:09:50 +0000 (13:09 +0100)]
mm: mmzone: MIGRATE_CMA migration type added

The MIGRATE_CMA migration type has two main characteristics:
(i) only movable pages can be allocated from MIGRATE_CMA
pageblocks and (ii) page allocator will never change migration
type of MIGRATE_CMA pageblocks.

This guarantees (to some degree) that page in a MIGRATE_CMA page
block can always be migrated somewhere else (unless there's no
memory left in the system).

It is designed to be used for allocating big chunks (eg. 10MiB)
of physically contiguous memory.  Once driver requests
contiguous memory, pages from MIGRATE_CMA pageblocks may be
migrated away to create a contiguous block.

To minimise number of migrations, MIGRATE_CMA migration type
is the last type tried when page allocator falls back to other
migration types when requested.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: page_alloc: change fallbacks array handling
Michal Nazarewicz [Wed, 11 Jan 2012 14:31:33 +0000 (15:31 +0100)]
mm: page_alloc: change fallbacks array handling

This commit adds a row for MIGRATE_ISOLATE type to the fallbacks array
which was missing from it.  It also, changes the array traversal logic
a little making MIGRATE_RESERVE an end marker.  The letter change,
removes the implicit MIGRATE_UNMOVABLE from the end of each row which
was read by __rmqueue_fallback() function.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: page_alloc: introduce alloc_contig_range()
Michal Nazarewicz [Thu, 29 Dec 2011 12:09:50 +0000 (13:09 +0100)]
mm: page_alloc: introduce alloc_contig_range()

This commit adds the alloc_contig_range() function which tries
to allocate given range of pages.  It tries to migrate all
already allocated pages that fall in the range thus freeing them.
Once all pages in the range are freed they are removed from the
buddy system thus allocated for the caller to use.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: compaction: export some of the functions
Michal Nazarewicz [Thu, 29 Dec 2011 12:09:50 +0000 (13:09 +0100)]
mm: compaction: export some of the functions

This commit exports some of the functions from compaction.c file
outside of it adding their declaration into internal.h header
file so that other mm related code can use them.

This forced compaction.c to always be compiled (as opposed to being
compiled only if CONFIG_COMPACTION is defined) but as to avoid
introducing code that user did not ask for, part of the compaction.c
is now wrapped in on #ifdef.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: compaction: introduce isolate_freepages_range()
Michal Nazarewicz [Mon, 30 Jan 2012 12:24:03 +0000 (13:24 +0100)]
mm: compaction: introduce isolate_freepages_range()

This commit introduces isolate_freepages_range() function which
generalises isolate_freepages_block() so that it can be used on
arbitrary PFN ranges.

isolate_freepages_block() is left with only minor changes.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: compaction: introduce map_pages()
Michal Nazarewicz [Mon, 30 Jan 2012 12:23:47 +0000 (13:23 +0100)]
mm: compaction: introduce map_pages()

This commit creates a map_pages() function which map pages freed
using split_free_pages().  This merely moves some code from
isolate_freepages() so that it can be reused in other places.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: compaction: introduce isolate_migratepages_range()
Michal Nazarewicz [Mon, 30 Jan 2012 12:16:26 +0000 (13:16 +0100)]
mm: compaction: introduce isolate_migratepages_range()

This commit introduces isolate_migratepages_range() function which
extracts functionality from isolate_migratepages() so that it can be
used on arbitrary PFN ranges.

isolate_migratepages() function is implemented as a simple wrapper
around isolate_migratepages_range().

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
6 years agomm: page_alloc: remove trailing whitespace
Michal Nazarewicz [Wed, 11 Jan 2012 14:16:11 +0000 (15:16 +0100)]
mm: page_alloc: remove trailing whitespace

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
6 years agoRemove CMA v22 in one shot
Sergio Aguirre [Wed, 2 May 2012 14:16:24 +0000 (09:16 -0500)]
Remove CMA v22 in one shot

This is for making an easier merge of newer kernel,
and avoid many conflicts.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agorm680: Add camera init
Sakari Ailus [Tue, 6 Mar 2012 16:33:16 +0000 (18:33 +0200)]
rm680: Add camera init

This currently introduces an extra file to the arch/arm/mach-omap2
directory: board-rm680-camera.c. Keeping the device tree in mind, the
context of the file could be represented as static data with one exception:
the external clock to the sensor.

This external clock is provided by the OMAP 3 SoC and required by the
sensor. The issue is that the clock originates from the ISP and not from
PRCM block as the other clocks and thus is not supported by the clock
framework. Otherwise the sensor driver could just clk_get() and clk_enable()
it, just like the regulators and gpios.

Signed-off-by: Sakari Ailus <sakari.ailus@maxwell.research.nokia.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agosmiapp: Generic SMIA++/SMIA PLL calculator
Sakari Ailus [Tue, 6 Mar 2012 16:33:15 +0000 (18:33 +0200)]
smiapp: Generic SMIA++/SMIA PLL calculator

Calculate PLL configuration based on input data: sensor configuration, board
properties and sensor-specific limits.

Signed-off-by: Sakari Ailus <sakari.ailus@maxwell.research.nokia.com>
6 years agoomap3isp: Find source pad from external entity
Sakari Ailus [Tue, 6 Mar 2012 16:33:14 +0000 (18:33 +0200)]
omap3isp: Find source pad from external entity

No longer assume pad number 0 is the source pad of the external entity. Find
the source pad from the external entity and use it instead.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agoomap3isp: Add resizer data rate configuration to resizer_link_validate
Sakari Ailus [Tue, 6 Mar 2012 16:33:13 +0000 (18:33 +0200)]
omap3isp: Add resizer data rate configuration to resizer_link_validate

The configuration of many other blocks depend on resizer maximum data rate.
Get the value from resizer at link validation time.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agoomap3isp: Configure CSI-2 phy based on platform data
Sakari Ailus [Tue, 6 Mar 2012 16:33:12 +0000 (18:33 +0200)]
omap3isp: Configure CSI-2 phy based on platform data

Configure CSI-2 phy based on platform data in the ISP driver. For that, the
new V4L2_CID_IMAGE_SOURCE_PIXEL_RATE control is used. Previously the same
was configured from the board code.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agoomap3isp: Move CCDC link validation to ccdc_link_validate()
Sakari Ailus [Tue, 6 Mar 2012 16:33:11 +0000 (18:33 +0200)]
omap3isp: Move CCDC link validation to ccdc_link_validate()

Perform CCDC link validation in ccdc_link_validate() instead of
isp_video_validate_pipeline(). Also perform maximum data rate check in
isp_video_check_external_subdevs().

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agoomap3isp: Default link validation for ccp2, csi2, preview and resizer
Sakari Ailus [Tue, 6 Mar 2012 16:33:10 +0000 (18:33 +0200)]
omap3isp: Default link validation for ccp2, csi2, preview and resizer

Use default link validation for ccp2, csi2, preview and resizer. On ccp2,
csi2 and ccdc we also collect information on external subdevs as one may be
connected to those entities.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agoomap3isp: Use external rate instead of vpcfg
Sakari Ailus [Tue, 6 Mar 2012 16:33:09 +0000 (18:33 +0200)]
omap3isp: Use external rate instead of vpcfg

Access pipe->external_rate instead of isp_ccdc.vpcfg.pixelclk. Also remove
means to set the value for isp_ccdc_vpcfg.pixelclk.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agoomap3isp: Introduce isp_video_check_external_subdevs()
Sakari Ailus [Tue, 6 Mar 2012 16:33:08 +0000 (18:33 +0200)]
omap3isp: Introduce isp_video_check_external_subdevs()

isp_video_check_external_subdevs() will retrieve external subdev's
bits-per-pixel and pixel rate for the use of other ISP subdevs at streamon
time. isp_video_check_external_subdevs() is called after pipeline
validation.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agoomap3isp: Add information on external subdev to struct isp_pipeline
Sakari Ailus [Tue, 6 Mar 2012 16:33:07 +0000 (18:33 +0200)]
omap3isp: Add information on external subdev to struct isp_pipeline

Add pointer to external subdev, pixel rate of the external subdev and bpp of
the format to struct isp_pipeline.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agoomap3isp: Collect entities that are part of the pipeline
Sakari Ailus [Tue, 6 Mar 2012 16:33:06 +0000 (18:33 +0200)]
omap3isp: Collect entities that are part of the pipeline

Collect entities which are part of the pipeline into a single bit mask.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agoomap3isp: Add lane configuration to platform data
Sakari Ailus [Tue, 6 Mar 2012 16:33:05 +0000 (18:33 +0200)]
omap3isp: Add lane configuration to platform data

Add lane configuration (order of clock and data lane) to platform data on
both CCP2 and CSI-2.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agoomap3isp: Assume media_entity_pipeline_start may fail
Sakari Ailus [Tue, 6 Mar 2012 16:33:04 +0000 (18:33 +0200)]
omap3isp: Assume media_entity_pipeline_start may fail

Since media_entity_pipeline_start() now does link validation, it may
actually fail. Perform the error handling.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agoomap3isp: Move setting constaints above media_entity_pipeline_start
Sakari Ailus [Tue, 6 Mar 2012 16:33:03 +0000 (18:33 +0200)]
omap3isp: Move setting constaints above media_entity_pipeline_start

The clock rate for l3_ick will soon be read during pipeline validation which
is now part of media_entity_pipeline_start(). For that reason we set
constraints earlier on.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agoomap3: add definition for CONTROL_CAMERA_PHY_CTRL
Sakari Ailus [Tue, 6 Mar 2012 16:33:02 +0000 (18:33 +0200)]
omap3: add definition for CONTROL_CAMERA_PHY_CTRL

This register is available only in OMAP3630.

The original patch was submitted by Vimarsh Zutshi.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agoomap3isp: Move definitions required by board code under include/media.
Sakari Ailus [Tue, 6 Mar 2012 16:33:01 +0000 (18:33 +0200)]
omap3isp: Move definitions required by board code under include/media.

XCLK definitions are often required by the board code. Move them to public
include file.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agoomap3isp: Support additional in-memory compressed bayer formats
Sakari Ailus [Tue, 6 Mar 2012 16:33:00 +0000 (18:33 +0200)]
omap3isp: Support additional in-memory compressed bayer formats

This also prevents accessing NULL pointer in csi2_try_format().

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: Allow changing control handler lock
Sakari Ailus [Tue, 6 Mar 2012 16:32:59 +0000 (18:32 +0200)]
v4l: Allow changing control handler lock

Allow choosing the lock used by the control handler. This may be handy
sometimes when a driver providing multiple subdevs does not want to use
several locks to serialise its functions.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agov4l: Implement v4l2_subdev_link_validate()
Sakari Ailus [Tue, 6 Mar 2012 16:32:58 +0000 (18:32 +0200)]
v4l: Implement v4l2_subdev_link_validate()

v4l2_subdev_link_validate() is the default op for validating a link. In V4L2
subdev context, it is used to call a pad op which performs the proper link
check without much extra work.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: Improve sub-device documentation for pad ops
Sakari Ailus [Tue, 6 Mar 2012 16:32:57 +0000 (18:32 +0200)]
v4l: Improve sub-device documentation for pad ops

Document that format related configuration is done through pad ops in case
the driver does use the media framework.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agomedia: Add link_validate() op to check links to the sink pad
Sakari Ailus [Tue, 6 Mar 2012 16:32:56 +0000 (18:32 +0200)]
media: Add link_validate() op to check links to the sink pad

The purpose of the link_validate() op is to allow an entity driver to ensure
that the properties of the pads at the both ends of the link are suitable
for starting the pipeline. link_validate is called on sink pads on active
links which belong to the active part of the graph.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: Add DPCM compressed raw bayer pixel formats
Sakari Ailus [Tue, 6 Mar 2012 16:32:55 +0000 (18:32 +0200)]
v4l: Add DPCM compressed raw bayer pixel formats

Add three other colour orders for 10-bit to 8-bit DPCM compressed raw bayer
pixel formats.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agov4l: Document raw bayer 4CC codes
Sakari Ailus [Tue, 6 Mar 2012 16:32:54 +0000 (18:32 +0200)]
v4l: Document raw bayer 4CC codes

Document guidelines how 4CC codes should be named. Only raw bayer is
included currently. Other formats should be documented later on.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agov4l: Image processing control class
Sakari Ailus [Tue, 6 Mar 2012 16:32:53 +0000 (18:32 +0200)]
v4l: Image processing control class

Add control class for image processing controls. The control class deals
with controls processing image, for example digital gain or noise filtering,
which can be present in any part of the pipeline.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agov4l: Image source control class
Sakari Ailus [Tue, 6 Mar 2012 16:32:52 +0000 (18:32 +0200)]
v4l: Image source control class

Add image source control class. This control class is intended to contain
low level controls which deal with control of the image capture process ---
the A/D converter in image sensors, for example.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agov4l: Mark VIDIOC_SUBDEV_G_CROP and VIDIOC_SUBDEV_S_CROP obsolete
Sakari Ailus [Tue, 6 Mar 2012 16:32:51 +0000 (18:32 +0200)]
v4l: Mark VIDIOC_SUBDEV_G_CROP and VIDIOC_SUBDEV_S_CROP obsolete

These two IOCTLS are obsoleted by VIDIOC_SUBDEV_G_SELECTION and
VIDIOC_SUBDEV_S_SELECTION. Mark them obsolete.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: Add subdev selections documentation
Sakari Ailus [Mon, 20 Feb 2012 01:56:48 +0000 (03:56 +0200)]
v4l: Add subdev selections documentation

Add documentation for V4L2 subdev selection API. This changes also
experimental V4L2 subdev API so that scaling now works through selection API
only.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agov4l: Add subdev selections documentation: svg and dia files
Sakari Ailus [Fri, 2 Mar 2012 17:30:16 +0000 (19:30 +0200)]
v4l: Add subdev selections documentation: svg and dia files

Add svga and dia files for V4L2 subdev selections documentation.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
6 years agov4l: Support s_crop and g_crop through s/g_selection
Sakari Ailus [Tue, 6 Mar 2012 16:32:48 +0000 (18:32 +0200)]
v4l: Support s_crop and g_crop through s/g_selection

Fall back to s_selection if s_crop isn't implemented by a driver. Same for
g_selection / g_crop.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: Check pad number in get try pointer functions
Sakari Ailus [Tue, 6 Mar 2012 16:32:47 +0000 (18:32 +0200)]
v4l: Check pad number in get try pointer functions

Unify functions to get try pointers and validate the pad number accessed by
the user.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: vdev_to_v4l2_subdev() should have return type "struct v4l2_subdev *"
Sakari Ailus [Tue, 6 Mar 2012 16:32:46 +0000 (18:32 +0200)]
v4l: vdev_to_v4l2_subdev() should have return type "struct v4l2_subdev *"

vdev_to_v4l2_subdev() should return struct v4l2_subdev *, not void *. Fix
this.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: VIDIOC_SUBDEV_S_SELECTION and VIDIOC_SUBDEV_G_SELECTION IOCTLs
Sakari Ailus [Tue, 6 Mar 2012 16:32:45 +0000 (18:32 +0200)]
v4l: VIDIOC_SUBDEV_S_SELECTION and VIDIOC_SUBDEV_G_SELECTION IOCTLs

Add support for VIDIOC_SUBDEV_S_SELECTION and VIDIOC_SUBDEV_G_SELECTION
IOCTLs. They replace functionality provided by VIDIOC_SUBDEV_S_CROP and
VIDIOC_SUBDEV_G_CROP IOCTLs and also add new functionality (composing).

VIDIOC_SUBDEV_G_CROP and VIDIOC_SUBDEV_S_CROP continue to be supported.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agovivi: Add an integer menu test control
Sakari Ailus [Tue, 6 Mar 2012 16:32:44 +0000 (18:32 +0200)]
vivi: Add an integer menu test control

Add an integer menu test control for the vivi driver.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: Document integer menu controls
Sakari Ailus [Tue, 6 Mar 2012 16:32:43 +0000 (18:32 +0200)]
v4l: Document integer menu controls

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6 years agov4l: Introduce integer menu controls
Sakari Ailus [Tue, 6 Mar 2012 16:32:42 +0000 (18:32 +0200)]
v4l: Introduce integer menu controls

Create a new control type called V4L2_CTRL_TYPE_INTEGER_MENU. Integer menu
controls are just like menu controls but the menu items are 64-bit integers
rather than strings.

Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Tested-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
6 years agoov5640: Swap order of scale and clock dividers
Sergio Aguirre [Tue, 1 May 2012 13:33:34 +0000 (08:33 -0500)]
ov5640: Swap order of scale and clock dividers

That seem to make an impact on the receiver side, which
was detecting a bad CSI PHY transition on the datalane before.

This makes it dissappear.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoomap4iss: clear error when pipeline propagation is done
Sergio Aguirre [Tue, 1 May 2012 02:57:56 +0000 (21:57 -0500)]
omap4iss: clear error when pipeline propagation is done

Whenever there's an error in one buffer, the pipeline state
should have been cleared once the propagation to the vb2 buffer
status is passed.

Set pipe->error = false now.

Reported-by: Rob Clark <rob@ti.com>
Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoomap4iss: Fix wrong usr_def_mapping rationale
Sergio Aguirre [Mon, 30 Apr 2012 02:28:19 +0000 (21:28 -0500)]
omap4iss: Fix wrong usr_def_mapping rationale

There are other formats that are valid for a mask of 0x40,
but not necessarily a user defined mapping.

For example, 0xDE, which is YUV422 8b + VP, sent in 16-bit group.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoLinux 3.4-rc5 master
Linus Torvalds [Sun, 29 Apr 2012 22:19:10 +0000 (15:19 -0700)]
Linux 3.4-rc5

6 years agoMerge tag 'pm-for-3.4-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael...
Linus Torvalds [Sun, 29 Apr 2012 22:00:44 +0000 (15:00 -0700)]
Merge tag 'pm-for-3.4-rc5' of git://git./linux/kernel/git/rafael/linux-pm

Pull power management fixes from Rafael J. Wysocki:
 "Fix for an issue causing hibernation to hang on systems with highmem
  (that practically means i386) due to broken memory management (bug
  introduced in 3.2, so -stable material) and PM documentation update
  making the freezer documentation follow the code again after some
  recent updates."

* tag 'pm-for-3.4-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  PM / Freezer / Docs: Update documentation about freezing of tasks
  PM / Hibernate: fix the number of pages used for hibernate/thaw buffering

6 years agoautofs: make the autofsv5 packet file descriptor use a packetized pipe
Linus Torvalds [Sun, 29 Apr 2012 20:30:08 +0000 (13:30 -0700)]
autofs: make the autofsv5 packet file descriptor use a packetized pipe

The autofs packet size has had a very unfortunate size problem on x86:
because the alignment of 'u64' differs in 32-bit and 64-bit modes, and
because the packet data was not 8-byte aligned, the size of the autofsv5
packet structure differed between 32-bit and 64-bit modes despite
looking otherwise identical (300 vs 304 bytes respectively).

We first fixed that up by making the 64-bit compat mode know about this
problem in commit a32744d4abae ("autofs: work around unhappy compat
problem on x86-64"), and that made a 32-bit 'systemd' work happily on a
64-bit kernel because everything then worked the same way as on a 32-bit
kernel.

But it turned out that 'automount' had actually known and worked around
this problem in user space, so fixing the kernel to do the proper 32-bit
compatibility handling actually *broke* 32-bit automount on a 64-bit
kernel, because it knew that the packet sizes were wrong and expected
those incorrect sizes.

As a result, we ended up reverting that compatibility mode fix, and
thus breaking systemd again, in commit fcbf94b9dedd.

With both automount and systemd doing a single read() system call, and
verifying that they get *exactly* the size they expect but using
different sizes, it seemed that fixing one of them inevitably seemed to
break the other.  At one point, a patch I seriously considered applying
from Michael Tokarev did a "strcmp()" to see if it was automount that
was doing the operation.  Ugly, ugly.

However, a prettier solution exists now thanks to the packetized pipe
mode.  By marking the communication pipe as being packetized (by simply
setting the O_DIRECT flag), we can always just write the bigger packet
size, and if user-space does a smaller read, it will just get that
partial end result and the extra alignment padding will simply be thrown
away.

This makes both automount and systemd happy, since they now get the size
they asked for, and the kernel side of autofs simply no longer needs to
care - it could pad out the packet arbitrarily.

Of course, if there is some *other* user of autofs (please, please,
please tell me it ain't so - and we haven't heard of any) that tries to
read the packets with multiple writes, that other user will now be
broken - the whole point of the packetized mode is that one system call
gets exactly one packet, and you cannot read a packet in pieces.

Tested-by: Michael Tokarev <mjt@tls.msk.ru>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: David Miller <davem@davemloft.net>
Cc: Ian Kent <raven@themaw.net>
Cc: Thomas Meyer <thomas@m3y3r.de>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
6 years agoPM / Freezer / Docs: Update documentation about freezing of tasks
Marcos Paulo de Souza [Sun, 29 Apr 2012 20:29:30 +0000 (22:29 +0200)]
PM / Freezer / Docs: Update documentation about freezing of tasks

The file Documentation/power/freezing-of-tasks.txt was still referencing
the TIF_FREEZE flag, that was removed by the commit
d88e4cb67197d007fb778d62fe17360e970d5bfa(freezer: remove now unused
TIF_FREEZE).

This patch removes all the references of TIF_FREEZE that were left
behind.

Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
Signed-off-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
6 years agopipes: add a "packetized pipe" mode for writing
Linus Torvalds [Sun, 29 Apr 2012 20:12:42 +0000 (13:12 -0700)]
pipes: add a "packetized pipe" mode for writing

The actual internal pipe implementation is already really about
individual packets (called "pipe buffers"), and this simply exposes that
as a special packetized mode.

When we are in the packetized mode (marked by O_DIRECT as suggested by
Alan Cox), a write() on a pipe will not merge the new data with previous
writes, so each write will get a pipe buffer of its own.  The pipe
buffer is then marked with the PIPE_BUF_FLAG_PACKET flag, which in turn
will tell the reader side to break the read at that boundary (and throw
away any partial packet contents that do not fit in the read buffer).

End result: as long as you do writes less than PIPE_BUF in size (so that
the pipe doesn't have to split them up), you can now treat the pipe as a
packet interface, where each read() system call will read one packet at
a time.  You can just use a sufficiently big read buffer (PIPE_BUF is
sufficient, since bigger than that doesn't guarantee atomicity anyway),
and the return value of the read() will naturally give you the size of
the packet.

NOTE! We do not support zero-sized packets, and zero-sized reads and
writes to a pipe continue to be no-ops.  Also note that big packets will
currently be split at write time, but that the size at which that
happens is not really specified (except that it's bigger than PIPE_BUF).
Currently that limit is the system page size, but we might want to
explicitly support bigger packets some day.

The main user for this is going to be the autofs packet interface,
allowing us to stop having to care so deeply about exact packet sizes
(which have had bugs with 32/64-bit compatibility modes).  But user
space can create packetized pipes with "pipe2(fd, O_DIRECT)", which will
fail with an EINVAL on kernels that do not support this interface.

Tested-by: Michael Tokarev <mjt@tls.msk.ru>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: David Miller <davem@davemloft.net>
Cc: Ian Kent <raven@themaw.net>
Cc: Thomas Meyer <thomas@m3y3r.de>
Cc: stable@kernel.org # needed for systemd/autofs interaction fix
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
6 years agoMerge tag 'staging-3.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh...
Linus Torvalds [Sun, 29 Apr 2012 19:19:13 +0000 (12:19 -0700)]
Merge tag 'staging-3.4-rc4' of git://git./linux/kernel/git/gregkh/staging

Pull staging tree fixes from Greg Kroah-Hartman:
 "Here are some tiny drivers/staging/ bugfixes.  Some build fixes that
  were recently reported, as well as one kfree bug that is hitting a
  number of users."

* tag 'staging-3.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
  staging: ozwpan: Fix bug where kfree is called twice.
  staging: octeon-ethernet: fix build errors by including interrupt.h
  staging: zcache: fix Kconfig crypto dependency
  staging: tidspbridge: remove usage of OMAP2_L4_IO_ADDRESS

6 years agoMerge tag 'usb-3.4-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
Linus Torvalds [Sun, 29 Apr 2012 19:17:54 +0000 (12:17 -0700)]
Merge tag 'usb-3.4-rc5' of git://git./linux/kernel/git/gregkh/usb

Pull USB fixes from Greg Kroah-Hartman:
 "Here are a number of small USB fixes for 3.4-rc5.

  Nothing major, as before, some USB gadget fixes.  There's a crash fix
  for a number of ASUS laptops on resume that had been reported by a
  number of different people.  We think the fix might also pertain to
  other machines, as this was a BIOS bug, and they seem to travel to
  different models and manufacturers quite easily.  Other than that,
  some other reported problems fixed as well."

* tag 'usb-3.4-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
  usb: gadget: udc-core: fix incompatibility with dummy-hcd
  usb: gadget: udc-core: fix wrong call order
  USB: cdc-wdm: fix race leading leading to memory corruption
  USB: EHCI: fix crash during suspend on ASUS computers
  usb gadget: uvc: uvc_request_data::length field must be signed
  usb: gadget: dummy: do not call pullup() on udc_stop()
  usb: musb: davinci.c: add missing unregister
  usb: musb: drop __deprecated flag
  USB: gadget: storage gadgets send wrong error code for unknown commands
  usb: otg: gpio_vbus: Add otg transceiver events and notifiers

6 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux...
Linus Torvalds [Sat, 28 Apr 2012 16:30:07 +0000 (09:30 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/mason/linux-btrfs

Pull btrfs fixes from Chris Mason:
 "This has our collection of bug fixes.  I missed the last rc because I
  thought our patches were making NFS crash during my xfs test runs.
  Turns out it was an NFS client bug fixed by someone else while I tried
  to bisect it.

  All of these fixes are small, but some are fairly high impact.  The
  biggest are fixes for our mount -o remount handling, a deadlock due to
  GFP_KERNEL allocations in readdir, and a RAID10 error handling bug.

  This was tested against both 3.3 and Linus' master as of this morning."

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: (26 commits)
  Btrfs: reduce lock contention during extent insertion
  Btrfs: avoid deadlocks from GFP_KERNEL allocations during btrfs_real_readdir
  Btrfs: Fix space checking during fs resize
  Btrfs: fix block_rsv and space_info lock ordering
  Btrfs: Prevent root_list corruption
  Btrfs: fix repair code for RAID10
  Btrfs: do not start delalloc inodes during sync
  Btrfs: fix that check_int_data mount option was ignored
  Btrfs: don't count CRC or header errors twice while scrubbing
  Btrfs: fix btrfs_ioctl_dev_info() crash on missing device
  btrfs: don't return EINTR
  Btrfs: double unlock bug in error handling
  Btrfs: always store the mirror we read the eb from
  fs/btrfs/volumes.c: add missing free_fs_devices
  btrfs: fix early abort in 'remount'
  Btrfs: fix max chunk size check in chunk allocator
  Btrfs: add missing read locks in backref.c
  Btrfs: don't call free_extent_buffer twice in iterate_irefs
  Btrfs: Make free_ipath() deal gracefully with NULL pointers
  Btrfs: avoid possible use-after-free in clear_extent_bit()
  ...

6 years agoMerge tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm...
Linus Torvalds [Sat, 28 Apr 2012 16:28:43 +0000 (09:28 -0700)]
Merge tag 'fixes-for-linus' of git://git./linux/kernel/git/arm/arm-soc

Pull ARM SoC fixes from Olof Johansson:
 "Nothing controversial, just another batch of fixes:

   - Samsung/exynos fixes for more merge window fallout: build errors
     and warnings mostly, but also some clock/device setup issues on
     exynos4/5
   - PXA bug and warning fixes related to gpio and pinmux
   - IRQ domain conversion bugfixes for U300 and MSM
   - A regulator setup fix for U300"

* tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
  ARM: PXA2xx: MFP: fix potential direction bug
  ARM: PXA2xx: MFP: fix bug with MFP_LPM_KEEP_OUTPUT
  arm/sa1100: fix sa1100-rtc memory resource
  ARM: pxa: fix gpio wakeup setting
  ARM: SAMSUNG: add missing MMC_CAP2_BROKEN_VOLTAGE capability
  ARM: EXYNOS: Fix compilation error when CONFIG_OF is not defined
  ARM: EXYNOS: Fix resource on dev-dwmci.c
  ARM: S3C24XX: Fix build warning for S3C2410_PM
  ARM: mini2440_defconfig: Fix build error
  ARM: msm: Fix gic irqdomain support
  ARM: EXYNOS: Fix incorrect initialization of GIC
  ARM: EXYNOS: use 'exynos4-sdhci' as device name for sdhci controllers
  ARM: u300: bump all IRQ numbers by one
  ARM: ux300: Fix unimplementable regulation constraints

6 years agoMerge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux
Linus Torvalds [Sat, 28 Apr 2012 16:27:07 +0000 (09:27 -0700)]
Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux

Pull drm fixes from Dave Airlie:
 "As soon as I sent the non-urgent stack, two important fixes come in:

   - i915: fixes SNB GPU hangs in a number of 3D apps

   - radeon: initial fix for VGA on LLano system, 3 or 4 of us have
     spent time debugging this, and Jerome finally figured out the magic
     bit the BIOS/fglrx set that we didn't.  This at least should get
     things working, there may be future reliability fixes."

* 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
  drm/i915: Set the Stencil Cache eviction policy to non-LRA mode.
  drm/radeon/kms: need to set up ss on DP bridges as well

6 years agoRevert "autofs: work around unhappy compat problem on x86-64"
Linus Torvalds [Sat, 28 Apr 2012 15:29:56 +0000 (08:29 -0700)]
Revert "autofs: work around unhappy compat problem on x86-64"

This reverts commit a32744d4abae24572eff7269bc17895c41bd0085.

While that commit was technically the right thing to do, and made the
x86-64 compat mode work identically to native 32-bit mode (and thus
fixing the problem with a 32-bit systemd install on a 64-bit kernel), it
turns out that the automount binaries had workarounds for this compat
problem.

Now, the workarounds are disgusting: doing an "uname()" to find out the
architecture of the kernel, and then comparing it for the 64-bit cases
and fixing up the size of the read() in automount for those.  And they
were confused: it's not actually a generic 64-bit issue at all, it's
very much tied to just x86-64, which has different alignment for an
'u64' in 64-bit mode than in 32-bit mode.

But the end result is that fixing the compat layer actually breaks the
case of a 32-bit automount on a x86-64 kernel.

There are various approaches to fix this (including just doing a
"strcmp()" on current->comm and comparing it to "automount"), but I
think that I will do the one that teaches pipes about a special "packet
mode", which will allow user space to not have to care too deeply about
the padding at the end of the autofs packet.

That change will make the compat workaround unnecessary, so let's revert
it first, and get automount working again in compat mode.  The
packetized pipes will then fix autofs for systemd.

Reported-and-requested-by: Michael Tokarev <mjt@tls.msk.ru>
Cc: Ian Kent <raven@themaw.net>
Cc: stable@kernel.org # for 3.3
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
6 years agov4l: Move dummy sensor to sensor section in kconfig
Sergio Aguirre [Sat, 28 Apr 2012 14:37:25 +0000 (09:37 -0500)]
v4l: Move dummy sensor to sensor section in kconfig

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agoomap4iss: Update documentation on tested baseline
Sergio Aguirre [Sat, 28 Apr 2012 13:26:44 +0000 (08:26 -0500)]
omap4iss: Update documentation on tested baseline

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agov4l: Remove chip identity for OV5650
Sergio Aguirre [Sat, 28 Apr 2012 13:18:50 +0000 (08:18 -0500)]
v4l: Remove chip identity for OV5650

Media controller version of the driver no longer needs it.

So, remove this.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agov4l: Remove chip identity for OV5640
Sergio Aguirre [Sat, 28 Apr 2012 13:16:59 +0000 (08:16 -0500)]
v4l: Remove chip identity for OV5640

Media controller version of the driver no longer needs it.

So, remove this.

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agopanda: camera: Add dummysensor support
Sergio Aguirre [Thu, 26 Apr 2012 16:28:47 +0000 (11:28 -0500)]
panda: camera: Add dummysensor support

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agov4l: Add dummy sensor driver
Sergio Aguirre [Thu, 26 Apr 2012 16:09:49 +0000 (11:09 -0500)]
v4l: Add dummy sensor driver

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
6 years agodrm/i915: Set the Stencil Cache eviction policy to non-LRA mode.
Kenneth Graunke [Fri, 27 Apr 2012 19:44:41 +0000 (12:44 -0700)]
drm/i915: Set the Stencil Cache eviction policy to non-LRA mode.

Clearing bit 5 of CACHE_MODE_0 is necessary to prevent GPU hangs in
OpenGL programs such as Google MapsGL, Google Earth, and gzdoom when
using separate stencil buffers.  Without it, the GPU tries to use the
LRA eviction policy, which isn't supported.  This was supposed to be off
by default, but seems to be on for many machines.

This cannot be done in gen6_init_clock_gating with most of the other
workaround bits; the render ring needs to exist.  Otherwise, the
register write gets dropped on the floor (one printk will show it
changed, but a second printk immediately following shows the value
reverts to the old one).

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=47535
Cc: stable@vger.kernel.org
Cc: Rob Castle <futuredub@gmail.com>
Cc: Eric Appleman <erappleman@gmail.com>
Cc: aaron667@gmx.net
Cc: Keith Packard <keithp@keithp.com>
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
6 years agodrm/radeon/kms: need to set up ss on DP bridges as well
Alex Deucher [Fri, 27 Apr 2012 21:18:59 +0000 (17:18 -0400)]
drm/radeon/kms: need to set up ss on DP bridges as well

Makes Nutmeg DP to VGA bridges work for me.

Fixes:
https://bugs.freedesktop.org/show_bug.cgi?id=42490

Noticed by Jerome Glisse (after weeks of debugging).

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
6 years agoMerge git://git.samba.org/sfrench/cifs-2.6
Linus Torvalds [Sat, 28 Apr 2012 03:56:54 +0000 (20:56 -0700)]
Merge git://git.samba.org/sfrench/cifs-2.6

Pull CIFS fixes from Steve French.

* git://git.samba.org/sfrench/cifs-2.6:
  Use correct conversion specifiers in cifs_show_options
  CIFS: Show backupuid/gid in /proc/mounts
  cifs: fix offset handling in cifs_iovec_write

6 years agoMerge tag 'stable/for-linus-3.4-rc4-tag' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sat, 28 Apr 2012 02:56:22 +0000 (19:56 -0700)]
Merge tag 'stable/for-linus-3.4-rc4-tag' of git://git./linux/kernel/git/konrad/xen

Pull Xen fixes from Konrad Rzeszutek Wilk:
 "Some of these had been in existence since the 2.6.27 days, some since
  3.0 - and some due to new features added in v3.4.

  The one that is most interesting is David's one - in the low-level
  assembler code we had be checking events needlessly.  With his patch
  now we do it when the appropriate flag is set - with the added benefit
  that we can process events faster.  Stefano's is fixing a mistake
  where the Linux IRQ numbers were ACK-ed instead of the Xen IRQ,
  resulting in missing interrupts.  The other ones are bootup related
  that can show up on various hardware."

 - In the low-level assembler code we would jump to check events even if
   none were present.  This incorrect behavior had been there since
   2.6.27 days!
 - When using the fast-path for ACK-ing interrupts we were using the
   Linux IRQ numbers instead of the Xen ones (and they can differ) and
   missing interrupts in process.
 - Fix bootup crashes when ACPI hotplug CPUs were present and they would
   expand past the set number of CPUs we were allocated.
 - Deal with broken BIOSes when uploading C-states to the hypervisor.
 - Disable the cpuid check for MWAIT_LEAF if the ACPI PAD driver is
   loaded.  If the ACPI PAD driver is used it will crash, so lets not
   export the functionality so the ACPI PAD driver won't load.

* tag 'stable/for-linus-3.4-rc4-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen:
  xen: correctly check for pending events when restoring irq flags
  xen/acpi: Workaround broken BIOSes exporting non-existing C-states.
  xen/smp: Fix crash when booting with ACPI hotplug CPUs.
  xen: use the pirq number to check the pirq_eoi_map
  xen/enlighten: Disable MWAIT_LEAF so that acpi-pad won't be loaded.