All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Linux Media Mailing List <linux-media@vger.kernel.org>,
	hverkuil@xs4all.nl
Subject: Re: [PATCH 4/6] v4l2-event: Don't set sev->fh to NULL on unsubcribe
Date: Fri, 28 Oct 2011 10:35:54 +0200	[thread overview]
Message-ID: <4EAA696A.1090301@redhat.com> (raw)
In-Reply-To: <201110271420.04488.laurent.pinchart@ideasonboard.com>

Hi,

Thanks for the reviews!

On 10/27/2011 02:20 PM, Laurent Pinchart wrote:
> Hi Hans,
>
> On Thursday 27 October 2011 13:18:01 Hans de Goede wrote:
>> 1: There is no reason for this after v4l2_event_unsubscribe releases the
>> spinlock nothing is holding a reference to the sev anymore except for the
>> local reference in the v4l2_event_unsubscribe function.
>>
>> 2: Setting sev->fh to NULL causes problems for the del op added in the next
>> patch of this series, since this op needs a way to get to its own data
>> structures, and typically this will be done by using container_of on an
>> embedded v4l2_fh struct.
>>
>> Signed-off-by: Hans de Goede<hdegoede@redhat.com>
>
> Acked-by: Laurent Pinchart<laurent.pinchart@ideasonboard.com>
>
> While reviewing the patch I noticed that v4l2_event_unsubscribe_all() calls
> v4l2_event_unsubscribe(), which performs control lookup again. Is there a
> reason for that, instead of handling event unsubscription directly in
> v4l2_event_unsubscribe_all() ?

I didn't write that part, so I'll let Hans V. answer this question.

Regards,

Hans

  reply	other threads:[~2011-10-28  8:35 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-27 11:17 Various ctrl and event frame work patches Hans de Goede
2011-10-27 11:17 ` [PATCH 1/6] v4l2-ctrl: Send change events to all fh for auto cluster slave controls Hans de Goede
2011-10-30 10:16   ` Hans Verkuil
2011-10-27 11:17 ` [PATCH 2/6] v4l2-event: Deny subscribing with a type of V4L2_EVENT_ALL Hans de Goede
2011-10-27 12:04   ` Laurent Pinchart
2011-10-30 10:17   ` Hans Verkuil
2011-10-27 11:18 ` [PATCH 3/6] v4l2-event: Remove pending events from fh event queue when unsubscribing Hans de Goede
2011-10-27 12:07   ` Laurent Pinchart
2011-10-30 10:24   ` Hans Verkuil
2011-10-27 11:18 ` [PATCH 4/6] v4l2-event: Don't set sev->fh to NULL on unsubcribe Hans de Goede
2011-10-27 12:20   ` Laurent Pinchart
2011-10-28  8:35     ` Hans de Goede [this message]
2011-10-28 11:48       ` Laurent Pinchart
2011-10-30 10:30   ` Hans Verkuil
2011-10-27 11:18 ` [PATCH 5/6] v4l2-event: Add v4l2_subscribed_event_ops Hans de Goede
2011-10-27 12:30   ` Laurent Pinchart
2011-10-28  8:37     ` Hans de Goede
2011-10-30 11:17   ` Hans Verkuil
2011-10-30 11:37     ` Hans Verkuil
2011-10-27 11:18 ` [PATCH 6/6] v4l2-ctrls: Use v4l2_subscribed_event_ops Hans de Goede
2011-10-30 11:24   ` Hans Verkuil
  -- strict thread matches above, loose matches on Subject: below --
2011-10-31 15:16 Various ctrl and event frame work patches (version 2) Hans de Goede
2011-10-31 15:16 ` [PATCH 4/6] v4l2-event: Don't set sev->fh to NULL on unsubcribe Hans de Goede

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=4EAA696A.1090301@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=hverkuil@xs4all.nl \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-media@vger.kernel.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 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.