From: Hongzhang Yang Date: Mon, 20 Aug 2012 08:11:21 +0000 (+0800) Subject: ENGR00220732-1 Remove clk_disable in VPU driver interrupt handling X-Git-Tag: v3.0.35-fsl~579 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=d203b9144b15f99e2c1134b6f7bbf46632434d8c;p=karo-tx-linux.git ENGR00220732-1 Remove clk_disable in VPU driver interrupt handling Original design is VPU lib API StartOneFrame() enables clock, and VPU driver disables clock after codec done interrupt has been received. However there are known issues of interrupt handling as below: - VPU interrupt handling callback is not scheduled in time causing work queue overflow - JPU done interrupt is not received because JPU issues it while JPU buffer empty interrupt is still being served - VPU finishes a frame (!vpu_IsBusy) but VPU done interrupt is not received All above will cause clk_disable in interrupt handling not called, thus VPU clock count increases by 1. So I plan to resolve clock unbalance issue first by removing clk_disable from VPU driver interrupt handling. Interrupt problem will not affect clock issue any longer. 1. Driver: remove clk_disable from vpu_worker_callback 2.1. Lib: remove clk_enable from API GetOutputInfo 2.2. Lib: avoid disabling VPU clock when VPU is busy in SWReset 3. Test: replace GetOutputInfo with SWReset in decoder_close / encoder_close Signed-off-by: Hongzhang Yang --- diff --git a/drivers/mxc/vpu/mxc_vpu.c b/drivers/mxc/vpu/mxc_vpu.c index 890456802331..92a1d0dc98c7 100644 --- a/drivers/mxc/vpu/mxc_vpu.c +++ b/drivers/mxc/vpu/mxc_vpu.c @@ -180,7 +180,6 @@ static inline void vpu_worker_callback(struct work_struct *w) * codec is done. */ if (codec_done) { - clk_disable(vpu_clk); codec_done = 0; }