forked from Minki/linux
drm/msm/gpu: Move gpu_poll_timeout() to adreno_gpu.h
The gpu_poll_timeout() function can be useful to multiple targets so mvoe it into adreno_gpu.h from the a5xx code. Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
This commit is contained in:
parent
896a248a90
commit
983674e24b
@ -20,7 +20,6 @@
|
|||||||
#include <linux/soc/qcom/mdt_loader.h>
|
#include <linux/soc/qcom/mdt_loader.h>
|
||||||
#include <linux/pm_opp.h>
|
#include <linux/pm_opp.h>
|
||||||
#include <linux/nvmem-consumer.h>
|
#include <linux/nvmem-consumer.h>
|
||||||
#include <linux/iopoll.h>
|
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
#include "msm_gem.h"
|
#include "msm_gem.h"
|
||||||
#include "msm_mmu.h"
|
#include "msm_mmu.h"
|
||||||
@ -1211,10 +1210,6 @@ struct a5xx_gpu_state {
|
|||||||
u32 *hlsqregs;
|
u32 *hlsqregs;
|
||||||
};
|
};
|
||||||
|
|
||||||
#define gpu_poll_timeout(gpu, addr, val, cond, interval, timeout) \
|
|
||||||
readl_poll_timeout((gpu)->mmio + ((addr) << 2), val, cond, \
|
|
||||||
interval, timeout)
|
|
||||||
|
|
||||||
static int a5xx_crashdumper_init(struct msm_gpu *gpu,
|
static int a5xx_crashdumper_init(struct msm_gpu *gpu,
|
||||||
struct a5xx_crashdumper *dumper)
|
struct a5xx_crashdumper *dumper)
|
||||||
{
|
{
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
#define __ADRENO_GPU_H__
|
#define __ADRENO_GPU_H__
|
||||||
|
|
||||||
#include <linux/firmware.h>
|
#include <linux/firmware.h>
|
||||||
|
#include <linux/iopoll.h>
|
||||||
|
|
||||||
#include "msm_gpu.h"
|
#include "msm_gpu.h"
|
||||||
|
|
||||||
@ -375,4 +376,9 @@ static inline uint32_t get_wptr(struct msm_ringbuffer *ring)
|
|||||||
((1 << 29) \
|
((1 << 29) \
|
||||||
((ilog2((_len)) & 0x1F) << 24) | (((_reg) << 2) & 0xFFFFF))
|
((ilog2((_len)) & 0x1F) << 24) | (((_reg) << 2) & 0xFFFFF))
|
||||||
|
|
||||||
|
|
||||||
|
#define gpu_poll_timeout(gpu, addr, val, cond, interval, timeout) \
|
||||||
|
readl_poll_timeout((gpu)->mmio + ((addr) << 2), val, cond, \
|
||||||
|
interval, timeout)
|
||||||
|
|
||||||
#endif /* __ADRENO_GPU_H__ */
|
#endif /* __ADRENO_GPU_H__ */
|
||||||
|
Loading…
Reference in New Issue
Block a user