---
name: "snd_card_free_in_thread"
section: "9"
platform: "linux"
package: "linux-manual-2.6.18"
version: "2.6.18.dfsg.1-26etch2"
release: "Debian 4.0 (Etch)"
platforms: ["linux"]
url: "https://new.carta.tech/snd_card_free_in_thread"
---

# snd\_card\_free\_in\_thread(9)

call snd\_card\_free in thread

## NAME

snd\_card\_free\_in\_thread - call snd\_card\_free in thread

## SYNOPSIS

**int snd\_card\_free\_in\_thread(struct snd\_card \*** *card***);**

## ARGUMENTS

*card*

soundcard structure

## DESCRIPTION

This function schedules the call of **snd\_card\_free** function in a work queue. When all devices are released (non-busy), the work is woken up and calls **snd\_card\_free**.

When a card can be disconnected at any time by hotplug service, this function should be used in disconnect (or detach) callback instead of calling **snd\_card\_free** directly.

Returns - zero otherwise a negative error code if the start of thread failed.

## COPYRIGHT
