|
@@ -676,6 +676,8 @@ static int dma_debug_device_change(struct notifier_block *nb,
|
|
struct device *dev = data;
|
|
struct device *dev = data;
|
|
int count;
|
|
int count;
|
|
|
|
|
|
|
|
+ if (global_disable)
|
|
|
|
+ return;
|
|
|
|
|
|
switch (action) {
|
|
switch (action) {
|
|
case BUS_NOTIFY_UNBOUND_DRIVER:
|
|
case BUS_NOTIFY_UNBOUND_DRIVER:
|
|
@@ -697,6 +699,9 @@ void dma_debug_add_bus(struct bus_type *bus)
|
|
{
|
|
{
|
|
struct notifier_block *nb;
|
|
struct notifier_block *nb;
|
|
|
|
|
|
|
|
+ if (global_disable)
|
|
|
|
+ return;
|
|
|
|
+
|
|
nb = kzalloc(sizeof(struct notifier_block), GFP_KERNEL);
|
|
nb = kzalloc(sizeof(struct notifier_block), GFP_KERNEL);
|
|
if (nb == NULL) {
|
|
if (nb == NULL) {
|
|
pr_err("dma_debug_add_bus: out of memory\n");
|
|
pr_err("dma_debug_add_bus: out of memory\n");
|