lkml.org 
[lkml]   [2020]   [Mar]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v6 5/6] media: rkvdec: Add the rkvdec driver
Em Mon, 2 Mar 2020 15:35:29 +0100
Boris Brezillon <boris.brezillon@collabora.com> escreveu:

> On Mon, 2 Mar 2020 14:57:46 +0100
> Mauro Carvalho Chehab <mchehab+huawei@kernel.org> wrote:
>
> > > + for (j = 0; j < 3; j++) {
> >
> > Again a magic number. I guess this came from that big "M_N" table with 4
> > elements, right? Please use a define instead of hardcoding a number
> > here.
>
> Nope, it's unrelated to the cabac_table size, it's related to how the
> HW accesses the P/B reflists (there are 1 P reflist, and 2 B reflists,
> hence the 3 here).

Ah, ok!

> I guess we can have a '#define NUM_REFLISTS 3'.

Works for me. Please use NUM_REFLISTS on a consistent way, making it
to reflect everywhere you might define or loop over those 3 reflists.


Thanks,
Mauro

\
 
 \ /
  Last update: 2020-03-02 15:40    [W:0.051 / U:2.516 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site