Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 83d45f23 authored by Dave Airlie's avatar Dave Airlie
Browse files

Merge branch 'linux-3.17' of git://anongit.freedesktop.org/git/nouveau/linux-2.6 into drm-fixes

A couple of thinkos from the -next merge, some random fixes from a
coverity scan, fix for (at least) GK106 accidentally using
non-existent vram on some board configurations, and better behaviour
of the instmem allocations if vmalloc space runs out.

* 'linux-3.17' of git://anongit.freedesktop.org/git/nouveau/linux-2.6:
  drm/nouveau/platform: fix compilation error
  drm/nouveau/gk20a: add LTC device
  drm/nouveau: warn if we fail to re-pin fb on resume
  drm/nouveau/nvif: fix dac load detect method definition
  drm/gf100-/gr: fix -ENOSPC detection when allocating zbc table entries
  drm/nouveau/nvif: return null pointers on failure, in addition to ret != 0
  drm/nouveau/ltc: fix tag base address getting truncated if above 4GiB
  drm/nvc0-/fb/ram: fix use of non-existant ram if partitions aren't uniform
  drm/nouveau/bar: behave better if ioremap failed
  drm/nouveau/kms: nouveau_fbcon_accel_fini can be static
  drm/nouveau: kill unused variable warning if !__OS_HAS_AGP
  drm/nouveau/nvif: fix a number of notify thinkos
parents 899552d6 4898ac04
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -132,12 +132,12 @@ nvkm_client_notify_new(struct nouveau_client *client,
		if (ret == 0) {
			client->notify[index] = notify;
			notify->client = client;
			return 0;
			return index;
		}
	}

	kfree(notify);
	return 0;
	return ret;
}

static int
+1 −0
Original line number Diff line number Diff line
@@ -163,6 +163,7 @@ nve0_identify(struct nouveau_device *device)
		device->oclass[NVDEV_SUBDEV_BUS    ] =  nvc0_bus_oclass;
		device->oclass[NVDEV_SUBDEV_TIMER  ] = &gk20a_timer_oclass;
		device->oclass[NVDEV_SUBDEV_FB     ] =  gk20a_fb_oclass;
		device->oclass[NVDEV_SUBDEV_LTC    ] =  gk104_ltc_oclass;
		device->oclass[NVDEV_SUBDEV_IBUS   ] = &gk20a_ibus_oclass;
		device->oclass[NVDEV_SUBDEV_INSTMEM] = nv50_instmem_oclass;
		device->oclass[NVDEV_SUBDEV_VM     ] = &nvc0_vmmgr_oclass;
+6 −0
Original line number Diff line number Diff line
@@ -68,6 +68,9 @@ nvc0_graph_zbc_color_get(struct nvc0_graph_priv *priv, int format,
		}
	}

	if (zbc < 0)
		return zbc;

	memcpy(priv->zbc_color[zbc].ds, ds, sizeof(priv->zbc_color[zbc].ds));
	memcpy(priv->zbc_color[zbc].l2, l2, sizeof(priv->zbc_color[zbc].l2));
	priv->zbc_color[zbc].format = format;
@@ -109,6 +112,9 @@ nvc0_graph_zbc_depth_get(struct nvc0_graph_priv *priv, int format,
		}
	}

	if (zbc < 0)
		return zbc;

	priv->zbc_depth[zbc].format = format;
	priv->zbc_depth[zbc].ds = ds;
	priv->zbc_depth[zbc].l2 = l2;
+1 −1
Original line number Diff line number Diff line
@@ -14,7 +14,7 @@ struct nouveau_client {
	void *data;

	int (*ntfy)(const void *, u32, const void *, u32);
	struct nvkm_client_notify *notify[8];
	struct nvkm_client_notify *notify[16];
};

static inline struct nouveau_client *
+11 −3
Original line number Diff line number Diff line
@@ -99,9 +99,14 @@ nouveau_bar_alloc(struct nouveau_bar *bar, struct nouveau_object *parent,
		  struct nouveau_mem *mem, struct nouveau_object **pobject)
{
	struct nouveau_object *engine = nv_object(bar);
	return nouveau_object_ctor(parent, engine, &nouveau_barobj_oclass,
	int ret = -ENOMEM;
	if (bar->iomem) {
		ret = nouveau_object_ctor(parent, engine,
					  &nouveau_barobj_oclass,
					  mem, 0, pobject);
	}
	return ret;
}

int
nouveau_bar_create_(struct nouveau_object *parent,
@@ -118,9 +123,12 @@ nouveau_bar_create_(struct nouveau_object *parent,
	if (ret)
		return ret;

	if (nv_device_resource_len(device, 3) != 0)
	if (nv_device_resource_len(device, 3) != 0) {
		bar->iomem = ioremap(nv_device_resource_start(device, 3),
				     nv_device_resource_len(device, 3));
		if (!bar->iomem)
			nv_warn(bar, "PRAMIN ioremap failed\n");
	}

	return 0;
}
Loading