On 15/04/2024 20:34, Ricardo Ribalda wrote:
Use an API that resembles more the actual use of job_count.
Found by cocci:
drivers/media/platform/mediatek/mdp3/mtk-mdp3-cmdq.c:527:5-24: WARNING: atomic_dec_and_test variation before object free at line 541.
drivers/media/platform/mediatek/mdp3/mtk-mdp3-cmdq.c:578:6-25: WARNING: atomic_dec_and_test variation before object free at line 581.
Same comment here as per the previous patch.
You should explain in terms of the memory ordering that refcount_t gives
so that the intention of the WARNING and the API change is well
communicated.
---
bod