|
12 | 12 | #include <linux/io.h>
|
13 | 13 | #include <linux/mfd/syscon.h>
|
14 | 14 | #include <linux/module.h>
|
| 15 | +#include <linux/moduleparam.h> |
15 | 16 | #include <linux/of_device.h>
|
16 | 17 | #include <linux/pm_opp.h>
|
17 | 18 | #include <linux/platform_device.h>
|
|
21 | 22 | #include "../jedec_ddr.h"
|
22 | 23 | #include "../of_memory.h"
|
23 | 24 |
|
| 25 | +static int irqmode; |
| 26 | +module_param(irqmode, int, 0644); |
| 27 | +MODULE_PARM_DESC(irqmode, "Enable IRQ mode (0=off [default], 1=on)"); |
| 28 | + |
24 | 29 | #define EXYNOS5_DREXI_TIMINGAREF (0x0030)
|
25 | 30 | #define EXYNOS5_DREXI_TIMINGROW0 (0x0034)
|
26 | 31 | #define EXYNOS5_DREXI_TIMINGDATA0 (0x0038)
|
@@ -1428,7 +1433,7 @@ static int exynos5_dmc_probe(struct platform_device *pdev)
|
1428 | 1433 | /* There is two modes in which the driver works: polling or IRQ */
|
1429 | 1434 | irq[0] = platform_get_irq_byname(pdev, "drex_0");
|
1430 | 1435 | irq[1] = platform_get_irq_byname(pdev, "drex_1");
|
1431 |
| - if (irq[0] > 0 && irq[1] > 0) { |
| 1436 | + if (irq[0] > 0 && irq[1] > 0 && irqmode) { |
1432 | 1437 | ret = devm_request_threaded_irq(dev, irq[0], NULL,
|
1433 | 1438 | dmc_irq_thread, IRQF_ONESHOT,
|
1434 | 1439 | dev_name(dev), dmc);
|
@@ -1485,7 +1490,7 @@ static int exynos5_dmc_probe(struct platform_device *pdev)
|
1485 | 1490 | if (dmc->in_irq_mode)
|
1486 | 1491 | exynos5_dmc_start_perf_events(dmc, PERF_COUNTER_START_VALUE);
|
1487 | 1492 |
|
1488 |
| - dev_info(dev, "DMC initialized\n"); |
| 1493 | + dev_info(dev, "DMC initialized, in irq mode: %d\n", dmc->in_irq_mode); |
1489 | 1494 |
|
1490 | 1495 | return 0;
|
1491 | 1496 |
|
|
0 commit comments