search for: seq_printf

Displaying 20 results from an estimated 165 matches for "seq_printf".

2013 Sep 06
0
[PATCH RESEND v3 0/7] Enable Drivers for Intel MIC X100 Coprocessors.
...--git a/drivers/misc/mic/host/mic_debugfs.c b/drivers/misc/mic/host/mic_debugfs.c index e22fb7b..002faa5 100644 --- a/drivers/misc/mic/host/mic_debugfs.c +++ b/drivers/misc/mic/host/mic_debugfs.c @@ -103,7 +103,7 @@ static int mic_smpt_show(struct seq_file *s, void *pos) unsigned long flags; seq_printf(s, "MIC %-2d |%-10s| %-14s %-10s\n", - mdev->id, "SMPT entry", "SW DMA addr", "RefCount"); + mdev->id, "SMPT entry", "SW DMA addr", "RefCount"); seq_puts(s, "====================================================\...
2023 Apr 16
0
[PATCH 4/9] drm/nouveau/debugfs: Replace five seq_printf() calls by seq_puts() in nouveau_debugfs_pstate_get()
...u/nouveau_debugfs.c index 13c82eea8828..99d022a91afc 100644 --- a/drivers/gpu/drm/nouveau/nouveau_debugfs.c +++ b/drivers/gpu/drm/nouveau/nouveau_debugfs.c @@ -120,16 +120,16 @@ nouveau_debugfs_pstate_get(struct seq_file *m, void *data) if (state >= 0) { if (info.ustate_ac == state) - seq_printf(m, " AC"); + seq_puts(m, " AC"); if (info.ustate_dc == state) - seq_printf(m, " DC"); + seq_puts(m, " DC"); if (info.pstate == state) - seq_printf(m, " *"); + seq_puts(m, " *"); } else { if (info.ustate_ac &lt...
2018 Jul 31
1
[PATCH] drm/nouveau: Fix potential memory access error in nouveau_debugfs_pstate_get()
nouveau_debugfs(drm) will never be NULL, because we're taking the value of the potentially null device pointer and adding to it so it isn't 0x0. So, check if drm is NULL instead. Signed-off-by: Lyude Paul <lyude at redhat.com> Cc: Karol Herbst <karolherbst at gmail.com> --- drivers/gpu/drm/nouveau/nouveau_debugfs.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
2007 Apr 18
1
[RFC, PATCH 21/24] i386 Vmi proc node
...s = tsc_end - tsc_start; + if (cycles < page_fault_cycles) + page_fault_cycles = cycles; + } +} + +static int proc_vmi_info_show(struct seq_file *m, void *v) +{ + if (!hypervisor_found) + seq_puts(m, "No VMI active\n"); + else + seq_puts(m, "Hypervisor VMI active\n"); + seq_printf(m, "Kernel VMI API version %d.%d\n", + VMI_API_REV_MAJOR, MIN_VMI_API_REV_MINOR); + if (vmi_rom) { + seq_printf(m, "VMI ROM API version: %d.%d\n", + vmi_rom->APIVersionMajor, + vmi_rom->APIVersionMinor); + seq_printf(m, " rom size: %d\n", +...
2007 Apr 18
1
[RFC, PATCH 21/24] i386 Vmi proc node
...s = tsc_end - tsc_start; + if (cycles < page_fault_cycles) + page_fault_cycles = cycles; + } +} + +static int proc_vmi_info_show(struct seq_file *m, void *v) +{ + if (!hypervisor_found) + seq_puts(m, "No VMI active\n"); + else + seq_puts(m, "Hypervisor VMI active\n"); + seq_printf(m, "Kernel VMI API version %d.%d\n", + VMI_API_REV_MAJOR, MIN_VMI_API_REV_MINOR); + if (vmi_rom) { + seq_printf(m, "VMI ROM API version: %d.%d\n", + vmi_rom->APIVersionMajor, + vmi_rom->APIVersionMinor); + seq_printf(m, " rom size: %d\n", +...
2014 Apr 17
0
[PATCH] drm/nouveau: add some basic debugfs dumping for nouveau's clients and vm mappings
...*vma) +{ + char ba[5]; + u64 offset = vma->offset, len = 0, end = vma->offset; + const char *map = nouveau_get_mapping(vma->mapping); + + nouveau_get_access(ba, vma->access); + + if (vma->node) { + len = vma->node->length << 12; + end = vma->offset + len - 1; + } + + seq_printf(m, "\tbo %p with handle %02i mapped %s at [%08llx-%08llx]: %s size %llu\n", + nvbo, handle, ba, offset, end, map, len); +} + +/* + * In theory this function doesn't need locking because all bo's are pinned, + * and we hold the modification lock. + */ +static void dump_channel_...
2014 Sep 26
0
[RFC PATCH 1/7] android: Support creating sync fence from drm fences
...tatic void sync_print_pt(struct seq_file *s, struct fence *pt, bool fence) { int status = 1; - struct sync_timeline *parent = sync_pt_parent(pt); - if (fence_is_signaled_locked(&pt->base)) - status = pt->base.status; + if (fence_is_signaled_locked(pt)) + status = pt->status; - seq_printf(s, " %s%spt %s", - fence ? parent->name : "", - fence ? "_" : "", - sync_status_str(status)); + if (fence) + seq_printf(s, " %d_pt %s", pt->context, + sync_status_str(status)); + else + seq_printf(s, " pt %s", s...
2013 Jul 29
0
[PATCH 3/5] Intel MIC Host Driver Changes for Virtio Devices.
...*pos) > { > struct mic_device *mdev = s->private; > + struct mic_device_desc *d; > + struct mic_device_ctrl *dc; > + struct mic_vqconfig *vqconfig; > + __u32 *features; > + __u8 *config; > struct mic_bootparam *bootparam = mdev->dp; > + int i, j; > > seq_printf(s, "Bootparam: magic 0x%x\n", > bootparam->magic); > @@ -222,6 +229,53 @@ static int dp_seq_show(struct seq_file *s, void *pos) > seq_printf(s, "Bootparam: shutdown_card %d\n", > bootparam->shutdown_card); > > + for (i = sizeof(*bootparam); i &l...
2015 Oct 26
1
[PATCH 4/4] nouveau/debugfs: add interface for current load
...t;dev); > + struct nvkm_pmu *pmu = nvxx_pmu(&drm->device); > + struct nvkm_pmu_load_data load_data; > + int ret; > + > + ret = nvkm_pmu_get_perf_data(pmu, &load_data); > + if (ret < 0) > + return ret; > + > + seq_printf(m, "core: %i\n", load_data.core); > + seq_printf(m, "mem: %i\n", load_data.mem); > + seq_printf(m, "video: %i\n", load_data.video); > + seq_printf(m, "pcie: %i\n", load_data.pcie); > + return 0; > +} > + > static...
2013 Jul 25
1
[PATCH 3/5] Intel MIC Host Driver Changes for Virtio Devices.
...ps = { static int dp_seq_show(struct seq_file *s, void *pos) { struct mic_device *mdev = s->private; + struct mic_device_desc *d; + struct mic_device_ctrl *dc; + struct mic_vqconfig *vqconfig; + __u32 *features; + __u8 *config; struct mic_bootparam *bootparam = mdev->dp; + int i, j; seq_printf(s, "Bootparam: magic 0x%x\n", bootparam->magic); @@ -222,6 +229,53 @@ static int dp_seq_show(struct seq_file *s, void *pos) seq_printf(s, "Bootparam: shutdown_card %d\n", bootparam->shutdown_card); + for (i = sizeof(*bootparam); i < MIC_DP_SIZE; + i += mi...
2013 Jul 25
1
[PATCH 3/5] Intel MIC Host Driver Changes for Virtio Devices.
...ps = { static int dp_seq_show(struct seq_file *s, void *pos) { struct mic_device *mdev = s->private; + struct mic_device_desc *d; + struct mic_device_ctrl *dc; + struct mic_vqconfig *vqconfig; + __u32 *features; + __u8 *config; struct mic_bootparam *bootparam = mdev->dp; + int i, j; seq_printf(s, "Bootparam: magic 0x%x\n", bootparam->magic); @@ -222,6 +229,53 @@ static int dp_seq_show(struct seq_file *s, void *pos) seq_printf(s, "Bootparam: shutdown_card %d\n", bootparam->shutdown_card); + for (i = sizeof(*bootparam); i < MIC_DP_SIZE; + i += mi...
2023 Jul 20
1
[PATCH drm-misc-next v8 02/12] drm: debugfs: provide infrastructure to dump a DRM GPU VA space
...t's show callback. + * + * Returns: 0 on success, -ENODEV if the &mgr is not initialized + */ +int drm_debugfs_gpuva_info(struct seq_file *m, + struct drm_gpuva_manager *mgr) +{ + struct drm_gpuva *va, *kva = &mgr->kernel_alloc_node; + + if (!mgr->name) + return -ENODEV; + + seq_printf(m, "DRM GPU VA space (%s) [0x%016llx;0x%016llx]\n", + mgr->name, mgr->mm_start, mgr->mm_start + mgr->mm_range); + seq_printf(m, "Kernel reserved node [0x%016llx;0x%016llx]\n", + kva->va.addr, kva->va.addr + kva->va.range); + seq_puts(m, "\n&quot...
2015 Nov 09
5
[PATCH v2 0/5] move pstate interface to debugfs
I made a little changes in this series: 1. merge the two last patches together 2. unify the private data interface with the drm debugfs one now it should be very obvious for a new dev on how to add new files to debugfs and how to get access to the nouveau structs Karol Herbst (5): debugfs: add infrastructure to add files with other fops than only read debugfs: rename functions to
2015 Oct 07
2
[PATCH] drm/virtio: use %llu format string form atomic64_t
...^ drivers/gpu/drm/virtio/virtgpu_debugfs.c: In function 'virtio_gpu_debugfs_irq_info': drivers/gpu/drm/virtio/virtgpu_debugfs.c:37:16: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'long long int' [-Wformat=] seq_printf(m, "fence %ld %lld\n", ^ In order to avoid the warnings, this changes the format strings to %llu and adds a cast to u64, which makes it work the same way everywhere. Signed-off-by: Arnd Bergmann <arnd at arndb.de> diff --git a/drivers/gpu/drm/virtio/virtgpu_debugf...
2015 Oct 07
2
[PATCH] drm/virtio: use %llu format string form atomic64_t
...^ drivers/gpu/drm/virtio/virtgpu_debugfs.c: In function 'virtio_gpu_debugfs_irq_info': drivers/gpu/drm/virtio/virtgpu_debugfs.c:37:16: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'long long int' [-Wformat=] seq_printf(m, "fence %ld %lld\n", ^ In order to avoid the warnings, this changes the format strings to %llu and adds a cast to u64, which makes it work the same way everywhere. Signed-off-by: Arnd Bergmann <arnd at arndb.de> diff --git a/drivers/gpu/drm/virtio/virtgpu_debugf...
2023 Apr 16
10
[PATCH 0/9] GPU-DRM-nouveau: Adjustments for seven function implementations
...s Elfring (9): debugfs: Move an expression into a function call parameter in nouveau_debugfs_pstate_set() debugfs: Move a variable assignment behind a null pointer check in nouveau_debugfs_pstate_get() debugfs: Use seq_putc() in nouveau_debugfs_pstate_get() debugfs: Replace five seq_printf() calls by seq_puts() in nouveau_debugfs_pstate_get() power_budget: Move an expression into a macro call parameter in nvbios_power_budget_header() clk: Move a variable assignment behind a null pointer check in nvkm_pstate_new() pci: Move a variable assignment behind condition chec...
2015 Oct 26
0
[PATCH 4/4] nouveau/debugfs: add interface for current load
...ruct drm_info_node *) m->private; + struct nouveau_drm *drm = nouveau_drm(node->minor->dev); + struct nvkm_pmu *pmu = nvxx_pmu(&drm->device); + struct nvkm_pmu_load_data load_data; + int ret; + + ret = nvkm_pmu_get_perf_data(pmu, &load_data); + if (ret < 0) + return ret; + + seq_printf(m, "core: %i\n", load_data.core); + seq_printf(m, "mem: %i\n", load_data.mem); + seq_printf(m, "video: %i\n", load_data.video); + seq_printf(m, "pcie: %i\n", load_data.pcie); + return 0; +} + static struct drm_info_list nouveau_debugfs_list[] = { { "v...
2015 Oct 26
0
[PATCH v2 4/4] nouveau/debugfs: add interface for current load
...ruct drm_info_node *) m->private; + struct nouveau_drm *drm = nouveau_drm(node->minor->dev); + struct nvkm_pmu *pmu = nvxx_pmu(&drm->device); + struct nvkm_pmu_load_data load_data; + int ret; + + ret = nvkm_pmu_get_perf_data(pmu, &load_data); + if (ret < 0) + return ret; + + seq_printf(m, "core: %i\n", load_data.core); + seq_printf(m, "mem: %i\n", load_data.mem); + seq_printf(m, "video: %i\n", load_data.video); + seq_printf(m, "pcie: %i\n", load_data.pcie); + return 0; +} + static struct drm_info_list nouveau_debugfs_list[] = { { "v...
2015 Oct 26
0
[PATCH v3 4/4] nouveau/debugfs: add interface for current load
...ruct drm_info_node *) m->private; + struct nouveau_drm *drm = nouveau_drm(node->minor->dev); + struct nvkm_pmu *pmu = nvxx_pmu(&drm->device); + struct nvkm_pmu_load_data load_data; + int ret; + + ret = nvkm_pmu_get_perf_data(pmu, &load_data); + if (ret < 0) + return ret; + + seq_printf(m, "core: %i\n", load_data.core); + seq_printf(m, "mem: %i\n", load_data.mem); + seq_printf(m, "video: %i\n", load_data.video); + seq_printf(m, "pcie: %i\n", load_data.pcie); + return 0; +} + static struct drm_info_list nouveau_debugfs_list[] = { { "v...
2017 Oct 08
1
[RFC PATCH 08/29] clk: We should pass the pstate id around not the index in the list
...nouveau_debugfs.c > +++ b/drm/nouveau/nouveau_debugfs.c > @@ -96,11 +96,11 @@ nouveau_debugfs_pstate_get(struct seq_file *m, void *data) > } while (attr.index); > > if (state >= 0) { > - if (info.ustate_ac == state) > + if (info.ustate_ac == attr.state) > seq_printf(m, " AC"); > - if (info.ustate_dc == state) > + if (info.ustate_dc == attr.state) > seq_printf(m, " DC"); > - if (info.pstate == state) > + if (info.pstate == attr.state) > seq_printf(m, " *"); > } else { > if (info.usta...