.. | .. |
---|
27 | 27 | #include <linux/slab.h> |
---|
28 | 28 | #include <asm/unaligned.h> |
---|
29 | 29 | |
---|
| 30 | +#include <drm/drm_util.h> |
---|
| 31 | + |
---|
30 | 32 | #define ATOM_DEBUG |
---|
31 | 33 | |
---|
32 | 34 | #include "atom.h" |
---|
.. | .. |
---|
51 | 53 | |
---|
52 | 54 | #define PLL_INDEX 2 |
---|
53 | 55 | #define PLL_DATA 3 |
---|
| 56 | + |
---|
| 57 | +#define ATOM_CMD_TIMEOUT_SEC 20 |
---|
54 | 58 | |
---|
55 | 59 | typedef struct { |
---|
56 | 60 | struct atom_context *ctx; |
---|
.. | .. |
---|
742 | 746 | cjiffies = jiffies; |
---|
743 | 747 | if (time_after(cjiffies, ctx->last_jump_jiffies)) { |
---|
744 | 748 | cjiffies -= ctx->last_jump_jiffies; |
---|
745 | | - if ((jiffies_to_msecs(cjiffies) > 10000)) { |
---|
746 | | - DRM_ERROR("atombios stuck in loop for more than 10secs aborting\n"); |
---|
| 749 | + if ((jiffies_to_msecs(cjiffies) > ATOM_CMD_TIMEOUT_SEC*1000)) { |
---|
| 750 | + DRM_ERROR("atombios stuck in loop for more than %dsecs aborting\n", |
---|
| 751 | + ATOM_CMD_TIMEOUT_SEC); |
---|
747 | 752 | ctx->abort = true; |
---|
748 | 753 | } |
---|
749 | 754 | } else { |
---|