linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Helen Koike <helen.koike@collabora.com>
To: Shuah Khan <skhan@linuxfoundation.org>,
	mchehab@kernel.org, andrealmeid@collabora.com,
	dafna.hirschfeld@collabora.com, hverkuil-cisco@xs4all.nl
Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 3/5] vimc: move duplicated IS_SRC and IS_SINK to common header
Date: Mon, 16 Sep 2019 07:42:03 -0300	[thread overview]
Message-ID: <431c6d0a-724b-1b78-685c-95bfa8f5c39e@collabora.com> (raw)
In-Reply-To: <124fe9af-5540-770e-d124-99e2b3b4e39a@linuxfoundation.org>



On 9/15/19 8:52 PM, Shuah Khan wrote:
> On 9/15/19 1:25 PM, Helen Koike wrote:
>> Hi Shuah,
>>
>> On 9/6/19 11:42 PM, Shuah Khan wrote:
>>> Move duplicated IS_SRC and IS_SINK dfines to common header. Rename
>>> them to VIMC_IS_SRC and VIM_IS_SINK.
>>>
>>> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
>>> ---
>>>   drivers/media/platform/vimc/vimc-common.h  |  4 ++++
>>>   drivers/media/platform/vimc/vimc-debayer.c | 11 ++++-------
>>>   drivers/media/platform/vimc/vimc-scaler.c  |  8 +++-----
>>>   3 files changed, 11 insertions(+), 12 deletions(-)
>>>
>>> diff --git a/drivers/media/platform/vimc/vimc-common.h b/drivers/media/platform/vimc/vimc-common.h
>>> index 87ee84f78322..236412ad7548 100644
>>> --- a/drivers/media/platform/vimc/vimc-common.h
>>> +++ b/drivers/media/platform/vimc/vimc-common.h
>>> @@ -27,6 +27,10 @@
>>>     #define VIMC_FRAME_INDEX(lin, col, width, bpp) ((lin * width + col) * bpp)
>>>   +/* Source and sink pad checks */
>>> +#define VIMC_IS_SRC(pad)    (pad)
>>> +#define VIMC_IS_SINK(pad)    (!(pad))
>>
>> This is true now, but it might not be true in the future.
>> In the output video device (that was sent by André but not yet upstream) for instance, only have a single
>> source pad (which I suppose the index will be 0), and this macro won't be true.
>>
> 
>> Maybe we could check pad flags in sd->entity->pads[index].flags ?
>>
> 
> I think this change should be done in André's patch?

Could be yes, making it generic since the start would be nice,
but I don't mind updating this latter when needed.

Then:

Acked-by: Helen Koike <helen.koike@collabora.com>

> 
> thanks,
> -- Shuah
Thanks
Helen

  reply	other threads:[~2019-09-16 10:42 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-07  2:42 [PATCH v4 0/5] Collapse vimc into single monolithic driver Shuah Khan
2019-09-07  2:42 ` [PATCH v4 1/5] media: vimc: Collapse component structure into a " Shuah Khan
2019-09-15 19:25   ` Helen Koike
2019-09-16  0:40     ` Shuah Khan
2019-09-07  2:42 ` [PATCH v4 2/5] media: vimc: Fix gpf in rmmod path when stream is active Shuah Khan
2019-09-15 19:25   ` Helen Koike
2019-09-07  2:42 ` [PATCH v4 3/5] vimc: move duplicated IS_SRC and IS_SINK to common header Shuah Khan
2019-09-15 19:25   ` Helen Koike
2019-09-15 23:52     ` Shuah Khan
2019-09-16 10:42       ` Helen Koike [this message]
2019-09-17  2:42         ` Shuah Khan
2019-09-07  2:42 ` [PATCH v4 4/5] doc: media: vimc: Update module parameter usage information Shuah Khan
2019-09-15 19:25   ` Helen Koike
2019-09-07  2:42 ` [PATCH v4 5/5] MAINTAINERS: Add reviewer to vimc driver Shuah Khan
2019-09-15 19:26   ` Helen Koike

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=431c6d0a-724b-1b78-685c-95bfa8f5c39e@collabora.com \
    --to=helen.koike@collabora.com \
    --cc=andrealmeid@collabora.com \
    --cc=dafna.hirschfeld@collabora.com \
    --cc=hverkuil-cisco@xs4all.nl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=skhan@linuxfoundation.org \
    /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).