Skip to content

Commit 9935af9

Browse files
Chun-Kuang HuAngeloGioacchino Del Regno
authored andcommitted
soc: mediatek: cmdq: Remove cmdq_pkt_flush_async() helper function
cmdq_pkt_flush_async() is not used by all client drivers (MediaTek drm driver and MediaTek mdp3 driver), so remove it. Signed-off-by: Chun-Kuang Hu <chunkuang.hu@kernel.org> Link: https://lore.kernel.org/r/20240222154120.16959-7-chunkuang.hu@kernel.org Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
1 parent 3d86ced commit 9935af9

2 files changed

Lines changed: 0 additions & 33 deletions

File tree

drivers/soc/mediatek/mtk-cmdq-helper.c

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -446,19 +446,4 @@ int cmdq_pkt_finalize(struct cmdq_pkt *pkt)
446446
}
447447
EXPORT_SYMBOL(cmdq_pkt_finalize);
448448

449-
int cmdq_pkt_flush_async(struct cmdq_pkt *pkt)
450-
{
451-
int err;
452-
struct cmdq_client *client = (struct cmdq_client *)pkt->cl;
453-
454-
err = mbox_send_message(client->chan, pkt);
455-
if (err < 0)
456-
return err;
457-
/* We can send next packet immediately, so just call txdone. */
458-
mbox_client_txdone(client->chan, 0);
459-
460-
return 0;
461-
}
462-
EXPORT_SYMBOL(cmdq_pkt_flush_async);
463-
464449
MODULE_LICENSE("GPL v2");

include/linux/soc/mediatek/mtk-cmdq.h

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -303,19 +303,6 @@ int cmdq_pkt_eoc(struct cmdq_pkt *pkt);
303303
*/
304304
int cmdq_pkt_finalize(struct cmdq_pkt *pkt);
305305

306-
/**
307-
* cmdq_pkt_flush_async() - trigger CMDQ to asynchronously execute the CMDQ
308-
* packet and call back at the end of done packet
309-
* @pkt: the CMDQ packet
310-
*
311-
* Return: 0 for success; else the error code is returned
312-
*
313-
* Trigger CMDQ to asynchronously execute the CMDQ packet and call back
314-
* at the end of done packet. Note that this is an ASYNC function. When the
315-
* function returned, it may or may not be finished.
316-
*/
317-
int cmdq_pkt_flush_async(struct cmdq_pkt *pkt);
318-
319306
#else /* IS_ENABLED(CONFIG_MTK_CMDQ) */
320307

321308
static inline int cmdq_dev_get_client_reg(struct device *dev,
@@ -436,11 +423,6 @@ static inline int cmdq_pkt_finalize(struct cmdq_pkt *pkt)
436423
return -EINVAL;
437424
}
438425

439-
static inline int cmdq_pkt_flush_async(struct cmdq_pkt *pkt)
440-
{
441-
return -EINVAL;
442-
}
443-
444426
#endif /* IS_ENABLED(CONFIG_MTK_CMDQ) */
445427

446428
#endif /* __MTK_CMDQ_H__ */

0 commit comments

Comments
 (0)