drivers/media/platform/rockchip/cif/capture.c:5159:6: error: conflicting types for 'rkcif_do_stop_stream' due to enum/integer mismatch; have 'void(struct rkcif_stream *, unsigned int)' [-Werror=enum-int-mismatch]
5159 | void rkcif_do_stop_stream(struct rkcif_stream *stream,
| ^~~~~~~~~~~~~~~~~~~~
In file included from drivers/media/platform/rockchip/cif/capture.c:24:
drivers/media/platform/rockchip/cif/dev.h:949:6: note: previous declaration of 'rkcif_do_stop_stream' with type 'void(struct rkcif_stream *, enum rkcif_stream_mode)'
949 | void rkcif_do_stop_stream(struct rkcif_stream *stream,
| ^~~~~~~~~~~~~~~~~~~~
drivers/media/platform/rockchip/cif/capture.c:6344:5: error: conflicting types for 'rkcif_do_start_stream' due to enum/integer mismatch; have 'int(struct rkcif_stream *, unsigned int)' [-Werror=enum-int-mismatch]
6344 | int rkcif_do_start_stream(struct rkcif_stream *stream, unsigned int mode)
| ^~~~~~~~~~~~~~~~~~~~~
drivers/media/platform/rockchip/cif/dev.h:947:5: note: previous declaration of 'rkcif_do_start_stream' with type 'int(struct rkcif_stream *, enum rkcif_stream_mode)'
947 | int rkcif_do_start_stream(struct rkcif_stream *stream,
| ^~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
scripts/Makefile.build:273: recipe for target 'drivers/media/platform/rockchip/cif/capture.o' failed
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: Ibbd427bf07937c655a93bf84d33f25e86fece9d0
before:
text data bss dec hex filename
538 232 0 770 302 drivers/mfd/rkx110_x120/rkx120.o
after:
text data bss dec hex filename
468 32 0 500 1f4 drivers/mfd/rkx110_x120/rkx120.o
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ic1b6fe5fef13e64756797e28b48935ac570aa80b
Previous versions did not update the acm status in real time.
This causes the input color format of post csc to be
wrongly judged.
Change-Id: I1213ec3962682a09d9ad80827564b1d68b97cb20
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
The power consumption of mphy will be abnormal when clk_ref_mphy_26m
is disabled and PD_USB is power off/on.
Signed-off-by: Liang Chen <cl@rock-chips.com>
Change-Id: Icd67187494a22656a25454352ffcc06cc4321577
Make sure that the vp to be registered has at least
one connector, otherwise it will be as an inactive vp.
Fixes: 6092eb96b6 ("drm/rockchip: vop2: add possible_vp_mask to calculate the exact possible_crtcs")
Change-Id: Ibc078d9f50e47877e4296c2e570721a6f69c9058
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
At HDMI 4kYUV420 or 4K60 split output mode, pixel clk is 600M, dclk from
hdmi phy is 297M.
Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I619b94647b7dcb651b34f084e346f10bcc35efd3
The win attached vp maybe unused, and the unused vp will not
register crtc, so we need to lool up all win under the pd and check
if the win attached vp has register crtc.
If all the win attached vp is unused, we set the first win(undter
the pd) attach to the first crtc to make sure the pd can be closed normally.
Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: Id7dfedae2d3b6e7a139ca2eebaefea250e986d12
Add vop register address base.
Add callback for active register dump.
Change-Id: I78b39f160c799aa72da22f17564696c92a256962
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
The dsp_stx/dsp_sty on vop is dest->x1/y1 + blank timing,
this is different from vop2.
Change-Id: If2f97e85aa65ee94dcf8889d5703d92750e36061
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Because the ebc is under pd vpu, and it may be enabled in uboot.
Change-Id: Iee8afa8f802a5f02c7c50f2223479349614371ff
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Currently when suspending driver and stopping workqueue it is checked whether
workqueue is not NULL and if so, it is destroyed.
Function destroy_workqueue() does drain queue and does clear variable, but
it does not set workqueue variable to NULL. This can cause kernel/module
panic if code attempts to clear workqueue that was not initialized.
This scenario is possible when resuming suspended driver in stmmac_resume(),
because there is no handling for failed stmmac_hw_setup(),
which can fail and return if DMA engine has failed to initialize,
and workqueue is initialized after DMA engine.
Should DMA engine fail to initialize, resume will proceed normally,
but interface won't work and TX queue will eventually timeout,
causing 'Reset adapter' error.
This then does destroy workqueue during reset process.
And since workqueue is initialized after DMA engine and can be skipped,
it will cause kernel/module panic.
To secure against this possible crash, set workqueue variable to NULL when
destroying workqueue.
Log/backtrace from crash goes as follows:
[88.031977]------------[ cut here ]------------
[88.031985]NETDEV WATCHDOG: eth0 (sxgmac): transmit queue 1 timed out
[88.032017]WARNING: CPU: 0 PID: 0 at net/sched/sch_generic.c:477 dev_watchdog+0x390/0x398
<Skipping backtrace for watchdog timeout>
[88.032251]---[ end trace e70de432e4d5c2c0 ]---
[88.032282]sxgmac 16d88000.ethernet eth0: Reset adapter.
[88.036359]------------[ cut here ]------------
[88.036519]Call trace:
[88.036523] flush_workqueue+0x3e4/0x430
[88.036528] drain_workqueue+0xc4/0x160
[88.036533] destroy_workqueue+0x40/0x270
[88.036537] stmmac_fpe_stop_wq+0x4c/0x70
[88.036541] stmmac_release+0x278/0x280
[88.036546] __dev_close_many+0xcc/0x158
[88.036551] dev_close_many+0xbc/0x190
[88.036555] dev_close.part.0+0x70/0xc0
[88.036560] dev_close+0x24/0x30
[88.036564] stmmac_service_task+0x110/0x140
[88.036569] process_one_work+0x1d8/0x4a0
[88.036573] worker_thread+0x54/0x408
[88.036578] kthread+0x164/0x170
[88.036583] ret_from_fork+0x10/0x20
[88.036588]---[ end trace e70de432e4d5c2c1 ]---
[88.036597]Unable to handle kernel NULL pointer dereference at virtual address 0000000000000004
Fixes: 5a5586112b ("net: stmmac: support FPE link partner hand-shaking procedure")
Change-Id: Id0284c08a103ec9d539a0665374f71ca0ae06fab
Signed-off-by: Jakub Raczynski <j.raczynski@samsung.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: David Wu <david.wu@rock-chips.com>
The CONFIG_ROCKCHIP_ANALOGIX_DP may be enabled for VOP or VOP2,
so make its dependency consistent with the configs of other
interfaces.
Fixes: b382406a2c ("drm/rockchip: Make VOP driver optional")
Change-Id: I272926898bf520d5e023e0bbb873f680362b68ee
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>