mirror of
https://github.com/adulau/aha.git
synced 2024-12-28 11:46:19 +00:00
dma-debug: add dma_debug_driver kernel command line
This patch add the dma_debug_driver= boot parameter to enable the driver filter for early boot. Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
This commit is contained in:
parent
8a6fc708b9
commit
1745de5e56
2 changed files with 25 additions and 0 deletions
|
@ -646,6 +646,13 @@ and is between 256 and 4096 characters. It is defined in the file
|
||||||
DMA-API debugging code disables itself because the
|
DMA-API debugging code disables itself because the
|
||||||
architectural default is too low.
|
architectural default is too low.
|
||||||
|
|
||||||
|
dma_debug_driver=<driver_name>
|
||||||
|
With this option the DMA-API debugging driver
|
||||||
|
filter feature can be enabled at boot time. Just
|
||||||
|
pass the driver to filter for as the parameter.
|
||||||
|
The filter can be disabled or changed to another
|
||||||
|
driver later using sysfs.
|
||||||
|
|
||||||
dscc4.setup= [NET]
|
dscc4.setup= [NET]
|
||||||
|
|
||||||
dtc3181e= [HW,SCSI]
|
dtc3181e= [HW,SCSI]
|
||||||
|
|
|
@ -1109,3 +1109,21 @@ void debug_dma_sync_sg_for_device(struct device *dev, struct scatterlist *sg,
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL(debug_dma_sync_sg_for_device);
|
EXPORT_SYMBOL(debug_dma_sync_sg_for_device);
|
||||||
|
|
||||||
|
static int __init dma_debug_driver_setup(char *str)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
for (i = 0; i < NAME_MAX_LEN - 1; ++i, ++str) {
|
||||||
|
current_driver_name[i] = *str;
|
||||||
|
if (*str == 0)
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (current_driver_name[0])
|
||||||
|
printk(KERN_INFO "DMA-API: enable driver filter for "
|
||||||
|
"driver [%s]\n", current_driver_name);
|
||||||
|
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
__setup("dma_debug_driver=", dma_debug_driver_setup);
|
||||||
|
|
Loading…
Reference in a new issue