summaryrefslogtreecommitdiffstats
path: root/drivers/media/platform/mediatek/jpeg
AgeCommit message (Collapse)AuthorFilesLines
2022-11-25media: mtk-jpegdec: add missing destroy_workqueue()Yang Yingliang1-0/+10
destroy_workqueue() needs be called to when driver is unloading, fix it by using devm_add_action_or_reset() to make workqueuedevice-managed. Fixes: dedc21500334 ("media: mtk-jpegdec: add jpeg decode worker interface") Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-09-30mtk-jpegdec: add stop cmd interface for jpgdeckyrie wu1-0/+3
Add stop cmd interface for jpgdec to stop stream Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30media: mtk-jpegdec: refactor jpegdec func interfacekyrie wu5-32/+66
refactor the func interface of mtk_jpeg_dec_set_config for decode Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30media: mtk-jpegdec: add output pic reorder interfacekyrie wu1-2/+45
add output reorder func to reorder the output images to ensure the output pic is consistent with the input images. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30media: mtk-jpegdec: add jpeg decode worker interfacekyrie wu3-12/+234
Add jpeg decoding worker to ensure that three HWs run in parallel in MT8195. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30media: mtk-jpegdec: add jpegdec timeout func interfacekyrie wu2-0/+28
Generalizes jpegdec timeout func interfaces to handle HW timeout. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30media: mtk-jpegdec: support jpegdec multi-hardwarekyrie wu3-2/+214
support jpegdec multi-hardware includes HW0/HW1/HW2. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30media: mtk-jpegdec: export jpeg decoder functionskyrie wu1-0/+6
mtk jpeg decoder is built as a module, export some functions to make them visible by other modules. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30mtk-jpegenc: add stop cmd interface for jpgenckyrie wu1-0/+4
Add stop cmd interface for jpgenc to stop stream Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30mtk-jpegenc: add output pic reorder interfacekyrie wu5-24/+81
There are two HWs in mt8195. Since the two HWs run in parallel, it is necessary to reorder the output images to ensure that the order is consistent with the input images. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30mtk-jpegenc: add jpeg encode worker interfacekyrie wu3-13/+232
Add jpeg encoding worker to ensure that two HWs run in parallel in MT8195. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30mtk-jpegenc: add jpegenc timeout func interfacekyrie wu2-0/+35
Generalizes jpegenc timeout func interfaces to handle HW timeout. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30mtk-jpegenc: support jpegenc multi-hardwarekyrie wu4-34/+249
support jpeg encode multi-hardware includes HW0 and HW1. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-30mtk-jpegenc: export jpeg encoder functionskyrie wu1-0/+6
mtk jpeg encoder is built as a module, export some functions to make them visible by other modules. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: irui wang <irui.wang@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-30media: platform: fix some double free in meson-ge2d and mtk-jpeg and s5p-mfcHangyu Hua1-1/+0
video_unregister_device will release device internally. There is no need to call video_device_release after video_unregister_device. Signed-off-by: Hangyu Hua <hbh25y@gmail.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-06-20media: media: jpegenc: set bit mask for jpegenckyrie wu1-0/+3
set jpeg encode DMA bit mask to support 34bits iova space(16GB) that the mt8186 iommu HW support. Whole the iova range separate to 0~4G/4G~8G/8G~12G/12G~16G, regarding which iova range jpgenc actually locate, it depends on the dma-ranges property of vdec dtsi node. Signed-off-by: kyrie wu <kyrie.wu@mediatek.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-04-24media: v4l: ioctl: Set bus_info in v4l_querycap()Sakari Ailus1-2/+0
The bus_info field is set by most drivers based on the type of the device bus as well as the name of the device. Do this in v4l_querycap() so drivers don't need to. This keeps compatibility with non-default and silly bus_info. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-03-18media: platform: rename mediatek/mtk-jpeg/ to mediatek/jpeg/Mauro Carvalho Chehab11-0/+2664
As the end goal is to have platform drivers split by vendor, rename mediatek/mtk-jpeg/ to mediatek/jpeg/. Requested-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>