Commit Graph

648494 Commits

Author SHA1 Message Date
he.he
57178bebde usb: adb panic [1/1]
PD#SWPL-2678

Problem:
adb panic in release_ffs_buffer

Solution:
1.when kzalloc data_ep use GFP_ATOMIC  instead of GFP_KERNEL
and keep spin lock protection.
2.check buffer_temp->data_ep == NULL, return

Test: adb push

Verify:
verified by he he

Change-Id: I3402b17d62b8a0ef4e3185a87729a0c3e87449e9
Signed-off-by: he.he <he.he@amlogic.com>
2019-02-27 04:25:53 +09:00
Bencheng Jing
43e88badd3 pq: fix sr registers load fail on txl [1/1]
PD#SWPL-2941

Problem:
sr top ctrl is closed when video off

Solution:
txl and txl sr top don't close

Verify:
TxL

Change-Id: Ia8e7e3bd93dd328497af66cf9758e3021cafe22c
Signed-off-by: Bencheng Jing <bencheng.jing@amlogic.com>
2019-02-27 04:25:53 +09:00
tao zeng
ab5ac7a16b mm: optimize stack usage for functions [1/1]
PD#SWPL-1773

Problem:
After adding optimization of vmap stack, we can found stack usage
of each functions when handle vmap fault. From test log we see some
functions using large stack size which over 256bytes. Especially
common call path from fs. We need to optimize stack usage of these
functions to reduce stack fault probability and save stack memory
usage.

Solution:
1. remove CONFIG_CC_STACKPROTECTOR_STRONG and set STACKPROTECTOR to
   NONE. This can save stack usage add by compiler for most functions.
   Kernel code size can also save over 1MB.
2. Add some noinline functions for android_fs_data rw trace calls. In
   these trace call it allcated a 256 bytes local buffer.
3. Add a wrap function for mem abort handler. By default, it defined a
   siginfo struct(size over 100 bytes) in local but only used when fault
   can't be handled.
4. reduce cached page size for vmap stack since probability of page
   fault caused by stack overflow is reduced after function stack usage
   optimized.
Monkey test show real stack usage ratio compared with 1st vmap
implementation reduced from 35% ~ 38% to 26 ~ 27%. Which is very
close to 25%, theory limit.

Verify:
P212

Change-Id: I5505cacc1cab51f88654052902852fd648b6a036
Signed-off-by: tao zeng <tao.zeng@amlogic.com>
2019-02-27 04:25:53 +09:00
Pengcheng Chen
ed7aa0d7ea osd: remove phys_to_vir to prevent crash on the 32bit & 2G boadr [1/1]
PD#SWPL-3079

Problem:
phys_to_vir in height mem rw caused crashed.

Solution:
remove phys_to_vir(dd funs not work)

Verify:
tl1

Change-Id: Ic9679471a51974cabf84b61efe90c88e845d01ea
Signed-off-by: Pengcheng Chen <pengcheng.chen@amlogic.com>
2019-02-27 04:25:53 +09:00
Hongmin Hua
98f5dd4800 cec: add the port map for connect status [1/1]
PD#SWPL-3010

Problem:
the arc can't work

Solution:
add the port map for connect status

Verify:
verified on darwin

Change-Id: I9f886c35de8670acdc431185bb26aa1836a8c150
Signed-off-by: Hongmin Hua <hongmin.hua@amlogic.com>
2019-02-27 04:25:53 +09:00
Yi Zeng
fbd010d178 nand: fix the free-node leak in rsv manager [1/1]
PD#SWPL-2776

Problem:
did not release the free node of rsv information

Solution:
release free node and set bit mask in right way

Verify:
S400

Change-Id: I781f2374b91ca1e7cd1a66e75fc554318737c377
Signed-off-by: Yi Zeng <yi.zeng@amlogic.com>
2019-02-27 04:25:53 +09:00
Jian Cao
99b4eeac49 video: fix picdec coverity error [1/1]
PD#SWPL-2797

Problem:
fix picdec coverity error

Solution:
solve picdec coverity issues

Verify:
verified on P212

Change-Id: Iee0a7beb3fbf8382e9dd4207075df85171ed62ae
Signed-off-by: Jian Cao <jian.cao@amlogic.com>
2019-02-27 04:25:51 +09:00
Jian Cao
eb6a2a6421 video: fix ppmgr coverity error [1/1]
PD#SWPL-2797

Problem:
fix ppmgr coverity error

Solution:
solve ppmgr coverity issues

Verify:
verified on P212

Change-Id: I05b837073ec9c981004320afaa0680648198d5b3
Signed-off-by: Jian Cao <jian.cao@amlogic.com>
2019-02-27 04:25:14 +09:00
Jian Cao
c924880485 osd: fix ge2d coverity error [1/1]
PD#SWPL-2798

Problem:
fix ge2d coverity error

Solution:
add return val timeout for waiting completion

Verify:
verified on P212

Change-Id: Iaacf3f5b30721eb5d72d3c355f0404f4848969b5
Signed-off-by: Jian Cao <jian.cao@amlogic.com>
2019-02-27 04:25:14 +09:00
Jian Cao
75320ab24e osd: fix osd coverity error [1/1]
PD#SWPL-2798

Problem:
fix osd coverity error

Solution:
solve osd coverity issues

Verify:
verified on P212

Change-Id: I9714e3b229786d39ffa5a150633d59082bdf3549
Signed-off-by: Jian Cao <jian.cao@amlogic.com>
2019-02-27 04:25:14 +09:00
MingLiang Dong
6dca69828b hdr: Enable default output to HDR for HDR TV [1/1]
PD#SWPL-3096

Problem:
G12A/G12B need enable sdr2hdr

Solution:
enable sdr2hdr function

Verify:
verify on G12A

Change-Id: I1e771a13d33fe675cfc36d8308afc37077545cd4
Signed-off-by: MingLiang Dong <mingliang.dong@amlogic.com>
2019-02-27 04:25:14 +09:00
nengwen.chen
a8e57a75f7 dtv_demod: DTV search menu does not have ISDB-T entry [4/6]
PD#SWPL-1664

Problem:
DTV search menu does not have ISDB-T entry

Solution:
add ISDB-T system support.

Verify:
verified by einstein

Change-Id: Ie0bdc988d53256487e24c3123320b50f2a58cdf3
Signed-off-by: nengwen.chen <nengwen.chen@amlogic.com>
2019-02-27 04:25:14 +09:00
Chuangcheng Peng
004b5414cc dvb-core: compatile with 32bit in 64bit kernel [1/1]
PD#SWPL-3009

Problem:
32bit frontend app can't call ioctl in 64bit-kernel

Solution:
Add 32bit define in header and handle in dvb_frontend in 64bit-kernel

Verify:
Verify at android_p at R311

Change-Id: I63178803cfb1cf7d670e3c2b55f104e97f5afa63
Signed-off-by: Chuangcheng Peng <chuangcheng.peng@amlogic.com>
2019-02-27 04:25:14 +09:00
tao zeng
d88c2abc54 mm: check phys_to_xxxx macro on 32bit OS [1/1]
PD#SWPL-1909

Problem:
If physical address of a memory location is not in linear mapping
range, then any caller with phys_to_xxxx to get a pointer will
cause bug.

Solution:
Check input address range for phys_to_xxxx to get a BUG output.
This change is used for debug

Verify:
P212

Change-Id: I13bcaa3983e2d730b8d2bc03cd28c62585f49969
Signed-off-by: tao zeng <tao.zeng@amlogic.com>
2019-02-27 04:25:14 +09:00
qiu.zeng
d9a4945758 BT: resolve bt remote re-connected fail [1/1]
PD#SWPL-2735

Problem:
bt remote re-connected fail

Solution:
control bluetooth opwer up

Verify:
Verifying on Public Edition r311

Change-Id: I8c74442894f606d5afd992e52d6c80bada0aed9f
Signed-off-by: Qiu Zeng <qiu.zeng@amlogic.com>
2019-02-27 04:25:14 +09:00
Brian Zhu
2c9dae4eb4 video: sr: add the missing bit mask for sr core1 [1/1]
PD#SWPL-2948

Problem:
Miss the sr core1 bit mask to cause display abnormal

Solution:
Add the bit mask for sr core1

Verify:
Test pass by x301

Change-Id: I742d86b610a9748adad7c143d7a85c6796d3c8f7
Signed-off-by: Brian Zhu <brian.zhu@amlogic.com>
2019-02-27 04:25:14 +09:00
Tao Zeng
b5771273c2 mm: subtract CMA isolated pages when allocate TVP [1/1]
PD#SWPL-2933

Problem:
When allocate CMA pages in buildroot enverioment, system will
hung in congestion_wait:
Call trace:
[<ffffff8009086a78>] __switch_to+0xa0/0xc8
[<ffffff8009de3eb8>] __schedule+0x268/0x7d8
[<ffffff8009de4464>] schedule+0x3c/0xa0
[<ffffff8009de7c9c>] schedule_timeout+0x1b4/0x448
[<ffffff8009de3be8>] io_schedule_timeout+0x98/0x100
[<ffffff80091e3fb8>] congestion_wait+0x90/0x190
[<ffffff80091ebcf4>] isolate_migratepages_block+0x7ec/0x890
[<ffffff80091ec794>] isolate_migratepages_range+0x8c/0x100
[<ffffff8009a8f34c>] aml_alloc_contig_migrate_range+0x104/0x158
[<ffffff8009a8f518>] cma_boost_work_func+0x178/0x270
[<ffffff80090cc228>] kthread+0xf8/0x110
[<ffffff80090836c0>] ret_from_fork+0x10/0x50

Solution:
subtract isolated CMA pages when allocation large CMA for TVP.

Verify:
local

Change-Id: I96153cf104abb009a8965c2230a5242e495dd031
Signed-off-by: Tao Zeng <tao.zeng@amlogic.com>
2019-02-27 04:25:14 +09:00
pengcheng chen
27bdd7a086 osd: fix afbc dd length error issue [1/1]
PD#SWPL-2674

Problem:
fix afbc dd length error issue

Solution:
add afbc_len to set screen_size

Verify:
verified on g12a-u200

Change-Id: I00df7945f0f928efe2b8be88c56f10f20bb1700f
Signed-off-by: pengcheng chen <pengcheng.chen@amlogic.com>
2019-02-27 04:25:14 +09:00
Hongmin Hua
b24b397f2b cec: set the phy port the same as ui id [2/2]
PD#SWPL-2685

Problem:
the atom switch wrong channel when wakeup by device

Solution:
set the phy port the same as ui id

Verify:
atom

Change-Id: I4e43f83af5bb30a2388df7e7030f135c3f0830ad
Signed-off-by: Hongmin Hua <hongmin.hua@amlogic.com>
2019-02-27 04:25:14 +09:00
Jian Hu
7df613bddf clk: g12a: add gen clock [1/1]
PD#OTT-1025

Problem:
not support gen clock

Solution:
add gen clock

Verify:
test passed on g12a u200

Change-Id: I5199289d3cd1483fffbbd41f8d104369214ba302
Signed-off-by: Jian Hu <jian.hu@amlogic.com>
2019-02-27 04:25:14 +09:00
Xingyu Chen
6294b33846 pinctrl: meson: add gen_clk_ee/ao pin groups for G12A/B [1/1]
PD#OTT-1025

Problem:
don't support gen_clk_ee and gen_clk_ao pin groups

Solution:
add gen_clk_ee/ao pin groups according to the corepinmux document

Verify:
test pass on U200

Change-Id: Ia3e61079def285c482d8dc4957b5f9e7db35847d
Signed-off-by: Xingyu Chen <xingyu.chen@amlogic.com>
2019-02-27 04:25:14 +09:00
tao zeng
342306da28 mm: optimize thread stack usage on arm64 [1/1]
PD#SWPL-1219

Problem:
On arm64, thread stack is 16KB for each task. If running task number
is large, this type of memory may over 40MB. It's a large amount on
small memory platform. But most case thread only use less 4KB stack.
It's waste of memory and we need optimize it.

Solution:
1. Pre-allocate a vmalloc address space for task stack;
2. Only map 1st page for stack and handle page fault in EL1
   when stack growth triggered exception;
3. handle stack switch for exception.

Verify:
p212

Change-Id: I47f511ccfa2868d982bc10a820ed6435b6d52ba9
Signed-off-by: tao zeng <tao.zeng@amlogic.com>
2019-02-27 04:25:14 +09:00
Jihong Sui
9296b7528e deinterlace: deinterlace: fix coverity error [1/1]
PD#SWPL-2863

Problem:
cdev_add without checking return value.

Solution:
add check

Verify:
p212

Change-Id: Ib1d96f6e5ee07dd28f67eb4ee77acb6580a1f877
Signed-off-by: Jihong Sui <jihong.sui@amlogic.com>
2019-02-27 04:25:14 +09:00
Jihong Sui
18a0d4f8ff deinterlace: deinterlace: set post_ctrl when no mirror [1/1]
PD#SWPL-1076

Problem:
Kplayer 4KDemo.mp4, show green screen.

Solution:
add DI_IF1_GEN_REG set when no mirror

Verify:
p212

Change-Id: I2cfb27068393832fb47498ebdb9b93349f1fe635
Signed-off-by: Jihong Sui <jihong.sui@amlogic.com>
2019-02-27 04:25:14 +09:00
Pengcheng Chen
456e46b3ff osd: add osd log module control [2/2]
PD#SWPL-2551

Problem:
add osd log module control

Solution:
add osd log module control

Verify:
verified on P212

Change-Id: Iadbf795cb7afe4ddcab0f9283b9c7f542eca0b29
Signed-off-by: Pengcheng Chen <pengcheng.chen@amlogic.com>
2019-02-27 04:25:14 +09:00
Jian Cao
f06b47ca96 osd: range of mouse is wrong under 4K mode [1/2]
PD#SWPL-2551

Problem:
range of mouse is wrong under 4K mode

Solution:
new cursor coordinate paras without using scale
add osd_cursor_hw_no_scale() to deal with it.

Verify:
verified on P212

Change-Id: I1748df569b96522eb58dc00af862983bca17815a
Signed-off-by: Jian Cao <jian.cao@amlogic.com>
2019-02-27 04:25:14 +09:00
Tao Guo
b22a775925 media: add get free handle cmd [4/9]
PD#SWPL-1081

Problem:
Need get freed handle for DRM frame mode

Solution:
Add ioctl cmd to get freed handle

Verify:
P212

Change-Id: Ic0ce64061e334fdea5580d9f92b3e0b58caa88eb
Signed-off-by: Tao Guo <tao.guo@amlogic.com>
2019-02-27 04:25:14 +09:00
Evoke Zhang
898c515822 lcd: mipi_dsi: update clk_post timing for dphy [1/1]
PD#SWPL-2436

Problem:
sometime the dphy clk_post is not match spec

Solution:
update clk_post config

Verify:
w400

Change-Id: Ib6b585f833bf923e72109991509915f4ad35d316
Signed-off-by: Evoke Zhang <evoke.zhang@amlogic.com>
2019-02-27 04:25:14 +09:00
Zongdong Jiao
69d0f1c38e hdmitx: parse colorattribute from uboot [2/2]
PD#SWPL-2181

Problem:
For some Rx, if the Tx cold boots up, the HPD can't be got in uboot.
That is to say, the output mode is CVBS in uboot, even HDMI cable is
connected. And during kernel boots up, it will reset to hdmi mode.
During the Android boots up, it will set to hdmi mode again. Twice
hdmi mode setting may cause TV flicks.

Solution:
Add parsing colorattribute from uboot and assign $attr to prevent
the second Android mode setting.

Verify:
S905X/P212

Change-Id: I665227bc3e8481acb40c34dde2f5cb3c633c64a2
Signed-off-by: Zongdong Jiao <zongdong.jiao@amlogic.com>
2019-02-27 04:25:14 +09:00
bichao.zheng
5c8f4bef40 arm: dts: fix wifi 32K Frequency offset [2/2]
PD#SWPL-2623

Problem:
wifi 32K Frequency offset too large

Solution:
Modification cycle

Verify:
x301

Change-Id: I04724b0eacdffc1760b67689be373cb8f671a125
Signed-off-by: bichao.zheng <bichao.zheng@amlogic.com>

Conflicts:
	arch/arm/boot/dts/amlogic/tl1_t962x2_x301.dts
2019-02-27 04:25:14 +09:00
bichao.zheng
44b4195bfe arm64: dts: fix wifi 32K Frequency offset [2/1]
PD#SWPL-2623

Problem:
wifi 32K Frequency offset too large

Solution:
Modification cycle

Verify:
axg u211 p321 r311 p212

Change-Id: Ica04bec99ba2097918387a980b94dc007bb4eca4
Signed-off-by: bichao.zheng <bichao.zheng@amlogic.com>
2019-02-27 04:25:14 +09:00
Jihong Sui
c05e87404b deinterlace: reduce the screen flash when fast forward [1/1]
PD#SWPL-2188

Problem:
1.fast forward/rewind operation, the screen flashes

Solution:
1.add function to update MCDI_MCVECRD_CTRL[9]

Verify:
1.txl

Change-Id: I1bf8583901fa49c518cca74e7716632447adf32f
Signed-off-by: Jihong Sui <jihong.sui@amlogic.com>
2019-02-27 04:25:14 +09:00
Jian Hu
a3c9f703ce clk: gxl: correct saradc clock id when check sardadc clock [1/1]
PD#OTT-944

Problem:
saradc check the wrong clock id.

Solution:
correct saradc id.

Verify:
verified on P212 board

Change-Id: I7fdde80c21228e45ec165252549bf4ca5f21bd67
Signed-off-by: Jian Hu <jian.hu@amlogic.com>
2019-02-27 04:25:14 +09:00
Daogao Xu
de8db8bd8c video: add fast and slow playback support [1/1]
PD#SWPL-1690

Problem:
YouTube requires support playback rate 0.25, 0.50, 1.00, 1.25, 1.50,
2.00

Solution:
vsync_slow_factor can be used to slow playback, extend it's value to
support fast playback

Verify:
mesongxl_p212_32_kernel49

Change-Id: I94589a210b8531cc198414b3017c3caf82827565
Signed-off-by: Daogao Xu <daogao.xu@amlogic.com>
2019-02-27 04:25:14 +09:00
wenfeng.guo
0e93156209 vpp: fix vpp covertiy error [1/1]
PD#SWPL-2458

Problem:
vpp has covertiy error

Solution:
fix vpp covertiy error

Verify:
r311

Change-Id: Ic755420107b72fa0a56d73e288b708ab421f7609
Signed-off-by: Wenfeng Guo <wenfeng.guo@amlogic.com>
2019-02-27 04:25:14 +09:00
Jiacheng Mei
5aac68a693 dts: reduce isp memory usage [1/1]
PD#SWPL-2512

Problem:
isp reserved mem too large

Solution:
reduce isp mem to 256M

Verify:
A311D-W400

Change-Id: I33ee2872daf961da5f0ba4ba4810b0ac9690e45f
Signed-off-by: Jiacheng Mei <jiacheng.mei@amlogic.com>
2019-02-27 04:25:14 +09:00
Bencheng Jing
8bb52d4c6b amvecm: fix dnlp read scurv_mid2 debug interface error [1/1]
PD#SWPL-2448

Problem:
can not read dnlp scurv_mid2 value

Solution:
fix the error

Verify:
t962x_r311

Change-Id: I7a7df769dd117fd83164065f6df8e3ae82c2499f
Signed-off-by: Bencheng Jing <bencheng.jing@amlogic.com>
2019-02-27 04:25:14 +09:00
Guosong Zhou
0712e13162 picdec: add mmap interface for picdec [2/2]
PD#SWPL-2280

Problem:
play picture crash

Solution:
add mmap interface for picdec

Verify:
verify by p321

Change-Id: Ib278de80035b0404884315e29fe933cd8f4b6cfe
Signed-off-by: Guosong Zhou <guosong.zhou@amlogic.com>
2019-02-27 04:25:12 +09:00
Kevin Kim
f59422e2f5 ODROID-COMMON:Add Mixer control for LINE-OUT Mute
Mute : tinymix -D 0 199 1
Unmute : tinymix -D 0 199 0
Boot on state : unmute

Change-Id: If899ea5607cbef8b62fb35b66c79089beb192d1a
s922_9.0.0_20190222
2019-02-22 12:06:03 +09:00
Dongjin Kim
f846045521 Merge "ODROID-N2: clk: add 2.004GHz cpu freq for A73 core and change the max" into odroidn2-4.9.y-android 2019-02-21 19:42:41 +09:00
Chris KIM
adc4fb5bc5 Revert "ODROID-N2: osd: support flexible fb size with free scale option"
This reverts commit e34d6ee040.

Change-Id: Icf9a0069fd26103fbb6185163dfbc9ea5ea78e96
2019-02-21 15:20:11 +09:00
Dongjin Kim
aedd70399d ODROID-N2: arm64/dts: add 'vdac_config' for CVBS output
Change-Id: Iad6c990888f804829b5e8ca3e5dfe9e1829ae9b2
Signed-off-by: Dongjin Kim <tobetter@gmail.com>
(cherry picked from commit 3fa6871cff)
2019-02-20 17:27:21 +09:00
Chao Liu
579beb6892 dts: g12a/b: config hw rng with dts [1/1]
PD#OTT-2062

Problem:
Boot up time with power cable is longer than boot up with usb cable

Solution:
config hw rng with dts

Verify:
android p + u212

Change-Id: I61613e945dbc9be06f2cbb29aae5043c84fca1de
Signed-off-by: Chao Liu <chao.liu@amlogic.com>
(cherry picked from commit aabb72a65e)
2019-02-20 10:59:45 +09:00
Joy Cho
54eb2c5f7f ODROID-N2: clk: add 2.004GHz cpu freq for A73 core and change the max
Change-Id: I99274d1084fc20a277a26669024391132da010f8
2019-02-20 08:58:46 +09:00
Joy Cho
2ac237d84d ODROID-N2: thermal: fix power to freq table generation bug
Change-Id: Icb25b389c8f2f88c367eef0b296300aca878bd0f
s922_9.0.0_20190214
2019-02-13 12:11:24 +09:00
Joy Cho
e34d6ee040 ODROID-N2: osd: support flexible fb size with free scale option
Change-Id: I87a63eda62b96e3d54cb88f92e16364ba8250acf
2019-02-13 12:01:13 +09:00
Joy Cho
0432f8b81b Merge "ODROID-N2: vout: update current vout mode string" into odroidn2-4.9.y-android 2019-02-13 11:57:40 +09:00
Joy Cho
6503dc28bd Merge "ODROID-N2: vout: hdmitx: adjust hdmi timing and hpll over 2Gbps" into odroidn2-4.9.y-android 2019-02-13 11:57:18 +09:00
Joy Cho
4c752a48bb Merge "ODROID-N2: vout: fix default display init option" into odroidn2-4.9.y-android 2019-02-13 11:56:51 +09:00
Joy Cho
12dc36630f ODROID-N2: thermal: add an exeception logic to control max cpu level
Change-Id: I880b89d828034b029e306bda7c8be9004c3ec913
FIXME: find a better way not to modify thermal core drivers
2019-02-13 11:51:11 +09:00