1517 Commits

Author SHA1 Message Date
Nathan Chancellor
c7ccf81651 Merge 4.4.225 into android-msm-wahoo-4.4
Changes in 4.4.225: (67 commits)
        igb: use igb_adapter->io_addr instead of e1000_hw->hw_addr
        padata: Remove unused but set variables
        padata: get_next is never NULL
        padata: ensure the reorder timer callback runs on the correct CPU
        padata: ensure padata_do_serial() runs on the correct CPU
        evm: Check also if *tfm is an error pointer in init_desc()
        fix multiplication overflow in copy_fdtable()
        HID: multitouch: add eGalaxTouch P80H84 support
        ceph: fix double unlock in handle_cap_export()
        USB: core: Fix misleading driver bug report
        platform/x86: asus-nb-wmi: Do not load on Asus T100TA and T200TA
        ARM: futex: Address build warning
        media: Fix media_open() to clear filp->private_data in error leg
        drivers/media/media-devnode: clear private_data before put_device()
        media-devnode: add missing mutex lock in error handler
        media-devnode: fix namespace mess
        media-device: dynamically allocate struct media_devnode
        media: fix use-after-free in cdev_put() when app exits after driver unbind
        media: fix media devnode ioctl/syscall and unregister race
        i2c: dev: switch from register_chrdev to cdev API
        i2c: dev: don't start function name with 'return'
        i2c: dev: use after free in detach
        i2c-dev: don't get i2c adapter via i2c_dev
        i2c: dev: Fix the race between the release of i2c_dev and cdev
        padata: set cpu_index of unused CPUs to -1
        sched/fair, cpumask: Export for_each_cpu_wrap()
        padata: Replace delayed timer with immediate workqueue in padata_reorder
        padata: initialize pd->cpu with effective cpumask
        padata: purge get_cpu and reorder_via_wq from padata_do_serial
        ALSA: pcm: fix incorrect hw_base increase
        ext4: lock the xattr block before checksuming it
        platform/x86: alienware-wmi: fix kfree on potentially uninitialized pointer
        libnvdimm/btt: Remove unnecessary code in btt_freelist_init
        l2tp: lock socket before checking flags in connect()
        l2tp: fix racy socket lookup in l2tp_ip and l2tp_ip6 bind()
        l2tp: hold session while sending creation notifications
        l2tp: take a reference on sessions used in genetlink handlers
        l2tp: don't use l2tp_tunnel_find() in l2tp_ip and l2tp_ip6
        net: l2tp: export debug flags to UAPI
        net: l2tp: deprecate PPPOL2TP_MSG_* in favour of L2TP_MSG_*
        net: l2tp: ppp: change PPPOL2TP_MSG_* => L2TP_MSG_*
        New kernel function to get IP overhead on a socket.
        L2TP:Adjust intf MTU, add underlay L3, L2 hdrs.
        l2tp: remove useless duplicate session detection in l2tp_netlink
        l2tp: remove l2tp_session_find()
        l2tp: define parameters of l2tp_session_get*() as "const"
        l2tp: define parameters of l2tp_tunnel_find*() as "const"
        l2tp: initialise session's refcount before making it reachable
        l2tp: hold tunnel while looking up sessions in l2tp_netlink
        l2tp: hold tunnel while processing genl delete command
        l2tp: hold tunnel while handling genl tunnel updates
        l2tp: hold tunnel while handling genl TUNNEL_GET commands
        l2tp: hold tunnel used while creating sessions with netlink
        l2tp: prevent creation of sessions on terminated tunnels
        l2tp: pass tunnel pointer to ->session_create()
        l2tp: fix l2tp_eth module loading
        l2tp: don't register sessions in l2tp_session_create()
        l2tp: initialise l2tp_eth sessions before registering them
        l2tp: protect sock pointer of struct pppol2tp_session with RCU
        l2tp: initialise PPP sessions before registering them
        Revert "gfs2: Don't demote a glock until its revokes are written"
        staging: iio: ad2s1210: Fix SPI reading
        mei: release me_cl object reference
        iio: sca3000: Remove an erroneous 'get_device()'
        l2tp: device MTU setup, tunnel socket needs a lock
        cpumask: Make for_each_cpu_wrap() available on UP as well
        Linux 4.4.225

Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>

Conflicts:
	fs/ext4/xattr.c
	net/l2tp/l2tp_core.c
	net/socket.c
2020-05-27 09:57:29 -07:00
Shuah Khan
b882fcc49c media: fix media devnode ioctl/syscall and unregister race
commit 6f0dd24a084a17f9984dd49dffbf7055bf123993 upstream.

Media devnode open/ioctl could be in progress when media device unregister
is initiated. System calls and ioctls check media device registered status
at the beginning, however, there is a window where unregister could be in
progress without changing the media devnode status to unregistered.

process 1				process 2
fd = open(/dev/media0)
media_devnode_is_registered()
	(returns true here)

					media_device_unregister()
						(unregister is in progress
						and devnode isn't
						unregistered yet)
					...
ioctl(fd, ...)
__media_ioctl()
media_devnode_is_registered()
	(returns true here)
					...
					media_devnode_unregister()
					...
					(driver releases the media device
					memory)

media_device_ioctl()
	(By this point
	devnode->media_dev does not
	point to allocated memory.
	use-after free in in mutex_lock_nested)

BUG: KASAN: use-after-free in mutex_lock_nested+0x79c/0x800 at addr
ffff8801ebe914f0

Fix it by clearing register bit when unregister starts to avoid the race.

process 1                               process 2
fd = open(/dev/media0)
media_devnode_is_registered()
        (could return true here)

                                        media_device_unregister()
                                                (clear the register bit,
						 then start unregister.)
                                        ...
ioctl(fd, ...)
__media_ioctl()
media_devnode_is_registered()
        (return false here, ioctl
	 returns I/O error, and
	 will not access media
	 device memory)
                                        ...
                                        media_devnode_unregister()
                                        ...
                                        (driver releases the media device
					 memory)

Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
Suggested-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reported-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Tested-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
[bwh: Backported to 4.4: adjut filename, context]
Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-05-27 16:40:25 +02:00
Mauro Carvalho Chehab
bcce79f625 media-device: dynamically allocate struct media_devnode
commit a087ce704b802becbb4b0f2a20f2cb3f6911802e upstream.

struct media_devnode is currently embedded at struct media_device.

While this works fine during normal usage, it leads to a race
condition during devnode unregister. the problem is that drivers
assume that, after calling media_device_unregister(), the struct
that contains media_device can be freed. This is not true, as it
can't be freed until userspace closes all opened /dev/media devnodes.

In other words, if the media devnode is still open, and media_device
gets freed, any call to an ioctl will make the core to try to access
struct media_device, with will cause an use-after-free and even GPF.

Fix this by dynamically allocating the struct media_devnode and only
freeing it when it is safe.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
[bwh: Backported to 4.4:
 - Drop change in au0828
 - Include <linux/slab.h> in media-device.c
 - Adjust context]
Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-05-27 16:40:25 +02:00
Mauro Carvalho Chehab
328ff670b0 media-devnode: fix namespace mess
commit 163f1e93e995048b894c5fc86a6034d16beed740 upstream.

Along all media controller code, "mdev" is used to represent
a pointer to struct media_device, and "devnode" for a pointer
to struct media_devnode.

However, inside media-devnode.[ch], "mdev" is used to represent
a pointer to struct media_devnode.

This is very confusing and may lead to development errors.

So, let's change all occurrences at media-devnode.[ch] to
also use "devnode" for such pointers.

This patch doesn't make any functional changes.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
[bwh: Backported to 4.4: adjust filename, context]
Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-05-27 16:40:25 +02:00
Nathan Chancellor
4cf66c0bce Merge 4.4.212 into android-msm-wahoo-4.4
Changes in 4.4.212: (184 commits)
        xfs: Sanity check flags of Q_XQUOTARM call
        powerpc/archrandom: fix arch_get_random_seed_int()
        mt7601u: fix bbp version check in mt7601u_wait_bbp_ready
        drm/virtio: fix bounds check in virtio_gpu_cmd_get_capset()
        ALSA: hda: fix unused variable warning
        ALSA: usb-audio: update quirk for B&W PX to remove microphone
        staging: comedi: ni_mio_common: protect register write overflow
        pcrypt: use format specifier in kobject_add
        exportfs: fix 'passing zero to ERR_PTR()' warning
        drm/dp_mst: Skip validating ports during destruction, just ref
        pinctrl: sh-pfc: r8a7740: Add missing REF125CK pin to gether_gmii group
        pinctrl: sh-pfc: r8a7740: Add missing LCD0 marks to lcd0_data24_1 group
        pinctrl: sh-pfc: r8a7791: Remove bogus ctrl marks from qspi_data4_b group
        pinctrl: sh-pfc: r8a7791: Remove bogus marks from vin1_b_data18 group
        pinctrl: sh-pfc: sh73a0: Add missing TO pin to tpu4_to3 group
        pinctrl: sh-pfc: r8a7794: Remove bogus IPSR9 field
        pinctrl: sh-pfc: sh7734: Add missing IPSR11 field
        pinctrl: sh-pfc: sh7269: Add missing PCIOR0 field
        pinctrl: sh-pfc: sh7734: Remove bogus IPSR10 value
        Input: nomadik-ske-keypad - fix a loop timeout test
        clk: highbank: fix refcount leak in hb_clk_init()
        clk: qoriq: fix refcount leak in clockgen_init()
        clk: socfpga: fix refcount leak
        clk: samsung: exynos4: fix refcount leak in exynos4_get_xom()
        clk: imx6q: fix refcount leak in imx6q_clocks_init()
        clk: imx6sx: fix refcount leak in imx6sx_clocks_init()
        clk: imx7d: fix refcount leak in imx7d_clocks_init()
        clk: vf610: fix refcount leak in vf610_clocks_init()
        clk: armada-370: fix refcount leak in a370_clk_init()
        clk: kirkwood: fix refcount leak in kirkwood_clk_init()
        clk: armada-xp: fix refcount leak in axp_clk_init()
        IB/usnic: Fix out of bounds index check in query pkey
        RDMA/ocrdma: Fix out of bounds index check in query pkey
        media: s5p-jpeg: Correct step and max values for V4L2_CID_JPEG_RESTART_INTERVAL
        crypto: tgr192 - fix unaligned memory access
        ASoC: imx-sgtl5000: put of nodes if finding codec fails
        rtc: cmos: ignore bogus century byte
        tty: ipwireless: Fix potential NULL pointer dereference
        rtc: ds1672: fix unintended sign extension
        rtc: 88pm860x: fix unintended sign extension
        rtc: 88pm80x: fix unintended sign extension
        rtc: pm8xxx: fix unintended sign extension
        fbdev: chipsfb: remove set but not used variable 'size'
        pinctrl: sh-pfc: emev2: Add missing pinmux functions
        pinctrl: sh-pfc: r8a7791: Fix scifb2_data_c pin group
        pinctrl: sh-pfc: sh73a0: Fix fsic_spdif pin groups
        block: don't use bio->bi_vcnt to figure out segment number
        vfio_pci: Enable memory accesses before calling pci_map_rom
        cdc-wdm: pass return value of recover_from_urb_loss
        drm/nouveau/bios/ramcfg: fix missing parentheses when calculating RON
        drm/nouveau/pmu: don't print reply values if exec is false
        ASoC: qcom: Fix of-node refcount unbalance in apq8016_sbc_parse_of()
        fs/nfs: Fix nfs_parse_devname to not modify it's argument
        clocksource/drivers/sun5i: Fail gracefully when clock rate is unavailable
        ARM: 8847/1: pm: fix HYP/SVC mode mismatch when MCPM is used
        regulator: wm831x-dcdc: Fix list of wm831x_dcdc_ilim from mA to uA
        nios2: ksyms: Add missing symbol exports
        scsi: megaraid_sas: reduce module load time
        xen, cpu_hotplug: Prevent an out of bounds access
        net: sh_eth: fix a missing check of of_get_phy_mode
        media: ivtv: update *pos correctly in ivtv_read_pos()
        media: cx18: update *pos correctly in cx18_read_pos()
        media: wl128x: Fix an error code in fm_download_firmware()
        media: cx23885: check allocation return
        jfs: fix bogus variable self-initialization
        m68k: mac: Fix VIA timer counter accesses
        ARM: OMAP2+: Fix potentially uninitialized return value for _setup_reset()
        media: davinci-isif: avoid uninitialized variable use
        spi: tegra114: clear packed bit for unpacked mode
        spi: tegra114: fix for unpacked mode transfers
        soc/fsl/qe: Fix an error code in qe_pin_request()
        spi: bcm2835aux: fix driver to not allow 65535 (=-1) cs-gpios
        ehea: Fix a copy-paste err in ehea_init_port_res
        scsi: qla2xxx: Unregister chrdev if module initialization fails
        ARM: pxa: ssp: Fix "WARNING: invalid free of devm_ allocated data"
        hwmon: (w83627hf) Use request_muxed_region for Super-IO accesses
        tipc: set sysctl_tipc_rmem and named_timeout right range
        powerpc: vdso: Make vdso32 installation conditional in vdso_install
        media: ov2659: fix unbalanced mutex_lock/unlock
        6lowpan: Off by one handling ->nexthdr
        dmaengine: axi-dmac: Don't check the number of frames for alignment
        ALSA: usb-audio: Handle the error from snd_usb_mixer_apply_create_quirk()
        packet: in recvmsg msg_name return at least sizeof sockaddr_ll
        ASoC: fix valid stream condition
        IB/mlx5: Add missing XRC options to QP optional params mask
        iommu/vt-d: Make kernel parameter igfx_off work with vIOMMU
        media: omap_vout: potential buffer overflow in vidioc_dqbuf()
        media: davinci/vpbe: array underflow in vpbe_enum_outputs()
        platform/x86: alienware-wmi: printing the wrong error code
        netfilter: ebtables: CONFIG_COMPAT: reject trailing data after last rule
        ARM: riscpc: fix lack of keyboard interrupts after irq conversion
        kdb: do a sanity check on the cpu in kdb_per_cpu()
        backlight: lm3630a: Return 0 on success in update_status functions
        thermal: cpu_cooling: Actually trace CPU load in thermal_power_cpu_get_power
        spi: spi-fsl-spi: call spi_finalize_current_message() at the end
        misc: sgi-xp: Properly initialize buf in xpc_get_rsvd_page_pa
        iommu: Use right function to get group for device
        signal/cifs: Fix cifs_put_tcp_session to call send_sig instead of force_sig
        inet: frags: call inet_frags_fini() after unregister_pernet_subsys()
        media: vivid: fix incorrect assignment operation when setting video mode
        powerpc/cacheinfo: add cacheinfo_teardown, cacheinfo_rebuild
        drm/msm/mdp5: Fix mdp5_cfg_init error return
        net/af_iucv: always register net_device notifier
        ASoC: ti: davinci-mcasp: Fix slot mask settings when using multiple AXRs
        rtc: pcf8563: Clear event flags and disable interrupts before requesting irq
        drm/msm/a3xx: remove TPL1 regs from snapshot
        iommu/amd: Make iommu_disable safer
        mfd: intel-lpss: Release IDA resources
        devres: allow const resource arguments
        net: pasemi: fix an use-after-free in pasemi_mac_phy_init()
        scsi: libfc: fix null pointer dereference on a null lport
        libertas_tf: Use correct channel range in lbtf_geo_init
        usb: host: xhci-hub: fix extra endianness conversion
        mic: avoid statically declaring a 'struct device'.
        x86/kgbd: Use NMI_VECTOR not APIC_DM_NMI
        ALSA: aoa: onyx: always initialize register read value
        cifs: fix rmmod regression in cifs.ko caused by force_sig changes
        crypto: caam - free resources in case caam_rng registration failed
        ext4: set error return correctly when ext4_htree_store_dirent fails
        ASoC: es8328: Fix copy-paste error in es8328_right_line_controls
        ASoC: cs4349: Use PM ops 'cs4349_runtime_pm'
        ASoC: wm8737: Fix copy-paste error in wm8737_snd_controls
        signal: Allow cifs and drbd to receive their terminating signals
        dmaengine: dw: platform: Switch to acpi_dma_controller_register()
        mac80211: minstrel_ht: fix per-group max throughput rate initialization
        mips: avoid explicit UB in assignment of mips_io_port_base
        ahci: Do not export local variable ahci_em_messages
        Partially revert "kfifo: fix kfifo_alloc() and kfifo_init()"
        power: supply: Init device wakeup after device_add()
        x86, perf: Fix the dependency of the x86 insn decoder selftest
        bcma: fix incorrect update of BCMA_CORE_PCI_MDIO_DATA
        iio: dac: ad5380: fix incorrect assignment to val
        ath9k: dynack: fix possible deadlock in ath_dynack_node_{de}init
        net: sonic: return NETDEV_TX_OK if failed to map buffer
        Btrfs: fix hang when loading existing inode cache off disk
        hwmon: (shtc1) fix shtc1 and shtw1 id mask
        net: sonic: replace dev_kfree_skb in sonic_send_packet
        net/rds: Fix 'ib_evt_handler_call' element in 'rds_ib_stat_names'
        iommu/amd: Wait for completion of IOTLB flush in attach_device
        net: hisilicon: Fix signedness bug in hix5hd2_dev_probe()
        net: broadcom/bcmsysport: Fix signedness in bcm_sysport_probe()
        net: ethernet: stmmac: Fix signedness bug in ipq806x_gmac_of_parse()
        mac80211: accept deauth frames in IBSS mode
        llc: fix another potential sk_buff leak in llc_ui_sendmsg()
        llc: fix sk_buff refcounting in llc_conn_state_process()
        net: stmmac: fix length of PTP clock's name string
        drm/msm/dsi: Implement reset correctly
        dmaengine: imx-sdma: fix size check for sdma script_number
        net: qca_spi: Move reset_count to struct qcaspi
        media: ov6650: Fix incorrect use of JPEG colorspace
        media: ov6650: Fix some format attributes not under control
        media: ov6650: Fix .get_fmt() V4L2_SUBDEV_FORMAT_TRY support
        MIPS: Loongson: Fix return value of loongson_hwmon_init
        net: neigh: use long type to store jiffies delta
        packet: fix data-race in fanout_flow_is_huge()
        dmaengine: ti: edma: fix missed failure handling
        drm/radeon: fix bad DMA from INTERRUPT_CNTL2
        arm64: dts: juno: Fix UART frequency
        m68k: Call timer_interrupt() with interrupts disabled
        can, slip: Protect tty->disc_data in write_wakeup and close with RCU
        firestream: fix memory leaks
        net: cxgb3_main: Add CAP_NET_ADMIN check to CHELSIO_GET_MEM
        net, ip_tunnel: fix namespaces move
        net_sched: fix datalen for ematch
        net: usb: lan78xx: Add .ndo_features_check
        hwmon: (adt7475) Make volt2reg return same reg as reg2volt input
        Input: keyspan-remote - fix control-message timeouts
        ARM: 8950/1: ftrace/recordmcount: filter relocation types
        mmc: sdhci: fix minimum clock rate for v3 controller
        Input: sur40 - fix interface sanity checks
        Input: gtco - fix endpoint sanity check
        Input: aiptek - fix endpoint sanity check
        hwmon: (nct7802) Fix voltage limits to wrong registers
        scsi: RDMA/isert: Fix a recently introduced regression related to logout
        tracing: xen: Ordered comparison of function pointers
        do_last(): fetch directory ->i_mode and ->i_uid before it's too late
        iio: buffer: align the size of scan bytes to size of the largest element
        scsi: iscsi: Avoid potential deadlock in iscsi_if_rx func
        md: Avoid namespace collision with bitmap API
        bitmap: Add bitmap_alloc(), bitmap_zalloc() and bitmap_free()
        netfilter: ipset: use bitmap infrastructure completely
        net/x25: fix nonblocking connect
        libertas: Fix two buffer overflows at parsing bss descriptor
        Linux 4.4.212

Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
2020-01-29 17:10:10 -07:00
Dan Carpenter
7aa9ac350e media: davinci/vpbe: array underflow in vpbe_enum_outputs()
[ Upstream commit b72845ee5577b227131b1fef23f9d9a296621d7b ]

In vpbe_enum_outputs() we check if (temp_index >= cfg->num_outputs) but
the problem is that "temp_index" can be negative.  This patch changes
the types to unsigned to address this array underflow bug.

Fixes: 66715cdc32 ("[media] davinci vpbe: VPBE display driver")

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: "Lad, Prabhakar" <prabhakar.csengg@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-01-29 10:21:43 +01:00
Nathan Chancellor
90e64383e5 Merge 4.4.160 into android-msm-wahoo-4.4
Changes in 4.4.160: (114 commits)
        crypto: skcipher - Fix -Wstringop-truncation warnings
        tsl2550: fix lux1_input error in low light
        vmci: type promotion bug in qp_host_get_user_memory()
        x86/numa_emulation: Fix emulated-to-physical node mapping
        staging: rts5208: fix missing error check on call to rtsx_write_register
        uwb: hwa-rc: fix memory leak at probe
        power: vexpress: fix corruption in notifier registration
        Bluetooth: Add a new Realtek 8723DE ID 0bda:b009
        USB: serial: kobil_sct: fix modem-status error handling
        6lowpan: iphc: reset mac_header after decompress to fix panic
        md-cluster: clear another node's suspend_area after the copy is finished
        media: exynos4-is: Prevent NULL pointer dereference in __isp_video_try_fmt()
        powerpc/kdump: Handle crashkernel memory reservation failure
        media: fsl-viu: fix error handling in viu_of_probe()
        x86/tsc: Add missing header to tsc_msr.c
        x86/entry/64: Add two more instruction suffixes
        scsi: target/iscsi: Make iscsit_ta_authentication() respect the output buffer size
        scsi: klist: Make it safe to use klists in atomic context
        scsi: ibmvscsi: Improve strings handling
        usb: wusbcore: security: cast sizeof to int for comparison
        powerpc/powernv/ioda2: Reduce upper limit for DMA window size
        alarmtimer: Prevent overflow for relative nanosleep
        s390/extmem: fix gcc 8 stringop-overflow warning
        ALSA: snd-aoa: add of_node_put() in error path
        media: s3c-camif: ignore -ENOIOCTLCMD from v4l2_subdev_call for s_power
        media: soc_camera: ov772x: correct setting of banding filter
        media: omap3isp: zero-initialize the isp cam_xclk{a,b} initial data
        staging: android: ashmem: Fix mmap size validation
        drivers/tty: add error handling for pcmcia_loop_config
        media: tm6000: add error handling for dvb_register_adapter
        ALSA: hda: Add AZX_DCAPS_PM_RUNTIME for AMD Raven Ridge
        ath10k: protect ath10k_htt_rx_ring_free with rx_ring.lock
        rndis_wlan: potential buffer overflow in rndis_wlan_auth_indication()
        wlcore: Add missing PM call for wlcore_cmd_wait_for_event_or_timeout()
        ARM: mvebu: declare asm symbols as character arrays in pmsu.c
        HID: hid-ntrig: add error handling for sysfs_create_group
        scsi: bnx2i: add error handling for ioremap_nocache
        EDAC, i7core: Fix memleaks and use-after-free on probe and remove
        ASoC: dapm: Fix potential DAI widget pointer deref when linking DAIs
        module: exclude SHN_UNDEF symbols from kallsyms api
        nfsd: fix corrupted reply to badly ordered compound
        ARM: dts: dra7: fix DCAN node addresses
        floppy: Do not copy a kernel pointer to user memory in FDGETPRM ioctl
        serial: cpm_uart: return immediately from console poll
        spi: tegra20-slink: explicitly enable/disable clock
        spi: sh-msiof: Fix invalid SPI use during system suspend
        spi: sh-msiof: Fix handling of write value for SISTR register
        spi: rspi: Fix invalid SPI use during system suspend
        spi: rspi: Fix interrupted DMA transfers
        USB: fix error handling in usb_driver_claim_interface()
        USB: handle NULL config in usb_find_alt_setting()
        slub: make ->cpu_partial unsigned int
        media: uvcvideo: Support realtek's UVC 1.5 device
        USB: usbdevfs: sanitize flags more
        USB: usbdevfs: restore warning for nonsensical flags
        Revert "usb: cdc-wdm: Fix a sleep-in-atomic-context bug in service_outstanding_interrupt()"
        USB: remove LPM management from usb_driver_claim_interface()
        Input: elantech - enable middle button of touchpad on ThinkPad P72
        IB/srp: Avoid that sg_reset -d ${srp_device} triggers an infinite loop
        scsi: target: iscsi: Use bin2hex instead of a re-implementation
        serial: imx: restore handshaking irq for imx1
        arm64: KVM: Tighten guest core register access from userspace
        ext4: never move the system.data xattr out of the inode body
        thermal: of-thermal: disable passive polling when thermal zone is disabled
        net: hns: fix length and page_offset overflow when CONFIG_ARM64_64K_PAGES
        e1000: check on netif_running() before calling e1000_up()
        e1000: ensure to free old tx/rx rings in set_ringparam()
        hwmon: (ina2xx) fix sysfs shunt resistor read access
        hwmon: (adt7475) Make adt7475_read_word() return errors
        i2c: i801: Allow ACPI AML access I/O ports not reserved for SMBus
        arm64: cpufeature: Track 32bit EL0 support
        arm64: KVM: Sanitize PSTATE.M when being set from userspace
        media: v4l: event: Prevent freeing event subscriptions while accessed
        KVM: PPC: Book3S HV: Don't truncate HPTE index in xlate function
        mac80211: correct use of IEEE80211_VHT_CAP_RXSTBC_X
        mac80211_hwsim: correct use of IEEE80211_VHT_CAP_RXSTBC_X
        gpio: adp5588: Fix sleep-in-atomic-context bug
        mac80211: mesh: fix HWMP sequence numbering to follow standard
        cfg80211: nl80211_update_ft_ies() to validate NL80211_ATTR_IE
        RAID10 BUG_ON in raise_barrier when force is true and conf->barrier is 0
        i2c: uniphier: issue STOP only for last message or I2C_M_STOP
        i2c: uniphier-f: issue STOP only for last message or I2C_M_STOP
        net: cadence: Fix a sleep-in-atomic-context bug in macb_halt_tx()
        fs/cifs: don't translate SFM_SLASH (U+F026) to backslash
        cfg80211: fix a type issue in ieee80211_chandef_to_operating_class()
        mac80211: fix a race between restart and CSA flows
        mac80211: Fix station bandwidth setting after channel switch
        mac80211: shorten the IBSS debug messages
        tools/vm/slabinfo.c: fix sign-compare warning
        tools/vm/page-types.c: fix "defined but not used" warning
        mm: madvise(MADV_DODUMP): allow hugetlbfs pages
        usb: gadget: fotg210-udc: Fix memory leak of fotg210->ep[i]
        perf probe powerpc: Ignore SyS symbols irrespective of endianness
        RDMA/ucma: check fd type in ucma_migrate_id()
        USB: yurex: Check for truncation in yurex_read()
        drm/nouveau/TBDdevinit: don't fail when PMU/PRE_OS is missing from VBIOS
        fs/cifs: suppress a string overflow warning
        dm thin metadata: try to avoid ever aborting transactions
        arch/hexagon: fix kernel/dma.c build warning
        hexagon: modify ffs() and fls() to return int
        arm64: jump_label.h: use asm_volatile_goto macro instead of "asm goto"
        r8169: Clear RTL_FLAG_TASK_*_PENDING when clearing RTL_FLAG_TASK_ENABLED
        s390/qeth: don't dump past end of unknown HW header
        cifs: read overflow in is_valid_oplock_break()
        xen/manage: don't complain about an empty value in control/sysrq node
        xen: avoid crash in disable_hotplug_cpu
        xen: fix GCC warning and remove duplicate EVTCHN_ROW/EVTCHN_COL usage
        smb2: fix missing files in root share directory listing
        ALSA: hda/realtek - Cannot adjust speaker's volume on Dell XPS 27 7760
        crypto: mxs-dcp - Fix wait logic on chan threads
        proc: restrict kernel stack dumps to root
        ocfs2: fix locking for res->tracking and dlm->tracking_list
        dm thin metadata: fix __udivdi3 undefined on 32-bit
        Linux 4.4.160

Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>

Conflicts:
	arch/arm64/include/asm/cpufeature.h
	arch/arm64/kernel/cpufeature.c
2018-10-10 12:17:35 -07:00
Sakari Ailus
bbbc4dabca media: v4l: event: Prevent freeing event subscriptions while accessed
commit ad608fbcf166fec809e402d548761768f602702c upstream.

The event subscriptions are added to the subscribed event list while
holding a spinlock, but that lock is subsequently released while still
accessing the subscription object. This makes it possible to unsubscribe
the event --- and freeing the subscription object's memory --- while
the subscription object is simultaneously accessed.

Prevent this by adding a mutex to serialise the event subscription and
unsubscription. This also gives a guarantee to the callback ops that the
add op has returned before the del op is called.

This change also results in making the elems field less special:
subscriptions are only added to the event list once they are fully
initialised.

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Hans Verkuil <hans.verkuil@cisco.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: stable@vger.kernel.org # for 4.14 and up
Fixes: c3b5b0241f ("V4L/DVB: V4L: Events: Add backend")
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-10-10 08:52:10 +02:00
sam.ch_chang
3930306936 msm: camera: Read OIS GYRO data in kernel
1)To stabilize i2c readout. Move readout thread to kernel.
2)Read from userspace if got event.

Bug: 37797997
Change-Id: I6b9ad6be0cdd8f48d98f5635fce85d62b1d9e7d7
Signed-off-by: Xu Han <xuhanyz@google.com>
2017-05-26 10:36:37 -07:00
Thierry Strudel
1bfb0526f6 Merge branch 'android-msm-8998-4.4-common' into android-msm-wahoo-4.4
Conflicts:
	Makefile
	arch/arm64/configs/wahoo_defconfig
	arch/arm64/include/asm/cpufeature.h
	arch/arm64/kernel/sleep.S
	arch/arm64/kernel/vmlinux.lds.S
	arch/arm64/mm/fault.c
	drivers/android/binder.c
	drivers/firmware/efi/arm-init.c
	drivers/firmware/efi/efi.c
	drivers/input/keyboard/gpio_keys.c
	drivers/input/misc/Makefile
	drivers/input/misc/vl53L0/Makefile
	drivers/input/misc/vl53L0/inc/vl53l010_api.h
	drivers/input/misc/vl53L0/inc/vl53l010_device.h
	drivers/input/misc/vl53L0/inc/vl53l010_strings.h
	drivers/input/misc/vl53L0/inc/vl53l010_tuning.h
	drivers/input/misc/vl53L0/inc/vl53l0_api.h
	drivers/input/misc/vl53L0/inc/vl53l0_api_calibration.h
	drivers/input/misc/vl53L0/inc/vl53l0_api_core.h
	drivers/input/misc/vl53L0/inc/vl53l0_api_histogram.h
	drivers/input/misc/vl53L0/inc/vl53l0_api_ranging.h
	drivers/input/misc/vl53L0/inc/vl53l0_api_strings.h
	drivers/input/misc/vl53L0/inc/vl53l0_def.h
	drivers/input/misc/vl53L0/inc/vl53l0_device.h
	drivers/input/misc/vl53L0/inc/vl53l0_interrupt_threshold_settings.h
	drivers/input/misc/vl53L0/inc/vl53l0_platform.h
	drivers/input/misc/vl53L0/inc/vl53l0_platform_log.h
	drivers/input/misc/vl53L0/inc/vl53l0_tuning.h
	drivers/input/misc/vl53L0/inc/vl53l0_types.h
	drivers/input/misc/vl53L0/src/vl53l010_api.c
	drivers/input/misc/vl53L0/src/vl53l010_tuning.c
	drivers/input/misc/vl53L0/src/vl53l0_api.c
	drivers/input/misc/vl53L0/src/vl53l0_api_calibration.c
	drivers/input/misc/vl53L0/src/vl53l0_api_core.c
	drivers/input/misc/vl53L0/src/vl53l0_api_histogram.c
	drivers/input/misc/vl53L0/src/vl53l0_api_ranging.c
	drivers/input/misc/vl53L0/src/vl53l0_api_strings.c
	drivers/input/misc/vl53L0/src/vl53l0_i2c_platform.c
	drivers/input/misc/vl53L0/src/vl53l0_platform.c
	drivers/input/misc/vl53L0/src/vl53l0_port_i2c.c
	drivers/input/misc/vl53L0/stmvl53l0-cci.h
	drivers/input/misc/vl53L0/stmvl53l0-i2c.h
	drivers/input/misc/vl53L0/stmvl53l0.h
	drivers/input/misc/vl53L0/stmvl53l0_module-cci.c
	drivers/input/misc/vl53L0/stmvl53l0_module-i2c.c
	drivers/input/misc/vl53L0/stmvl53l0_module.c
	drivers/input/touchscreen/Makefile
	drivers/leds/leds-qpnp.c
	drivers/media/platform/msm/camera_v2/isp/msm_isp_stats_util.c
	drivers/media/platform/msm/camera_v2/msm.c
	drivers/pinctrl/qcom/pinctrl-msm.c
	drivers/platform/msm/ipa/ipa_v3/ipa_client.c
	drivers/platform/msm/mhi/mhi_ssr.c
	drivers/power/supply/qcom/qpnp-smb2.c
	drivers/power/supply/qcom/smb-lib.c
	drivers/power/supply/qcom/smb-lib.h
	drivers/soc/qcom/icnss.c
	drivers/soc/qcom/qdsp6v2/audio_notifier.c
	drivers/soc/qcom/service-notifier.c
	drivers/video/fbdev/msm/mdss_panel.h
	fs/exec.c
	fs/ext4/inode.c
	fs/ext4/readpage.c
	fs/namei.c
	fs/sdcardfs/derived_perm.c
	fs/sdcardfs/file.c
	fs/sdcardfs/inode.c
	fs/sdcardfs/lookup.c
	fs/sdcardfs/main.c
	fs/sdcardfs/multiuser.h
	fs/sdcardfs/packagelist.c
	fs/sdcardfs/sdcardfs.h
	fs/sdcardfs/super.c
	fs/utimes.c
	include/linux/string.h
	lib/kstrtox.c
	lib/string.c
	net/ipv4/tcp_ipv4.c
	net/unix/af_unix.c
	sound/soc/codecs/wcd934x/wcd934x-mbhc.h
	sound/soc/msm/msm8998.c

Change-Id: I918ebad22a5f81d48be07bd2bc2ac435ed9acb0a
Signed-off-by: Thierry Strudel <tstrudel@google.com>
2017-04-07 12:27:45 -07:00
Pratap Nirujogi
e616d102ce msm: camera: cpp: Replace const by macro
Replace hardcoded constant 8 with MSM_OUTPUT_BUF_CNT
macro.

Change-Id: Ia77847fcf4ead7a77fbdedc1b96031ee4f5687dd
CRs-Fixed: 2004036
Signed-off-by: Pratap Nirujogi <pratapn@codeaurora.org>
2017-03-21 02:50:25 -07:00
Praneeth Paladugu
68251b1597 msm: vidc: Add support for querying controls
Add support in driver to query for control information.
This helps clients to findout limits for various controls
and sets the values accordingly.

Also update the control limits based on Venus HW capabilities.
This helps to prevent rogue clients not to set invalid values
to HW.

CRs-Fixed: 2003998
Change-Id: Ib444aba2203c898f778f4d7c0bc086ecc07461af
Signed-off-by: Vikash Garodia <vgarodia@codeaurora.org>
2017-02-20 19:49:07 +05:30
Thierry Strudel
05df0a9e71 Merge branch 'android-msm-8998-4.4-common' into android-msm-muskie-4.4
Merging release LA.UM.5.7.R1.07.01.01.253.064 Pre-CS4 0.0.091.1

Bug: 34911851
Change-Id: Iaaf2a1402940c98a3b36457b5fb99059f4a718f8
Signed-off-by: Thierry Strudel <tstrudel@google.com>
2017-02-09 18:08:53 -08:00
Vaibhav Deshu Venkatesh
6f732e040d msm: vidc: Cache invalidate performance fix
When allocate buffer is used we allocate one huge buffer
with offsets instead of allocating multiple small buffers.
During cache invalidate we pass this big buffer and the
size passed is the size of this big buffer. This causes
performance issue. Instead we now pass the actual offsetted
buffer and smaller individual buffer size for invalidation.

CRs-Fixed: 1096624
Change-Id: Ifad386882e4a404b1e455cc3e11ae0e820d2a577
Signed-off-by: Vaibhav Deshu Venkatesh <vdeshuve@codeaurora.org>
Signed-off-by: Chinmay Sawarkar <chinmays@codeaurora.org>
2016-12-20 23:40:48 -08:00
sam.ch_chang
cbb50e60fd drivers: msm/camera_v2: sensor: ois: read OIS position
Read OIS position via i2c.

Bug: 33241262
Change-Id: I1bf491826ada592405d37822981db337cac6a70f
Signed-off-by: sam.ch_chang <sam.ch_chang@htc.com>
2016-12-16 14:33:54 -08:00
Runmin Wang
617229a3e9 Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4
* msm-4.4/tmp-510d0a3f:
  Linux 4.4.11
  nf_conntrack: avoid kernel pointer value leak in slab name
  drm/radeon: fix DP link training issue with second 4K monitor
  drm/i915/bdw: Add missing delay during L3 SQC credit programming
  drm/i915: Bail out of pipe config compute loop on LPT
  drm/radeon: fix PLL sharing on DCE6.1 (v2)
  Revert "[media] videobuf2-v4l2: Verify planes array in buffer dequeueing"
  Input: max8997-haptic - fix NULL pointer dereference
  get_rock_ridge_filename(): handle malformed NM entries
  tools lib traceevent: Do not reassign parg after collapse_tree()
  qla1280: Don't allocate 512kb of host tags
  atomic_open(): fix the handling of create_error
  regulator: axp20x: Fix axp22x ldo_io voltage ranges
  regulator: s2mps11: Fix invalid selector mask and voltages for buck9
  workqueue: fix rebind bound workers warning
  ARM: dts: at91: sam9x5: Fix the memory range assigned to the PMC
  vfs: rename: check backing inode being equal
  vfs: add vfs_select_inode() helper
  perf/core: Disable the event on a truncated AUX record
  regmap: spmi: Fix regmap_spmi_ext_read in multi-byte case
  pinctrl: at91-pio4: fix pull-up/down logic
  spi: spi-ti-qspi: Handle truncated frames properly
  spi: spi-ti-qspi: Fix FLEN and WLEN settings if bits_per_word is overridden
  spi: pxa2xx: Do not detect number of enabled chip selects on Intel SPT
  ALSA: hda - Fix broken reconfig
  ALSA: hda - Fix white noise on Asus UX501VW headset
  ALSA: hda - Fix subwoofer pin on ASUS N751 and N551
  ALSA: usb-audio: Yet another Phoneix Audio device quirk
  ALSA: usb-audio: Quirk for yet another Phoenix Audio devices (v2)
  crypto: testmgr - Use kmalloc memory for RSA input
  crypto: hash - Fix page length clamping in hash walk
  crypto: qat - fix invalid pf2vf_resp_wq logic
  s390/mm: fix asce_bits handling with dynamic pagetable levels
  zsmalloc: fix zs_can_compact() integer overflow
  ocfs2: fix posix_acl_create deadlock
  ocfs2: revert using ocfs2_acl_chmod to avoid inode cluster lock hang
  net/route: enforce hoplimit max value
  tcp: refresh skb timestamp at retransmit time
  net: thunderx: avoid exposing kernel stack
  net: fix a kernel infoleak in x25 module
  uapi glibc compat: fix compile errors when glibc net/if.h included before linux/if.h MIME-Version: 1.0
  bridge: fix igmp / mld query parsing
  net: bridge: fix old ioctl unlocked net device walk
  VSOCK: do not disconnect socket when peer has shutdown SEND only
  net/mlx4_en: Fix endianness bug in IPV6 csum calculation
  net: fix infoleak in rtnetlink
  net: fix infoleak in llc
  net: fec: only clear a queue's work bit if the queue was emptied
  netem: Segment GSO packets on enqueue
  sch_dsmark: update backlog as well
  sch_htb: update backlog as well
  net_sched: update hierarchical backlog too
  net_sched: introduce qdisc_replace() helper
  gre: do not pull header in ICMP error processing
  net: Implement net_dbg_ratelimited() for CONFIG_DYNAMIC_DEBUG case
  samples/bpf: fix trace_output example
  bpf: fix check_map_func_compatibility logic
  bpf: fix refcnt overflow
  bpf: fix double-fdput in replace_map_fd_with_map_ptr()
  net/mlx4_en: fix spurious timestamping callbacks
  ipv4/fib: don't warn when primary address is missing if in_dev is dead
  net/mlx5e: Fix minimum MTU
  net/mlx5e: Device's mtu field is u16 and not int
  openvswitch: use flow protocol when recalculating ipv6 checksums
  atl2: Disable unimplemented scatter/gather feature
  vlan: pull on __vlan_insert_tag error path and fix csum correction
  net: use skb_postpush_rcsum instead of own implementations
  cdc_mbim: apply "NDP to end" quirk to all Huawei devices
  bpf/verifier: reject invalid LD_ABS | BPF_DW instruction
  net: sched: do not requeue a NULL skb
  packet: fix heap info leak in PACKET_DIAG_MCLIST sock_diag interface
  route: do not cache fib route info on local routes with oif
  decnet: Do not build routes to devices without decnet private data.
  parisc: Use generic extable search and sort routines
  arm64: kasan: Use actual memory node when populating the kernel image shadow
  arm64: mm: treat memstart_addr as a signed quantity
  arm64: lse: deal with clobbered IP registers after branch via PLT
  arm64: mm: check at build time that PAGE_OFFSET divides the VA space evenly
  arm64: kasan: Fix zero shadow mapping overriding kernel image shadow
  arm64: consistently use p?d_set_huge
  arm64: fix KASLR boot-time I-cache maintenance
  arm64: hugetlb: partial revert of 66b3923a1a0f
  arm64: make irq_stack_ptr more robust
  arm64: efi: invoke EFI_RNG_PROTOCOL to supply KASLR randomness
  efi: stub: use high allocation for converted command line
  efi: stub: add implementation of efi_random_alloc()
  efi: stub: implement efi_get_random_bytes() based on EFI_RNG_PROTOCOL
  arm64: kaslr: randomize the linear region
  arm64: add support for kernel ASLR
  arm64: add support for building vmlinux as a relocatable PIE binary
  arm64: switch to relative exception tables
  extable: add support for relative extables to search and sort routines
  scripts/sortextable: add support for ET_DYN binaries
  arm64: futex.h: Add missing PAN toggling
  arm64: make asm/elf.h available to asm files
  arm64: avoid dynamic relocations in early boot code
  arm64: avoid R_AARCH64_ABS64 relocations for Image header fields
  arm64: add support for module PLTs
  arm64: move brk immediate argument definitions to separate header
  arm64: mm: use bit ops rather than arithmetic in pa/va translations
  arm64: mm: only perform memstart_addr sanity check if DEBUG_VM
  arm64: User die() instead of panic() in do_page_fault()
  arm64: allow kernel Image to be loaded anywhere in physical memory
  arm64: defer __va translation of initrd_start and initrd_end
  arm64: move kernel image to base of vmalloc area
  arm64: kvm: deal with kernel symbols outside of linear mapping
  arm64: decouple early fixmap init from linear mapping
  arm64: pgtable: implement static [pte|pmd|pud]_offset variants
  arm64: introduce KIMAGE_VADDR as the virtual base of the kernel region
  arm64: add support for ioremap() block mappings
  arm64: prevent potential circular header dependencies in asm/bug.h
  of/fdt: factor out assignment of initrd_start/initrd_end
  of/fdt: make memblock minimum physical address arch configurable
  arm64: Remove the get_thread_info() function
  arm64: kernel: Don't toggle PAN on systems with UAO
  arm64: cpufeature: Test 'matches' pointer to find the end of the list
  arm64: kernel: Add support for User Access Override
  arm64: add ARMv8.2 id_aa64mmfr2 boiler plate
  arm64: cpufeature: Change read_cpuid() to use sysreg's mrs_s macro
  arm64: use local label prefixes for __reg_num symbols
  arm64: vdso: Mark vDSO code as read-only
  arm64: ubsan: select ARCH_HAS_UBSAN_SANITIZE_ALL
  arm64: ptdump: Indicate whether memory should be faulting
  arm64: Add support for ARCH_SUPPORTS_DEBUG_PAGEALLOC
  arm64: Drop alloc function from create_mapping
  arm64: prefetch: add missing #include for spin_lock_prefetch
  arm64: lib: patch in prfm for copy_page if requested
  arm64: lib: improve copy_page to deal with 128 bytes at a time
  arm64: prefetch: add alternative pattern for CPUs without a prefetcher
  arm64: prefetch: don't provide spin_lock_prefetch with LSE
  arm64: allow vmalloc regions to be set with set_memory_*
  arm64: kernel: implement ACPI parking protocol
  arm64: mm: create new fine-grained mappings at boot
  arm64: ensure _stext and _etext are page-aligned
  arm64: mm: allow passing a pgdir to alloc_init_*
  arm64: mm: allocate pagetables anywhere
  arm64: mm: use fixmap when creating page tables
  arm64: mm: add functions to walk tables in fixmap
  arm64: mm: add __{pud,pgd}_populate
  arm64: mm: avoid redundant __pa(__va(x))
  arm64: mm: add functions to walk page tables by PA
  arm64: mm: move pte_* macros
  arm64: kasan: avoid TLB conflicts
  arm64: mm: add code to safely replace TTBR1_EL1
  arm64: add function to install the idmap
  arm64: unmap idmap earlier
  arm64: unify idmap removal
  arm64: mm: place empty_zero_page in bss
  arm64: mm: specialise pagetable allocators
  asm-generic: Fix local variable shadow in __set_fixmap_offset
  Eliminate the .eh_frame sections from the aarch64 vmlinux and kernel modules
  arm64: Fix an enum typo in mm/dump.c
  arm64: kasan: ensure that the KASAN zero page is mapped read-only
  arch/arm64/include/asm/pgtable.h: add pmd_mkclean for THP
  arm64: hide __efistub_ aliases from kallsyms
  Linux 4.4.10
  drm/i915/skl: Fix DMC load on Skylake J0 and K0
  lib/test-string_helpers.c: fix and improve string_get_size() tests
  ACPI / processor: Request native thermal interrupt handling via _OSC
  drm/i915: Fake HDMI live status
  drm/i915: Make RPS EI/thresholds multiple of 25 on SNB-BDW
  drm/i915: Fix eDP low vswing for Broadwell
  drm/i915/ddi: Fix eDP VDD handling during booting and suspend/resume
  drm/radeon: make sure vertical front porch is at least 1
  iio: ak8975: fix maybe-uninitialized warning
  iio: ak8975: Fix NULL pointer exception on early interrupt
  drm/amdgpu: set metadata pointer to NULL after freeing.
  drm/amdgpu: make sure vertical front porch is at least 1
  gpu: ipu-v3: Fix imx-ipuv3-crtc module autoloading
  nvmem: mxs-ocotp: fix buffer overflow in read
  USB: serial: cp210x: add Straizona Focusers device ids
  USB: serial: cp210x: add ID for Link ECU
  ata: ahci-platform: Add ports-implemented DT bindings.
  libahci: save port map for forced port map
  powerpc: Fix bad inline asm constraint in create_zero_mask()
  ACPICA: Dispatcher: Update thread ID for recursive method calls
  x86/sysfb_efi: Fix valid BAR address range check
  ARC: Add missing io barriers to io{read,write}{16,32}be()
  ARM: cpuidle: Pass on arm_cpuidle_suspend()'s return value
  propogate_mnt: Handle the first propogated copy being a slave
  fs/pnode.c: treat zero mnt_group_id-s as unequal
  x86/tsc: Read all ratio bits from MSR_PLATFORM_INFO
  MAINTAINERS: Remove asterisk from EFI directory names
  writeback: Fix performance regression in wb_over_bg_thresh()
  batman-adv: Reduce refcnt of removed router when updating route
  batman-adv: Fix broadcast/ogm queue limit on a removed interface
  batman-adv: Check skb size before using encapsulated ETH+VLAN header
  batman-adv: fix DAT candidate selection (must use vid)
  mm: update min_free_kbytes from khugepaged after core initialization
  proc: prevent accessing /proc/<PID>/environ until it's ready
  Input: zforce_ts - fix dual touch recognition
  HID: Fix boot delay for Creative SB Omni Surround 5.1 with quirk
  HID: wacom: Add support for DTK-1651
  xen/evtchn: fix ring resize when binding new events
  xen/balloon: Fix crash when ballooning on x86 32 bit PAE
  xen: Fix page <-> pfn conversion on 32 bit systems
  ARM: SoCFPGA: Fix secondary CPU startup in thumb2 kernel
  ARM: EXYNOS: Properly skip unitialized parent clock in power domain on
  mm/zswap: provide unique zpool name
  mm, cma: prevent nr_isolated_* counters from going negative
  Minimal fix-up of bad hashing behavior of hash_64()
  MD: make bio mergeable
  tracing: Don't display trigger file for events that can't be enabled
  mac80211: fix statistics leak if dev_alloc_name() fails
  ath9k: ar5008_hw_cmn_spur_mitigate: add missing mask_m & mask_p initialisation
  lpfc: fix misleading indentation
  clk: qcom: msm8960: Fix ce3_src register offset
  clk: versatile: sp810: support reentrance
  clk: qcom: msm8960: fix ce3_core clk enable register
  clk: meson: Fix meson_clk_register_clks() signature type mismatch
  clk: rockchip: free memory in error cases when registering clock branches
  soc: rockchip: power-domain: fix err handle while probing
  clk-divider: make sure read-only dividers do not write to their register
  CNS3xxx: Fix PCI cns3xxx_write_config()
  mwifiex: fix corner case association failure
  ata: ahci_xgene: dereferencing uninitialized pointer in probe
  nbd: ratelimit error msgs after socket close
  mfd: intel-lpss: Remove clock tree on error path
  ipvs: drop first packet to redirect conntrack
  ipvs: correct initial offset of Call-ID header search in SIP persistence engine
  ipvs: handle ip_vs_fill_iph_skb_off failure
  RDMA/iw_cxgb4: Fix bar2 virt addr calculation for T4 chips
  Revert: "powerpc/tm: Check for already reclaimed tasks"
  arm64: head.S: use memset to clear BSS
  efi: stub: define DISABLE_BRANCH_PROFILING for all architectures
  arm64: entry: remove pointless SPSR mode check
  arm64: mm: move pgd_cache initialisation to pgtable_cache_init
  arm64: module: avoid undefined shift behavior in reloc_data()
  arm64: module: fix relocation of movz instruction with negative immediate
  arm64: traps: address fallout from printk -> pr_* conversion
  arm64: ftrace: fix a stack tracer's output under function graph tracer
  arm64: pass a task parameter to unwind_frame()
  arm64: ftrace: modify a stack frame in a safe way
  arm64: remove irq_count and do_softirq_own_stack()
  arm64: hugetlb: add support for PTE contiguous bit
  arm64: Use PoU cache instr for I/D coherency
  arm64: Defer dcache flush in __cpu_copy_user_page
  arm64: reduce stack use in irq_handler
  arm64: Documentation: add list of software workarounds for errata
  arm64: mm: place __cpu_setup in .text
  arm64: cmpxchg: Don't incldue linux/mmdebug.h
  arm64: mm: fold alternatives into .init
  arm64: Remove redundant padding from linker script
  arm64: mm: remove pointless PAGE_MASKing
  arm64: don't call C code with el0's fp register
  arm64: when walking onto the task stack, check sp & fp are in current->stack
  arm64: Add this_cpu_ptr() assembler macro for use in entry.S
  arm64: irq: fix walking from irq stack to task stack
  arm64: Add do_softirq_own_stack() and enable irq_stacks
  arm64: Modify stack trace and dump for use with irq_stack
  arm64: Store struct thread_info in sp_el0
  arm64: Add trace_hardirqs_off annotation in ret_to_user
  arm64: ftrace: fix the comments for ftrace_modify_code
  arm64: ftrace: stop using kstop_machine to enable/disable tracing
  arm64: spinlock: serialise spin_unlock_wait against concurrent lockers
  arm64: enable HAVE_IRQ_TIME_ACCOUNTING
  arm64: fix COMPAT_SHMLBA definition for large pages
  arm64: add __init/__initdata section marker to some functions/variables
  arm64: pgtable: implement pte_accessible()
  arm64: mm: allow sections for unaligned bases
  arm64: mm: detect bad __create_mapping uses
  Linux 4.4.9
  extcon: max77843: Use correct size for reading the interrupt register
  stm class: Select CONFIG_SRCU
  megaraid_sas: add missing curly braces in ioctl handler
  sunrpc/cache: drop reference when sunrpc_cache_pipe_upcall() detects a race
  thermal: rockchip: fix a impossible condition caused by the warning
  unbreak allmodconfig KCONFIG_ALLCONFIG=...
  jme: Fix device PM wakeup API usage
  jme: Do not enable NIC WoL functions on S0
  bus: imx-weim: Take the 'status' property value into account
  ARM: dts: pxa: fix dma engine node to pxa3xx-nand
  ARM: dts: armada-375: use armada-370-sata for SATA
  ARM: EXYNOS: select THERMAL_OF
  ARM: prima2: always enable reset controller
  ARM: OMAP3: Add cpuidle parameters table for omap3430
  ext4: fix races of writeback with punch hole and zero range
  ext4: fix races between buffered IO and collapse / insert range
  ext4: move unlocked dio protection from ext4_alloc_file_blocks()
  ext4: fix races between page faults and hole punching
  perf stat: Document --detailed option
  perf tools: handle spaces in file names obtained from /proc/pid/maps
  perf hists browser: Only offer symbol scripting when a symbol is under the cursor
  mtd: nand: Drop mtd.owner requirement in nand_scan
  mtd: brcmnand: Fix v7.1 register offsets
  mtd: spi-nor: remove micron_quad_enable()
  serial: sh-sci: Remove cpufreq notifier to fix crash/deadlock
  ext4: fix NULL pointer dereference in ext4_mark_inode_dirty()
  x86/mm/kmmio: Fix mmiotrace for hugepages
  perf evlist: Reference count the cpu and thread maps at set_maps()
  drivers/misc/ad525x_dpot: AD5274 fix RDAC read back errors
  rtc: max77686: Properly handle regmap_irq_get_virq() error code
  rtc: rx8025: remove rv8803 id
  rtc: ds1685: passing bogus values to irq_restore
  rtc: vr41xx: Wire up alarm_irq_enable
  rtc: hym8563: fix invalid year calculation
  PM / Domains: Fix removal of a subdomain
  PM / OPP: Initialize u_volt_min/max to a valid value
  misc: mic/scif: fix wrap around tests
  misc/bmp085: Enable building as a module
  lib/mpi: Endianness fix
  fbdev: da8xx-fb: fix videomodes of lcd panels
  scsi_dh: force modular build if SCSI is a module
  paride: make 'verbose' parameter an 'int' again
  regulator: s5m8767: fix get_register() error handling
  irqchip/mxs: Fix error check of of_io_request_and_map()
  irqchip/sunxi-nmi: Fix error check of of_io_request_and_map()
  spi/rockchip: Make sure spi clk is on in rockchip_spi_set_cs
  locking/mcs: Fix mcs_spin_lock() ordering
  regulator: core: Fix nested locking of supplies
  regulator: core: Ensure we lock all regulators
  regulator: core: fix regulator_lock_supply regression
  Revert "regulator: core: Fix nested locking of supplies"
  videobuf2-v4l2: Verify planes array in buffer dequeueing
  videobuf2-core: Check user space planes array in dqbuf
  USB: usbip: fix potential out-of-bounds write
  cgroup: make sure a parent css isn't freed before its children
  mm/hwpoison: fix wrong num_poisoned_pages accounting
  mm: vmscan: reclaim highmem zone if buffer_heads is over limit
  numa: fix /proc/<pid>/numa_maps for THP
  mm/huge_memory: replace VM_NO_THP VM_BUG_ON with actual VMA check
  memcg: relocate charge moving from ->attach to ->post_attach
  cgroup, cpuset: replace cpuset_post_attach_flush() with cgroup_subsys->post_attach callback
  slub: clean up code for kmem cgroup support to kmem_cache_free_bulk
  workqueue: fix ghost PENDING flag while doing MQ IO
  x86/apic: Handle zero vector gracefully in clear_vector_irq()
  efi: Expose non-blocking set_variable() wrapper to efivars
  efi: Fix out-of-bounds read in variable_matches()
  IB/security: Restrict use of the write() interface
  IB/mlx5: Expose correct max_sge_rd limit
  cxl: Keep IRQ mappings on context teardown
  v4l2-dv-timings.h: fix polarity for 4k formats
  vb2-memops: Fix over allocation of frame vectors
  ASoC: rt5640: Correct the digital interface data select
  ASoC: dapm: Make sure we have a card when displaying component widgets
  ASoC: ssm4567: Reset device before regcache_sync()
  ASoC: s3c24xx: use const snd_soc_component_driver pointer
  EDAC: i7core, sb_edac: Don't return NOTIFY_BAD from mce_decoder callback
  toshiba_acpi: Fix regression caused by hotkey enabling value
  i2c: exynos5: Fix possible ABBA deadlock by keeping I2C clock prepared
  i2c: cpm: Fix build break due to incompatible pointer types
  perf intel-pt: Fix segfault tracing transactions
  drm/i915: Use fw_domains_put_with_fifo() on HSW
  drm/i915: Fixup the free space logic in ring_prepare
  drm/amdkfd: uninitialized variable in dbgdev_wave_control_set_registers()
  drm/i915: skl_update_scaler() wants a rotation bitmask instead of bit number
  drm/i915: Cleanup phys status page too
  pwm: brcmstb: Fix check of devm_ioremap_resource() return code
  drm/dp/mst: Get validated port ref in drm_dp_update_payload_part1()
  drm/dp/mst: Restore primary hub guid on resume
  drm/dp/mst: Validate port in drm_dp_payload_send_msg()
  drm/nouveau/gr/gf100: select a stream master to fixup tfb offset queries
  drm: Loongson-3 doesn't fully support wc memory
  drm/radeon: fix vertical bars appear on monitor (v2)
  drm/radeon: forbid mapping of userptr bo through radeon device file
  drm/radeon: fix initial connector audio value
  drm/radeon: add a quirk for a XFX R9 270X
  drm/amdgpu: fix regression on CIK (v2)
  amdgpu/uvd: add uvd fw version for amdgpu
  drm/amdgpu: bump the afmt limit for CZ, ST, Polaris
  drm/amdgpu: use defines for CRTCs and AMFT blocks
  drm/amdgpu: when suspending, if uvd/vce was running. need to cancel delay work.
  iommu/dma: Restore scatterlist offsets correctly
  iommu/amd: Fix checking of pci dma aliases
  pinctrl: single: Fix pcs_parse_bits_in_pinctrl_entry to use __ffs than ffs
  pinctrl: mediatek: correct debounce time unit in mtk_gpio_set_debounce
  xen kconfig: don't "select INPUT_XEN_KBDDEV_FRONTEND"
  Input: pmic8xxx-pwrkey - fix algorithm for converting trigger delay
  Input: gtco - fix crash on detecting device without endpoints
  netlink: don't send NETLINK_URELEASE for unbound sockets
  nl80211: check netlink protocol in socket release notification
  powerpc: Update TM user feature bits in scan_features()
  powerpc: Update cpu_user_features2 in scan_features()
  powerpc: scan_features() updates incorrect bits for REAL_LE
  crypto: talitos - fix AEAD tcrypt tests
  crypto: talitos - fix crash in talitos_cra_init()
  crypto: sha1-mb - use corrcet pointer while completing jobs
  crypto: ccp - Prevent information leakage on export
  iwlwifi: mvm: fix memory leak in paging
  iwlwifi: pcie: lower the debug level for RSA semaphore access
  s390/pci: add extra padding to function measurement block
  cpufreq: intel_pstate: Fix processing for turbo activation ratio
  Revert "drm/amdgpu: disable runtime pm on PX laptops without dGPU power control"
  Revert "drm/radeon: disable runtime pm on PX laptops without dGPU power control"
  drm/i915: Fix race condition in intel_dp_destroy_mst_connector()
  drm/qxl: fix cursor position with non-zero hotspot
  drm/nouveau/core: use vzalloc for allocating ramht
  futex: Acknowledge a new waiter in counter before plist
  futex: Handle unlock_pi race gracefully
  asm-generic/futex: Re-enable preemption in futex_atomic_cmpxchg_inatomic()
  ALSA: hda - Add dock support for ThinkPad X260
  ALSA: pcxhr: Fix missing mutex unlock
  ALSA: hda - add PCI ID for Intel Broxton-T
  ALSA: hda - Keep powering up ADCs on Cirrus codecs
  ALSA: hda/realtek - Add ALC3234 headset mode for Optiplex 9020m
  ALSA: hda - Don't trust the reported actual power state
  x86 EDAC, sb_edac.c: Repair damage introduced when "fixing" channel address
  x86/mm/xen: Suppress hugetlbfs in PV guests
  arm64: Update PTE_RDONLY in set_pte_at() for PROT_NONE permission
  arm64: Honour !PTE_WRITE in set_pte_at() for kernel mappings
  sched/cgroup: Fix/cleanup cgroup teardown/init
  dmaengine: pxa_dma: fix the maximum requestor line
  dmaengine: hsu: correct use of channel status register
  dmaengine: dw: fix master selection
  debugfs: Make automount point inodes permanently empty
  lib: lz4: fixed zram with lz4 on big endian machines
  dm cache metadata: fix cmd_read_lock() acquiring write lock
  dm cache metadata: fix READ_LOCK macros and cleanup WRITE_LOCK macros
  usb: gadget: f_fs: Fix use-after-free
  usb: hcd: out of bounds access in for_each_companion
  xhci: fix 10 second timeout on removal of PCI hotpluggable xhci controllers
  usb: xhci: fix wild pointers in xhci_mem_cleanup
  xhci: resume USB 3 roothub first
  usb: xhci: applying XHCI_PME_STUCK_QUIRK to Intel BXT B0 host
  assoc_array: don't call compare_object() on a node
  ARM: OMAP2+: hwmod: Fix updating of sysconfig register
  ARM: OMAP2: Fix up interconnect barrier initialization for DRA7
  ARM: mvebu: Correct unit address for linksys
  ARM: dts: AM43x-epos: Fix clk parent for synctimer
  KVM: arm/arm64: Handle forward time correction gracefully
  kvm: x86: do not leak guest xcr0 into host interrupt handlers
  x86/mce: Avoid using object after free in genpool
  block: loop: fix filesystem corruption in case of aio/dio
  block: partition: initialize percpuref before sending out KOBJ_ADD

Conflicts:
	arch/arm64/Kconfig
	arch/arm64/include/asm/cputype.h
	arch/arm64/include/asm/hardirq.h
	arch/arm64/include/asm/irq.h
	arch/arm64/include/asm/mmu_context.h
	arch/arm64/kernel/cpu_errata.c
	arch/arm64/kernel/cpuinfo.c
	arch/arm64/kernel/setup.c
	arch/arm64/kernel/smp.c
	arch/arm64/kernel/stacktrace.c
	arch/arm64/mm/init.c
	arch/arm64/mm/mmu.c
	arch/arm64/mm/pageattr.c
	mm/memcontrol.c

CRs-Fixed: 1069136
Signed-off-by: Bryan Huntsman <bryanh@codeaurora.org>
Signed-off-by: Runmin Wang <runminw@codeaurora.org>
Change-Id: Ie9a16debd0578331a66947376f3b787a7bb54d65
2016-10-21 18:00:55 -07:00
Vivek Veenam
3951ec5f08 msm: camera: Add a driver to control IR CUT device
This driver is able to control a IR CUT device. The interface to
user space is:
CFG_IR_CUT_INIT
CFG_IR_CUT_OFF
CFG_IR_CUT_ON
CFG_IR_CUT_RELEASE

Change-Id: I30d1c4e6c40b8e58a70f06db9e05231b4c7f676f
Signed-off-by: Vivek Veenam <vveenam@codeaurora.org>
2016-09-16 10:29:29 -07:00
Vivek Veenam
1dc1147122 msm: camera: Add a driver to control IR LED device
This driver is able to control a IR LED device. The interface to
user space is:
CFG_IR_LED_INIT
CFG_IR_LED_OFF
CFG_IR_LED_ON with intensity field
CFG_IR_LED_RELEASE.

Change-Id: I2e04fa47efd1454bb487eca67bd9ceaeab3e9edf
Signed-off-by: Vivek Veenam <vveenam@codeaurora.org>
2016-09-11 23:22:40 -07:00
Linux Build Service Account
2b4e8cbd34 Merge "Revert "Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4"" 2016-08-29 00:49:25 -07:00
Trilok Soni
5ab1e18aa3 Revert "Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4"
This reverts commit 9d6fd2c3e9 ("Merge remote-tracking branch
'msm-4.4/tmp-510d0a3f' into msm-4.4"), because it breaks the
dump parsing tools due to kernel can be loaded anywhere in the memory
now and not fixed at linear mapping.

Change-Id: Id416f0a249d803442847d09ac47781147b0d0ee6
Signed-off-by: Trilok Soni <tsoni@codeaurora.org>
2016-08-26 14:34:05 -07:00
Jeremy Gebben
d73f8ad9d7 radio: iris: uapi header split
The uapi directory should only contain userspace visible
definitions, move everything else to the regular include directory.

Change-Id: I33a2f4511eef540c979a3880e7926cbe6cadafe6
Signed-off-by: Jeremy Gebben <jgebben@codeaurora.org>
Signed-off-by: Rupesh Tatiya <rtatiya@codeaurora.org>
2016-08-21 22:15:23 -07:00
Trilok Soni
9d6fd2c3e9 Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4
* msm-4.4/tmp-510d0a3f:
  Linux 4.4.11
  nf_conntrack: avoid kernel pointer value leak in slab name
  drm/radeon: fix DP link training issue with second 4K monitor
  drm/i915/bdw: Add missing delay during L3 SQC credit programming
  drm/i915: Bail out of pipe config compute loop on LPT
  drm/radeon: fix PLL sharing on DCE6.1 (v2)
  Revert "[media] videobuf2-v4l2: Verify planes array in buffer dequeueing"
  Input: max8997-haptic - fix NULL pointer dereference
  get_rock_ridge_filename(): handle malformed NM entries
  tools lib traceevent: Do not reassign parg after collapse_tree()
  qla1280: Don't allocate 512kb of host tags
  atomic_open(): fix the handling of create_error
  regulator: axp20x: Fix axp22x ldo_io voltage ranges
  regulator: s2mps11: Fix invalid selector mask and voltages for buck9
  workqueue: fix rebind bound workers warning
  ARM: dts: at91: sam9x5: Fix the memory range assigned to the PMC
  vfs: rename: check backing inode being equal
  vfs: add vfs_select_inode() helper
  perf/core: Disable the event on a truncated AUX record
  regmap: spmi: Fix regmap_spmi_ext_read in multi-byte case
  pinctrl: at91-pio4: fix pull-up/down logic
  spi: spi-ti-qspi: Handle truncated frames properly
  spi: spi-ti-qspi: Fix FLEN and WLEN settings if bits_per_word is overridden
  spi: pxa2xx: Do not detect number of enabled chip selects on Intel SPT
  ALSA: hda - Fix broken reconfig
  ALSA: hda - Fix white noise on Asus UX501VW headset
  ALSA: hda - Fix subwoofer pin on ASUS N751 and N551
  ALSA: usb-audio: Yet another Phoneix Audio device quirk
  ALSA: usb-audio: Quirk for yet another Phoenix Audio devices (v2)
  crypto: testmgr - Use kmalloc memory for RSA input
  crypto: hash - Fix page length clamping in hash walk
  crypto: qat - fix invalid pf2vf_resp_wq logic
  s390/mm: fix asce_bits handling with dynamic pagetable levels
  zsmalloc: fix zs_can_compact() integer overflow
  ocfs2: fix posix_acl_create deadlock
  ocfs2: revert using ocfs2_acl_chmod to avoid inode cluster lock hang
  net/route: enforce hoplimit max value
  tcp: refresh skb timestamp at retransmit time
  net: thunderx: avoid exposing kernel stack
  net: fix a kernel infoleak in x25 module
  uapi glibc compat: fix compile errors when glibc net/if.h included before linux/if.h MIME-Version: 1.0
  bridge: fix igmp / mld query parsing
  net: bridge: fix old ioctl unlocked net device walk
  VSOCK: do not disconnect socket when peer has shutdown SEND only
  net/mlx4_en: Fix endianness bug in IPV6 csum calculation
  net: fix infoleak in rtnetlink
  net: fix infoleak in llc
  net: fec: only clear a queue's work bit if the queue was emptied
  netem: Segment GSO packets on enqueue
  sch_dsmark: update backlog as well
  sch_htb: update backlog as well
  net_sched: update hierarchical backlog too
  net_sched: introduce qdisc_replace() helper
  gre: do not pull header in ICMP error processing
  net: Implement net_dbg_ratelimited() for CONFIG_DYNAMIC_DEBUG case
  samples/bpf: fix trace_output example
  bpf: fix check_map_func_compatibility logic
  bpf: fix refcnt overflow
  bpf: fix double-fdput in replace_map_fd_with_map_ptr()
  net/mlx4_en: fix spurious timestamping callbacks
  ipv4/fib: don't warn when primary address is missing if in_dev is dead
  net/mlx5e: Fix minimum MTU
  net/mlx5e: Device's mtu field is u16 and not int
  openvswitch: use flow protocol when recalculating ipv6 checksums
  atl2: Disable unimplemented scatter/gather feature
  vlan: pull on __vlan_insert_tag error path and fix csum correction
  net: use skb_postpush_rcsum instead of own implementations
  cdc_mbim: apply "NDP to end" quirk to all Huawei devices
  bpf/verifier: reject invalid LD_ABS | BPF_DW instruction
  net: sched: do not requeue a NULL skb
  packet: fix heap info leak in PACKET_DIAG_MCLIST sock_diag interface
  route: do not cache fib route info on local routes with oif
  decnet: Do not build routes to devices without decnet private data.
  parisc: Use generic extable search and sort routines
  arm64: kasan: Use actual memory node when populating the kernel image shadow
  arm64: mm: treat memstart_addr as a signed quantity
  arm64: lse: deal with clobbered IP registers after branch via PLT
  arm64: mm: check at build time that PAGE_OFFSET divides the VA space evenly
  arm64: kasan: Fix zero shadow mapping overriding kernel image shadow
  arm64: consistently use p?d_set_huge
  arm64: fix KASLR boot-time I-cache maintenance
  arm64: hugetlb: partial revert of 66b3923a1a0f
  arm64: make irq_stack_ptr more robust
  arm64: efi: invoke EFI_RNG_PROTOCOL to supply KASLR randomness
  efi: stub: use high allocation for converted command line
  efi: stub: add implementation of efi_random_alloc()
  efi: stub: implement efi_get_random_bytes() based on EFI_RNG_PROTOCOL
  arm64: kaslr: randomize the linear region
  arm64: add support for kernel ASLR
  arm64: add support for building vmlinux as a relocatable PIE binary
  arm64: switch to relative exception tables
  extable: add support for relative extables to search and sort routines
  scripts/sortextable: add support for ET_DYN binaries
  arm64: futex.h: Add missing PAN toggling
  arm64: make asm/elf.h available to asm files
  arm64: avoid dynamic relocations in early boot code
  arm64: avoid R_AARCH64_ABS64 relocations for Image header fields
  arm64: add support for module PLTs
  arm64: move brk immediate argument definitions to separate header
  arm64: mm: use bit ops rather than arithmetic in pa/va translations
  arm64: mm: only perform memstart_addr sanity check if DEBUG_VM
  arm64: User die() instead of panic() in do_page_fault()
  arm64: allow kernel Image to be loaded anywhere in physical memory
  arm64: defer __va translation of initrd_start and initrd_end
  arm64: move kernel image to base of vmalloc area
  arm64: kvm: deal with kernel symbols outside of linear mapping
  arm64: decouple early fixmap init from linear mapping
  arm64: pgtable: implement static [pte|pmd|pud]_offset variants
  arm64: introduce KIMAGE_VADDR as the virtual base of the kernel region
  arm64: add support for ioremap() block mappings
  arm64: prevent potential circular header dependencies in asm/bug.h
  of/fdt: factor out assignment of initrd_start/initrd_end
  of/fdt: make memblock minimum physical address arch configurable
  arm64: Remove the get_thread_info() function
  arm64: kernel: Don't toggle PAN on systems with UAO
  arm64: cpufeature: Test 'matches' pointer to find the end of the list
  arm64: kernel: Add support for User Access Override
  arm64: add ARMv8.2 id_aa64mmfr2 boiler plate
  arm64: cpufeature: Change read_cpuid() to use sysreg's mrs_s macro
  arm64: use local label prefixes for __reg_num symbols
  arm64: vdso: Mark vDSO code as read-only
  arm64: ubsan: select ARCH_HAS_UBSAN_SANITIZE_ALL
  arm64: ptdump: Indicate whether memory should be faulting
  arm64: Add support for ARCH_SUPPORTS_DEBUG_PAGEALLOC
  arm64: Drop alloc function from create_mapping
  arm64: prefetch: add missing #include for spin_lock_prefetch
  arm64: lib: patch in prfm for copy_page if requested
  arm64: lib: improve copy_page to deal with 128 bytes at a time
  arm64: prefetch: add alternative pattern for CPUs without a prefetcher
  arm64: prefetch: don't provide spin_lock_prefetch with LSE
  arm64: allow vmalloc regions to be set with set_memory_*
  arm64: kernel: implement ACPI parking protocol
  arm64: mm: create new fine-grained mappings at boot
  arm64: ensure _stext and _etext are page-aligned
  arm64: mm: allow passing a pgdir to alloc_init_*
  arm64: mm: allocate pagetables anywhere
  arm64: mm: use fixmap when creating page tables
  arm64: mm: add functions to walk tables in fixmap
  arm64: mm: add __{pud,pgd}_populate
  arm64: mm: avoid redundant __pa(__va(x))
  arm64: mm: add functions to walk page tables by PA
  arm64: mm: move pte_* macros
  arm64: kasan: avoid TLB conflicts
  arm64: mm: add code to safely replace TTBR1_EL1
  arm64: add function to install the idmap
  arm64: unmap idmap earlier
  arm64: unify idmap removal
  arm64: mm: place empty_zero_page in bss
  arm64: mm: specialise pagetable allocators
  asm-generic: Fix local variable shadow in __set_fixmap_offset
  Eliminate the .eh_frame sections from the aarch64 vmlinux and kernel modules
  arm64: Fix an enum typo in mm/dump.c
  arm64: kasan: ensure that the KASAN zero page is mapped read-only
  arch/arm64/include/asm/pgtable.h: add pmd_mkclean for THP
  arm64: hide __efistub_ aliases from kallsyms
  Linux 4.4.10
  drm/i915/skl: Fix DMC load on Skylake J0 and K0
  lib/test-string_helpers.c: fix and improve string_get_size() tests
  ACPI / processor: Request native thermal interrupt handling via _OSC
  drm/i915: Fake HDMI live status
  drm/i915: Make RPS EI/thresholds multiple of 25 on SNB-BDW
  drm/i915: Fix eDP low vswing for Broadwell
  drm/i915/ddi: Fix eDP VDD handling during booting and suspend/resume
  drm/radeon: make sure vertical front porch is at least 1
  iio: ak8975: fix maybe-uninitialized warning
  iio: ak8975: Fix NULL pointer exception on early interrupt
  drm/amdgpu: set metadata pointer to NULL after freeing.
  drm/amdgpu: make sure vertical front porch is at least 1
  gpu: ipu-v3: Fix imx-ipuv3-crtc module autoloading
  nvmem: mxs-ocotp: fix buffer overflow in read
  USB: serial: cp210x: add Straizona Focusers device ids
  USB: serial: cp210x: add ID for Link ECU
  ata: ahci-platform: Add ports-implemented DT bindings.
  libahci: save port map for forced port map
  powerpc: Fix bad inline asm constraint in create_zero_mask()
  ACPICA: Dispatcher: Update thread ID for recursive method calls
  x86/sysfb_efi: Fix valid BAR address range check
  ARC: Add missing io barriers to io{read,write}{16,32}be()
  ARM: cpuidle: Pass on arm_cpuidle_suspend()'s return value
  propogate_mnt: Handle the first propogated copy being a slave
  fs/pnode.c: treat zero mnt_group_id-s as unequal
  x86/tsc: Read all ratio bits from MSR_PLATFORM_INFO
  MAINTAINERS: Remove asterisk from EFI directory names
  writeback: Fix performance regression in wb_over_bg_thresh()
  batman-adv: Reduce refcnt of removed router when updating route
  batman-adv: Fix broadcast/ogm queue limit on a removed interface
  batman-adv: Check skb size before using encapsulated ETH+VLAN header
  batman-adv: fix DAT candidate selection (must use vid)
  mm: update min_free_kbytes from khugepaged after core initialization
  proc: prevent accessing /proc/<PID>/environ until it's ready
  Input: zforce_ts - fix dual touch recognition
  HID: Fix boot delay for Creative SB Omni Surround 5.1 with quirk
  HID: wacom: Add support for DTK-1651
  xen/evtchn: fix ring resize when binding new events
  xen/balloon: Fix crash when ballooning on x86 32 bit PAE
  xen: Fix page <-> pfn conversion on 32 bit systems
  ARM: SoCFPGA: Fix secondary CPU startup in thumb2 kernel
  ARM: EXYNOS: Properly skip unitialized parent clock in power domain on
  mm/zswap: provide unique zpool name
  mm, cma: prevent nr_isolated_* counters from going negative
  Minimal fix-up of bad hashing behavior of hash_64()
  MD: make bio mergeable
  tracing: Don't display trigger file for events that can't be enabled
  mac80211: fix statistics leak if dev_alloc_name() fails
  ath9k: ar5008_hw_cmn_spur_mitigate: add missing mask_m & mask_p initialisation
  lpfc: fix misleading indentation
  clk: qcom: msm8960: Fix ce3_src register offset
  clk: versatile: sp810: support reentrance
  clk: qcom: msm8960: fix ce3_core clk enable register
  clk: meson: Fix meson_clk_register_clks() signature type mismatch
  clk: rockchip: free memory in error cases when registering clock branches
  soc: rockchip: power-domain: fix err handle while probing
  clk-divider: make sure read-only dividers do not write to their register
  CNS3xxx: Fix PCI cns3xxx_write_config()
  mwifiex: fix corner case association failure
  ata: ahci_xgene: dereferencing uninitialized pointer in probe
  nbd: ratelimit error msgs after socket close
  mfd: intel-lpss: Remove clock tree on error path
  ipvs: drop first packet to redirect conntrack
  ipvs: correct initial offset of Call-ID header search in SIP persistence engine
  ipvs: handle ip_vs_fill_iph_skb_off failure
  RDMA/iw_cxgb4: Fix bar2 virt addr calculation for T4 chips
  Revert: "powerpc/tm: Check for already reclaimed tasks"
  arm64: head.S: use memset to clear BSS
  efi: stub: define DISABLE_BRANCH_PROFILING for all architectures
  arm64: entry: remove pointless SPSR mode check
  arm64: mm: move pgd_cache initialisation to pgtable_cache_init
  arm64: module: avoid undefined shift behavior in reloc_data()
  arm64: module: fix relocation of movz instruction with negative immediate
  arm64: traps: address fallout from printk -> pr_* conversion
  arm64: ftrace: fix a stack tracer's output under function graph tracer
  arm64: pass a task parameter to unwind_frame()
  arm64: ftrace: modify a stack frame in a safe way
  arm64: remove irq_count and do_softirq_own_stack()
  arm64: hugetlb: add support for PTE contiguous bit
  arm64: Use PoU cache instr for I/D coherency
  arm64: Defer dcache flush in __cpu_copy_user_page
  arm64: reduce stack use in irq_handler
  arm64: Documentation: add list of software workarounds for errata
  arm64: mm: place __cpu_setup in .text
  arm64: cmpxchg: Don't incldue linux/mmdebug.h
  arm64: mm: fold alternatives into .init
  arm64: Remove redundant padding from linker script
  arm64: mm: remove pointless PAGE_MASKing
  arm64: don't call C code with el0's fp register
  arm64: when walking onto the task stack, check sp & fp are in current->stack
  arm64: Add this_cpu_ptr() assembler macro for use in entry.S
  arm64: irq: fix walking from irq stack to task stack
  arm64: Add do_softirq_own_stack() and enable irq_stacks
  arm64: Modify stack trace and dump for use with irq_stack
  arm64: Store struct thread_info in sp_el0
  arm64: Add trace_hardirqs_off annotation in ret_to_user
  arm64: ftrace: fix the comments for ftrace_modify_code
  arm64: ftrace: stop using kstop_machine to enable/disable tracing
  arm64: spinlock: serialise spin_unlock_wait against concurrent lockers
  arm64: enable HAVE_IRQ_TIME_ACCOUNTING
  arm64: fix COMPAT_SHMLBA definition for large pages
  arm64: add __init/__initdata section marker to some functions/variables
  arm64: pgtable: implement pte_accessible()
  arm64: mm: allow sections for unaligned bases
  arm64: mm: detect bad __create_mapping uses
  Linux 4.4.9
  extcon: max77843: Use correct size for reading the interrupt register
  stm class: Select CONFIG_SRCU
  megaraid_sas: add missing curly braces in ioctl handler
  sunrpc/cache: drop reference when sunrpc_cache_pipe_upcall() detects a race
  thermal: rockchip: fix a impossible condition caused by the warning
  unbreak allmodconfig KCONFIG_ALLCONFIG=...
  jme: Fix device PM wakeup API usage
  jme: Do not enable NIC WoL functions on S0
  bus: imx-weim: Take the 'status' property value into account
  ARM: dts: pxa: fix dma engine node to pxa3xx-nand
  ARM: dts: armada-375: use armada-370-sata for SATA
  ARM: EXYNOS: select THERMAL_OF
  ARM: prima2: always enable reset controller
  ARM: OMAP3: Add cpuidle parameters table for omap3430
  ext4: fix races of writeback with punch hole and zero range
  ext4: fix races between buffered IO and collapse / insert range
  ext4: move unlocked dio protection from ext4_alloc_file_blocks()
  ext4: fix races between page faults and hole punching
  perf stat: Document --detailed option
  perf tools: handle spaces in file names obtained from /proc/pid/maps
  perf hists browser: Only offer symbol scripting when a symbol is under the cursor
  mtd: nand: Drop mtd.owner requirement in nand_scan
  mtd: brcmnand: Fix v7.1 register offsets
  mtd: spi-nor: remove micron_quad_enable()
  serial: sh-sci: Remove cpufreq notifier to fix crash/deadlock
  ext4: fix NULL pointer dereference in ext4_mark_inode_dirty()
  x86/mm/kmmio: Fix mmiotrace for hugepages
  perf evlist: Reference count the cpu and thread maps at set_maps()
  drivers/misc/ad525x_dpot: AD5274 fix RDAC read back errors
  rtc: max77686: Properly handle regmap_irq_get_virq() error code
  rtc: rx8025: remove rv8803 id
  rtc: ds1685: passing bogus values to irq_restore
  rtc: vr41xx: Wire up alarm_irq_enable
  rtc: hym8563: fix invalid year calculation
  PM / Domains: Fix removal of a subdomain
  PM / OPP: Initialize u_volt_min/max to a valid value
  misc: mic/scif: fix wrap around tests
  misc/bmp085: Enable building as a module
  lib/mpi: Endianness fix
  fbdev: da8xx-fb: fix videomodes of lcd panels
  scsi_dh: force modular build if SCSI is a module
  paride: make 'verbose' parameter an 'int' again
  regulator: s5m8767: fix get_register() error handling
  irqchip/mxs: Fix error check of of_io_request_and_map()
  irqchip/sunxi-nmi: Fix error check of of_io_request_and_map()
  spi/rockchip: Make sure spi clk is on in rockchip_spi_set_cs
  locking/mcs: Fix mcs_spin_lock() ordering
  regulator: core: Fix nested locking of supplies
  regulator: core: Ensure we lock all regulators
  regulator: core: fix regulator_lock_supply regression
  Revert "regulator: core: Fix nested locking of supplies"
  videobuf2-v4l2: Verify planes array in buffer dequeueing
  videobuf2-core: Check user space planes array in dqbuf
  USB: usbip: fix potential out-of-bounds write
  cgroup: make sure a parent css isn't freed before its children
  mm/hwpoison: fix wrong num_poisoned_pages accounting
  mm: vmscan: reclaim highmem zone if buffer_heads is over limit
  numa: fix /proc/<pid>/numa_maps for THP
  mm/huge_memory: replace VM_NO_THP VM_BUG_ON with actual VMA check
  memcg: relocate charge moving from ->attach to ->post_attach
  cgroup, cpuset: replace cpuset_post_attach_flush() with cgroup_subsys->post_attach callback
  slub: clean up code for kmem cgroup support to kmem_cache_free_bulk
  workqueue: fix ghost PENDING flag while doing MQ IO
  x86/apic: Handle zero vector gracefully in clear_vector_irq()
  efi: Expose non-blocking set_variable() wrapper to efivars
  efi: Fix out-of-bounds read in variable_matches()
  IB/security: Restrict use of the write() interface
  IB/mlx5: Expose correct max_sge_rd limit
  cxl: Keep IRQ mappings on context teardown
  v4l2-dv-timings.h: fix polarity for 4k formats
  vb2-memops: Fix over allocation of frame vectors
  ASoC: rt5640: Correct the digital interface data select
  ASoC: dapm: Make sure we have a card when displaying component widgets
  ASoC: ssm4567: Reset device before regcache_sync()
  ASoC: s3c24xx: use const snd_soc_component_driver pointer
  EDAC: i7core, sb_edac: Don't return NOTIFY_BAD from mce_decoder callback
  toshiba_acpi: Fix regression caused by hotkey enabling value
  i2c: exynos5: Fix possible ABBA deadlock by keeping I2C clock prepared
  i2c: cpm: Fix build break due to incompatible pointer types
  perf intel-pt: Fix segfault tracing transactions
  drm/i915: Use fw_domains_put_with_fifo() on HSW
  drm/i915: Fixup the free space logic in ring_prepare
  drm/amdkfd: uninitialized variable in dbgdev_wave_control_set_registers()
  drm/i915: skl_update_scaler() wants a rotation bitmask instead of bit number
  drm/i915: Cleanup phys status page too
  pwm: brcmstb: Fix check of devm_ioremap_resource() return code
  drm/dp/mst: Get validated port ref in drm_dp_update_payload_part1()
  drm/dp/mst: Restore primary hub guid on resume
  drm/dp/mst: Validate port in drm_dp_payload_send_msg()
  drm/nouveau/gr/gf100: select a stream master to fixup tfb offset queries
  drm: Loongson-3 doesn't fully support wc memory
  drm/radeon: fix vertical bars appear on monitor (v2)
  drm/radeon: forbid mapping of userptr bo through radeon device file
  drm/radeon: fix initial connector audio value
  drm/radeon: add a quirk for a XFX R9 270X
  drm/amdgpu: fix regression on CIK (v2)
  amdgpu/uvd: add uvd fw version for amdgpu
  drm/amdgpu: bump the afmt limit for CZ, ST, Polaris
  drm/amdgpu: use defines for CRTCs and AMFT blocks
  drm/amdgpu: when suspending, if uvd/vce was running. need to cancel delay work.
  iommu/dma: Restore scatterlist offsets correctly
  iommu/amd: Fix checking of pci dma aliases
  pinctrl: single: Fix pcs_parse_bits_in_pinctrl_entry to use __ffs than ffs
  pinctrl: mediatek: correct debounce time unit in mtk_gpio_set_debounce
  xen kconfig: don't "select INPUT_XEN_KBDDEV_FRONTEND"
  Input: pmic8xxx-pwrkey - fix algorithm for converting trigger delay
  Input: gtco - fix crash on detecting device without endpoints
  netlink: don't send NETLINK_URELEASE for unbound sockets
  nl80211: check netlink protocol in socket release notification
  powerpc: Update TM user feature bits in scan_features()
  powerpc: Update cpu_user_features2 in scan_features()
  powerpc: scan_features() updates incorrect bits for REAL_LE
  crypto: talitos - fix AEAD tcrypt tests
  crypto: talitos - fix crash in talitos_cra_init()
  crypto: sha1-mb - use corrcet pointer while completing jobs
  crypto: ccp - Prevent information leakage on export
  iwlwifi: mvm: fix memory leak in paging
  iwlwifi: pcie: lower the debug level for RSA semaphore access
  s390/pci: add extra padding to function measurement block
  cpufreq: intel_pstate: Fix processing for turbo activation ratio
  Revert "drm/amdgpu: disable runtime pm on PX laptops without dGPU power control"
  Revert "drm/radeon: disable runtime pm on PX laptops without dGPU power control"
  drm/i915: Fix race condition in intel_dp_destroy_mst_connector()
  drm/qxl: fix cursor position with non-zero hotspot
  drm/nouveau/core: use vzalloc for allocating ramht
  futex: Acknowledge a new waiter in counter before plist
  futex: Handle unlock_pi race gracefully
  asm-generic/futex: Re-enable preemption in futex_atomic_cmpxchg_inatomic()
  ALSA: hda - Add dock support for ThinkPad X260
  ALSA: pcxhr: Fix missing mutex unlock
  ALSA: hda - add PCI ID for Intel Broxton-T
  ALSA: hda - Keep powering up ADCs on Cirrus codecs
  ALSA: hda/realtek - Add ALC3234 headset mode for Optiplex 9020m
  ALSA: hda - Don't trust the reported actual power state
  x86 EDAC, sb_edac.c: Repair damage introduced when "fixing" channel address
  x86/mm/xen: Suppress hugetlbfs in PV guests
  arm64: Update PTE_RDONLY in set_pte_at() for PROT_NONE permission
  arm64: Honour !PTE_WRITE in set_pte_at() for kernel mappings
  sched/cgroup: Fix/cleanup cgroup teardown/init
  dmaengine: pxa_dma: fix the maximum requestor line
  dmaengine: hsu: correct use of channel status register
  dmaengine: dw: fix master selection
  debugfs: Make automount point inodes permanently empty
  lib: lz4: fixed zram with lz4 on big endian machines
  dm cache metadata: fix cmd_read_lock() acquiring write lock
  dm cache metadata: fix READ_LOCK macros and cleanup WRITE_LOCK macros
  usb: gadget: f_fs: Fix use-after-free
  usb: hcd: out of bounds access in for_each_companion
  xhci: fix 10 second timeout on removal of PCI hotpluggable xhci controllers
  usb: xhci: fix wild pointers in xhci_mem_cleanup
  xhci: resume USB 3 roothub first
  usb: xhci: applying XHCI_PME_STUCK_QUIRK to Intel BXT B0 host
  assoc_array: don't call compare_object() on a node
  ARM: OMAP2+: hwmod: Fix updating of sysconfig register
  ARM: OMAP2: Fix up interconnect barrier initialization for DRA7
  ARM: mvebu: Correct unit address for linksys
  ARM: dts: AM43x-epos: Fix clk parent for synctimer
  KVM: arm/arm64: Handle forward time correction gracefully
  kvm: x86: do not leak guest xcr0 into host interrupt handlers
  x86/mce: Avoid using object after free in genpool
  block: loop: fix filesystem corruption in case of aio/dio
  block: partition: initialize percpuref before sending out KOBJ_ADD

Conflicts:
	arch/arm64/Kconfig
	arch/arm64/include/asm/cputype.h
	arch/arm64/include/asm/hardirq.h
	arch/arm64/include/asm/irq.h
	arch/arm64/kernel/cpu_errata.c
	arch/arm64/kernel/cpuinfo.c
	arch/arm64/kernel/setup.c
	arch/arm64/kernel/smp.c
	arch/arm64/kernel/stacktrace.c
	arch/arm64/mm/init.c
	arch/arm64/mm/mmu.c
	arch/arm64/mm/pageattr.c
	mm/memcontrol.c

CRs-Fixed: 1054234
Signed-off-by: Trilok Soni <tsoni@codeaurora.org>
Change-Id: I2a7a34631ffee36ce18b9171f16d023be777392f
2016-08-18 14:50:45 -07:00
Shubhraprakash Das
81670a3954 media: videobuf2: Increase max buffers
Increase the maximum video buffers to 64 as with camera 64
buffers are allocated and used.

CRs-Fixed: 1039456
Change-Id: I37d91c4f7e5d98333cf6be3c75168e134ae78060
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
2016-07-11 18:56:20 -07:00
Sakari Ailus
3a4b3d187d videobuf2-core: Check user space planes array in dqbuf
commit e7e0c3e26587749b62d17b9dd0532874186c77f7 upstream.

The number of planes in videobuf2 is specific to a buffer. In order to
verify that the planes array provided by the user is long enough, a new
vb2_buf_op is required.

Call __verify_planes_array() when the dequeued buffer is known. Return an
error to the caller if there was one, otherwise remove the buffer from the
done list.

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-05-04 14:48:50 -07:00
Rajesh Bondugula
0b9105a224 msm: camera: sensor: Update actuator specific I2C structures
Update actuator specific I2C addr_type and data_type
structures. Use the strucutres defined by sensor.

CRs-Fixed: 982082
Change-Id: I77753fd25d5a4256a4a4cdd74518facd63becf25
Signed-off-by: Rajesh Bondugula <rajeshb@codeaurora.org>
2016-04-07 16:00:33 -07:00
Alan Kwong
0203eacc8c msm: sde: Add interface to support sde v4l2 rotator
Current fbdev rotator interface lacks support for mult-context
use cases.  This new interface adopts V4L2 M2M framework to
support multiple concurrent sessions/contexts efficiently.

CRs-Fixed: 972831
Change-Id: I89593a57ba44e91c95d73154a7830539e5aab6e3
Signed-off-by: Alan Kwong <akwong@codeaurora.org>
2016-03-25 16:03:56 -07:00
Jeremy Gebben
52fc5f122d msm: camera: uapi header split
Move userspace visible definitions to the uapi directory.

Change-Id: I95b754a1f888f849eb50e449a211b18633aff6a2
Signed-off-by: Jeremy Gebben <jgebben@codeaurora.org>
Signed-off-by: Lakshmi Narayana Kalavala <lkalaval@codeaurora.org>
2016-03-25 16:03:38 -07:00
Jing Zhou
a69176361c msm: camera: isp: Remove buffer queue shared list
Remove the shared list of buffer queue that is used in case of
dual vfe. Whenever a buffer is dequeued from the buffer queue
program it on both vfe and ensure that buffer is dequeued only
once by compositing the buf done irq.
Also, program scratch buffer for stats stream

Change-Id: I96cd0a97b24bf6bc0223cbee8d1fc6bf2ecc7c49
Signed-off-by: Harsh Shah <harshs@codeaurora.org>
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
Signed-off-by: Jing Zhou <jzhou70@codeaurora.org>
2016-03-23 21:22:45 -07:00
Jing Zhou
cc999c3a99 msm: camera: isp: Debug double add state check
Add changes to track buffer being added to list. Add error
messages if buffer is found to be added twice. Add state checking
in the isp driver.

Change-Id: I1504e8984db3578009b8944719bbd559ad57d63d
Signed-off-by: Harsh Shah <harshs@codeaurora.org>
Signed-off-by: Jing Zhou <jzhou70@codeaurora.org>
2016-03-23 21:22:40 -07:00
Arun Menon
c9647fc5cf msm: vidc: Add Video driver for MSM targets
Add snapshot for Video driver source for MSM targets. The code is
migrated from msm-3.18 kernel at the below commit level -
d5809484bb1bf5864dad2f081b0145224762963a.

Signed-off-by: Arun Menon <avmenon@codeaurora.org>
2016-03-23 21:22:38 -07:00
Terence Ho
fd9c7c7b8d msm: camera: add slave write array support
Add support for slave_write_array and to pass addr_type with
slave_read.

Change-Id: Ia530dcf684739f43e36fc67fec83bc0be0c8cf78
Signed-off-by: Terence Ho <terenceh@codeaurora.org>
2016-03-23 21:17:15 -07:00
Peter Liu
f10ced0ba5 msm: camera: isp: fix error report id mask
Stream id mask need more than 8 bit,
thus increase bit width for error reporting.

Change-Id: I308a9d3df6024768b07ec49562f3241707566e2a
Signed-off-by: Peter Liu <pingchie@codeaurora.org>
2016-03-23 21:15:31 -07:00
Abhishek Kondaveeti
3b5427bdee msm: isp: Add output format support for camif
Add output format support for camif raw path
in isp.

Change-Id: If8e633175a5488b8da740654c8204b0247d3c408
Signed-off-by: Abhishek Kondaveeti <akondave@codeaurora.org>
2016-03-23 21:15:07 -07:00
Domi Papoi
99e6ef35c7 adv7481: Add driver code for adv7481
Adding adv7481 driver for db-platform.

Change-Id: I7729d310578b61357f0d7297851f3c412b166699
Signed-off-by: Domi Papoi <dpapoi@codeaurora.org>
2016-03-23 21:13:37 -07:00
Lakshmi Narayana Kalavala
12d7df3314 msm: camera: Add all camera drivers
Add all camera drivers by picking them up from
AU_LINUX_ANDROID_LA.HB.1.3.1.06.00.00.187.056 (e70ad0cd)

Signed-off-by: Lakshmi Narayana Kalavala <lkalaval@codeaurora.org>
2016-03-23 20:48:07 -07:00
Antti Palosaari
9effc72fd7 [media] v4l2: add support for SDR transmitter
New IOCTL ops:
vidioc_enum_fmt_sdr_out
vidioc_g_fmt_sdr_out
vidioc_s_fmt_sdr_out
vidioc_try_fmt_sdr_out

New vb2 buffertype:
V4L2_BUF_TYPE_SDR_OUTPUT

New v4l2 capability:
V4L2_CAP_SDR_OUTPUT

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-20 15:40:50 -02:00
Junghak Sung
3c5be988e0 [media] media: videobuf2: Move v4l2-specific stuff to videobuf2-v4l2
Move v4l2-specific stuff from videobu2-core to videobuf2-v4l2
without doing any functional changes.

Signed-off-by: Junghak Sung <jh1009.sung@samsung.com>
Signed-off-by: Geunyoung Kim <nenggun.kim@samsung.com>
Acked-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Acked-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-20 15:14:28 -02:00
Junghak Sung
b0e0e1f83d [media] media: videobuf2: Prepare to divide videobuf2
Prepare to divide videobuf2
- Separate vb2 trace events from v4l2 trace event.
- Make wrapper functions that will move to v4l2-side.
- Make vb2_core_* functions that will remain in core-side.
- Add a callback function table for buffer operation which makes vb2-core
  to be able to invoke a v4l2-side functions.
- Rename internal functions as vb2_*.

Signed-off-by: Junghak Sung <jh1009.sung@samsung.com>
Signed-off-by: Geunyoung Kim <nenggun.kim@samsung.com>
Acked-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Acked-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-20 15:12:45 -02:00
Junghak Sung
bed04f9342 [media] media: videobuf2: Replace v4l2-specific data with vb2 data
Simple changes that replace v4l2-specific data with vb2 data
in videobuf2-core.

enum v4l2_buf_type --> int
enum v4l2_memory --> enum vb2_memory
VIDEO_MAX_FRAME --> VB2_MAX_FRAME
VIDEO_MAX_PLANES --> VB2_MAX_PLANES
struct v4l2_fh *owner --> void *owner
V4L2_TYPE_IS_MULTIPLANAR() --> is_multiplanar
V4L2_TYPE_IS_OUTPUT() --> is_output

Signed-off-by: Junghak Sung <jh1009.sung@samsung.com>
Signed-off-by: Geunyoung Kim <nenggun.kim@samsung.com>
Acked-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Acked-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-20 14:49:39 -02:00
Junghak Sung
33119e80c3 [media] media: videobuf2: Change queue_setup argument
Replace struct v4l2_format * with void * to make queue_setup()
for common use.
And then, modify all device drivers related with this change.

Signed-off-by: Junghak Sung <jh1009.sung@samsung.com>
Signed-off-by: Geunyoung Kim <nenggun.kim@samsung.com>
Acked-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Acked-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
[hans.verkuil@cisco.com: fix missing const in fimc-lite.c]

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-20 14:48:39 -02:00
Mauro Carvalho Chehab
7096410614 [media] lirc_dev.h: Make checkpatch happy
Remove warnings about bad whitespacing at function
struct parameters.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 13:50:42 -03:00
Mauro Carvalho Chehab
be14c5cd59 [media] DocBook: Convert struct lirc_driver to doc-nano format
The struct lirc_driver is already documented, but on some
internal format. Convert it to Kernel doc-nano format and
add documentation for some additional parameters that are
also present at the structure.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 13:49:03 -03:00
Mauro Carvalho Chehab
326ab27bbd [media] DocBook: Document tveeprom.h
This header declares the code and structures used to parse
Hauppauge eeproms. As this is part of the V4L2 common, and
used by several drivers, let's properly document it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 13:49:02 -03:00
Mauro Carvalho Chehab
6dd3187447 [media] tveeprom: Remove two unused fields from struct
The digitizer* fields aren't used. Remove them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 12:56:16 -03:00
Mauro Carvalho Chehab
5057f3262c [media] DocBook: add documentation for tuner-types.h
The tuner-types.h is part of the V4L2 core and should be
touched for every new tuner added. So, it deserves to be
documented at the device-drivers DocBook.

Add it to device-drivers.tmpl and add descriptions for
enum param_type and struct tuner_range.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 11:37:15 -03:00
Mauro Carvalho Chehab
65fc64090e [media] DocBook: convert struct tuner_parms to doc-nano format
The struct tuner_params is almost fully documented, but
using a non-standard way. Convert it to doc-nano format,
and add descriptions for the parameters that aren't
documented yet.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 10:36:16 -03:00
Mauro Carvalho Chehab
62e93f090b [media] tuner.h: Make checkpatch.pl happier
Remove some bad whitespaces before tabs and fix the initial
comment to be compliant with Kernel coding style.

Now, the only complains are about long comment lines at the
defines. Those warnings should be ok to be kept.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 10:00:18 -03:00
Mauro Carvalho Chehab
07c68a7423 [media] DocBook: Document include/media/tuner.h
This is part of the V4L2 core, so its kABI should be
documented at device-drivers DocBook.

Add the meta-tags for that.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 09:50:36 -03:00
Mauro Carvalho Chehab
efe98010b8 [media] DocBook: Fix remaining issues with VB2 core documentation
Right now, "private:" tag should be lower-case, otherwise the
scripts/kernel-doc won't do the right thing.

Also, no fields after "private:" should be documented. As we don't
want to strip the documentation, let's untag. This way, it will
be seen only at the file, and not at the DocBooks.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-05 09:12:56 -03:00
Mauro Carvalho Chehab
ef69ee1bc2 [media] media-entity.c: get rid of var length arrays
Fix those sparse warnings:
	drivers/media/media-entity.c:238:17: warning: Variable length array is used.
	drivers/media/media-entity.c:239:17: warning: Variable length array is used.

That allows sparse and other code check tools to verify if the
function is using more stack than allowed.

It also solves a bad Kernel pratice of using var length arrays
at the stack.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-10-01 18:10:05 -03:00