From: Neil Armstrong <narmstrong@baylibre.com>
To: Hans Verkuil <hverkuil@xs4all.nl>,
mchehab@kernel.org, hans.verkuil@cisco.com
Cc: Maxime Jourdan <mjourdan@baylibre.com>,
linux-media@vger.kernel.org, linux-amlogic@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 5/5] media: meson: vdec: add VP9 decoder support
Date: Fri, 14 Feb 2020 16:24:31 +0100 [thread overview]
Message-ID: <fed44541-8237-5910-3a69-c6e92e739607@baylibre.com> (raw)
In-Reply-To: <444673d2-f1f0-bfe8-1aa2-b37cbdec6231@xs4all.nl>
On 14/02/2020 16:04, Hans Verkuil wrote:
> On 2/6/20 9:41 AM, Neil Armstrong wrote:
>> From: Maxime Jourdan <mjourdan@baylibre.com>
>>
>> This adds VP9 decoding for the Amlogic GXL, G12A & SM1 SoCs, using
>> the commong "HEVC" HW decoder.
>>
>> For G12A & SM1, it uses the IOMMU support from the firmware.
>>
>> For 10bit decoding, the firmware can only decode in the proprietary
>> Amlogic Framebuffer Compression format, but can output in 8bit NV12
>> buffer while writing the decoded frame.
>>
>> Signed-off-by: Maxime Jourdan <mjourdan@baylibre.com>
>> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
>> ---
>> drivers/staging/media/meson/vdec/Makefile | 2 +-
>> drivers/staging/media/meson/vdec/codec_vp9.c | 2138 +++++++++++++++++
>> drivers/staging/media/meson/vdec/codec_vp9.h | 13 +
>> drivers/staging/media/meson/vdec/hevc_regs.h | 7 +
>> drivers/staging/media/meson/vdec/vdec.c | 5 +
>> .../staging/media/meson/vdec/vdec_helpers.c | 4 +
>> .../staging/media/meson/vdec/vdec_platform.c | 38 +
>> 7 files changed, 2206 insertions(+), 1 deletion(-)
>> create mode 100644 drivers/staging/media/meson/vdec/codec_vp9.c
>> create mode 100644 drivers/staging/media/meson/vdec/codec_vp9.h
>>
>> diff --git a/drivers/staging/media/meson/vdec/Makefile b/drivers/staging/media/meson/vdec/Makefile
>> index f55b6e625034..6e726af84ac9 100644
>> --- a/drivers/staging/media/meson/vdec/Makefile
>> +++ b/drivers/staging/media/meson/vdec/Makefile
>> @@ -3,6 +3,6 @@
>>
>> meson-vdec-objs = esparser.o vdec.o vdec_helpers.o vdec_platform.o
>> meson-vdec-objs += vdec_1.o vdec_hevc.o
>> -meson-vdec-objs += codec_mpeg12.o codec_h264.o codec_hevc_common.o
>> +meson-vdec-objs += codec_mpeg12.o codec_h264.o codec_hevc_common.o codec_vp9.o
>>
>> obj-$(CONFIG_VIDEO_MESON_VDEC) += meson-vdec.o
>> diff --git a/drivers/staging/media/meson/vdec/codec_vp9.c b/drivers/staging/media/meson/vdec/codec_vp9.c
>> new file mode 100644
>> index 000000000000..e7ffbc6dd892
>> --- /dev/null
>> +++ b/drivers/staging/media/meson/vdec/codec_vp9.c
>> @@ -0,0 +1,2138 @@
>
> ...
>
>> +#define ROUND_POWER_OF_TWO(value, num) (((value) + (1 << ((num) - 1))) >> (num))
>
> Checkpatch says:
>
> CHECK: Macro argument reuse 'num' - possible side-effects?
> #377: FILE: drivers/staging/media/meson/vdec/codec_vp9.c:330:
> +#define ROUND_POWER_OF_TWO(value, num) (((value) + (1 << ((num) - 1))) >> (num))
>
> While num is const in this source, I do prefer if this is turned into a static inline.
>
> It's just safer.
Ok
>
> Regards,
>
> Hans
>
prev parent reply other threads:[~2020-02-14 15:24 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-06 8:41 [PATCH v4 0/5] media: meson: vdec: Add VP9 decoding support Neil Armstrong
2020-02-06 8:41 ` [PATCH v4 1/5] media: meson: vdec: align stride on 32 bytes Neil Armstrong
2020-02-06 8:41 ` [PATCH v4 2/5] media: meson: vdec: add helpers for lossless framebuffer compression buffers Neil Armstrong
2020-02-06 8:41 ` [PATCH v4 3/5] media: meson: vdec: add common HEVC decoder support Neil Armstrong
2020-02-14 15:07 ` Hans Verkuil
2020-02-14 15:24 ` Neil Armstrong
2020-02-06 8:41 ` [PATCH v4 4/5] media: meson: vdec: add VP9 input support Neil Armstrong
2020-02-06 8:41 ` [PATCH v4 5/5] media: meson: vdec: add VP9 decoder support Neil Armstrong
2020-02-14 15:04 ` Hans Verkuil
2020-02-14 15:24 ` Neil Armstrong [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fed44541-8237-5910-3a69-c6e92e739607@baylibre.com \
--to=narmstrong@baylibre.com \
--cc=hans.verkuil@cisco.com \
--cc=hverkuil@xs4all.nl \
--cc=linux-amlogic@lists.infradead.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=mjourdan@baylibre.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).