Lines Matching refs:amixer_mgr
202 struct amixer_mgr *mgr) in amixer_rsc_init()
232 static int get_amixer_rsc(struct amixer_mgr *mgr, in get_amixer_rsc()
284 static int put_amixer_rsc(struct amixer_mgr *mgr, struct amixer *amixer) in put_amixer_rsc()
300 int amixer_mgr_create(struct hw *hw, struct amixer_mgr **ramixer_mgr) in amixer_mgr_create()
303 struct amixer_mgr *amixer_mgr; in amixer_mgr_create() local
306 amixer_mgr = kzalloc(sizeof(*amixer_mgr), GFP_KERNEL); in amixer_mgr_create()
307 if (!amixer_mgr) in amixer_mgr_create()
310 err = rsc_mgr_init(&amixer_mgr->mgr, AMIXER, AMIXER_RESOURCE_NUM, hw); in amixer_mgr_create()
314 spin_lock_init(&amixer_mgr->mgr_lock); in amixer_mgr_create()
316 amixer_mgr->get_amixer = get_amixer_rsc; in amixer_mgr_create()
317 amixer_mgr->put_amixer = put_amixer_rsc; in amixer_mgr_create()
318 amixer_mgr->card = hw->card; in amixer_mgr_create()
320 *ramixer_mgr = amixer_mgr; in amixer_mgr_create()
325 kfree(amixer_mgr); in amixer_mgr_create()
329 int amixer_mgr_destroy(struct amixer_mgr *amixer_mgr) in amixer_mgr_destroy() argument
331 rsc_mgr_uninit(&amixer_mgr->mgr); in amixer_mgr_destroy()
332 kfree(amixer_mgr); in amixer_mgr_destroy()