All of lore.kernel.org
 help / color / mirror / Atom feed
From: Julia Lawall <julia.lawall@lip6.fr>
To: perex@perex.cz, tiwai@suse.de, alsa-devel@alsa-project.org
Subject: snd_usb_endpoint_free
Date: Wed, 25 Jun 2014 08:28:43 +0200 (CEST)	[thread overview]
Message-ID: <alpine.DEB.2.02.1406250824110.2012@localhost6.localdomain6> (raw)

The function snd_usb_endpoint_free in sound/usb/endpoint.c is defined as 
follows:

void snd_usb_endpoint_free(struct list_head *head)
{
        struct snd_usb_endpoint *ep;

        ep = list_entry(head, struct snd_usb_endpoint, list);
        release_urbs(ep, 1);
        kfree(ep);
}

I wonder if the final kfree should be list_del?  In practice, this 
function is only used from snd_usb_audio_disconnect in sound/usb/card.c 
where the entire list is destroyed, but it seems like quite a generic 
function that someone may someday want to use for just freeing one entry.

julia

             reply	other threads:[~2014-06-25  6:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-25  6:28 Julia Lawall [this message]
2014-06-25  6:50 ` snd_usb_endpoint_free Julia Lawall
2014-06-25 10:13   ` snd_usb_endpoint_free Daniel Mack
2014-06-25 10:16     ` snd_usb_endpoint_free Julia Lawall
2014-06-25 12:33     ` snd_usb_endpoint_free Takashi Iwai

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=alpine.DEB.2.02.1406250824110.2012@localhost6.localdomain6 \
    --to=julia.lawall@lip6.fr \
    --cc=alsa-devel@alsa-project.org \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.de \
    /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.