identified ~10 remaining callers of the
function, leading to the follow-on cleanup patch, and would allow
activating the pr_debugs, estimating the callrate, and the potential
savings by using the wrapper macro. It is unused ATM, but it fills
out the picture.
Signed-off-by: Jim Cromie
---
drivers/gpu/
On Wed, Nov 3, 2021 at 9:58 AM Jason Baron wrote:
>
>
>
> On 10/27/21 12:36 AM, Jim Cromie wrote:
> > Use new macro to create a sysfs control bitmap knob to control
> > print-to-trace in: /sys/module/drm/parameters/trace
> >
> > todo: reconsider this api, ie
wrt drm.trace knob
2 separate macros: DEFINE_DYNAMIC_DEBUG_{LOG,TRACE}_GROUPS - JBaron
v9: https://patchwork.freedesktop.org/series/96327/
v8: https://patchwork.freedesktop.org/series/93914/
https://lore.kernel.org/lkml/20210915163957.2949166-1-jim.cro...@gmail.com/
The major change since v
ifferent
- "drm:kms"also different - includes drm:kms2:
- "drm:kms:\t" also different - could be troublesome
- "drm:kms:*" doesn't work, no wildcard on format atm.
Order matters in DEFINE_DYNAMIC_DEBUG_CATEGORIES(... @bit_descs)
allocates and initializes ...
Signed-off-by: Jim Cromie
---
include/drm/drm_drv.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/drm/drm_drv.h b/include/drm/drm_drv.h
index 0cd95953cdf5..4b29261c4537 100644
--- a/include/drm/drm_drv.h
+++ b/include/drm/drm_drv.h
ed pr-debugs; in this example,
"drm:atomic:fail:".
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/i915/gvt/debug.h | 18 +-
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/drivers/gpu/drm/i915/gvt/debug.h b/drivers/gpu/drm/i915/gvt/debug.h
index c6027125c1ec..b
o create a sysfs location which maps
from bits to these 13 sets of categorized pr_debugs to en/disable.
Makefile adds -DDYNAMIC_DEBUG_MODULE for CONFIG_DYNAMIC_DEBUG_CORE,
otherwise BUILD_BUG_ON triggers (obvious errors on subtle misuse is
better than mysterious ones).
Signed-off-by:
add sysfs knobs to enable modules' pr_debug()s ---> tracefs
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/amd/display/dc/core/dc_debug.c | 8
drivers/gpu/drm/drm_print.c| 13 ++---
drivers/gpu/drm/i915/intel_gvt.c | 15 ---
=_ "todo:
maybe avoid via dyndbg\012"
drivers/gpu/drm/drm_edid_load.c:178 [drm]edid_load =_ "todo: maybe avoid via
dyndbg\012"
At quick glance, edid won't qualify, drm_print might, drm_vblank is
strongest chance, maybe atomic-ioctl too.
Signed-off-by: Jim Cromie
---
incl
quot; callsites from getting stomped on by `echo 0 >
debug`. Other categories could differ, but we need some default.
Dyndbg requires that the prefix be in the compiled-in format string;
run-time prefixing evades callsite selection by category.
pr_debug("%s: ...", __func
:" },
[7] = { "gvt:render:" },
[8] = { "gvt:sched:" }
};
DEFINE_DYNAMIC_DEBUG_BITGRPS(debug_gvt, __gvt_debug,
"dyndbg bitmap desc",
If CONFIG_DYNAMIC_DEBUG_CORE=y, then gvt/Makefile adds
-DDYNAMIC_DEBUG_MODULE to cflags, which CONFIG_DYNAMIC_DE
acer(),
since dyndbg could just provide it when TRACING is on.
NOTES:
$> modprobe test_dynamic_debug dyndbg=+p
it fails 3/29 tests. havent looked at why.
$> modprobe test_dynamic_debug use_bad_tracer=1
Earlier in dev, bad_tracer() exploded in recursion, I havent been able
to r
r flags, but DEFINE_DYNAMIC_DEBUG_BITGRPS_FLAGS
can be used to explicitly toggle them.
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 44 ++-
lib/dynamic_debug.c | 4 ++--
2 files changed, 35 insertions(+), 13 deletions(-)
diff --git a/
k-next]$ wc /proc/dynamic_debug/control
8927 71062 1099699 /proc/dynamic_debug/control
[jimc@gandalf wk-next]$ uname -a
Linux gandalf 5.15.0-rh2-12144-g5d5db04dfb0c #3 SMP PREEMPT Thu Nov 11 10:5
- pr_debug as event provider
using exported trace_array_printk
cheap with JU
ifferent
- "drm:kms"also different - includes drm:kms2:
- "drm:kms:\t" also different - could be troublesome
- "drm:kms:*" doesn't work, no wildcard on format atm.
Order matters in DEFINE_DYNAMIC_DEBUG_CATEGORIES(... @bit_descs)
allocates and initializes ...
Signed-off-by: Jim Cromie
---
include/drm/drm_drv.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/drm/drm_drv.h b/include/drm/drm_drv.h
index 0cd95953cdf5..4b29261c4537 100644
--- a/include/drm/drm_drv.h
+++ b/include/drm/drm_drv.h
o create a sysfs location which maps
from bits to these 13 sets of categorized pr_debugs to en/disable.
Makefile adds -DDYNAMIC_DEBUG_MODULE for CONFIG_DYNAMIC_DEBUG_CORE,
otherwise BUILD_BUG_ON triggers (obvious errors on subtle misuse is
better than mysterious ones).
Signed-off-by:
ed pr-debugs; in this example,
"drm:atomic:fail:".
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/i915/gvt/debug.h | 18 +-
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/drivers/gpu/drm/i915/gvt/debug.h b/drivers/gpu/drm/i915/gvt/debug.h
index c6027125c1ec..b
:" },
[7] = { "gvt:render:" },
[8] = { "gvt:sched:" }
};
DEFINE_DYNAMIC_DEBUG_BITGRPS(debug_gvt, __gvt_debug,
"dyndbg bitmap desc",
If CONFIG_DYNAMIC_DEBUG_CORE=y, then gvt/Makefile adds
-DDYNAMIC_DEBUG_MODULE to cflags, which CONFIG_DYNAMIC_DE
quot; callsites from getting stomped on by `echo 0 >
debug`. Other categories could differ, but we need some default.
Dyndbg requires that the prefix be in the compiled-in format string;
run-time prefixing evades callsite selection by category.
pr_debug("%s: ...", __func
=_ "todo:
maybe avoid via dyndbg\012"
drivers/gpu/drm/drm_edid_load.c:178 [drm]edid_load =_ "todo: maybe avoid via
dyndbg\012"
At quick glance, edid won't qualify, drm_print might, drm_vblank is
strongest chance, maybe atomic-ioctl too.
Signed-off-by: Jim Cromie
---
incl
acer(),
since dyndbg could just provide it when TRACING is on.
NOTES:
$> modprobe test_dynamic_debug dyndbg=+p
it fails 3/29 tests. havent looked at why.
$> modprobe test_dynamic_debug use_bad_tracer=1
Earlier in dev, bad_tracer() exploded in recursion, I havent been able
to r
r flags, but DEFINE_DYNAMIC_DEBUG_BITGRPS_FLAGS
can be used to explicitly toggle them.
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 44 ++-
lib/dynamic_debug.c | 4 ++--
2 files changed, 35 insertions(+), 13 deletions(-)
diff --git a/
add sysfs knobs to enable modules' pr_debug()s ---> tracefs
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/amd/display/dc/core/dc_debug.c | 8
drivers/gpu/drm/drm_print.c| 13 ++---
drivers/gpu/drm/i915/intel_gvt.c | 15 ---
12 Nov 2021 10:08:41 -0500
> >>> Jason Baron wrote:
> >>>
> >>>> On 11/12/21 6:49 AM, Vincent Whitchurch wrote:
> >>>>> On Thu, Nov 11, 2021 at 03:02:04PM -0700, Jim Cromie wrote:
> >>>>&
; > >> On 11/16/21 3:46 AM, Pekka Paalanen wrote:
> > >>> On Fri, 12 Nov 2021 10:08:41 -0500
> > >>> Jason Baron wrote:
> > >>>
> > >>>> On 11/12/21 6:49 AM, Vincent Whitchurch wrote:
> > >>>>>
y was original goal.
- loses the optional decorations.
drm has its own logmsg standards, doesnt need decorations slapped on
later: could recast flags for drm specific decorations
This is based on 5.17-rc4
Its also here: in (dd-drm branch)
ghlinux-rohttps://github.com/jimc/linux.git (fetch
/dynamic_debug/control
done;
# A B ~B ~A
for flg in +T +p "-p #broke here" -T; do
echo " $site $flg " > /proc/dynamic_debug/control
done
}
pt_test
Fixes: 84da83a6ffc0 dyndbg: combine flags & mask into a struct, simplify with it
CC: vincent.whitchu
mething like:
_pick_sym_(DRM_UT_CORE, "mumble something useful about CORE debug")
_pick_sym_(a,b) a // gives us what we need here
_pick_help_(a,b) #a " : " b // mod-info fodder
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 50
ly, the default would be
zero, but DRM_UT_CORE "uses" that value, in the sense that 0 is
exposed as a bit position in drm.debug. Using 15 allows identity
mapping from category to class, avoiding fiddly offsets.
CC: Rasmus Villemoes
Signed-off-by: Jim Cromie
fixup class-id preset
fix2
ected users, and any prospects would
likely reuse the bitmap or a straightforward extension of it, we can
drop this function until its really needed.
This also drops the CONFIG_DYNAMIC_DEBUG=N stub-func, and its
pr_warn(), which I avoided in 2012, then added in 2020 :-/
Signed-off-by: Jim Cromie
-test, the category now fits in
4 bits, allowing it in struct _ddebug.class_id:4. This sets us up to
adapt drm to use dyndbg with JUMP_LABEL, thus avoiding all those
bit-tests anyway.
Signed-off-by: Jim Cromie
---
include/drm/drm_print.h | 22 +++---
1 file changed, 11 inserti
move site.flag update after the v4pr_info("change") message, and
improve the message to print both old and new flag values.
Heres new form:
dyndbg: changed net/ipv4/tcp.c:2424 [tcp]tcp_recvmsg_locked pT -> _
Signed-off-by: Jim Cromie
---
lib/dynamic_debug.c | 11 ++-
1
IC_DEBUG_CORE only eliminates
the builtin portion, leaving only drm modules, but still 200k of
module data is a lot.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/Kconfig | 12
drivers/gpu/drm/Makefile | 2 ++
include/drm/drm_print.h | 12
3 files changed, 26 inserti
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 10 +-
include/drm/drm_print.h | 9 +++--
2 files changed, 12 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/drm_print.c b/drivers/gpu/drm/drm_print.c
index f783d4963d4b..e45ba224e57c 100644
--- a/drivers/gpu/d
Hide flags test in a macro.
no functional changes.
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h
index 664bb83778d2..106065244f73 100644
--- a/include
ration for all those drm.debug
callsites.
For CONFIG_DRM_USE_DYNAMIC_DEBUG=N, just pass null.
NB: desc->class_id is redundant with category, but !!desc dependent.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 23 +--
include/drm/drm_print.h | 23 +
.0-rc4-lm1-9-g6ce0b88d2539-dirty/kernel/drivers/gpu/drm/drm.ko
NB: this was noticed using _drm_debug_enabled(), added earlier.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/drm_print.c b/drivers/gpu
ons.
_ddebug.class_id is uint:4, values 0-14 are valid. 15 is reserved for
non-classified callsites (regular pr_debugs). Using it terminates the
scan, don't use it halfway through your list.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 20 ++--
include/drm/drm
function.
When plugged into 1, it identified ~10 remaining callers of the
function, leading to the follow-on cleanup patch, and would allow
activating the pr_debugs, estimating the callrate, and the potential
savings by using the wrapper macro. It is unused ATM, but it fills
out the picture.
Signed-off
his is based on 5.17-rc4, for no particular reason.
Its also here: in (dd-drm branch)
ghlinux-rohttps://github.com/jimc/linux.git (fetch)
Jim Cromie (13):
dyndbg: fix static_branch manipulation @stable
dyndbg: add class_id field and query support
dyndbg: add DEFINE_DYNAMIC_DEBUG_CL
/dynamic_debug/control
done;
# A B ~B ~A
for flg in +T +p "-p #broke here" -T; do
echo " $site $flg " > /proc/dynamic_debug/control
done
}
pt_test
Fixes: 84da83a6ffc0 dyndbg: combine flags & mask into a struct, simplify with it
CC: vincent.whitchu
ly, the default would be
zero, but DRM_UT_CORE "uses" that value, in the sense that 0 is
exposed as a bit position in drm.debug. Using 15 allows identity
mapping from category to class, avoiding fiddly offsets.
CC: Rasmus Villemoes
Signed-off-by: Jim Cromie
fixup class-id preset
fix2
t could be upgraded,
something like:
_pick_sym_(DRM_UT_CORE, "mumble something useful about CORE debug")
_pick_sym_(a,b) a // gives us what we need here
_pick_help_(a,b) #a " : " b // mod-info fodder
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug
ected users, and any prospects would
likely reuse the bitmap or a straightforward extension of it, we can
drop this function until its really needed.
This also drops the CONFIG_DYNAMIC_DEBUG=N stub-func, and its
pr_warn(), which I avoided in 2012, then added in 2020 :-/
Signed-off-by: Jim Cromie
move site.flag update after the v4pr_info("change") message, and
improve the message to print both old and new flag values.
Heres new form:
dyndbg: changed net/ipv4/tcp.c:2424 [tcp]tcp_recvmsg_locked pT -> _
Signed-off-by: Jim Cromie
---
lib/dynamic_debug.c | 11 ++-
1
-test, the category now fits in
4 bits, allowing it in struct _ddebug.class_id:4. This sets us up to
adapt drm to use dyndbg with JUMP_LABEL, thus avoiding all those
bit-tests anyway.
Signed-off-by: Jim Cromie
---
include/drm/drm_print.h | 22 +++---
1 file changed, 11 inserti
Hide flags test in a macro.
no functional changes.
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h
index 664bb83778d2..106065244f73 100644
--- a/include
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 10 +-
include/drm/drm_print.h | 9 +++--
2 files changed, 12 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/drm_print.c b/drivers/gpu/drm/drm_print.c
index f783d4963d4b..e45ba224e57c 100644
--- a/drivers/gpu/d
IC_DEBUG_CORE only eliminates
the builtin portion, leaving only drm modules, but still 200k of
module data is a lot.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/Kconfig | 12
drivers/gpu/drm/Makefile | 2 ++
include/drm/drm_print.h | 12
3 files changed, 26 inserti
.0-rc4-lm1-9-g6ce0b88d2539-dirty/kernel/drivers/gpu/drm/drm.ko
NB: this was noticed using _drm_debug_enabled(), added earlier.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/drm_print.c b/drivers/gpu
function.
When plugged into 1, it identified ~10 remaining callers of the
function, leading to the follow-on cleanup patch, and would allow
activating the pr_debugs, estimating the callrate, and the potential
savings by using the wrapper macro. It is unused ATM, but it fills
out the picture.
Signed-off
cases/reasons.
_ddebug.class_id is uint:4, values 0-14 are valid. 15 is reserved for
non-classified callsites (regular pr_debugs). Using it terminates the
scan, don't use it halfway through your list.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 20 ++--
ration for all those drm.debug
callsites.
For CONFIG_DRM_USE_DYNAMIC_DEBUG=N, just pass null.
NB: desc->class_id is redundant with category, but !!desc dependent.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 23 +--
include/drm/drm_print.h | 23 +
On Tue, Mar 1, 2022 at 2:32 PM Patchwork
wrote:
>
> Patch Details
> Series:use dynamic-debug under drm.debug api (rev2)
> URL:https://patchwork.freedesktop.org/series/100289/
> State:failure
> Details:https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22448/index.html
>
> CI Bug Log - changes from
On Tue, Mar 1, 2022 at 2:00 PM Patchwork
wrote:
>
> == Series Details ==
>
> Series: use dynamic-debug under drm.debug api (rev2)
> URL : https://patchwork.freedesktop.org/series/100289/
> State : warning
>
> == Summary ==
>
> $ dim sparse --fast origin/drm-tip
> Sparse version: v0.6.2
> Fast mo
On Tue, Mar 1, 2022 at 1:57 PM Patchwork
wrote:
>
> == Series Details ==
>
> Series: use dynamic-debug under drm.debug api (rev2)
> URL : https://patchwork.freedesktop.org/series/100289/
> State : warning
>
> == Summary ==
>
> $ dim checkpatch origin/drm-tip
> c2ed9cc02d9c dyndbg: fix static_bra
patchwork CI cuz of a macro warning in dyndbg, which
would be nice for CI to "pass" because its out of DRM tree, and
subject to a separate review process, and in the meantime, it would be
nice to see it under test.
Going item by item:
On Wed, Jul 14, 2021 at 11:51:36AM -0600, Jim Cromie
ER >
/sys/module/drm/parameters/debug_categories
# LEVEL_NAMES
echo NV_TRACE > /sys/module/nouveau/parameters/debug-mumble*
That design choice is allowed cuz verbosity is always attached to a
(user visible) interface, and theres no reason not to put the
implementation there (in the callb
uot; > /proc/dynamic_debug/control
done;
# A B ~B ~A
for flg in +T +p "-p #broke here" -T; do
echo " $site $flg " > /proc/dynamic_debug/control
done
}
pt_test
Fixes: 84da83a6ffc0 dyndbg: combine flags & mask into a struct, simplify with it
CC: vinc
/proc/dynamic_debug/control walks the prdbg catalog in "reverse",
fix this by adding new ddebug_tables to tail of list.
This puts init/main.c entries 1st, which looks more than coincidental.
no functional changes.
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
lib/dynamic_d
strcmp for exact param-name match.
Reported-by: Rasmus Villemoes
Fixes: b48420c1d301 dynamic_debug: make dynamic-debug work for module
initialization
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
iter
1st step towards 'demotion' of iter->site, for removal later
treat vars as iters:
- drop init at top
init just above for-loop, in a textual block
Signed-off-by: Jim Cromie
---
lib/dynamic_debug.c | 33 +
1 file changed, 17 insertion
ameters/do_prints
echo module test_dynamic_debug +mftl > /proc/dynamic_debug/control
echo junk > /sys/module/test_dynamic_debug/parameters/do_prints
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
MAINTAINERS | 2 ++
lib/Kconfig.debug| 10 ++
print "old => new" flag values to the info("change") message.
no functional change.
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
lib/dynamic_debug.c | 11 ++-
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/lib/dynamic_debug.c b/li
for struct
_ddeubg_info. This might be prone to include loops, since its also
included by printk.h. Nothing has broken in robot-land on this.
cc: Luis Chamberlain
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 13 +++-
kernel/module/internal.h | 4 ++--
kernel/m
427 [main]run_init_process =_ " with environment:\n"
init/main.c:1429 [main]run_init_process =_ "%s\n"
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
lib/dynamic_debug.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/dynamic_debug.c b/li
y compiler.
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 7 +++
1 file changed, 7 insertions(+)
diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h
index 633f4e463766..3c9690da44d9 100644
--- a/include/linux/dynamic_debug.h
+++ b/include/linux/dynam
s only a couple dozen
pointers to save. TODO: re-evaluate for lines removable.
Signed-off-by: Jim Cromie
---
v6
. fix compile err due to reorderd commits, and missed lkp report.
. init dt->maps in ddebug_add_module, prior to ddebug_attach_module_classes
---
lib/dy
h 0 matches, 1 errs
[ 28.800378] dyndbg: bit_0: -22 matches on class: D2_CORE -> 0x1
[ 28.801959] dyndbg: test_dynamic_debug.T_D2: updated 0x0 -> 0x1
[ 28.803974] dyndbg: total matches: -22
Signed-off-by: Jim Cromie
---
lib/test_dynamic_debug.c | 125 ++
trim fmlt descriptions
CC: linux-...@vger.kernel.org
Signed-off-by: Jim Cromie
---
fixup-doc: trailing colons for block headers, trim fedora numbers. Bagas
---
.../admin-guide/dynamic-debug-howto.rst | 235 +-
1 file changed, 117 insertions(+), 118 deletions(-)
diff --git a/Docume
identified ~10 remaining callers of the
function, leading to the follow-on cleanup patch, and would allow
activating the pr_debugs, estimating the callrate, and the potential
savings by using the wrapper macro. It is unused ATM, but it fills
out the picture.
Signed-off-by: Jim Cromie
---
drivers/gpu/
n.c:1429 [main]run_init_process =_ "%s\012"
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
lib/dynamic_debug.c | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c
index 7fb99492c16f..8ff11977b8bd 100644
-
according to
each module's private class-map.
No callsites are actually selected by this patch, since none are
class'd yet.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 14 +
drivers/gpu/drm/display/drm_dp_helper.c | 13
urns
off L>2 (and ignores L1), and +L2 would turn on L<=2 (and ignore others).
Signed-off-by: Jim Cromie
---
. revised DD_CLASS_TYPE_{DISJOINT,LEVEL}_* names
. reorder-enum - _NAMES feature is extra.
---
include/linux/dynamic_debug.h | 55 +++
1 fil
g it only when/after
the query-string omitted the module.
NB: the query class FOO handling is forthcoming.
Fixes: 8e59b5cfb9a6 dynamic_debug: add modname arg to exec_query callchain
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
lib/dynamic_debug.c | 11 +++
1 file changed, 7 in
Add an explanation of the new "class CLASS_NAME" syntax and meaning,
noting that the module determines if CLASS_NAME applies to it.
Signed-off-by: Jim Cromie
---
Documentation/admin-guide/dynamic-debug-howto.rst | 11 +++
1 file changed, 11 insertions(+)
diff --git a/Doc
ts already strongly implied by the use of the enum itself; its
not a normal enum if it can be 2 values simultaneously.
Signed-off-by: Jim Cromie
---
include/drm/drm_print.h | 22 +++---
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/include/drm/drm_print.h b/i
("dyndbg: refine export, rename to
dynamic_debug_exec_queries()")
Fixes: 4c0d77828d4f ("dyndbg: export ddebug_exec_queries")
Acked-by: Jason Baron
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 9 -
lib/dynamic_debug.c | 29 --
supplied, valid_class = _CLASS_DFLT. This
insures that legacy queries do not trample on new class'd callsites,
as they get added.
Also add a new column to control-file output, displaying non-default
class-name (when found) or the "unknown _id:", if it has not been
(correctly) decl
tracefs, so pr_debug() and
dev_dbg() calls can add more debug context into the trace-logs, and
then at users option, less into syslog.
The new events allow enabling by event-type in tracefs, and dyndbg
allows individual enablement of prdbg callsites (via +T flag).
Signed-off-by: Jim Cromie
c/dynamic_debug/control
CONFIG_DRM_USE_DYNAMIC_DEBUG=y/n is configurable because of the .data
footprint cost of per-callsite control; 56 bytes/site * ~2k for i915,
~4k callsites for amdgpu. This is large enough that a kernel builder
might not want it.
Signed-off-by: Jim Cromie
---
drivers/gpu/dr
():
- It currently builds a debug_table, and *will* find and attach classes.
dynamic_debug_init():
- add class fields to the _ddebug_info cursor var: di.
Signed-off-by: Jim Cromie
---
include/asm-generic/vmlinux.lds.h | 3 +++
include/linux/dynamic_debug.h | 2 ++
kernel/module/main.c
e due to existing uses of drm_dbg_kms().
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/nouveau/nouveau_drv.h | 16 ++--
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_drv.h
b/drivers/gpu/drm/nouveau/nouveau_drv.h
index 84df5ddae4d0..3b
onal.
For CONFIG_DRM_USE_DYNAMIC_DEBUG=N, just pass null.
Note: desc->class_id is redundant with category parameter, but its
availability is dependent on desc.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 8 +---
include/drm/drm_print.h | 23 ---
2
tly to see how lkp sorts it.
Signed-off-by: Jim Cromie
---
include/drm/drm_print.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/drm/drm_print.h b/include/drm/drm_print.h
index 2d2cef76b5c1..f8bb3e7158c6 100644
--- a/include/drm/drm_print.h
+++ b/include/drm/drm_print.h
@@
new symbol _DPRINTK_FLAGS_PRINTK, in order to
break any stale uses.
CC: vincent.whitchu...@axis.com
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 10 ++
lib/dynamic_debug.c | 8
2 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/include/linux/dynamic
104] dyndbg: module:nouveau attached 3 classes
[ 966.353759] dyndbg: 119 debug prints in module nouveau
NOTE: it was 632 with previous commit, switching NV_DEBUG to use
NV_SUBDEV_DBG_DEBUG instead of NV_DBG_DEBUG may be the cause.
Signed-off-by: Jim Cromie
---
.../gpu/drm/nouveau/
behavior change.
cc: Rasmus Villemoes
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 71 +++
1 file changed, 55 insertions(+), 16 deletions(-)
diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h
index 6a2001250da1..633f4e463766
nt.whitchu...@axis.com/
with a few differences:
- s/dynamic_/ddebug_/ on Vincent's additions
- __printf attrs on the _printk funcs
- reuses trace_console() event, not adding a new "printk:dyndbg" event.
next patch replaces this with 2 new events
CC: vincent.whitchu...@axis.com
add new flag, and OR it into _DPRINTK_FLAGS_ENABLED definition
CC: vincent.whitchu...@axis.com
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h
index
ddebug_classes_bitmap_param
refs 1, reusing it.
flags = "T", to enable trace-events on this callsite.
3- module_param_cb([2]) - does the sysfs part
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/drm_print.c | 10 ++
1 file changed, 10 insertions(+)
diff --git a/drivers/gpu/drm/drm_print.c b/d
use in
drm_dbg() and drm_devdbg(), and call them. This recapitulates the
changes described above, connecting 3-10K drm.debug callsites to
tracefs.
Signed-off-by: Jim Cromie
---
include/trace/events/dyndbg.h | 74 +++
lib/dynamic_debug.c
linker compute
the offset and initialize ._index accordingly, but that resulted in
some "linker cant compute" error. Ive initialized it in
__ddebug_add_module() instead.
Signed-off-by: Jim Cromie
---
include/linux/dynamic_debug.h | 34 ++
1 file c
with nouveau, which uses its own stack of macros to
construct calls to dev_info, dev_dbg, etc, for which adaptation means
drm_dbg_##driver constructs.
Signed-off-by: Jim Cromie
---
include/drm/drm_print.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/drm/drm_print.h b
27;s
site-rec of a builtin or loadable module, which is unique over the
pertinent lifetime, and has all the info.
WAG,TLDR: "decorating" could be defered until `cat trace`, modulo
loadable sites[] data being needed to render after module is unloaded.
no functional changes.
Signed-o
---
lib/dynamic_debug.c | 15 ---
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c
index 41c23ec979f4..059212df68f9 100644
--- a/lib/dynamic_debug.c
+++ b/lib/dynamic_debug.c
@@ -1347,7 +1347,7 @@ static int __ddebug_add_module(str
is independent, including choice of
DISJOINT or LEVELS, as long as class-names don't conflict.
So theres some flexibility.
Signed-off-by: Jim Cromie
---
drivers/gpu/drm/nouveau/include/nvkm/core/subdev.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/nouve
bear +/- signs, which alters the on-bit-pos by 1. IOW,
+L2 means L0,L1,L2, and -L2 means just L0,L1. This kinda spoils the
readback fidelity, since the L0 bit gets turned on by any use of any
L*, except "-L0".
All the interface uncertainty here pertains to the _NAMES features.
Nobody has
. I found the x86 problems
myself, l...@intel.com found arm & sparc problems, and may yet find
others.
Reported-by: # on [jimc:lkp-test/dyndbg-diet] recently
Signed-off-by: Jim Cromie
---
arch/arm/boot/compressed/Makefile | 2 ++
arch/sparc/vdso/Makefile | 2 ++
arch/x86/b
301 - 400 of 891 matches
Mail list logo