checked for null pointers when removing axidma
fixed axidma unloading