There were several instances in which apf code could fail silently.
This patch adds descriptive messages to the kernel debug log instead of
just returning an error code. This is done to aid future debugging.
Signed-off-by: Michael Gill <gill@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
unsigned int i;
for (i = 0; i < MAX_XLNK_DMAS; i++)
- xlnk_devpacks[0] = NULL;
+ xlnk_devpacks[i] = NULL;
}
case XLNK_IOCRECRES: /* recover resource */
status = xlnk_recover_resource(args);
break;
+ default:
+ pr_err("xlnk- Unknown ioctl code emitted\n");
+ status = -EINVAL;
}
return status;
vma->vm_end - vma->vm_start,
vma->vm_page_prot);
}
- if (status)
+ if (status) {
+ pr_err("xlnk_mmap failed with code %d\n", EAGAIN);
return -EAGAIN;
+ }
xlnk_vma_open(vma);
vma->vm_ops = &xlnk_vm_ops;