Displaying 20 results from an estimated 280 matches for "nouveau_device".
2015 Nov 26
0
[libdrm 08/13] nouveau: make use of nouveau_drm::fd instead of nouveau_device::fd
...veau/pushbuf.c | 7 ++++---
5 files changed, 40 insertions(+), 44 deletions(-)
diff --git a/nouveau/abi16.c b/nouveau/abi16.c
index 34e9fb1..5ba2690 100644
--- a/nouveau/abi16.c
+++ b/nouveau/abi16.c
@@ -37,7 +37,7 @@
static int
abi16_chan_nv04(struct nouveau_object *obj)
{
- struct nouveau_device *dev = (struct nouveau_device *)obj->parent;
+ struct nouveau_drm *drm = nouveau_drm(obj);
struct nv04_fifo *nv04 = obj->data;
struct drm_nouveau_channel_alloc req = {
.fb_ctxdma_handle = nv04->vram,
@@ -45,7 +45,7 @@ abi16_chan_nv04(struct nouveau_object *obj)
};
int ret;
- r...
2014 Mar 13
2
[PATCH] nouveau: safen up nouveau_device list usage against concurrent access
...m.mit.edu>
---
nouveau/nouveau.c | 29 ++++++++++++++++++++++++++++-
nouveau/private.h | 3 ++-
2 files changed, 30 insertions(+), 2 deletions(-)
diff --git a/nouveau/nouveau.c b/nouveau/nouveau.c
index ee7893b..72c31cf 100644
--- a/nouveau/nouveau.c
+++ b/nouveau/nouveau.c
@@ -85,6 +85,12 @@ nouveau_device_wrap(int fd, int close, struct nouveau_device **pdev)
if (!nvdev)
return -ENOMEM;
+ ret = pthread_mutex_init(&nvdev->lock, NULL);
+ if (ret) {
+ free(nvdev);
+ return ret;
+ }
+
nvdev->base.fd = fd;
ver = drmGetVersion(fd);
@@ -161,6 +167,7 @@ nouveau_device_del(struct nouv...
2012 May 20
16
nouveau_subdev & misc patches
...wide range of fixes - from a few
month's old one-liners from Andreas Heider regarding vga_switcheroo, via a
null pointer dereference and double memory allocation, to a buffer overflow.
Please review and comment
---
drivers/gpu/drm/nouveau/nouveau_acpi.c | 3 ++-
drivers/gpu/drm/nouveau/nouveau_device.c | 26 +++++++++++++++-----------
drivers/gpu/drm/nouveau/nouveau_fb.h | 1 -
drivers/gpu/drm/nouveau/nouveau_gpio.h | 3 ---
drivers/gpu/drm/nouveau/nouveau_gpuobj.c | 12 ++++--------
drivers/gpu/drm/nouveau/nouveau_perf.c | 2 +-
drivers/gpu/drm/nouveau/nouveau_pm.c |...
2009 Jan 29
1
git compile failure
...to build nouveau form git. The compile fails with:
gcc -DHAVE_CONFIG_H -I. -I.. -D_XOPEN_SOURCE=500 -I
-I/usr/include/pixman-1 -I/usr/include/drm -I/usr/include/X11/dri -g -O2
-Wall -minline-all-stringops -D_XOPEN_SOURCE=500 -I
-I/usr/include/pixman-1 -I/usr/include/drm -I/usr/include/X11/dri -MT
nouveau_device.lo -MD -MP -MF .deps/nouveau_device.Tpo -c
nouveau_device.c -fPIC -DPIC -o .libs/nouveau_device.o
In file included from nouveau_device.c:27:
nouveau_drmif.h:47: error: expected ?=?, ?,?, ?;?, ?asm? or
?__attribute__? before ?int?
nouveau_drmif.h:51: error: expected ?=?, ?,?, ?;?, ?asm? or
?__attrib...
2015 Dec 16
0
[libdrm v3 13/14] nouveau: clean up nouveau.h, noting deprecated members/functions
...+++++---------------------------
1 file changed, 114 insertions(+), 113 deletions(-)
diff --git a/nouveau/nouveau.h b/nouveau/nouveau.h
index f3cf8f5..335ce77 100644
--- a/nouveau/nouveau.h
+++ b/nouveau/nouveau.h
@@ -4,24 +4,43 @@
#include <stdint.h>
#include <stdbool.h>
-#define NOUVEAU_DEVICE_CLASS 0x80000000
-#define NOUVEAU_FIFO_CHANNEL_CLASS 0x80000001
-#define NOUVEAU_NOTIFIER_CLASS 0x80000002
-#define NOUVEAU_PARENT_CLASS 0xffffffff
+/* Supported class information, provided by the kernel */
+struct nouveau_sclass {
+ int32_t oclass;
+ int minver;
+ int maxver;
+};...
2015 Dec 07
2
[mesa v2 5/9] nouveau: fix screen creation failure paths
...we do this in a somewhat
consistent way with the device being cleaned up in one place or
another but not both?
On Thu, Nov 26, 2015 at 8:04 PM, Ben Skeggs <skeggsb at gmail.com> wrote:
> From: Ben Skeggs <bskeggs at redhat.com>
>
> The winsys layer would attempt to cleanup the nouveau_device if screen
> init failed, however, in most paths the pipe driver would have already
> destroyed it, resulting in accesses to freed memory etc.
>
> This commit fixes the problem by allowing the winsys to detect whether
> the pipe driver's destroy function needs to be called or not....
2014 Jul 31
1
[libdrm PATCH 1/3] nouveau: Only export public functions.
...b/nouveau/nouveau.c
index 1bede84..43f0d3c 100644
--- a/nouveau/nouveau.c
+++ b/nouveau/nouveau.c
@@ -62,14 +62,14 @@ debug_init(char *args)
* is kept here to prevent AIGLX from crashing if the DDX is linked against
* the new libdrm, but the DRI driver against the old
*/
-int
+drm_public int
nouveau_device_open_existing(struct nouveau_device **pdev, int close, int fd,
drm_context_t ctx)
{
return -EACCES;
}
-int
+drm_public int
nouveau_device_wrap(int fd, int close, struct nouveau_device **pdev)
{
struct nouveau_device_priv *nvdev = calloc(1, sizeof(*nvdev));
@@ -147,7 +147,7 @@ nou...
2015 Dec 07
1
[mesa v2 5/9] nouveau: fix screen creation failure paths
...reen_create() function destroy the device
in all failure paths?
>
>>
>> On Thu, Nov 26, 2015 at 8:04 PM, Ben Skeggs <skeggsb at gmail.com> wrote:
>>> From: Ben Skeggs <bskeggs at redhat.com>
>>>
>>> The winsys layer would attempt to cleanup the nouveau_device if screen
>>> init failed, however, in most paths the pipe driver would have already
>>> destroyed it, resulting in accesses to freed memory etc.
>>>
>>> This commit fixes the problem by allowing the winsys to detect whether
>>> the pipe driver's des...
2015 Nov 26
0
[libdrm 07/13] nouveau: stack legacy nouveau_device on top of nouveau_drm
...ggs at redhat.com>
---
nouveau/nouveau.c | 46 +++++++++++++++++++++-------------------------
1 file changed, 21 insertions(+), 25 deletions(-)
diff --git a/nouveau/nouveau.c b/nouveau/nouveau.c
index 9f82fde..e304a1b 100644
--- a/nouveau/nouveau.c
+++ b/nouveau/nouveau.c
@@ -244,39 +244,36 @@ nouveau_device_open_existing(struct nouveau_device **pdev, int close, int fd,
int
nouveau_device_wrap(int fd, int close, struct nouveau_device **pdev)
{
- struct nouveau_device_priv *nvdev = calloc(1, sizeof(*nvdev));
- struct nouveau_device *dev = &nvdev->base;
+ struct nouveau_drm *drm;
+ struct nouve...
2014 Apr 08
0
[PATCH] libdrm/nouveau: safen up nouveau libdrm against concurrent access
...uveau.c | 108 +++++++++++++++++++++++++++++++++++++++++++-----------
nouveau/private.h | 3 +-
2 files changed, 89 insertions(+), 22 deletions(-)
diff --git a/nouveau/nouveau.c b/nouveau/nouveau.c
index ee7893b..75dfb0e 100644
--- a/nouveau/nouveau.c
+++ b/nouveau/nouveau.c
@@ -85,6 +85,12 @@ nouveau_device_wrap(int fd, int close, struct nouveau_device **pdev)
if (!nvdev)
return -ENOMEM;
+ ret = pthread_mutex_init(&nvdev->lock, NULL);
+ if (ret) {
+ free(nvdev);
+ return ret;
+ }
+
nvdev->base.fd = fd;
ver = drmGetVersion(fd);
@@ -161,6 +167,7 @@ nouveau_device_del(struc...
2015 Nov 27
14
[libdrm v2 01/14] nouveau: import and install a selection of nvif headers from the kernel
From: Ben Skeggs <bskeggs at redhat.com>
This commit also modifies the install path of the main libdrm_nouveau
header to be under a nouveau/ subdirectory.
Signed-off-by: Ben Skeggs <bskeggs at redhat.com>
---
include/drm/nouveau_drm.h | 1 +
nouveau/Makefile.am | 11 +++-
nouveau/libdrm_nouveau.pc.in | 2 +-
nouveau/nvif/cl0080.h | 45 ++++++++++++++
2015 Nov 26
18
[libdrm 01/13] nouveau: move more abi16-specific logic into abi16.c
...ed, 67 insertions(+), 58 deletions(-)
diff --git a/nouveau/abi16.c b/nouveau/abi16.c
index 59bc436..8f24ba2 100644
--- a/nouveau/abi16.c
+++ b/nouveau/abi16.c
@@ -33,7 +33,7 @@
#include "private.h"
-drm_private int
+static int
abi16_chan_nv04(struct nouveau_object *obj)
{
struct nouveau_device *dev = (struct nouveau_device *)obj->parent;
@@ -57,7 +57,7 @@ abi16_chan_nv04(struct nouveau_object *obj)
return 0;
}
-drm_private int
+static int
abi16_chan_nvc0(struct nouveau_object *obj)
{
struct nouveau_device *dev = (struct nouveau_device *)obj->parent;
@@ -78,7 +78,7 @@ abi16...
2014 Jul 31
2
[PATCH v5] drm/nouveau: map pages using DMA API
...7 +++++--
6 files changed, 30 insertions(+), 45 deletions(-)
diff --git a/drm/nouveau_bo.c b/drm/nouveau_bo.c
index 4db886f9f793..e4f2071c46c3 100644
--- a/drm/nouveau_bo.c
+++ b/drm/nouveau_bo.c
@@ -1340,6 +1340,7 @@ nouveau_ttm_tt_populate(struct ttm_tt *ttm)
struct nouveau_drm *drm;
struct nouveau_device *device;
struct drm_device *dev;
+ struct device *pdev;
unsigned i;
int r;
bool slave = !!(ttm->page_flags & TTM_PAGE_FLAG_SG);
@@ -1358,6 +1359,7 @@ nouveau_ttm_tt_populate(struct ttm_tt *ttm)
drm = nouveau_bdev(ttm->bdev);
device = nv_device(drm->device);
dev = drm->...
2015 Nov 27
13
[mesa v2 1/9] nouveau: bump required libdrm version to 2.4.66
From: Ben Skeggs <bskeggs at redhat.com>
Signed-off-by: Ben Skeggs <bskeggs at redhat.com>
---
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 4016871..c02ee61 100644
--- a/configure.ac
+++ b/configure.ac
@@ -73,7 +73,7 @@ LIBDRM_RADEON_REQUIRED=2.4.56
LIBDRM_AMDGPU_REQUIRED=2.4.63
LIBDRM_INTEL_REQUIRED=2.4.61
2015 Nov 26
9
[mesa 1/9] nouveau: bump required libdrm version to 2.4.66
From: Ben Skeggs <bskeggs at redhat.com>
Signed-off-by: Ben Skeggs <bskeggs at redhat.com>
---
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 4016871..c02ee61 100644
--- a/configure.ac
+++ b/configure.ac
@@ -73,7 +73,7 @@ LIBDRM_RADEON_REQUIRED=2.4.56
LIBDRM_AMDGPU_REQUIRED=2.4.63
LIBDRM_INTEL_REQUIRED=2.4.61
2015 Nov 27
0
[mesa v2 5/9] nouveau: fix screen creation failure paths
From: Ben Skeggs <bskeggs at redhat.com>
The winsys layer would attempt to cleanup the nouveau_device if screen
init failed, however, in most paths the pipe driver would have already
destroyed it, resulting in accesses to freed memory etc.
This commit fixes the problem by allowing the winsys to detect whether
the pipe driver's destroy function needs to be called or not.
Signed-off-by: Ben Ske...
2015 Feb 25
2
[PATCH 2/2] nouveau: Do not add most bo's to the global bo list.
...else {
> - DRMLISTDEL(&nvbo->head);
> - pthread_mutex_unlock(&nvdev->lock);
> drmIoctl(bo->device->fd, DRM_IOCTL_GEM_CLOSE, &req);
> }
> if (bo->map)
> @@ -379,7 +377,6 @@ nouveau_bo_new(struct nouveau_device *dev, uint32_t flags, uint32_t align,
> uint64_t size, union nouveau_bo_config *config,
> struct nouveau_bo **pbo)
> {
> - struct nouveau_device_priv *nvdev = nouveau_device(dev);
> struct nouveau_bo_priv *nvbo = calloc(1, sizeof(*nvbo));...
2014 Sep 08
1
[PATCH] gpio: rename g92 class to g94
...tions(-)
delete mode 100644 nvkm/subdev/gpio/nv92.c
create mode 100644 nvkm/subdev/gpio/nv94.c
diff --git a/nvkm/engine/device/nv50.c b/nvkm/engine/device/nv50.c
index ca265fe..96f568d 100644
--- a/nvkm/engine/device/nv50.c
+++ b/nvkm/engine/device/nv50.c
@@ -145,7 +145,7 @@ nv50_identify(struct nouveau_device *device)
case 0x92:
device->cname = "G92";
device->oclass[NVDEV_SUBDEV_VBIOS ] = &nouveau_bios_oclass;
- device->oclass[NVDEV_SUBDEV_GPIO ] = nv92_gpio_oclass;
+ device->oclass[NVDEV_SUBDEV_GPIO ] = nv50_gpio_oclass;
device->oclass[NVDEV_SUBDEV_I2C...
2015 Dec 16
11
[mesa v3 1/9] nouveau: bump required libdrm version to 2.4.66
From: Ben Skeggs <bskeggs at redhat.com>
v2. forgot bump for non-gallium driver
Signed-off-by: Ben Skeggs <bskeggs at redhat.com>
---
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index b6680d0..965c6f7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -72,8 +72,8 @@ LIBDRM_REQUIRED=2.4.60
2015 Dec 16
16
[libdrm v3 01/14] nouveau: import and install a selection of nvif headers from the kernel
From: Ben Skeggs <bskeggs at redhat.com>
This commit also modifies the install path of the main libdrm_nouveau
header to be under a nouveau/ subdirectory.
Signed-off-by: Ben Skeggs <bskeggs at redhat.com>
---
include/drm/nouveau_drm.h | 1 +
nouveau/Makefile.am | 11 +++-
nouveau/libdrm_nouveau.pc.in | 2 +-
nouveau/nvif/cl0080.h | 45 ++++++++++++++