Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 25c98a8e in mainline for uspace/drv/audio/sb16/main.c


Ignore:
Timestamp:
2011-11-25T22:11:00Z (10 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master
Children:
b67968c
Parents:
53a7fda
Message:

sb16: Implement audio mixer interface.

Move mixer fun creation and initialization to sb_init.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/audio/sb16/main.c

    r53a7fda r25c98a8e  
    120120
    121121
    122         ddf_fun_t *dsp_fun = NULL, *mixer_fun = NULL;
     122        ddf_fun_t *dsp_fun = NULL;
    123123#define CHECK_RET_UNREG_DEST_RETURN(ret, msg...) \
    124124if (ret != EOK) { \
     
    126126        if (dsp_fun) \
    127127                ddf_fun_destroy(dsp_fun); \
    128         if (mixer_fun) \
    129                 ddf_fun_destroy(mixer_fun); \
    130128        unregister_interrupt_handler(device, irq); \
    131129        return ret; \
     
    139137        ret = dsp_fun ? EOK : ENOMEM;
    140138        CHECK_RET_UNREG_DEST_RETURN(ret, "Failed to create dsp function.");
    141 
    142 
    143         mixer_fun = ddf_fun_create(device, fun_exposed, "mixer");
    144         ret = dsp_fun ? EOK : ENOMEM;
    145         CHECK_RET_UNREG_DEST_RETURN(ret, "Failed to create mixer function.");
    146139
    147140        ret = sb16_init_sb16(
     
    154147            "Failed to bind dsp function: %s.\n", str_error(ret));
    155148
    156         ret = ddf_fun_bind(mixer_fun);
    157         CHECK_RET_UNREG_DEST_RETURN(ret,
    158             "Failed to bind mixer function: %s.\n", str_error(ret));
    159 
    160149        /* Everything's OK assign driver_data. */
    161         mixer_fun->driver_data = soft_state;
    162150        dsp_fun->driver_data = soft_state;
    163151
Note: See TracChangeset for help on using the changeset viewer.