blob: 2d32308c3f7a61b3d605dc4fc60028c81283f53c [file] [log] [blame]
Jan Kiszka3ee7b3f2015-02-17 13:46:36 -08001#
2# gdb helper commands and functions for Linux kernel debugging
3#
4# loader module
5#
6# Copyright (c) Siemens AG, 2012, 2013
7#
8# Authors:
9# Jan Kiszka <jan.kiszka@siemens.com>
10#
11# This work is licensed under the terms of the GNU GPL version 2.
12#
13
14import os
15
Aaron Tomlinb9969552022-07-12 12:02:48 +010016sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)) + "/scripts/gdb")
Jan Kiszka3ee7b3f2015-02-17 13:46:36 -080017
18try:
19 gdb.parse_and_eval("0")
20 gdb.execute("", to_string=True)
21except:
22 gdb.write("NOTE: gdb 7.2 or later required for Linux helper scripts to "
23 "work.\n")
Jan Kiszkab0fecd82015-02-17 13:46:41 -080024else:
Florian Fainelli8af055a2023-04-06 14:52:51 -070025 import linux.constants
26 if linux.constants.LX_CONFIG_DEBUG_INFO_REDUCED:
27 raise gdb.GdbError("Reduced debug information will prevent GDB "
28 "from having complete types.\n")
Jan Kiszkab0fecd82015-02-17 13:46:41 -080029 import linux.utils
Jan Kiszka66051722015-02-17 13:46:47 -080030 import linux.symbols
Jan Kiszka7b599ef2015-02-17 13:46:55 -080031 import linux.modules
Jan Kiszkaae7dbaa2015-02-17 13:47:04 -080032 import linux.dmesg
Jan Kiszka47528712015-02-17 13:47:10 -080033 import linux.tasks
Stephen Boyd90cf83db2019-05-14 15:45:53 -070034 import linux.config
Jan Kiszkafe7f9ed2015-02-17 13:47:21 -080035 import linux.cpus
ThiƩbaud Weksteen084f6b12015-06-30 14:58:07 -070036 import linux.lists
Stephen Boyd449ca0c2019-05-14 15:45:56 -070037 import linux.rbtree
Kieran Bingham2d061d92016-03-22 14:27:33 -070038 import linux.proc
Stephen Boyd442284a2019-05-14 15:45:59 -070039 import linux.timerlist
Leonard Crestezd1e97102019-05-14 15:46:08 -070040 import linux.clk
Leonard Crestez8207d4a2019-07-16 16:30:12 -070041 import linux.genpd
Leonard Crestez778c1f52019-07-16 16:30:15 -070042 import linux.device
Glenn Washburnf4efbda2023-02-28 18:53:34 -060043 import linux.vfs
Dmitrii Bundine36903b2023-01-02 20:10:14 +030044 import linux.mm
Kieran Binghamb7235d62023-04-04 14:40:49 -070045 import linux.radixtree
Florian Fainellib0969d72023-04-06 15:04:51 -070046 import linux.interrupts