*
* When the sound card is not available anymore due to unbinding driver or
* hot unplugging, this signal is emit. The owner of this object should
- * call g_object_free() as quickly as possible to release ALSA control
- * character device.
+ * call g_object_unref() as quickly as possible to be going to release ALSA
+ * control character device.
*/
ctl_card_sigs[CTL_CARD_SIG_HANDLE_DISCONNECTION] =
g_signal_new("handle-disconnection",
* @error: A #GError.
*
* Open ALSA control character device for the sound card.
+ *
+ * The call of function executes open(2) system call for ALSA control character
+ * device.
*/
void alsactl_card_open(ALSACtlCard *self, guint card_id, gint open_flag,
GError **error)
* @error: A #GError.
*
* Get the information of sound card.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_CARD_INFO command for ALSA control character device.
*/
void alsactl_card_get_info(ALSACtlCard *self, ALSACtlCardInfo **card_info,
GError **error)
*
* Generate a list of ALSACtlElemId for ALSA control character device
* associated to the sound card.
+ *
+ * The call of function executes several ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_LIST command for ALSA control character device.
*/
void alsactl_card_get_elem_id_list(ALSACtlCard *self, GList **entries,
GError **error)
* @error: A #GError.
*
* Lock/Unlock indicated element not to be written by the other processes.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_LOCK and SNDRV_CTL_IOCTL_ELEM_UNLOCK commands for
+ * ALSA control character device..
*/
void alsactl_card_lock_elem(ALSACtlCard *self, const ALSACtlElemId *elem_id,
gboolean lock, GError **error)
* @error: A #GError.
*
* Get information of element corresponding to given id.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_INFO command for ALSA control character device. For
+ * enumerated element, it executes the system call for several times to
+ * retrieve all of enumeration labels.
*/
void alsactl_card_get_elem_info(ALSACtlCard *self, const ALSACtlElemId *elem_id,
ALSACtlElemInfo **elem_info, GError **error)
*
* Write the given array of bytes as Type/Length/Value data for element pointed
* by the identifier.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_TLV_WRITE command for ALSA control character device.
*/
void alsactl_card_write_elem_tlv(ALSACtlCard *self,
const ALSACtlElemId *elem_id,
*
* Read Type/Length/Value data from element pointed by the identifier and fulfil
* the given array of bytes with the data.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_TLV_READ command for ALSA control character device.
*/
void alsactl_card_read_elem_tlv(ALSACtlCard *self, const ALSACtlElemId *elem_id,
gint32 *const *container, gsize *container_count,
*
* Command the given array of bytes as Type/Length/Value data for element
* pointed by the identifier.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_TLV_COMMAND command for ALSA control character device.
*/
void alsactl_card_command_elem_tlv(ALSACtlCard *self,
const ALSACtlElemId *elem_id,
* @error: A #GError.
*
* Add the user-defined elements and return the list of their identifier.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_ADD command for ALSA control character device.
*/
void alsactl_card_add_elems(ALSACtlCard *self, const ALSACtlElemId *elem_id,
guint elem_count, ALSACtlElemInfo *elem_info,
* @error: A #GError.
*
* Add user-defined elements to replace the existent ones.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_REPLACE command for ALSA control character device.
*/
void alsactl_card_replace_elems(ALSACtlCard *self, const ALSACtlElemId *elem_id,
guint elem_count, ALSACtlElemInfo *elem_info,
* @error: A #GError.
*
* Remove user-defined elements pointed by the identifier.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_REMOVE command for ALSA control character device.
*/
void alsactl_card_remove_elems(ALSACtlCard *self, const ALSACtlElemId *elem_id,
GError **error)
* @error: A #GError.
*
* Write given value to element indicated by given ID.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_WRITE command for ALSA control character device.
*/
void alsactl_card_write_elem_value(ALSACtlCard *self,
const ALSACtlElemId *elem_id,
* @error: A #GError.
*
* Read given value from element indicated by given ID.
+ *
+ * The call of function executes ioctl(2) system call with
+ * SNDRV_CTL_IOCTL_ELEM_READ command for ALSA control character device.
*/
void alsactl_card_read_elem_value(ALSACtlCard *self,
const ALSACtlElemId *elem_id,
* @error: A #GError.
*
* Allocate GSource structure to handle events from ALSA control character
- * device.
+ * device. In each iteration of GManContext, the read(2) system call is
+ * executed to dispatch control event for 'handle-elem-event' signal,
+ * according to the result of poll(2) system call.
*/
void alsactl_card_create_source(ALSACtlCard *self, GSource **gsrc,
GError **error)