18c2ecf20Sopenharmony_ci.. _reportingbugs: 28c2ecf20Sopenharmony_ci 38c2ecf20Sopenharmony_ciReporting bugs 48c2ecf20Sopenharmony_ci++++++++++++++ 58c2ecf20Sopenharmony_ci 68c2ecf20Sopenharmony_ciBackground 78c2ecf20Sopenharmony_ci========== 88c2ecf20Sopenharmony_ci 98c2ecf20Sopenharmony_ciThe upstream Linux kernel maintainers only fix bugs for specific kernel 108c2ecf20Sopenharmony_civersions. Those versions include the current "release candidate" (or -rc) 118c2ecf20Sopenharmony_cikernel, any "stable" kernel versions, and any "long term" kernels. 128c2ecf20Sopenharmony_ci 138c2ecf20Sopenharmony_ciPlease see https://www.kernel.org/ for a list of supported kernels. Any 148c2ecf20Sopenharmony_cikernel marked with [EOL] is "end of life" and will not have any fixes 158c2ecf20Sopenharmony_cibackported to it. 168c2ecf20Sopenharmony_ci 178c2ecf20Sopenharmony_ciIf you've found a bug on a kernel version that isn't listed on kernel.org, 188c2ecf20Sopenharmony_cicontact your Linux distribution or embedded vendor for support. 198c2ecf20Sopenharmony_ciAlternatively, you can attempt to run one of the supported stable or -rc 208c2ecf20Sopenharmony_cikernels, and see if you can reproduce the bug on that. It's preferable 218c2ecf20Sopenharmony_cito reproduce the bug on the latest -rc kernel. 228c2ecf20Sopenharmony_ci 238c2ecf20Sopenharmony_ci 248c2ecf20Sopenharmony_ciHow to report Linux kernel bugs 258c2ecf20Sopenharmony_ci=============================== 268c2ecf20Sopenharmony_ci 278c2ecf20Sopenharmony_ci 288c2ecf20Sopenharmony_ciIdentify the problematic subsystem 298c2ecf20Sopenharmony_ci---------------------------------- 308c2ecf20Sopenharmony_ci 318c2ecf20Sopenharmony_ciIdentifying which part of the Linux kernel might be causing your issue 328c2ecf20Sopenharmony_ciincreases your chances of getting your bug fixed. Simply posting to the 338c2ecf20Sopenharmony_cigeneric linux-kernel mailing list (LKML) may cause your bug report to be 348c2ecf20Sopenharmony_cilost in the noise of a mailing list that gets 1000+ emails a day. 358c2ecf20Sopenharmony_ci 368c2ecf20Sopenharmony_ciInstead, try to figure out which kernel subsystem is causing the issue, 378c2ecf20Sopenharmony_ciand email that subsystem's maintainer and mailing list. If the subsystem 388c2ecf20Sopenharmony_cimaintainer doesn't answer, then expand your scope to mailing lists like 398c2ecf20Sopenharmony_ciLKML. 408c2ecf20Sopenharmony_ci 418c2ecf20Sopenharmony_ci 428c2ecf20Sopenharmony_ciIdentify who to notify 438c2ecf20Sopenharmony_ci---------------------- 448c2ecf20Sopenharmony_ci 458c2ecf20Sopenharmony_ciOnce you know the subsystem that is causing the issue, you should send a 468c2ecf20Sopenharmony_cibug report. Some maintainers prefer bugs to be reported via bugzilla 478c2ecf20Sopenharmony_ci(https://bugzilla.kernel.org), while others prefer that bugs be reported 488c2ecf20Sopenharmony_civia the subsystem mailing list. 498c2ecf20Sopenharmony_ci 508c2ecf20Sopenharmony_ciTo find out where to send an emailed bug report, find your subsystem or 518c2ecf20Sopenharmony_cidevice driver in the MAINTAINERS file. Search in the file for relevant 528c2ecf20Sopenharmony_cientries, and send your bug report to the person(s) listed in the "M:" 538c2ecf20Sopenharmony_cilines, making sure to Cc the mailing list(s) in the "L:" lines. When the 548c2ecf20Sopenharmony_cimaintainer replies to you, make sure to 'Reply-all' in order to keep the 558c2ecf20Sopenharmony_cipublic mailing list(s) in the email thread. 568c2ecf20Sopenharmony_ci 578c2ecf20Sopenharmony_ciIf you know which driver is causing issues, you can pass one of the driver 588c2ecf20Sopenharmony_cifiles to the get_maintainer.pl script:: 598c2ecf20Sopenharmony_ci 608c2ecf20Sopenharmony_ci perl scripts/get_maintainer.pl -f <filename> 618c2ecf20Sopenharmony_ci 628c2ecf20Sopenharmony_ciIf it is a security bug, please copy the Security Contact listed in the 638c2ecf20Sopenharmony_ciMAINTAINERS file. They can help coordinate bugfix and disclosure. See 648c2ecf20Sopenharmony_ci:ref:`Documentation/admin-guide/security-bugs.rst <securitybugs>` for more information. 658c2ecf20Sopenharmony_ci 668c2ecf20Sopenharmony_ciIf you can't figure out which subsystem caused the issue, you should file 678c2ecf20Sopenharmony_cia bug in kernel.org bugzilla and send email to 688c2ecf20Sopenharmony_cilinux-kernel@vger.kernel.org, referencing the bugzilla URL. (For more 698c2ecf20Sopenharmony_ciinformation on the linux-kernel mailing list see 708c2ecf20Sopenharmony_cihttp://vger.kernel.org/lkml/). 718c2ecf20Sopenharmony_ci 728c2ecf20Sopenharmony_ci 738c2ecf20Sopenharmony_ciTips for reporting bugs 748c2ecf20Sopenharmony_ci----------------------- 758c2ecf20Sopenharmony_ci 768c2ecf20Sopenharmony_ciIf you haven't reported a bug before, please read: 778c2ecf20Sopenharmony_ci 788c2ecf20Sopenharmony_ci https://www.chiark.greenend.org.uk/~sgtatham/bugs.html 798c2ecf20Sopenharmony_ci 808c2ecf20Sopenharmony_ci http://www.catb.org/esr/faqs/smart-questions.html 818c2ecf20Sopenharmony_ci 828c2ecf20Sopenharmony_ciIt's REALLY important to report bugs that seem unrelated as separate email 838c2ecf20Sopenharmony_cithreads or separate bugzilla entries. If you report several unrelated 848c2ecf20Sopenharmony_cibugs at once, it's difficult for maintainers to tease apart the relevant 858c2ecf20Sopenharmony_cidata. 868c2ecf20Sopenharmony_ci 878c2ecf20Sopenharmony_ci 888c2ecf20Sopenharmony_ciGather information 898c2ecf20Sopenharmony_ci------------------ 908c2ecf20Sopenharmony_ci 918c2ecf20Sopenharmony_ciThe most important information in a bug report is how to reproduce the 928c2ecf20Sopenharmony_cibug. This includes system information, and (most importantly) 938c2ecf20Sopenharmony_cistep-by-step instructions for how a user can trigger the bug. 948c2ecf20Sopenharmony_ci 958c2ecf20Sopenharmony_ciIf the failure includes an "OOPS:", take a picture of the screen, capture 968c2ecf20Sopenharmony_cia netconsole trace, or type the message from your screen into the bug 978c2ecf20Sopenharmony_cireport. Please read "Documentation/admin-guide/bug-hunting.rst" before posting your 988c2ecf20Sopenharmony_cibug report. This explains what you should do with the "Oops" information 998c2ecf20Sopenharmony_cito make it useful to the recipient. 1008c2ecf20Sopenharmony_ci 1018c2ecf20Sopenharmony_ciThis is a suggested format for a bug report sent via email or bugzilla. 1028c2ecf20Sopenharmony_ciHaving a standardized bug report form makes it easier for you not to 1038c2ecf20Sopenharmony_cioverlook things, and easier for the developers to find the pieces of 1048c2ecf20Sopenharmony_ciinformation they're really interested in. If some information is not 1058c2ecf20Sopenharmony_cirelevant to your bug, feel free to exclude it. 1068c2ecf20Sopenharmony_ci 1078c2ecf20Sopenharmony_ciFirst run the ver_linux script included as scripts/ver_linux, which 1088c2ecf20Sopenharmony_cireports the version of some important subsystems. Run this script with 1098c2ecf20Sopenharmony_cithe command ``awk -f scripts/ver_linux``. 1108c2ecf20Sopenharmony_ci 1118c2ecf20Sopenharmony_ciUse that information to fill in all fields of the bug report form, and 1128c2ecf20Sopenharmony_cipost it to the mailing list with a subject of "PROBLEM: <one line 1138c2ecf20Sopenharmony_cisummary from [1.]>" for easy identification by the developers:: 1148c2ecf20Sopenharmony_ci 1158c2ecf20Sopenharmony_ci [1.] One line summary of the problem: 1168c2ecf20Sopenharmony_ci [2.] Full description of the problem/report: 1178c2ecf20Sopenharmony_ci [3.] Keywords (i.e., modules, networking, kernel): 1188c2ecf20Sopenharmony_ci [4.] Kernel information 1198c2ecf20Sopenharmony_ci [4.1.] Kernel version (from /proc/version): 1208c2ecf20Sopenharmony_ci [4.2.] Kernel .config file: 1218c2ecf20Sopenharmony_ci [5.] Most recent kernel version which did not have the bug: 1228c2ecf20Sopenharmony_ci [6.] Output of Oops.. message (if applicable) with symbolic information 1238c2ecf20Sopenharmony_ci resolved (see Documentation/admin-guide/bug-hunting.rst) 1248c2ecf20Sopenharmony_ci [7.] A small shell script or example program which triggers the 1258c2ecf20Sopenharmony_ci problem (if possible) 1268c2ecf20Sopenharmony_ci [8.] Environment 1278c2ecf20Sopenharmony_ci [8.1.] Software (add the output of the ver_linux script here) 1288c2ecf20Sopenharmony_ci [8.2.] Processor information (from /proc/cpuinfo): 1298c2ecf20Sopenharmony_ci [8.3.] Module information (from /proc/modules): 1308c2ecf20Sopenharmony_ci [8.4.] Loaded driver and hardware information (/proc/ioports, /proc/iomem) 1318c2ecf20Sopenharmony_ci [8.5.] PCI information ('lspci -vvv' as root) 1328c2ecf20Sopenharmony_ci [8.6.] SCSI information (from /proc/scsi/scsi) 1338c2ecf20Sopenharmony_ci [8.7.] Other information that might be relevant to the problem 1348c2ecf20Sopenharmony_ci (please look in /proc and include all information that you 1358c2ecf20Sopenharmony_ci think to be relevant): 1368c2ecf20Sopenharmony_ci [X.] Other notes, patches, fixes, workarounds: 1378c2ecf20Sopenharmony_ci 1388c2ecf20Sopenharmony_ci 1398c2ecf20Sopenharmony_ciFollow up 1408c2ecf20Sopenharmony_ci========= 1418c2ecf20Sopenharmony_ci 1428c2ecf20Sopenharmony_ciExpectations for bug reporters 1438c2ecf20Sopenharmony_ci------------------------------ 1448c2ecf20Sopenharmony_ci 1458c2ecf20Sopenharmony_ciLinux kernel maintainers expect bug reporters to be able to follow up on 1468c2ecf20Sopenharmony_cibug reports. That may include running new tests, applying patches, 1478c2ecf20Sopenharmony_cirecompiling your kernel, and/or re-triggering your bug. The most 1488c2ecf20Sopenharmony_cifrustrating thing for maintainers is for someone to report a bug, and then 1498c2ecf20Sopenharmony_cinever follow up on a request to try out a fix. 1508c2ecf20Sopenharmony_ci 1518c2ecf20Sopenharmony_ciThat said, it's still useful for a kernel maintainer to know a bug exists 1528c2ecf20Sopenharmony_cion a supported kernel, even if you can't follow up with retests. Follow 1538c2ecf20Sopenharmony_ciup reports, such as replying to the email thread with "I tried the latest 1548c2ecf20Sopenharmony_cikernel and I can't reproduce my bug anymore" are also helpful, because 1558c2ecf20Sopenharmony_cimaintainers have to assume silence means things are still broken. 1568c2ecf20Sopenharmony_ci 1578c2ecf20Sopenharmony_ciExpectations for kernel maintainers 1588c2ecf20Sopenharmony_ci----------------------------------- 1598c2ecf20Sopenharmony_ci 1608c2ecf20Sopenharmony_ciLinux kernel maintainers are busy, overworked human beings. Some times 1618c2ecf20Sopenharmony_cithey may not be able to address your bug in a day, a week, or two weeks. 1628c2ecf20Sopenharmony_ciIf they don't answer your email, they may be on vacation, or at a Linux 1638c2ecf20Sopenharmony_ciconference. Check the conference schedule at https://LWN.net for more info: 1648c2ecf20Sopenharmony_ci 1658c2ecf20Sopenharmony_ci https://lwn.net/Calendar/ 1668c2ecf20Sopenharmony_ci 1678c2ecf20Sopenharmony_ciIn general, kernel maintainers take 1 to 5 business days to respond to 1688c2ecf20Sopenharmony_cibugs. The majority of kernel maintainers are employed to work on the 1698c2ecf20Sopenharmony_cikernel, and they may not work on the weekends. Maintainers are scattered 1708c2ecf20Sopenharmony_ciaround the world, and they may not work in your time zone. Unless you 1718c2ecf20Sopenharmony_cihave a high priority bug, please wait at least a week after the first bug 1728c2ecf20Sopenharmony_cireport before sending the maintainer a reminder email. 1738c2ecf20Sopenharmony_ci 1748c2ecf20Sopenharmony_ciThe exceptions to this rule are regressions, kernel crashes, security holes, 1758c2ecf20Sopenharmony_cior userspace breakage caused by new kernel behavior. Those bugs should be 1768c2ecf20Sopenharmony_ciaddressed by the maintainers ASAP. If you suspect a maintainer is not 1778c2ecf20Sopenharmony_ciresponding to these types of bugs in a timely manner (especially during a 1788c2ecf20Sopenharmony_cimerge window), escalate the bug to LKML and Linus Torvalds. 1798c2ecf20Sopenharmony_ci 1808c2ecf20Sopenharmony_ciThank you! 1818c2ecf20Sopenharmony_ci 1828c2ecf20Sopenharmony_ci[Some of this is taken from Frohwalt Egerer's original linux-kernel FAQ] 183