firefly-linux-kernel-4.4.55.git
9 years agomipi: arm64: rockchip_defconfig enable mipi default.
xubilv [Thu, 26 Mar 2015 00:33:31 +0000 (08:33 +0800)]
mipi: arm64: rockchip_defconfig enable mipi default.

Signed-off-by: xubilv <xbl@rock-chips.com>
9 years agork3368: dvfs: avoid null-pointer dereference in dvfs_get_temp
Xiao Feng [Thu, 26 Mar 2015 02:38:56 +0000 (10:38 +0800)]
rk3368: dvfs: avoid null-pointer dereference in dvfs_get_temp

Signed-off-by: Xiao Feng <xf@rock-chips.com>
9 years agommc: rk_sdmmc: substitude regulator_set_voltage for io switch usage
lintao [Thu, 26 Mar 2015 09:14:55 +0000 (17:14 +0800)]
mmc: rk_sdmmc: substitude regulator_set_voltage for io switch usage

Signed-off-by: lintao <lintao@rock-chips.com>
9 years agoHDMI: rockchip-hdmiv2:
Zheng Yang [Thu, 26 Mar 2015 08:18:38 +0000 (16:18 +0800)]
HDMI: rockchip-hdmiv2:
Set i2c5_hdmi to gpio mode when suspend and reset
it to hdmi ddc mode when system resume.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
9 years agoHDMI: add dts node "rockchip,defaultmode" to define HDMI default output mode.
Zheng Yang [Thu, 26 Mar 2015 06:40:32 +0000 (14:40 +0800)]
HDMI: add dts node "rockchip,defaultmode" to define HDMI default output mode.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
9 years agomipi: rk3368 support power domain - pd_mipi_dsi.
xubilv [Wed, 25 Mar 2015 10:03:40 +0000 (18:03 +0800)]
mipi: rk3368 support power domain - pd_mipi_dsi.

Signed-off-by: xubilv <xbl@rock-chips.com>
9 years agoMerge branch develop-3.10
Huang, Tao [Wed, 25 Mar 2015 11:10:16 +0000 (19:10 +0800)]
Merge branch develop-3.10

9 years agomipi: correct coding style error of rk32_mipi_dsi.c
xubilv [Wed, 25 Mar 2015 09:51:07 +0000 (17:51 +0800)]
mipi: correct coding style error of rk32_mipi_dsi.c

Signed-off-by: xubilv <xbl@rock-chips.com>
9 years agoHDMI: fix feature SUPPORT_TMDS_600M filter error.
Zheng Yang [Wed, 25 Mar 2015 10:46:56 +0000 (18:46 +0800)]
HDMI: fix feature SUPPORT_TMDS_600M filter error.
For some sink device, it's max tmdsclk is only 300M, but
it support 4K YUV420 mode, so it can be filted by feature
SUPPORT_TMDS_600M under current code.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
9 years agoHDMI: fix feature SUPPORT_TMDS_600M filter error.
Zheng Yang [Wed, 25 Mar 2015 10:46:56 +0000 (18:46 +0800)]
HDMI: fix feature SUPPORT_TMDS_600M filter error.
For some sink device, it's max tmdsclk is only 300M, but
it support 4K YUV420 mode, so it can be filted by feature
SUPPORT_TMDS_600M under current code.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
9 years agoadd rga2 pd_clk support
zsq [Wed, 25 Mar 2015 09:09:26 +0000 (17:09 +0800)]
add rga2 pd_clk support

9 years agoupdate 8723bu wifi driver
xxh [Wed, 25 Mar 2015 04:19:16 +0000 (12:19 +0800)]
update 8723bu wifi driver
1.Improve_P2P_compatibility for Android L
2.Fix_HiddenAP_handle
3.P2P ScanSparse For Miracas

9 years agoRK3368 GPU version: L0.10
zxl [Wed, 25 Mar 2015 03:05:17 +0000 (11:05 +0800)]
RK3368 GPU version: L0.10
Init Power Rogue DDK code

Signed-off-by: zxl <zhuangxl@rock-chips.com>
9 years agork3368: dvfs: add temperature control
Xiao Feng [Tue, 24 Mar 2015 13:06:42 +0000 (21:06 +0800)]
rk3368: dvfs: add temperature control

Signed-off-by: Xiao Feng <xf@rock-chips.com>
9 years agork3368: pwm: add pwm interface for cabc
David Wu [Tue, 24 Mar 2015 11:11:00 +0000 (19:11 +0800)]
rk3368: pwm: add pwm interface for cabc

Signed-off-by: David Wu <wdc@rock-chips.com>
9 years agork3368 lcdc: CABC regulation pwm in frame start
hjc [Tue, 24 Mar 2015 11:02:00 +0000 (19:02 +0800)]
rk3368 lcdc: CABC regulation pwm in frame start

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork3368 dts: add backlight node into lcdc
hjc [Tue, 24 Mar 2015 11:00:36 +0000 (19:00 +0800)]
rk3368 dts: add backlight node into lcdc

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: add lut for CABC
hjc [Mon, 23 Mar 2015 08:29:34 +0000 (16:29 +0800)]
rk fb: add lut for CABC

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: only use iommu need to check config
hjc [Mon, 23 Mar 2015 08:08:43 +0000 (16:08 +0800)]
rk fb: only use iommu need to check config

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: add lut for CABC
hjc [Mon, 23 Mar 2015 08:29:34 +0000 (16:29 +0800)]
rk fb: add lut for CABC

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: only use iommu need to check config
hjc [Mon, 23 Mar 2015 08:08:43 +0000 (16:08 +0800)]
rk fb: only use iommu need to check config

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agodisabled gmac as default in rk3368.dtsi
hwg [Tue, 24 Mar 2015 07:58:26 +0000 (15:58 +0800)]
disabled gmac as default in rk3368.dtsi

9 years agosensor: add mpu6500 accel support
guoyi [Tue, 24 Mar 2015 06:30:23 +0000 (14:30 +0800)]
sensor: add mpu6500 accel support

9 years agork3368:camera: change aclk_isp from <&gates17 0> to <&gates16 0>.
dalon.zhang [Mon, 23 Mar 2015 08:38:54 +0000 (16:38 +0800)]
rk3368:camera: change aclk_isp from <&gates17 0> to <&gates16 0>.

9 years agodefault disable gmac in rk3368-p9_818.dts
hwg [Tue, 24 Mar 2015 03:42:53 +0000 (11:42 +0800)]
default disable gmac in rk3368-p9_818.dts

9 years agodts: rk3368: enable fclk_mcu\stclk_mcu\clk_jtag temporarily
dkl [Mon, 23 Mar 2015 10:13:03 +0000 (18:13 +0800)]
dts: rk3368: enable fclk_mcu\stclk_mcu\clk_jtag temporarily

Signed-off-by: dkl <dkl@rock-chips.com>
9 years agoarm64: rockchip: update rockchip_defconfig by savedefconfig
Huang, Tao [Mon, 23 Mar 2015 10:14:24 +0000 (18:14 +0800)]
arm64: rockchip: update rockchip_defconfig by savedefconfig

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agoarm64: rockchip: rockchip_defconfig enable DEBUG_INFO
Huang, Tao [Mon, 23 Mar 2015 10:13:13 +0000 (18:13 +0800)]
arm64: rockchip: rockchip_defconfig enable DEBUG_INFO

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agoMerge branch develop-3.10
Huang, Tao [Mon, 23 Mar 2015 09:59:35 +0000 (17:59 +0800)]
Merge branch develop-3.10

Conflicts:
arch/arm/mach-rockchip/dvfs.c

9 years agousb: dwc_otg: fix bug in FORCE_HOST_MODE
lyz [Mon, 23 Mar 2015 08:57:46 +0000 (16:57 +0800)]
usb: dwc_otg: fix bug in FORCE_HOST_MODE

9 years agork3368: usb: adjust usb phy parameter
lyz [Mon, 23 Mar 2015 08:48:19 +0000 (16:48 +0800)]
rk3368: usb: adjust usb phy parameter

9 years agork: arm64: disable set pm_power_off for compatible with old pmic driver
Huang, Tao [Mon, 23 Mar 2015 09:16:25 +0000 (17:16 +0800)]
rk: arm64: disable set pm_power_off for compatible with old pmic driver

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agoDMA: pl330: add chan_status to mutex between pl330_tasklet and pl330_control DMA_TERM...
Huibin Hong [Mon, 23 Mar 2015 09:11:09 +0000 (17:11 +0800)]
DMA: pl330: add chan_status to mutex between pl330_tasklet and pl330_control DMA_TERMINATE_ALL

Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
9 years agocamsys_drv: v0.0x1e.0
dalon.zhang [Mon, 23 Mar 2015 08:43:14 +0000 (16:43 +0800)]
camsys_drv: v0.0x1e.0

9 years agork fb: box product not need to load screen when switch screen par enable is zero
hjc [Mon, 23 Mar 2015 07:20:27 +0000 (15:20 +0800)]
rk fb: box product not need to load screen when switch screen par enable is zero

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: fix open hdmi open backlight again in no dual mode
hjc [Tue, 16 Dec 2014 02:00:55 +0000 (10:00 +0800)]
rk fb: fix open hdmi open backlight again in no dual mode

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork3368 lcdc: support win mirror and update NO_DUAL mode
hjc [Fri, 12 Dec 2014 07:01:28 +0000 (15:01 +0800)]
rk3368 lcdc: support win mirror and update NO_DUAL mode

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: compatible when 32bit system call used on 64bit kernel
hjc [Thu, 25 Dec 2014 03:26:52 +0000 (11:26 +0800)]
rk fb: compatible when 32bit system call used on 64bit kernel

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork3368 lcdc: add CABC mode config
hjc [Fri, 9 Jan 2015 06:44:04 +0000 (14:44 +0800)]
rk3368 lcdc: add CABC mode config

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agosolve bluetooth hid problem:
hwg [Mon, 23 Mar 2015 06:59:10 +0000 (14:59 +0800)]
solve bluetooth hid problem:
  when bluetooth hid device connected, the key is delayed to be reponse about 5 second

9 years agorevert drivers/hid/uhid.c of commit 522c0bb37a66e65b704a4bd0f1bee7fec526dd32
hwg [Mon, 23 Mar 2015 06:53:04 +0000 (14:53 +0800)]
revert drivers/hid/uhid.c of commit 522c0bb37a66e65b704a4bd0f1bee7fec526dd32
  solve uhid Bad address error in 64bit cpu

9 years agork fb: box product not need to load screen when switch screen par enable is zero
hjc [Mon, 23 Mar 2015 07:20:27 +0000 (15:20 +0800)]
rk fb: box product not need to load screen when switch screen par enable is zero

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agorevert drivers/hid/uhid.c of commit 522c0bb37a66e65b704a4bd0f1bee7fec526dd32
hwg [Mon, 23 Mar 2015 06:53:04 +0000 (14:53 +0800)]
revert drivers/hid/uhid.c of commit 522c0bb37a66e65b704a4bd0f1bee7fec526dd32
  solve uhid Bad address error in 64bit cpu

9 years agork fb: if not want the config effect,set reserved[3] bit[0] 1
hjc [Mon, 9 Mar 2015 10:09:37 +0000 (18:09 +0800)]
rk fb: if not want the config effect,set reserved[3] bit[0] 1

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: if uboot-logo-on set 1, open iommu when iommu en
hjc [Thu, 26 Feb 2015 10:27:40 +0000 (18:27 +0800)]
rk fb: if uboot-logo-on set 1, open iommu when iommu en

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: update pixclock init value and scale mode only support ONE_DUAL mode
hjc [Wed, 18 Mar 2015 08:26:49 +0000 (16:26 +0800)]
rk fb: update pixclock init value and scale mode only support ONE_DUAL mode

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: add win mirror pos config
hjc [Tue, 23 Dec 2014 06:26:48 +0000 (14:26 +0800)]
rk fb: add win mirror pos config

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: add support phy address config
hjc [Fri, 20 Mar 2015 02:53:50 +0000 (10:53 +0800)]
rk fb: add support phy address config

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork fb: compatible with 32 bit system
hjc [Tue, 17 Mar 2015 06:31:01 +0000 (14:31 +0800)]
rk fb: compatible with 32 bit system

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agommc: rk_sdmmc: remove hpclk ops in set_sdio_status callback
lintao [Mon, 23 Mar 2015 02:45:44 +0000 (10:45 +0800)]
mmc: rk_sdmmc: remove hpclk ops in set_sdio_status callback

Signed-off-by: lintao <lintao@rock-chips.com>
9 years agommc: rk_sdmmc: close FJTAG when drv probe
lintao [Mon, 23 Mar 2015 01:53:48 +0000 (09:53 +0800)]
mmc: rk_sdmmc: close FJTAG when drv probe

Signed-off-by: lintao <lintao@rock-chips.com>
9 years agork fb: update check var screen info
hjc [Mon, 23 Mar 2015 01:29:40 +0000 (09:29 +0800)]
rk fb: update check var screen info

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agosolve realtek wifi driver compile error with rk3368
hwg [Sun, 22 Mar 2015 02:51:17 +0000 (10:51 +0800)]
solve realtek wifi driver compile error with rk3368

9 years agoRevert "Add flags parameter to get_country_code template"
hwg [Sun, 22 Mar 2015 02:34:43 +0000 (10:34 +0800)]
Revert "Add flags parameter to get_country_code template"

This reverts commit a3d5a3f5affd45d9aa21daf04d4eb543fd3ed444.

Conflicts:
include/linux/wlan_plat.h

9 years agodvfs: add gpu temperate control
Xiao Feng [Thu, 12 Mar 2015 11:56:11 +0000 (19:56 +0800)]
dvfs: add gpu temperate control

Signed-off-by: Xiao Feng <xf@rock-chips.com>
9 years agoarm64: rockchip: rk3368: set sleep idle latency as large as possible
Huang, Tao [Sat, 21 Mar 2015 09:41:36 +0000 (17:41 +0800)]
arm64: rockchip: rk3368: set sleep idle latency as large as possible

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agodvfs: add gpu temperate control
Xiao Feng [Thu, 12 Mar 2015 11:56:11 +0000 (19:56 +0800)]
dvfs: add gpu temperate control

Signed-off-by: Xiao Feng <xf@rock-chips.com>
9 years agork3368: support armoff
chenjh [Fri, 20 Mar 2015 10:11:46 +0000 (18:11 +0800)]
rk3368: support armoff

Signed-off-by: chenjh <chenjh@rock-chips.com>
9 years agork3368: update arm dvfs table and add gpu 576M
Xiao Feng [Sat, 21 Mar 2015 08:47:16 +0000 (16:47 +0800)]
rk3368: update arm dvfs table and add gpu 576M

Signed-off-by: Xiao Feng <xf@rock-chips.com>
9 years agopd: rk3368: add qos save support
dkl [Sat, 21 Mar 2015 09:13:32 +0000 (17:13 +0800)]
pd: rk3368: add qos save support

Signed-off-by: dkl <dkl@rock-chips.com>
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agork: move cpu_axi.h from arch/arm/mach-rockchip to include/linux/rockchip
Huang, Tao [Sat, 21 Mar 2015 09:03:42 +0000 (17:03 +0800)]
rk: move cpu_axi.h from arch/arm/mach-rockchip to include/linux/rockchip

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agork_serial: support console write by thread
Huang, Tao [Sat, 21 Mar 2015 08:48:49 +0000 (16:48 +0800)]
rk_serial: support console write by thread

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agork: cpufreq: interactive: touch boost all cpus
Huang, Tao [Sat, 21 Mar 2015 08:44:11 +0000 (16:44 +0800)]
rk: cpufreq: interactive: touch boost all cpus

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agocpufreq: cpufreq_stats: prevent last_index = -1
Huang, Tao [Sat, 21 Mar 2015 07:54:17 +0000 (15:54 +0800)]
cpufreq: cpufreq_stats: prevent last_index = -1

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agocpufreq: rockchip_big_little: fix panic when topology_physical_package_id return...
Huang, Tao [Sat, 21 Mar 2015 07:45:52 +0000 (15:45 +0800)]
cpufreq: rockchip_big_little: fix panic when topology_physical_package_id return -1 if no cluster info in dts

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agocpufreq: rockchip_big_little: add rockchip_bl_ prefix and indent
Huang, Tao [Sat, 21 Mar 2015 07:04:28 +0000 (15:04 +0800)]
cpufreq: rockchip_big_little: add rockchip_bl_ prefix and indent

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agodt-bindings: add rockchip vendor prefix
Heiko Stübner [Fri, 20 Dec 2013 15:26:47 +0000 (16:26 +0100)]
dt-bindings: add rockchip vendor prefix

It seems I forgot to add the vendor prefix for rockchip to the vendor-prefix
list. Therefore add it now.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Rob Herring <robh@kernel.org>
(cherry picked from commit e48ca29d30a10556eb7abd8d91980b8a57dabf10)

9 years agork3368 lcdc: enable irq when open lcdc device
hjc [Fri, 20 Mar 2015 10:37:48 +0000 (18:37 +0800)]
rk3368 lcdc: enable irq when open lcdc device

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agodts: rk3368-box.dts fix rk1000 tve probe error and reduce the frequency of EMMC to...
huangzhibao [Fri, 20 Mar 2015 06:12:34 +0000 (14:12 +0800)]
dts: rk3368-box.dts fix rk1000 tve probe error and reduce the frequency of EMMC to 100M

9 years agork fb: add support phy address config
hjc [Fri, 20 Mar 2015 02:53:50 +0000 (10:53 +0800)]
rk fb: add support phy address config

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agospi: show spi test time and data rate after test
Huibin Hong [Thu, 19 Mar 2015 09:56:59 +0000 (17:56 +0800)]
spi: show spi test time and data rate after test

Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
9 years agoRK3368: spi: spi0 2csn,spi1 2csn,sp2 1csn in dts config
Huibin Hong [Thu, 19 Mar 2015 09:54:54 +0000 (17:54 +0800)]
RK3368: spi: spi0 2csn,spi1 2csn,sp2 1csn in dts config

Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
9 years agospi: add CONFIG_NEED_SG_DMA_LENGTH for dma_length
Huibin Hong [Thu, 19 Mar 2015 09:53:14 +0000 (17:53 +0800)]
spi: add CONFIG_NEED_SG_DMA_LENGTH for dma_length

Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
9 years agork31xx lvds: add power domain control for lvds
hjc [Thu, 19 Mar 2015 09:02:30 +0000 (17:02 +0800)]
rk31xx lvds: add power domain control for lvds

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agork3368 lcdc: add power domain control for lcdc
hjc [Thu, 19 Mar 2015 08:47:22 +0000 (16:47 +0800)]
rk3368 lcdc: add power domain control for lcdc

Signed-off-by: hjc <hjc@rock-chips.com>
9 years agoMerge branch 'rk_develop-3.10' into rk_develop-3.10-next
dalon.zhang [Thu, 19 Mar 2015 08:42:17 +0000 (16:42 +0800)]
Merge branch 'rk_develop-3.10' into rk_develop-3.10-next

Conflicts:
drivers/mmc/host/rk_sdmmc.c

9 years agocamera: rk3368: add aclk_rga
dalon.zhang [Thu, 19 Mar 2015 08:13:19 +0000 (16:13 +0800)]
camera: rk3368: add aclk_rga

9 years agofix rga timeout mmu buf free bug
zsq [Thu, 19 Mar 2015 08:22:23 +0000 (16:22 +0800)]
fix rga timeout mmu buf free bug

9 years agocamsys_drv: v0.0x1d.0
dalon.zhang [Thu, 19 Mar 2015 08:17:47 +0000 (16:17 +0800)]
camsys_drv: v0.0x1d.0

9 years agoarm64: rockchip: rk3368 support psci-0.2
Huang, Tao [Thu, 19 Mar 2015 07:58:47 +0000 (15:58 +0800)]
arm64: rockchip: rk3368 support psci-0.2

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agoarm64: rockchip: rk3368 fix qos reg define and increase peri priority
Huang, Tao [Thu, 19 Mar 2015 05:59:29 +0000 (13:59 +0800)]
arm64: rockchip: rk3368 fix qos reg define and increase peri priority

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
9 years agoMerge branch 'linux-linaro-lsk' into linux-linaro-lsk-android
Alex Shi [Thu, 19 Mar 2015 00:57:07 +0000 (08:57 +0800)]
Merge branch 'linux-linaro-lsk' into linux-linaro-lsk-android

9 years ago Merge tag 'v3.10.72' into linux-linaro-lsk
Alex Shi [Thu, 19 Mar 2015 00:57:04 +0000 (08:57 +0800)]
 Merge tag 'v3.10.72' into linux-linaro-lsk

 This is the 3.10.72 stable release

9 years agowifi: remove make modules configs
hwg [Thu, 19 Mar 2015 00:51:22 +0000 (08:51 +0800)]
wifi: remove make modules configs

9 years agoMerge branch 'linux-linaro-lsk' into linux-linaro-lsk-android
Mark Brown [Wed, 18 Mar 2015 14:34:36 +0000 (14:34 +0000)]
Merge branch 'linux-linaro-lsk' into linux-linaro-lsk-android

9 years agocamsys_head: v0.0xb.0
dalon.zhang [Wed, 18 Mar 2015 13:22:06 +0000 (21:22 +0800)]
camsys_head: v0.0xb.0

9 years agork3368: support cpu suspend to wfi
chenjh [Wed, 18 Mar 2015 07:30:32 +0000 (15:30 +0800)]
rk3368: support cpu suspend to wfi

Signed-off-by: chenjh <chenjh@rock-chips.com>
9 years agoLinux 3.10.72
Greg Kroah-Hartman [Wed, 18 Mar 2015 12:22:50 +0000 (13:22 +0100)]
Linux 3.10.72

9 years agoath5k: fix spontaneus AR5312 freezes
Sergey Ryazanov [Tue, 3 Feb 2015 21:21:13 +0000 (00:21 +0300)]
ath5k: fix spontaneus AR5312 freezes

commit 8bfae4f9938b6c1f033a5159febe97e441d6d526 upstream.

Sometimes while CPU have some load and ath5k doing the wireless
interface reset the whole WiSoC completely freezes. Set of tests shows
that using atomic delay function while we wait interface reset helps to
avoid such freezes.

The easiest way to reproduce this issue: create a station interface,
start continous scan with wpa_supplicant and load CPU by something. Or
just create multiple station interfaces and put them all in continous
scan.

This patch partially reverts the commit 1846ac3dbec0 ("ath5k: Use
usleep_range where possible"), which replaces initial udelay()
by usleep_range().

I do not know actual source of this issue, but all looks like that HW
freeze is caused by transaction on internal SoC bus, while wireless
block is in reset state.

Also I should note that I do not know how many chips are affected, but I
did not see this issue with chips, other than AR5312.

CC: Jiri Slaby <jirislaby@gmail.com>
CC: Nick Kossifidis <mickflemm@gmail.com>
CC: Luis R. Rodriguez <mcgrof@do-not-panic.com>
Fixes: 1846ac3dbec0 ("ath5k: Use usleep_range where possible")
Reported-by: Christophe Prevotaux <c.prevotaux@rural-networks.com>
Tested-by: Christophe Prevotaux <c.prevotaux@rural-networks.com>
Tested-by: Eric Bree <ebree@nltinc.com>
Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoACPI / video: Load the module even if ACPI is disabled
Chris Wilson [Sun, 1 Mar 2015 10:41:37 +0000 (10:41 +0000)]
ACPI / video: Load the module even if ACPI is disabled

commit 6e17cb12881ba8d5e456b89f072dc6b70048af36 upstream.

i915.ko depends upon the acpi/video.ko module and so refuses to load if
ACPI is disabled at runtime if for example the BIOS is broken beyond
repair. acpi/video provides an optional service for i915.ko and so we
should just allow the modules to load, but do no nothing in order to let
the machines boot correctly.

Reported-by: Bill Augur <bill-auger@programmer.net>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Jani Nikula <jani.nikula@intel.com>
Acked-by: Aaron Lu <aaron.lu@intel.com>
[ rjw: Fixed up the new comment in acpi_video_init() ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agodrm/radeon: fix 1 RB harvest config setup for TN/RL
Alex Deucher [Thu, 19 Feb 2015 21:02:15 +0000 (16:02 -0500)]
drm/radeon: fix 1 RB harvest config setup for TN/RL

commit dbfb00c3e7e18439f2ebf67fe99bf7a50b5bae1e upstream.

The logic was reversed from what the hw actually exposed.
Fixes graphics corruption in certain harvest configurations.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoDrivers: hv: vmbus: incorrect device name is printed when child device is unregistered
Fernando Soto [Fri, 14 Jun 2013 23:13:35 +0000 (23:13 +0000)]
Drivers: hv: vmbus: incorrect device name is printed when child device is unregistered

commit 84672369ffb98a51d4ddf74c20a23636da3ad615 upstream.

Whenever a device is unregistered in vmbus_device_unregister (drivers/hv/vmbus_drv.c), the device name in the log message may contain garbage as the memory has already been freed by the time pr_info is called. Log example:
 [ 3149.170475] hv_vmbus: child device àõsèè0_5 unregistered

By logging the message just before calling device_unregister, the correct device name is printed:
[ 3145.034652] hv_vmbus: child device vmbus_0_5 unregistered

Also changing register & unregister messages to debug to avoid unnecessarily cluttering the kernel log.

Signed-off-by: Fernando M Soto <fsoto@bluecatnetworks.com>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Cc: Joseph Salisbury <joseph.salisbury@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoHID: fixup the conflicting keyboard mappings quirk
Jiri Kosina [Tue, 6 Jan 2015 21:34:19 +0000 (22:34 +0100)]
HID: fixup the conflicting keyboard mappings quirk

commit 8e7b341037db1835ee6eea64663013cbfcf33575 upstream.

The ignore check that got added in 6ce901eb61 ("HID: input: fix confusion
on conflicting mappings") needs to properly check for VARIABLE reports
as well (ARRAY reports should be ignored), otherwise legitimate keyboards
might break.

Fixes: 6ce901eb61 ("HID: input: fix confusion on conflicting mappings")
Reported-by: Fredrik Hallenberg <megahallon@gmail.com>
Reported-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoHID: input: fix confusion on conflicting mappings
David Herrmann [Mon, 29 Dec 2014 14:21:26 +0000 (15:21 +0100)]
HID: input: fix confusion on conflicting mappings

commit 6ce901eb61aa30ba8565c62049ee80c90728ef14 upstream.

On an PC-101/103/104 keyboard (American layout) the 'Enter' key and its
neighbours look like this:

           +---+ +---+ +-------+
           | 1 | | 2 | |   5   |
           +---+ +---+ +-------+
             +---+ +-----------+
             | 3 | |     4     |
             +---+ +-----------+

On a PC-102/105 keyboard (European layout) it looks like this:

           +---+ +---+ +-------+
           | 1 | | 2 | |       |
           +---+ +---+ +-+  4  |
             +---+ +---+ |     |
             | 3 | | 5 | |     |
             +---+ +---+ +-----+

(Note that the number of keys is the same, but key '5' is moved down and
 the shape of key '4' is changed. Keys '1' to '3' are exactly the same.)

The keys 1-4 report the same scan-code in HID in both layouts, even though
the keysym they produce is usually different depending on the XKB-keymap
used by user-space.
However, key '5' (US 'backslash'/'pipe') reports 0x31 for the upper layout
and 0x32 for the lower layout, as defined by the HID spec. This is highly
confusing as the linux-input API uses a single keycode for both.

So far, this was never a problem as there never has been a keyboard with
both of those keys present at the same time. It would have to look
something like this:

           +---+ +---+ +-------+
           | 1 | | 2 | |  x31  |
           +---+ +---+ +-------+
             +---+ +---+ +-----+
             | 3 | |x32| |  4  |
             +---+ +---+ +-----+

HID can represent such a keyboard, but the linux-input API cannot.
Furthermore, any user-space mapping would be confused by this and,
luckily, no-one ever produced such hardware.

Now, the HID input layer fixed this mess by mapping both 0x31 and 0x32 to
the same keycode (KEY_BACKSLASH==0x2b). As only one of both physical keys
is present on a hardware, this works just fine.

Lets introduce hardware-vendors into this:
------------------------------------------

Unfortunately, it seems way to expensive to produce a different device for
American and European layouts. Therefore, hardware-vendors put both keys,
(0x31 and 0x32) on the same keyboard, but only one of them is hooked up
to the physical button, the other one is 'dead'.
This means, they can use the same hardware, with a different button-layout
and automatically produce the correct HID events for American *and*
European layouts. This is unproblematic for normal keyboards, as the
'dead' key will never report any KEY-DOWN events. But RollOver keyboards
send the whole matrix on each key-event, allowing n-key roll-over mode.
This means, we get a 0x31 and 0x32 event on each key-press. One of them
will always be 0, the other reports the real state. As we map both to the
same keycode, we will get spurious key-events, even though the real
key-state never changed.

The easiest way would be to blacklist 'dead' keys and never handle those.
We could simply read the 'country' tag of USB devices and blacklist either
key according to the layout. But... hardware vendors... want the same
device for all countries and thus many of them set 'country' to 0 for all
devices. Meh..

So we have to deal with this properly. As we cannot know which of the keys
is 'dead', we either need a heuristic and track those keys, or we simply
make use of our value-tracking for HID fields. We simply ignore HID events
for absolute data if the data didn't change. As HID tracks events on the
HID level, we haven't done the keycode translation, yet. Therefore, the
'dead' key is tracked independently of the real key, therefore, any events
on it will be ignored.

This patch simply discards any HID events for absolute data if it didn't
change compared to the last report. We need to ignore relative and
buffered-byte reports for obvious reasons. But those cannot be affected by
this bug, so we're fine.

Preferably, we'd do this filtering on the HID-core level. But this might
break a lot of custom drivers, if they do not follow the HID specs.
Therefore, we do this late in hid-input just before we inject it into the
input layer (which does the exact same filtering, but on the keycode
level).

If this turns out to break some devices, we might have to limit filtering
to EV_KEY events. But lets try to do the Right Thing first, and properly
filter any absolute data that didn't change.

This patch is tagged for 'stable' as it fixes a lot of n-key RollOver
hardware. We might wanna wait with backporting for a while, before we know
it doesn't break anything else, though.

Reported-by: Adam Goode <adam@spicenitz.org>
Reported-by: Fredrik Hallenberg <megahallon@gmail.com>
Tested-by: Fredrik Hallenberg <megahallon@gmail.com>
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: comedi: cb_pcidas64: fix incorrect AI range code handling
Ian Abbott [Mon, 19 Jan 2015 14:47:27 +0000 (14:47 +0000)]
staging: comedi: cb_pcidas64: fix incorrect AI range code handling

commit be8e89087ec2d2c8a1ad1e3db64bf4efdfc3c298 upstream.

The hardware range code values and list of valid ranges for the AI
subdevice is incorrect for several supported boards.  The hardware range
code values for all boards except PCI-DAS4020/12 is determined by
calling `ai_range_bits_6xxx()` based on the maximum voltage of the range
and whether it is bipolar or unipolar, however it only returns the
correct hardware range code for the PCI-DAS60xx boards.  For
PCI-DAS6402/16 (and /12) it returns the wrong code for the unipolar
ranges.  For PCI-DAS64/Mx/16 it returns the wrong code for all the
ranges and the comedi range table is incorrect.

Change `ai_range_bits_6xxx()` to use a look-up table pointed to by new
member `ai_range_codes` of `struct pcidas64_board` to map the comedi
range table indices to the hardware range codes.  Use a new comedi range
table for the PCI-DAS64/Mx/16 boards (and the commented out variants).

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agodm snapshot: fix a possible invalid memory access on unload
Mikulas Patocka [Tue, 17 Feb 2015 19:34:00 +0000 (14:34 -0500)]
dm snapshot: fix a possible invalid memory access on unload

commit 22aa66a3ee5b61e0f4a0bfeabcaa567861109ec3 upstream.

When the snapshot target is unloaded, snapshot_dtr() waits until
pending_exceptions_count drops to zero.  Then, it destroys the snapshot.
Therefore, the function that decrements pending_exceptions_count
should not touch the snapshot structure after the decrement.

pending_complete() calls free_pending_exception(), which decrements
pending_exceptions_count, and then it performs up_write(&s->lock) and it
calls retry_origin_bios() which dereferences  s->origin.  These two
memory accesses to the fields of the snapshot may touch the dm_snapshot
struture after it is freed.

This patch moves the call to free_pending_exception() to the end of
pending_complete(), so that the snapshot will not be destroyed while
pending_complete() is in progress.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agodm: fix a race condition in dm_get_md
Mikulas Patocka [Tue, 17 Feb 2015 19:30:53 +0000 (14:30 -0500)]
dm: fix a race condition in dm_get_md

commit 2bec1f4a8832e74ebbe859f176d8a9cb20dd97f4 upstream.

The function dm_get_md finds a device mapper device with a given dev_t,
increases the reference count and returns the pointer.

dm_get_md calls dm_find_md, dm_find_md takes _minor_lock, finds the
device, tests that the device doesn't have DMF_DELETING or DMF_FREEING
flag, drops _minor_lock and returns pointer to the device. dm_get_md then
calls dm_get. dm_get calls BUG if the device has the DMF_FREEING flag,
otherwise it increments the reference count.

There is a possible race condition - after dm_find_md exits and before
dm_get is called, there are no locks held, so the device may disappear or
DMF_FREEING flag may be set, which results in BUG.

To fix this bug, we need to call dm_get while we hold _minor_lock. This
patch renames dm_find_md to dm_get_md and changes it so that it calls
dm_get while holding the lock.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agodm io: reject unsupported DISCARD requests with EOPNOTSUPP
Darrick J. Wong [Fri, 13 Feb 2015 19:05:37 +0000 (11:05 -0800)]
dm io: reject unsupported DISCARD requests with EOPNOTSUPP

commit 37527b869207ad4c208b1e13967d69b8bba1fbf9 upstream.

I created a dm-raid1 device backed by a device that supports DISCARD
and another device that does NOT support DISCARD with the following
dm configuration:

 #  echo '0 2048 mirror core 1 512 2 /dev/sda 0 /dev/sdb 0' | dmsetup create moo
 # lsblk -D
 NAME         DISC-ALN DISC-GRAN DISC-MAX DISC-ZERO
 sda                 0        4K       1G         0
 `-moo (dm-0)        0        4K       1G         0
 sdb                 0        0B       0B         0
 `-moo (dm-0)        0        4K       1G         0

Notice that the mirror device /dev/mapper/moo advertises DISCARD
support even though one of the mirror halves doesn't.

If I issue a DISCARD request (via fstrim, mount -o discard, or ioctl
BLKDISCARD) through the mirror, kmirrord gets stuck in an infinite
loop in do_region() when it tries to issue a DISCARD request to sdb.
The problem is that when we call do_region() against sdb, num_sectors
is set to zero because q->limits.max_discard_sectors is zero.
Therefore, "remaining" never decreases and the loop never terminates.

To fix this: before entering the loop, check for the combination of
REQ_DISCARD and no discard and return -EOPNOTSUPP to avoid hanging up
the mirror device.

This bug was found by the unfortunate coincidence of pvmove and a
discard operation in the RHEL 6.5 kernel; upstream is also affected.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Acked-by: "Martin K. Petersen" <martin.petersen@oracle.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agodm mirror: do not degrade the mirror on discard error
Mikulas Patocka [Thu, 12 Feb 2015 15:09:20 +0000 (10:09 -0500)]
dm mirror: do not degrade the mirror on discard error

commit f2ed51ac64611d717d1917820a01930174c2f236 upstream.

It may be possible that a device claims discard support but it rejects
discards with -EOPNOTSUPP.  It happens when using loopback on ext2/ext3
filesystem driven by the ext4 driver.  It may also happen if the
underlying devices are moved from one disk on another.

If discard error happens, we reject the bio with -EOPNOTSUPP, but we do
not degrade the array.

This patch fixes failed test shell/lvconvert-repair-transient.sh in the
lvm2 testsuite if the testsuite is extracted on an ext2 or ext3
filesystem and it is being driven by the ext4 driver.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: comedi: comedi_compat32.c: fix COMEDI_CMD copy back
Ian Abbott [Tue, 27 Jan 2015 18:16:51 +0000 (18:16 +0000)]
staging: comedi: comedi_compat32.c: fix COMEDI_CMD copy back

commit 42b8ce6f55facfa101462e694d33fc6bca471138 upstream.

`do_cmd_ioctl()` in "comedi_fops.c" handles the `COMEDI_CMD` ioctl.
This returns `-EAGAIN` if it has copied a modified `struct comedi_cmd`
back to user-space.  (This occurs when the low-level Comedi driver's
`do_cmdtest()` handler returns non-zero to indicate a problem with the
contents of the `struct comedi_cmd`, or when the `struct comedi_cmd` has
the `CMDF_BOGUS` flag set.)

`compat_cmd()` in "comedi_compat32.c" handles the 32-bit compatible
version of the `COMEDI_CMD` ioctl.  Currently, it never copies a 32-bit
compatible version of `struct comedi_cmd` back to user-space, which is
at odds with the way the regular `COMEDI_CMD` ioctl is handled.  To fix
it, change `compat_cmd()` to copy a 32-bit compatible version of the
`struct comedi_cmd` back to user-space when the main ioctl handler
returns `-EAGAIN`.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>