예제 #1
0
/**
 * @brief Destroy a MIDIDriverAppleMIDI instance.
 * Free all resources occupied by the driver.
 * @public @memberof MIDIDriverAppleMIDI
 * @param driver The driver.
 */
void MIDIDriverAppleMIDIDestroy( struct MIDIDriverAppleMIDI * driver ) {
  _applemidi_disconnect( driver, 0 );
  RTPMIDISessionRelease( driver->rtpmidi_session );
  RTPSessionRelease( driver->rtp_session );
  MIDIMessageQueueRelease( driver->in_queue );
  MIDIMessageQueueRelease( driver->out_queue );
}
예제 #2
0
/**
 * @brief Destroy a MIDIDriverAppleMIDI instance.
 * Free all resources occupied by the driver.
 * @public @memberof MIDIDriverAppleMIDI
 * @param driver The driver.
 */
void MIDIDriverAppleMIDIDestroy(struct MIDIDriverAppleMIDI *driver)
{
	_applemidi_disconnect(driver, NULL);
	RTPMIDISessionRelease(driver->rtpmidi_session);
	RTPSessionRelease(driver->rtp_session);
	// MIDIMessageQueueRelease(driver->in_queue);
	// MIDIMessageQueueRelease(driver->out_queue);
	MIDIDriverRelease(&(driver->base));
	del_timer(&driver->timer);
	kfree(driver);
}