Displaying 7 results from an estimated 7 matches for "get_counter_index".
2015 Oct 26
1
[PATCH 4/4] nouveau/debugfs: add interface for current load
.../nvkm/subdev/pmu/base.c
> index d95eb86..ddb36e7 100644
> --- a/drm/nouveau/nvkm/subdev/pmu/base.c
> +++ b/drm/nouveau/nvkm/subdev/pmu/base.c
> @@ -140,6 +140,24 @@ nvkm_pmu_recv(struct work_struct *work)
> process, message, data0, data1);
> }
>
> +#define get_counter_index(v, i) (((v) & 0xff << ((i)*8)) >> ((i)*8))
Is this the same thing as
(v >> (i*8)) & 0xff
? I can't tell if you're attempting to preserve the sign, but don't
see why you'd want to since it all just becomes a u8 anyways.
> +
> +int
> +nvkm_pmu_ge...
2015 Oct 26
0
[PATCH 4/4] nouveau/debugfs: add interface for current load
...a/drm/nouveau/nvkm/subdev/pmu/base.c b/drm/nouveau/nvkm/subdev/pmu/base.c
index d95eb86..ddb36e7 100644
--- a/drm/nouveau/nvkm/subdev/pmu/base.c
+++ b/drm/nouveau/nvkm/subdev/pmu/base.c
@@ -140,6 +140,24 @@ nvkm_pmu_recv(struct work_struct *work)
process, message, data0, data1);
}
+#define get_counter_index(v, i) (((v) & 0xff << ((i)*8)) >> ((i)*8))
+
+int
+nvkm_pmu_get_perf_data(struct nvkm_pmu *pmu, struct nvkm_pmu_load_data *data)
+{
+ int result[2], ret;
+ ret = nvkm_pmu_send(pmu, result, PROC_PERF, PERF_MSG_LOAD, 0, 0);
+
+ if (ret < 0)
+ return ret;
+
+ data->core = get_co...
2015 Oct 26
0
[PATCH v2 4/4] nouveau/debugfs: add interface for current load
...a/drm/nouveau/nvkm/subdev/pmu/base.c b/drm/nouveau/nvkm/subdev/pmu/base.c
index d95eb86..9f4ce6a 100644
--- a/drm/nouveau/nvkm/subdev/pmu/base.c
+++ b/drm/nouveau/nvkm/subdev/pmu/base.c
@@ -140,6 +140,24 @@ nvkm_pmu_recv(struct work_struct *work)
process, message, data0, data1);
}
+#define get_counter_index(v, i) (((v) >> ((i)*8)) & 0xff)
+
+int
+nvkm_pmu_get_perf_data(struct nvkm_pmu *pmu, struct nvkm_pmu_load_data *data)
+{
+ u32 result[2], ret;
+ ret = nvkm_pmu_send(pmu, result, PROC_PERF, PERF_MSG_LOAD, 0, 0);
+
+ if (ret < 0)
+ return ret;
+
+ data->core = get_counter_index(resul...
2015 Oct 26
0
[PATCH v3 4/4] nouveau/debugfs: add interface for current load
...a/drm/nouveau/nvkm/subdev/pmu/base.c b/drm/nouveau/nvkm/subdev/pmu/base.c
index d95eb86..6594812 100644
--- a/drm/nouveau/nvkm/subdev/pmu/base.c
+++ b/drm/nouveau/nvkm/subdev/pmu/base.c
@@ -140,6 +140,24 @@ nvkm_pmu_recv(struct work_struct *work)
process, message, data0, data1);
}
+#define get_counter_index(v, i) (((v) >> ((i)*8)) & 0xff)
+
+int
+nvkm_pmu_get_perf_data(struct nvkm_pmu *pmu, struct nvkm_pmu_load_data *data)
+{
+ u32 result[2];
+
+ int ret = nvkm_pmu_send(pmu, result, PROC_PERF, PERF_MSG_LOAD, 0, 0);
+ if (ret < 0)
+ return ret;
+
+ data->core = get_counter_index(result...
2015 Oct 26
9
[PATCH 0/4] Add pdaemon load counters
this series makes use of the load counters we can use to get information about
the current load of the gpu.
This series includes the needed pmu bits and a debugfs interface to read them
out. Currently the values are between 0 and 255, because it is much easier to
implement it this way on the pmu.
Karol Herbst (4):
subdev/pmu/fuc: add gk104
pmu/fuc: add macros for pdaemon pwr counters
2016 Feb 08
4
[PATCH 0/4] PMU engine counters
these are usually used for dynamic reclocking on gt215 and newer
The counters are used to get the load of the core, memory, video and pcie loads
currently I expose the loads through a debugfs "current_load" file, but I want
to move that to nvif and just add a wrapper around that in debugfs for
convenience
Anyway there are still some issues I would like to discuss:
1. currently the
2016 Feb 16
4
[PATCH v2 0/4] PMU engine counters
these are usually used for dynamic reclocking on gt215 and newer
The counters are used to get the load of the core, memory, video and pcie loads
currently I expose the loads through a debugfs "current_load" file, but I want
to move that to nvif and just add a wrapper around that in debugfs for
convenience. Using nvif would have the advantage, that userspace tools can
easily get loads