[media] coda: split encoder specific parts out of device_run and irq_handler