mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-28 14:44:10 +08:00
Merge branch 'etnaviv/next' of https://git.pengutronix.de/git/lst/linux into drm-next
"small fixes and a change to not restrict etnaviv to certain architectures." Signed-off-by: Dave Airlie <airlied@redhat.com> From: Lucas Stach <l.stach@pengutronix.de> Link: https://patchwork.freedesktop.org/patch/msgid/4bc1a4c8447bb947d2fe8facd0ff09c5b8753087.camel@pengutronix.de
This commit is contained in:
commit
3a7d2f4f44
@ -5193,7 +5193,7 @@ DRM DRIVERS FOR VIVANTE GPU IP
|
||||
M: Lucas Stach <l.stach@pengutronix.de>
|
||||
R: Russell King <linux+etnaviv@armlinux.org.uk>
|
||||
R: Christian Gmeiner <christian.gmeiner@gmail.com>
|
||||
L: etnaviv@lists.freedesktop.org
|
||||
L: etnaviv@lists.freedesktop.org (moderated for non-subscribers)
|
||||
L: dri-devel@lists.freedesktop.org
|
||||
S: Maintained
|
||||
F: drivers/gpu/drm/etnaviv/
|
||||
|
@ -2,7 +2,6 @@
|
||||
config DRM_ETNAVIV
|
||||
tristate "ETNAVIV (DRM support for Vivante GPU IP cores)"
|
||||
depends on DRM
|
||||
depends on ARCH_MXC || ARCH_DOVE || (ARM && COMPILE_TEST)
|
||||
depends on MMU
|
||||
select SHMEM
|
||||
select SYNC_FILE
|
||||
|
@ -15,8 +15,6 @@ struct etnaviv_perfmon_request;
|
||||
struct etnaviv_cmdbuf {
|
||||
/* suballocator this cmdbuf is allocated from */
|
||||
struct etnaviv_cmdbuf_suballoc *suballoc;
|
||||
/* user context key, must be unique between all active users */
|
||||
struct etnaviv_file_private *ctx;
|
||||
/* cmdbuf properties */
|
||||
int suballoc_offset;
|
||||
void *vaddr;
|
||||
|
@ -215,7 +215,7 @@ void etnaviv_core_dump(struct etnaviv_gpu *gpu)
|
||||
mutex_lock(&obj->lock);
|
||||
pages = etnaviv_gem_get_pages(obj);
|
||||
mutex_unlock(&obj->lock);
|
||||
if (pages) {
|
||||
if (!IS_ERR(pages)) {
|
||||
int j;
|
||||
|
||||
iter.hdr->data[0] = bomap - bomap_start;
|
||||
|
@ -95,6 +95,7 @@ struct etnaviv_gem_submit_bo {
|
||||
struct etnaviv_gem_submit {
|
||||
struct drm_sched_job sched_job;
|
||||
struct kref refcount;
|
||||
struct etnaviv_file_private *ctx;
|
||||
struct etnaviv_gpu *gpu;
|
||||
struct dma_fence *out_fence, *in_fence;
|
||||
int out_fence_id;
|
||||
|
@ -15,7 +15,7 @@ struct sg_table *etnaviv_gem_prime_get_sg_table(struct drm_gem_object *obj)
|
||||
int npages = obj->size >> PAGE_SHIFT;
|
||||
|
||||
if (WARN_ON(!etnaviv_obj->pages)) /* should have already pinned! */
|
||||
return NULL;
|
||||
return ERR_PTR(-EINVAL);
|
||||
|
||||
return drm_prime_pages_to_sg(etnaviv_obj->pages, npages);
|
||||
}
|
||||
|
@ -506,7 +506,7 @@ int etnaviv_ioctl_gem_submit(struct drm_device *dev, void *data,
|
||||
if (ret)
|
||||
goto err_submit_objects;
|
||||
|
||||
submit->cmdbuf.ctx = file->driver_priv;
|
||||
submit->ctx = file->driver_priv;
|
||||
submit->exec_state = args->exec_state;
|
||||
submit->flags = args->flags;
|
||||
|
||||
|
@ -320,8 +320,8 @@ etnaviv_iommuv2_domain_alloc(struct etnaviv_gpu *gpu)
|
||||
domain = &etnaviv_domain->base;
|
||||
|
||||
domain->dev = gpu->dev;
|
||||
domain->base = 0;
|
||||
domain->size = (u64)SZ_1G * 4;
|
||||
domain->base = SZ_4K;
|
||||
domain->size = (u64)SZ_1G * 4 - SZ_4K;
|
||||
domain->ops = &etnaviv_iommuv2_ops;
|
||||
|
||||
ret = etnaviv_iommuv2_init(etnaviv_domain);
|
||||
|
@ -113,7 +113,7 @@ static const struct etnaviv_pm_domain doms_3d[] = {
|
||||
.name = "PE",
|
||||
.profile_read = VIVS_MC_PROFILE_PE_READ,
|
||||
.profile_config = VIVS_MC_PROFILE_CONFIG0,
|
||||
.nr_signals = 5,
|
||||
.nr_signals = 4,
|
||||
.signal = (const struct etnaviv_pm_signal[]) {
|
||||
{
|
||||
"PIXEL_COUNT_KILLED_BY_COLOR_PIPE",
|
||||
@ -435,7 +435,7 @@ int etnaviv_pm_query_sig(struct etnaviv_gpu *gpu,
|
||||
|
||||
dom = meta->domains + signal->domain;
|
||||
|
||||
if (signal->iter > dom->nr_signals)
|
||||
if (signal->iter >= dom->nr_signals)
|
||||
return -EINVAL;
|
||||
|
||||
sig = &dom->signal[signal->iter];
|
||||
@ -461,7 +461,7 @@ int etnaviv_pm_req_validate(const struct drm_etnaviv_gem_submit_pmr *r,
|
||||
|
||||
dom = meta->domains + r->domain;
|
||||
|
||||
if (r->signal > dom->nr_signals)
|
||||
if (r->signal >= dom->nr_signals)
|
||||
return -EINVAL;
|
||||
|
||||
return 0;
|
||||
|
@ -153,7 +153,7 @@ int etnaviv_sched_push_job(struct drm_sched_entity *sched_entity,
|
||||
mutex_lock(&submit->gpu->fence_lock);
|
||||
|
||||
ret = drm_sched_job_init(&submit->sched_job, sched_entity,
|
||||
submit->cmdbuf.ctx);
|
||||
submit->ctx);
|
||||
if (ret)
|
||||
goto out_unlock;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user