From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Sakari Ailus <sakari.ailus@iki.fi>
Cc: linux-media@vger.kernel.org, sylwester.nawrocki@gmail.com
Subject: Re: [PATCH 2/4] media: Check for active links on pads with MEDIA_PAD_FL_MUST_CONNECT flag
Date: Tue, 01 Oct 2013 14:39:14 +0200 [thread overview]
Message-ID: <5707510.U5dlJYRQYf@avalon> (raw)
In-Reply-To: <20130923195702.GA3022@valkosipuli.retiisi.org.uk>
Hi Sakari,
On Monday 23 September 2013 22:57:02 Sakari Ailus wrote:
> On Fri, Sep 20, 2013 at 10:54:22PM +0200, Laurent Pinchart wrote:
> > > @@ -248,21 +250,46 @@ __must_check int
> > > media_entity_pipeline_start(struct media_entity *entity,
> > > if (!entity->ops || !entity->ops->link_validate)
> > > continue;
> > >
> > > + bitmap_zero(active, entity->num_pads);
> > > + bitmap_fill(has_no_links, entity->num_pads);
> > > +
> > > for (i = 0; i < entity->num_links; i++) {
> > > struct media_link *link = &entity->links[i];
> > > -
> > > - /* Is this pad part of an enabled link? */
> > > - if (!(link->flags & MEDIA_LNK_FL_ENABLED))
> > > - continue;
> > > -
> > > - /* Are we the sink or not? */
> > > - if (link->sink->entity != entity)
> > > + struct media_pad *pad = link->sink->entity == entity
> > > + ? link->sink : link->source;
> >
> > What about aligning the ? to the = ? With that change,
>
> How about to the beginning of the next operand rather than "="?
>
> (Think of adding parentheses around the rvalue of "=".)
>
> I think it's fine as it was, but if it's to be changed then it should be
> aligned to link->sink->entity IMHO. :-)
My preference goes for aligning the ? under the =, but I agree it's not
logical from an rvalue point of view :-) I would favor aligning the ? under
the l of link, but enough bikeshedding for now, please pick whichever solution
you prefer :-)
--
Regards,
Laurent Pinchart
next prev parent reply other threads:[~2013-10-01 12:39 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1379541668-23085-1-git-send-email-sakari.ailus@iki.fi>
[not found] ` <1379541668-23085-2-git-send-email-sakari.ailus@iki.fi>
[not found] ` <30672590.OiMqoca9Fg@avalon>
2013-09-30 23:08 ` [PATCH 1/4] media: Add pad flag MEDIA_PAD_FL_MUST_CONNECT Sakari Ailus
2013-09-30 23:21 ` Laurent Pinchart
2013-09-30 23:28 ` Sakari Ailus
2013-10-01 8:55 ` Laurent Pinchart
2013-10-01 9:17 ` Sakari Ailus
2013-10-01 9:22 ` Laurent Pinchart
[not found] ` <22265733.Mjk5afGodv@avalon>
[not found] ` <20130923195702.GA3022@valkosipuli.retiisi.org.uk>
2013-10-01 12:39 ` Laurent Pinchart [this message]
2013-10-01 12:52 ` [PATCH 2/4] media: Check for active links on pads with MEDIA_PAD_FL_MUST_CONNECT flag Sakari Ailus
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=5707510.U5dlJYRQYf@avalon \
--to=laurent.pinchart@ideasonboard.com \
--cc=linux-media@vger.kernel.org \
--cc=sakari.ailus@iki.fi \
--cc=sylwester.nawrocki@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.