From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jerome Glisse Subject: Re: [PATCH 1/8] drm/: Don't call drm_mmap Date: Tue, 23 Sep 2014 17:38:16 -0400 Message-ID: <20140923213813.GA13669@gmail.com> References: <1411480014-10138-1-git-send-email-daniel.vetter@ffwll.ch> <1411480014-10138-2-git-send-email-daniel.vetter@ffwll.ch> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mail-qa0-f49.google.com (mail-qa0-f49.google.com [209.85.216.49]) by gabe.freedesktop.org (Postfix) with ESMTP id A5D9F6E105 for ; Tue, 23 Sep 2014 14:38:24 -0700 (PDT) Received: by mail-qa0-f49.google.com with SMTP id n8so2313004qaq.36 for ; Tue, 23 Sep 2014 14:38:24 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1411480014-10138-2-git-send-email-daniel.vetter@ffwll.ch> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: Daniel Vetter Cc: Christian Engelmayer , Josh Triplett , DRI Development , Fabian Frederick , Rashika , Ben Skeggs , Alex Deucher , Daniel Vetter , Christian =?iso-8859-1?Q?K=F6nig?= List-Id: dri-devel@lists.freedesktop.org On Tue, Sep 23, 2014 at 03:46:47PM +0200, Daniel Vetter wrote: > Really, the legacy buffer api should be dead, especially for all these > newfangled drivers. I suspect this is copypasta from the transitioning > days, which probably originated in radeon. > = > Cc: David Airlie > Cc: Alex Deucher > Cc: "Christian K=F6nig" > Cc: David Herrmann > Cc: Rashika > Cc: Josh Triplett > Cc: Daniel Vetter > Cc: Fabian Frederick > Cc: Gerd Hoffmann > Cc: Ben Skeggs > Cc: Alexandre Courbot > Cc: Maarten Lankhorst > Cc: Christian Engelmayer > Signed-off-by: Daniel Vetter I would say NAK as i am pretty sure this break radeon UMS code path. Of course if we have the go ahead to nuke radeon UMS i am more than happy. > --- > drivers/gpu/drm/ast/ast_ttm.c | 2 +- > drivers/gpu/drm/bochs/bochs_mm.c | 2 +- > drivers/gpu/drm/cirrus/cirrus_ttm.c | 2 +- > drivers/gpu/drm/mgag200/mgag200_ttm.c | 2 +- > drivers/gpu/drm/nouveau/nouveau_ttm.c | 2 +- > drivers/gpu/drm/qxl/qxl_ttm.c | 2 +- > drivers/gpu/drm/radeon/radeon_ttm.c | 2 +- > 7 files changed, 7 insertions(+), 7 deletions(-) > = > diff --git a/drivers/gpu/drm/ast/ast_ttm.c b/drivers/gpu/drm/ast/ast_ttm.c > index 5098c7dd435c..c65d432f42c4 100644 > --- a/drivers/gpu/drm/ast/ast_ttm.c > +++ b/drivers/gpu/drm/ast/ast_ttm.c > @@ -427,7 +427,7 @@ int ast_mmap(struct file *filp, struct vm_area_struct= *vma) > struct ast_private *ast; > = > if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) > - return drm_mmap(filp, vma); > + return -EINVAL; > = > file_priv =3D filp->private_data; > ast =3D file_priv->minor->dev->dev_private; > diff --git a/drivers/gpu/drm/bochs/bochs_mm.c b/drivers/gpu/drm/bochs/boc= hs_mm.c > index 2af30e7607d7..324f5a09a0a1 100644 > --- a/drivers/gpu/drm/bochs/bochs_mm.c > +++ b/drivers/gpu/drm/bochs/bochs_mm.c > @@ -339,7 +339,7 @@ int bochs_mmap(struct file *filp, struct vm_area_stru= ct *vma) > struct bochs_device *bochs; > = > if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) > - return drm_mmap(filp, vma); > + return -EINVAL; > = > file_priv =3D filp->private_data; > bochs =3D file_priv->minor->dev->dev_private; > diff --git a/drivers/gpu/drm/cirrus/cirrus_ttm.c b/drivers/gpu/drm/cirrus= /cirrus_ttm.c > index 3e7d758330a9..d3c615f9b183 100644 > --- a/drivers/gpu/drm/cirrus/cirrus_ttm.c > +++ b/drivers/gpu/drm/cirrus/cirrus_ttm.c > @@ -411,7 +411,7 @@ int cirrus_mmap(struct file *filp, struct vm_area_str= uct *vma) > struct cirrus_device *cirrus; > = > if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) > - return drm_mmap(filp, vma); > + return -EINVAL; > = > file_priv =3D filp->private_data; > cirrus =3D file_priv->minor->dev->dev_private; > diff --git a/drivers/gpu/drm/mgag200/mgag200_ttm.c b/drivers/gpu/drm/mgag= 200/mgag200_ttm.c > index be883ef5a1d3..8ac70626df6c 100644 > --- a/drivers/gpu/drm/mgag200/mgag200_ttm.c > +++ b/drivers/gpu/drm/mgag200/mgag200_ttm.c > @@ -428,7 +428,7 @@ int mgag200_mmap(struct file *filp, struct vm_area_st= ruct *vma) > struct mga_device *mdev; > = > if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) > - return drm_mmap(filp, vma); > + return -EINVAL; > = > file_priv =3D filp->private_data; > mdev =3D file_priv->minor->dev->dev_private; > diff --git a/drivers/gpu/drm/nouveau/nouveau_ttm.c b/drivers/gpu/drm/nouv= eau/nouveau_ttm.c > index e81d086577ce..753a6def61e7 100644 > --- a/drivers/gpu/drm/nouveau/nouveau_ttm.c > +++ b/drivers/gpu/drm/nouveau/nouveau_ttm.c > @@ -281,7 +281,7 @@ nouveau_ttm_mmap(struct file *filp, struct vm_area_st= ruct *vma) > struct nouveau_drm *drm =3D nouveau_drm(file_priv->minor->dev); > = > if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) > - return drm_mmap(filp, vma); > + return -EINVAL; > = > return ttm_bo_mmap(filp, vma, &drm->ttm.bdev); > } > diff --git a/drivers/gpu/drm/qxl/qxl_ttm.c b/drivers/gpu/drm/qxl/qxl_ttm.c > index abe945a04fd4..0cbc4c987164 100644 > --- a/drivers/gpu/drm/qxl/qxl_ttm.c > +++ b/drivers/gpu/drm/qxl/qxl_ttm.c > @@ -127,7 +127,7 @@ int qxl_mmap(struct file *filp, struct vm_area_struct= *vma) > if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) { > pr_info("%s: vma->vm_pgoff (%ld) < DRM_FILE_PAGE_OFFSET\n", > __func__, vma->vm_pgoff); > - return drm_mmap(filp, vma); > + return -EINVAL; > } > = > file_priv =3D filp->private_data; > diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon= /radeon_ttm.c > index eca2ce60d440..902a3e8af79b 100644 > --- a/drivers/gpu/drm/radeon/radeon_ttm.c > +++ b/drivers/gpu/drm/radeon/radeon_ttm.c > @@ -956,7 +956,7 @@ int radeon_mmap(struct file *filp, struct vm_area_str= uct *vma) > int r; > = > if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) { > - return drm_mmap(filp, vma); > + return -EINVAL; > } > = > file_priv =3D filp->private_data; > -- = > 2.1.0 > = > _______________________________________________ > dri-devel mailing list > dri-devel@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/dri-devel