Displaying 13 results from an estimated 13 matches for "nvbe".
Did you mean:
nv4e
2010 Jan 30
1
[PATCH] nouveau: move dereferences after null checks
...output of: /path/to/smatch_scripts/filter_kernel_deref_check.sh warns.txt
>
> regards,
> dan carpenter
>
> (...)
> drivers/gpu/drm/nouveau/nouveau_object.c +891 'chan': if (!chan || !gpuobj_ret || *gpuobj_ret != NULL)
> drivers/gpu/drm/nouveau/nouveau_sgdma.c +61 'nvbe': if (nvbe && nvbe->pages) {
> drivers/gpu/drm/nouveau/nouveau_connector.c +91 'connector': if (!connector)
> drivers/gpu/drm/nouveau/nv50_crtc.c +306 'crtc': if (!crtc)
> (...)
---
From: Marcin Slusarz <marcin.slusarz at gmail.com>
Subject: [PATCH] no...
2014 Dec 10
2
[PATCH] drm: sgdma: free allocated memory if TT init fails
...u_sgdma.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drm/nouveau_sgdma.c b/drm/nouveau_sgdma.c
index 01707e7deaf5..e4fc494d688d 100644
--- a/drm/nouveau_sgdma.c
+++ b/drm/nouveau_sgdma.c
@@ -107,7 +107,10 @@ nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev,
else
nvbe->ttm.ttm.func = &nv50_sgdma_backend;
- if (ttm_dma_tt_init(&nvbe->ttm, bdev, size, page_flags, dummy_read_page))
+ if (ttm_dma_tt_init(&nvbe->ttm, bdev, size, page_flags, dummy_read_page)) {
+ kfree(nvbe);
return NULL;
+ }
+
return &nvbe->ttm.ttm;
}
--
2.1.3
2014 Dec 10
0
[PATCH] drm: sgdma: free allocated memory if TT init fails
...letion(-)
>
> diff --git a/drm/nouveau_sgdma.c b/drm/nouveau_sgdma.c
> index 01707e7deaf5..e4fc494d688d 100644
> --- a/drm/nouveau_sgdma.c
> +++ b/drm/nouveau_sgdma.c
> @@ -107,7 +107,10 @@ nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev,
> else
> nvbe->ttm.ttm.func = &nv50_sgdma_backend;
>
> - if (ttm_dma_tt_init(&nvbe->ttm, bdev, size, page_flags, dummy_read_page))
> + if (ttm_dma_tt_init(&nvbe->ttm, bdev, size, page_flags, dummy_read_page)) {
> + kfree(nvbe);
> retur...
2014 Dec 10
0
[PATCH] drm: sgdma: add comment around suspiscious error handler
...om>
---
drm/nouveau_sgdma.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drm/nouveau_sgdma.c b/drm/nouveau_sgdma.c
index ec76c0b4e452..23c377a6c761 100644
--- a/drm/nouveau_sgdma.c
+++ b/drm/nouveau_sgdma.c
@@ -106,6 +106,11 @@ nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev,
nvbe->ttm.ttm.func = &nv50_sgdma_backend;
if (ttm_dma_tt_init(&nvbe->ttm, bdev, size, page_flags, dummy_read_page))
+ /*
+ * A failing ttm_dma_tt_init() will call ttm_tt_destroy()
+ * and thus our nouveau_sgdma_destroy() hook, so we don't need
+ * to free nvbe here.
+ */...
2014 Dec 10
0
[PATCH] drm: sgdma: remove unused nouveau_sgdma_be::dev
...b/drm/nouveau_sgdma.c
@@ -9,7 +9,6 @@ struct nouveau_sgdma_be {
* nouve_bo.c works properly, otherwise have to move them here
*/
struct ttm_dma_tt ttm;
- struct drm_device *dev;
struct nouveau_mem *node;
};
@@ -101,7 +100,6 @@ nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev,
if (!nvbe)
return NULL;
- nvbe->dev = drm->dev;
if (drm->device.info.family < NV_DEVICE_INFO_V0_TESLA)
nvbe->ttm.ttm.func = &nv04_sgdma_backend;
else
--
2.1.3
2013 Aug 11
0
Fixing nouveau for >4k PAGE_SIZE
...ate your thought as to whether the below is correct
(and thus I'm on the right track) :
--- a/drivers/gpu/drm/nouveau/nouveau_sgdma.c
+++ b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
@@ -31,7 +31,7 @@ nv04_sgdma_bind(struct ttm_tt *ttm, struct ttm_mem_reg *mem)
{
struct nouveau_sgdma_be *nvbe = (struct nouveau_sgdma_be *)ttm;
struct nouveau_mem *node = mem->mm_node;
- u64 size = mem->num_pages << 12;
+ u64 size = mem->num_pages << PAGE_SHIFT;
if (ttm->sg) {
node->sg = ttm->sg;
diff --git a/drivers/gpu/drm/nouvea...
2013 Aug 11
2
Fixing nouveau for >4k PAGE_SIZE
Op 11-08-13 07:36, Benjamin Herrenschmidt schreef:
> On Sun, 2013-08-11 at 10:41 +1000, Benjamin Herrenschmidt wrote:
>> Now, to do that, I need a better understanding of the various things
>> in there since I'm not familiar with nouveau at all. What I think I've
>> figured out is with a few questions, it would be awesome if you could
>> answer them so I can have
2013 Aug 11
2
Fixing nouveau for >4k PAGE_SIZE
...rm/nouveau/nouveau_sgdma.c b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
index ca5492a..494cf88 100644
--- a/drivers/gpu/drm/nouveau/nouveau_sgdma.c
+++ b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
@@ -31,7 +31,7 @@ nv04_sgdma_bind(struct ttm_tt *ttm, struct ttm_mem_reg *mem)
{
struct nouveau_sgdma_be *nvbe = (struct nouveau_sgdma_be *)ttm;
struct nouveau_mem *node = mem->mm_node;
- u64 size = mem->num_pages << 12;
+ u64 size = mem->num_pages << PAGE_SHIFT;
if (ttm->sg) {
node->sg = ttm->sg;
diff --git a/drivers/gpu/drm/nouveau/nouveau_ttm.c b/drivers/gpu/drm/nou...
2013 Nov 29
2
Fixing nouveau for >4k PAGE_SIZE
...rm/nouveau/nouveau_sgdma.c b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
index 0843ebc..f255ff8 100644
--- a/drivers/gpu/drm/nouveau/nouveau_sgdma.c
+++ b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
@@ -31,7 +31,7 @@ nv04_sgdma_bind(struct ttm_tt *ttm, struct ttm_mem_reg *mem)
{
struct nouveau_sgdma_be *nvbe = (struct nouveau_sgdma_be *)ttm;
struct nouveau_mem *node = mem->mm_node;
- u64 size = mem->num_pages << 12;
+ u64 size = mem->num_pages << PAGE_SHIFT;
if (ttm->sg) {
node->sg = ttm->sg;
diff --git a/drivers/gpu/drm/nouveau/nouveau_ttm.c b/drivers/gpu/drm/nou...
2013 Aug 11
2
Fixing nouveau for >4k PAGE_SIZE
..._sgdma.c
> > index ca5492a..494cf88 100644
> > --- a/drivers/gpu/drm/nouveau/nouveau_sgdma.c
> > +++ b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
> > @@ -31,7 +31,7 @@ nv04_sgdma_bind(struct ttm_tt *ttm, struct ttm_mem_reg *mem)
> > {
> > struct nouveau_sgdma_be *nvbe = (struct nouveau_sgdma_be *)ttm;
> > struct nouveau_mem *node = mem->mm_node;
> > - u64 size = mem->num_pages << 12;
> > + u64 size = mem->num_pages << PAGE_SHIFT;
> >
> > if (ttm->sg) {
> > node->sg = ttm->sg;
> > di...
2013 Aug 11
0
Fixing nouveau for >4k PAGE_SIZE
...rivers/gpu/drm/nouveau/nouveau_sgdma.c
> index ca5492a..494cf88 100644
> --- a/drivers/gpu/drm/nouveau/nouveau_sgdma.c
> +++ b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
> @@ -31,7 +31,7 @@ nv04_sgdma_bind(struct ttm_tt *ttm, struct ttm_mem_reg *mem)
> {
> struct nouveau_sgdma_be *nvbe = (struct nouveau_sgdma_be *)ttm;
> struct nouveau_mem *node = mem->mm_node;
> - u64 size = mem->num_pages << 12;
> + u64 size = mem->num_pages << PAGE_SHIFT;
>
> if (ttm->sg) {
> node->sg = ttm->sg;
> diff --git a/drivers/gpu/drm/nouveau/...
2013 Dec 11
0
Fixing nouveau for >4k PAGE_SIZE
.../gpu/drm/nouveau/nouveau_sgdma.c
> index 0843ebc..f255ff8 100644
> --- a/drivers/gpu/drm/nouveau/nouveau_sgdma.c
> +++ b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
> @@ -31,7 +31,7 @@ nv04_sgdma_bind(struct ttm_tt *ttm, struct ttm_mem_reg *mem)
> {
> struct nouveau_sgdma_be *nvbe = (struct nouveau_sgdma_be *)ttm;
> struct nouveau_mem *node = mem->mm_node;
> - u64 size = mem->num_pages << 12;
> + u64 size = mem->num_pages << PAGE_SHIFT;
Ack. However, a patch doing this already exists in the Nouveau kernel
tree (http://cgit.f...
2013 Aug 29
0
Fixing nouveau for >4k PAGE_SIZE
...ex ca5492a..494cf88 100644
>> > --- a/drivers/gpu/drm/nouveau/nouveau_sgdma.c
>> > +++ b/drivers/gpu/drm/nouveau/nouveau_sgdma.c
>> > @@ -31,7 +31,7 @@ nv04_sgdma_bind(struct ttm_tt *ttm, struct ttm_mem_reg *mem)
>> > {
>> > struct nouveau_sgdma_be *nvbe = (struct nouveau_sgdma_be *)ttm;
>> > struct nouveau_mem *node = mem->mm_node;
>> > - u64 size = mem->num_pages << 12;
>> > + u64 size = mem->num_pages << PAGE_SHIFT;
>> >
>> > if (ttm->sg) {
>> >...