> > > + if (rlink != link->reverse) {
> > > + r++;
> >
> > The variable is incremented here but otherwise never used, you can remove it.
Suggested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
{
struct media_link *rlink, *tmp;
struct media_entity *remote;
- unsigned int r = 0;
if (link->source->entity == entity)
remote = link->sink->entity;
remote = link->source->entity;
list_for_each_entry_safe(rlink, tmp, &remote->links, list) {
- if (rlink != link->reverse) {
- r++;
+ if (rlink != link->reverse)
continue;
- }
if (link->source->entity == entity)
remote->num_backlinks--;