search for: stbl

Displaying 20 results from an estimated 24 matches for "stbl".

Did you mean: sbl
2008 Jan 07
2
How should I improve the following R code?
...ve the tables in the following CSV format: time,index,count 0,0:1:7:30,234:120:11:1 1,0:2:3:19,199:110:87:9 That is, each line represents a table, and I have N lines for N minutes of data collection. Now, I wrote the following code to get quantiles for each time period: library(Hmisc) stbl <- read.csv("data.csv") index <- lapply(strsplit(stbl$index, ":", fixed = TRUE), as.numeric) count <- lapply(strsplit(stbl$count, ":", fixed = TRUE), as.numeric) len <- length(index) for (i in 1:len) { v <- wtd.quantile(index[[i]], count[[...
2008 Jul 28
4
RODBC to query an Oracle table
...y SQL coding is incorrect; I just started learning it. But if someone could point me in the right direction or tell me if I am going about this the correct way that would be greatly appreciated! The script I have right now is: >require(RODBC) >channel<-odbcConnect("MeganXE") >stbl<-sqlQuery(channel, 'select plotnum, sampyear, sptype from density') >sqlQuery(channel, 'select count (sampyear, plotnum, sptype) from stbl where sampyear=1995 AND plotnum=1 AND sptype='S' OR sptype='H') I get this error: unexpected symbol in "sqlQuery(channel...
2016 Mar 25
7
[PATCH 0/4] Configure Power Sensors
The power sensors can be configured to sample the readout values over time. Nvidia does this too, so nouveau should probably do that too. Karol Herbst (4): iccsense: remove read function iccsense: convert to linked list iccsense: split sensor into own struct iccsense: configure sensors like nvidia does drm/nouveau/include/nvkm/subdev/iccsense.h | 6 +- drm/nouveau/nouveau_hwmon.c
2016 Oct 24
0
[PATCH 2/3] subdev/iccsense: Parse max and crit power level
...gt; #include <subdev/i2c.h> static bool @@ -216,10 +217,20 @@ nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) { struct nvkm_iccsense *iccsense = nvkm_iccsense(subdev); struct nvkm_bios *bios = subdev->device->bios; + struct nvbios_power_budget budget; struct nvbios_iccsense stbl; int i; - if (!bios || nvbios_iccsense_parse(bios, &stbl) || !stbl.nr_entry) + if (!bios) + return 0; + + if (!nvbios_power_budget_parse(bios, &budget) && budget.nr_entry && + budget.cap_entry != 0xff) { + iccsense->power_w_max = budget.entries[budget.cap_entry...
2020 Oct 14
2
[PATCH RFC] drm/nouveau: fix memory leak in nvkm_iccsense_oneinit
...8e3f52a 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c @@ -280,8 +280,10 @@ nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) } rail = kmalloc(sizeof(*rail), GFP_KERNEL); - if (!rail) + if (!rail) { + kfree(stbl.rail); return -ENOMEM; + } rail->read = read; rail->sensor = sensor; @@ -291,6 +293,7 @@ nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) list_add_tail(&rail->head, &iccsense->rails); } } + kfree(stbl.rail); return 0; } -- 2.17.1
2016 Mar 25
0
[PATCH 3/4] iccsense: split sensor into own struct
..._iccsense_create_sensor(iccsense, id); +} + static int nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) { struct nvkm_iccsense *iccsense = nvkm_iccsense(subdev); struct nvkm_bios *bios = subdev->device->bios; - struct nvkm_i2c *i2c = subdev->device->i2c; struct nvbios_iccsense stbl; int i; - if (!i2c || !bios || nvbios_iccsense_parse(bios, &stbl) - || !stbl.nr_entry) + if (!bios || nvbios_iccsense_parse(bios, &stbl) || !stbl.nr_entry) return 0; iccsense->data_valid = true; for (i = 0; i < stbl.nr_entry; ++i) { struct pwr_rail_t *r = &stbl...
2016 Mar 28
4
[PATCH v2 0/4] Configure Power Sensors
The power sensors can be configured to sample the readout values over time. Nvidia does this too, so nouveau should probably do that too. v2: use list_del and rework an error message Karol Herbst (4): iccsense: remove read function iccsense: convert to linked list iccsense: split sensor into own struct iccsense: configure sensors like nvidia does
2016 Mar 25
0
[PATCH 2/4] iccsense: convert to linked list
...e(subdev); + struct nvkm_iccsense_rail *rail, *tmp; - if (iccsense->rails) - kfree(iccsense->rails); + list_for_each_entry_safe(rail, tmp, &iccsense->rails, head) + kfree(rail); return iccsense; } @@ -145,11 +142,6 @@ nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) || !stbl.nr_entry) return 0; - iccsense->rails = kmalloc(sizeof(*iccsense->rails) * stbl.nr_entry, - GFP_KERNEL); - if (!iccsense->rails) - return -ENOMEM; - iccsense->data_valid = true; for (i = 0; i < stbl.nr_entry; ++i) { struct pwr_rail_t *r = &s...
2016 Feb 20
0
[PATCH v4 3/6] iccsense: implement for ina209, ina219 and ina3221
...se->rails); + + return iccsense; +} + +struct nvkm_subdev_func iccsense_func = { + .dtor = nvkm_iccsense_dtor, +}; int nvkm_iccsense_ctor(struct nvkm_device *device, int index, struct nvkm_iccsense *iccsense) { + struct nvkm_bios *bios; + struct nvkm_i2c *i2c; + struct nvbios_iccsense stbl; + int i; + nvkm_subdev_ctor(&iccsense_func, device, index, 0, &iccsense->subdev); + bios = device->bios; + i2c = device->i2c; + + if (!i2c || !bios || nvbios_iccsense_parse(bios, &stbl) + || !stbl.nr_entry) + return 0; + + iccsense->rails = kmalloc(sizeof(*iccsense-&...
2017 Jan 23
3
[PATCH v4 0/3] Expose power budget cap via hwmon
There is an optinal header field in the power budget table we can use to read out the power cap of the GPU. The meaning of this header field was confirmed with nvidia-smi -q: The rows "Min Power Limit", "Power Limit" and "Max Power Limit" are set to the "min", "avg" and "max" values from the referenced power budget entry respectively.
2020 Oct 15
0
[PATCH RFC] drm/nouveau: fix memory leak in nvkm_iccsense_oneinit
...280,8 +280,10 @@ nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) > } > > rail = kmalloc(sizeof(*rail), GFP_KERNEL); > - if (!rail) > + if (!rail) { > + kfree(stbl.rail); > return -ENOMEM; > + } > > rail->read = read; > rail->sensor = sensor; > @@ -291,6 +293,7 @@ nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) >...
2020 Oct 19
0
[PATCH] drm/nouveau: fix memory leak in iccsense/base.c
...4a>] nvif_device_ctor+0x24/0x70 [nouveau] [<00000000878b3286>] nouveau_cli_init+0x1a3/0x460 [nouveau] [<00000000a1578335>] nouveau_drm_device_init+0x77/0x740 [nouveau] [<00000000faef6b28>] nouveau_drm_probe+0x132/0x1f0 [nouveau] Fix nvkm_iccsense_oneinit(), to free stbl.rail post iteration. Signed-off-by: Vamshi K Sthambamkadi <vamshi.k.sthambamkadi at gmail.com> --- drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c b/drivers/gpu/drm/nouveau/nvkm/subde...
2016 Nov 12
4
[PATCH 0/3] Expose power budget cap via hwmon
There is an optinal header field in the power budget table we can use to read out the power cap of the GPU. We should have this in the kernel before actually using it to catch errors and see how reliable this is, but as it seems it works on all GPUs as expected on Kepler und Maxwells with the power cap field set in the vbios. This series keeps things really simple for now until we figure out
2016 Nov 30
4
[PATCH v3 0/3] Expose power budget cap via hwmon
There is an optinal header field in the power budget table we can use to read out the power cap of the GPU. We should have this in the kernel before actually using it to catch errors and see how reliable this is, but as it seems it works on all GPUs as expected on Kepler und Maxwells with the power cap field set in the vbios. This series keeps things really simple for now until we figure out
2016 Jul 27
0
[PATCH] nvkm/iccsense: Parse the resistors and config the right way
...->type = extdev.type; sensor->i2c = &i2c_bus->i2c; sensor->addr = addr; - sensor->rail_mask = 0x0; + sensor->config = 0x0; return sensor; } @@ -273,48 +224,56 @@ nvkm_iccsense_oneinit(struct nvkm_subdev *subdev) iccsense->data_valid = true; for (i = 0; i < stbl.nr_entry; ++i) { - struct pwr_rail_t *r = &stbl.rail[i]; - struct nvkm_iccsense_rail *rail; + struct pwr_rail_t *pwr_rail = &stbl.rail[i]; struct nvkm_iccsense_sensor *sensor; - int (*read)(struct nvkm_iccsense *, - struct nvkm_iccsense_rail *); + int r; - if (!r->mode |...
2016 Feb 20
12
[PATCH v4 0/6] Suppor for various power sensors on GF100+
This is a complete rework from the first version I sent out. Now the implementation is more centered around the power_rails we find in the SENSE table instead of extdev centered. This makes the implementation a lot easier and straightforward. I've added support for the INA219, INA209 and INA3221 sensors found on multiple Fermi and Kepler cards. The power consumption is also exported via
2016 Oct 24
7
RFC [PATCH 0/3] Expose power budget cap via hwmon
There is an optinal header field in the power budget table we can use to read out the power cap of the GPU. Sadly it is optional and if that field isn't sad, things beome complicated. Anyhow, this is good enough for most cards and we can use it later for capping the power consumption of the GPUs, but first, just export those values through hwmon. First design, will change stuff, want
2016 Feb 24
7
[PATCH v5 0/6] Suppor for various power sensors on GF100+
This is a complete rework from the first version I sent out. Now the implementation is more centered around the power_rails we find in the SENSE table instead of extdev centered. This makes the implementation a lot easier and straightforward. I've added support for the INA219, INA209 and INA3221 sensors found on multiple Fermi and Kepler cards. The power consumption is also exported via
2016 Feb 20
4
[PATCH v3 0/4] Suppor for various power sensors on GF100+
This is a complete rework from the first version I sent out. Now the implementation is more centered around the power_rails we find in the SENSE table instead of extdev centered. This makes the implementation a lot easier and straightforward. I've added support for the INA219, INA209 and INA3221 sensors found on multiple Fermi and Kepler cards. The power consumption is also exported via
2016 Feb 19
4
[PATCH v2 0/4] Suppor for various power sensors on GF100+
This is a complete rework from the last version I sent out. Now the implementation is more centered around the power_rails we find in the SENSE table instead of extdev centered. This makes the implementation a lot easier and straightforward. I've added support for the INA219, INA209 and INA3221 sensors found on multiple Fermi and Kepler cards, but only the INA3221 bits are tested so far.