Lines Matching refs:txc
377 static int hsc_tx_set(struct hsi_client *cl, struct hsc_tx_config *txc) in hsc_tx_set() argument
382 if ((txc->mode != HSI_MODE_STREAM) && (txc->mode != HSI_MODE_FRAME)) in hsc_tx_set()
384 if ((txc->channels == 0) || (txc->channels > HSC_DEVS)) in hsc_tx_set()
386 if (txc->channels & (txc->channels - 1)) in hsc_tx_set()
388 if ((txc->arb_mode != HSI_ARB_RR) && (txc->arb_mode != HSI_ARB_PRIO)) in hsc_tx_set()
391 cl->tx_cfg.mode = txc->mode; in hsc_tx_set()
392 cl->tx_cfg.num_hw_channels = txc->channels; in hsc_tx_set()
393 cl->tx_cfg.speed = txc->speed; in hsc_tx_set()
394 cl->tx_cfg.arb_mode = txc->arb_mode; in hsc_tx_set()
404 static inline void hsc_tx_get(struct hsi_client *cl, struct hsc_tx_config *txc) in hsc_tx_get() argument
406 txc->mode = cl->tx_cfg.mode; in hsc_tx_get()
407 txc->channels = cl->tx_cfg.num_hw_channels; in hsc_tx_get()
408 txc->speed = cl->tx_cfg.speed; in hsc_tx_get()
409 txc->arb_mode = cl->tx_cfg.arb_mode; in hsc_tx_get()
530 struct hsc_tx_config txc; in hsc_ioctl() local
564 if (copy_from_user(&txc, (void __user *)arg, sizeof(txc))) in hsc_ioctl()
566 return hsc_tx_set(channel->cl, &txc); in hsc_ioctl()
568 hsc_tx_get(channel->cl, &txc); in hsc_ioctl()
569 if (copy_to_user((void __user *)arg, &txc, sizeof(txc))) in hsc_ioctl()