From nobody Thu Apr 18 20:40:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1679062764342155.3474507674191; Fri, 17 Mar 2023 07:19:24 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pdAuV-0006YF-MC; Fri, 17 Mar 2023 10:18:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdAuR-0006Ww-I1; Fri, 17 Mar 2023 10:18:19 -0400 Received: from mout.kundenserver.de ([217.72.192.73]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdAuP-0004tG-Th; Fri, 17 Mar 2023 10:18:19 -0400 Received: from quad ([82.142.8.70]) by mrelayeu.kundenserver.de (mreue108 [212.227.15.183]) with ESMTPSA (Nemesis) id 1N8GEY-1qYO7m2iga-0149VO; Fri, 17 Mar 2023 15:18:10 +0100 From: Laurent Vivier To: qemu-devel@nongnu.org Cc: qemu-trivial@nongnu.org, Bernhard Beschow , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Laurent Vivier Subject: [PULL 1/3] exec/memory: Fix kernel-doc warning Date: Fri, 17 Mar 2023 15:18:06 +0100 Message-Id: <20230317141808.826875-2-laurent@vivier.eu> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230317141808.826875-1-laurent@vivier.eu> References: <20230317141808.826875-1-laurent@vivier.eu> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:dBnAfVPArdEqHVx+fuXn+g/trh5q9fGrrN1d64P8FsHjqhxkOie IMf98NdGZeidrnW6JqeRYF+mla+0SHTUVonzQppjizz3kjIw9/pbrvtN8Ea/2XJwiwUoWdV 6SMBD3FqYY2vkSTw9hZXW1QzwD+kQgxlxjPzQSfVJYp53KQTXbDrS4vOnWd93GOlYDGGcOx kv8NpVaUZivdOAz9/jbtw== UI-OutboundReport: notjunk:1;M01:P0:wCCPaR57oIc=;jNdSCAwwUVMwR1q10XST+wMWSeu AAw38cKaJldlJ15nUWxthnFNZPT3m5lkuUjJah/oCDRCZJiwNH1AtTjBEdrChbUXScCceeJb8 fOHrjZQYUXkPzIpgyNKVHrTnNhH/07ie0wbFtFbiXJCk55vo4O1lgiP5voqViKwKs8cqnivxJ D6h5dQ2fmVxJXdQ3P4oMBHH+9eCaspzmSo1vesh/ep7bKMphC0aiX+bte4IN319bRUuIyYfJx yWUQu1RvWDBdzwhIMN9ufiFgwqlYf28KTe1Rnm+qsXsrkbLrT+5dVquOaxQJWc1XKHgHO4JU7 XeH9MPc1xHEBDJ4kIXHgyVQF8tupnXe2Qfex4HmndJwkOiCdfpLJXiBjp6gT5WaG2xC3i8HWr d63MlreeF2IjAM4LxhCKjkg6ZmRftg4JyQNjhcQwCW9UXJOWew5L2OuPjxS2t9QZxEqjWlV1+ N9yjJTjDVGQeUO+urTN+VDYGPgIfj3MpBGZLAOo7n4VWJ+3lXjVsYU2+3AWuinWM/ykrnnXpw aMTjD7Tf+uayvhYy1PStcC3etAW7Lnwa9yYPVsMI8cyqsSOtOvNh3yf2fwcG4zazlxyBDIZJs ze/d9eLmztgs/FG130Xi540nTEA5BhdswbeXdYKq7AV/xPVul6g3lwPri5Sck3/ftKQ0Yr0pq 6kb8WL35x92+3Oe3csV67hSL0OoW/ITkdLLnAVR+4w== Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: none client-ip=217.72.192.73; envelope-from=laurent@vivier.eu; helo=mout.kundenserver.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1679062766041100006 From: Bernhard Beschow During build the kernel-doc script complains about the following issue: src/docs/../include/exec/memory.h:1741: warning: Function parameter or me= mber 'n' not described in 'memory_region_unmap_iommu_notifier_range' src/docs/../include/exec/memory.h:1741: warning: Excess function paramete= r 'notifier' description in 'memory_region_unmap_iommu_notifier_range' Settle on "notifier" for consistency with other memory functions. Fixes: 7caebbf9ea53 ("memory: introduce memory_region_unmap_iommu_notifier_range()") Signed-off-by: Bernhard Beschow Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20230315072552.47117-1-shentey@gmail.com> Signed-off-by: Laurent Vivier --- include/exec/memory.h | 2 +- softmmu/memory.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/include/exec/memory.h b/include/exec/memory.h index 6fa0b071f04d..15ade918baa4 100644 --- a/include/exec/memory.h +++ b/include/exec/memory.h @@ -1738,7 +1738,7 @@ void memory_region_notify_iommu_one(IOMMUNotifier *no= tifier, * * @notifier: the notifier to be notified */ -void memory_region_unmap_iommu_notifier_range(IOMMUNotifier *n); +void memory_region_unmap_iommu_notifier_range(IOMMUNotifier *notifier); =20 =20 /** diff --git a/softmmu/memory.c b/softmmu/memory.c index 4699ba55ec80..5305aca7ca3d 100644 --- a/softmmu/memory.c +++ b/softmmu/memory.c @@ -1996,17 +1996,17 @@ void memory_region_notify_iommu_one(IOMMUNotifier *= notifier, } } =20 -void memory_region_unmap_iommu_notifier_range(IOMMUNotifier *n) +void memory_region_unmap_iommu_notifier_range(IOMMUNotifier *notifier) { IOMMUTLBEvent event; =20 event.type =3D IOMMU_NOTIFIER_UNMAP; event.entry.target_as =3D &address_space_memory; - event.entry.iova =3D n->start; + event.entry.iova =3D notifier->start; event.entry.perm =3D IOMMU_NONE; - event.entry.addr_mask =3D n->end - n->start; + event.entry.addr_mask =3D notifier->end - notifier->start; =20 - memory_region_notify_iommu_one(n, &event); + memory_region_notify_iommu_one(notifier, &event); } =20 void memory_region_notify_iommu(IOMMUMemoryRegion *iommu_mr, --=20 2.39.2 From nobody Thu Apr 18 20:40:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1679062778817344.56800043611554; Fri, 17 Mar 2023 07:19:38 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pdAuY-0006Zj-RP; Fri, 17 Mar 2023 10:18:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdAuX-0006Yu-7f; Fri, 17 Mar 2023 10:18:25 -0400 Received: from mout.kundenserver.de ([217.72.192.73]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdAuV-0004w5-JE; Fri, 17 Mar 2023 10:18:24 -0400 Received: from quad ([82.142.8.70]) by mrelayeu.kundenserver.de (mreue108 [212.227.15.183]) with ESMTPSA (Nemesis) id 1MqrwN-1qH8M61Mp7-00mtln; Fri, 17 Mar 2023 15:18:11 +0100 From: Laurent Vivier To: qemu-devel@nongnu.org Cc: qemu-trivial@nongnu.org, Ilya Leoshkevich , Peter Maydell , Yoshinori Sato , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Laurent Vivier Subject: [PULL 2/3] target/sh4: Honor QEMU_LOG_FILENAME with QEMU_LOG=cpu Date: Fri, 17 Mar 2023 15:18:07 +0100 Message-Id: <20230317141808.826875-3-laurent@vivier.eu> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230317141808.826875-1-laurent@vivier.eu> References: <20230317141808.826875-1-laurent@vivier.eu> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:EIj+NJU9KlUXb/iuch3xmxLd/XK1NveMT1T9/vfq2jXLStFhjLI M+iv4e7qBaLdEQNB+r3Uv13b+hHsLnBWtvd2hZMmGJxNMVRGCKdFjvDM+aanHjlac9XPc6X IwVN4f2EEd7izCMYhqqIkPS073Scoh3Fal88ORu8XQkEFWNZVSiRcRkpwVAKjlVFbQ13z4b YrWpak1x4mgL/pjy6q0Ew== UI-OutboundReport: notjunk:1;M01:P0:H5mTWCljFz0=;q076jwn0eQy/tNgbQjkMLo2YnW/ lN89AHm4YeGXEIk142/IgfdI2kB6sQx1P+65/NBKm6LMNkaw/zAYv7qgDLp1c0jlN9DbIS68K 9HvmKHKlmpCyQIKXuskVfnj4yhBcLigl/Q4iUGmgPvAFdvmhdOdPawebvEQZ5yI+bs3Ark5Vq BUrgvuGeEKIFinfh2lXtnj/TP0caFCjkD5Y5WeIt38Q0jA3yGRprGTVeqvvVNceRnnBhVQOI1 cIkU1UOCLCRmk477EZb0UH4K3cVznKWtnY2rzGJ8Z2EKg96ZKdWpHKghyc9gy8jpbmSDD3FiM uq91L1OYlhMDseDvvqHLBLdyjkd4RW1Y9Cd5/gyLjeYX+pNlq52AXk41ULOnsQateOdtoatbe VoXZuhsUHg8uY7vSW9L4T5ia6LoVJf1HoQ+8CsFXN8OoHAKDL34Y39DiGAQ1+UAJQPRe33s1x DrMuR+TS9h9hk6X+rrGU7m81YxQcQos/EhZlcHEmhPhhHFYkFjH8fq+jJGw0BPwhdkSFFpc4S 8RouwxkRvqUxvKive0ETmBPlT8+qEUWLuPpny7qSnHD+fZa67Ewb2Iwdc8IHFAtsgXzY2ZxQX F6h83z07YYNLAmiIMMJA/+ksW8PGnTH5COIWooVe56ucmEO0wlcw0JpfFW8URt/neUQ4AKnx6 yH75rLKpFJQenjQoJh9RS2WCg+OgidCQCcVwnlGvJw== Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: none client-ip=217.72.192.73; envelope-from=laurent@vivier.eu; helo=mout.kundenserver.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1679062780128100001 From: Ilya Leoshkevich When using QEMU_LOG=3Dcpu on sh4, QEMU_LOG_FILENAME is partially ignored. Fix by using qemu_fprintf() instead of qemu_printf() in the respective places. Fixes: 90c84c560067 ("qom/cpu: Simplify how CPUClass:cpu_dump_state() print= s") Reviewed-by: Peter Maydell Reviewed-by: Yoshinori Sato Signed-off-by: Ilya Leoshkevich Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20230316003411.129462-1-iii@linux.ibm.com> Signed-off-by: Laurent Vivier --- target/sh4/translate.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/target/sh4/translate.c b/target/sh4/translate.c index 97da8bce488e..6e40d5dd6a1f 100644 --- a/target/sh4/translate.c +++ b/target/sh4/translate.c @@ -171,16 +171,16 @@ void superh_cpu_dump_state(CPUState *cs, FILE *f, int= flags) qemu_fprintf(f, "sgr=3D0x%08x dbr=3D0x%08x delayed_pc=3D0x%08x fpul=3D= 0x%08x\n", env->sgr, env->dbr, env->delayed_pc, env->fpul); for (i =3D 0; i < 24; i +=3D 4) { - qemu_printf("r%d=3D0x%08x r%d=3D0x%08x r%d=3D0x%08x r%d=3D0x%08x\n= ", - i, env->gregs[i], i + 1, env->gregs[i + 1], - i + 2, env->gregs[i + 2], i + 3, env->gregs[i + 3]); + qemu_fprintf(f, "r%d=3D0x%08x r%d=3D0x%08x r%d=3D0x%08x r%d=3D0x%0= 8x\n", + i, env->gregs[i], i + 1, env->gregs[i + 1], + i + 2, env->gregs[i + 2], i + 3, env->gregs[i + 3]); } if (env->flags & TB_FLAG_DELAY_SLOT) { - qemu_printf("in delay slot (delayed_pc=3D0x%08x)\n", - env->delayed_pc); + qemu_fprintf(f, "in delay slot (delayed_pc=3D0x%08x)\n", + env->delayed_pc); } else if (env->flags & TB_FLAG_DELAY_SLOT_COND) { - qemu_printf("in conditional delay slot (delayed_pc=3D0x%08x)\n", - env->delayed_pc); + qemu_fprintf(f, "in conditional delay slot (delayed_pc=3D0x%08x)\n= ", + env->delayed_pc); } else if (env->flags & TB_FLAG_DELAY_SLOT_RTE) { qemu_fprintf(f, "in rte delay slot (delayed_pc=3D0x%08x)\n", env->delayed_pc); --=20 2.39.2 From nobody Thu Apr 18 20:40:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 167906276387313.000400455726663; Fri, 17 Mar 2023 07:19:23 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pdAuV-0006Xy-D1; Fri, 17 Mar 2023 10:18:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdAuQ-0006WP-73; Fri, 17 Mar 2023 10:18:18 -0400 Received: from mout.kundenserver.de ([212.227.17.10]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdAuO-0004tn-CU; Fri, 17 Mar 2023 10:18:17 -0400 Received: from quad ([82.142.8.70]) by mrelayeu.kundenserver.de (mreue108 [212.227.15.183]) with ESMTPSA (Nemesis) id 1M3DFj-1peYUI3Uyb-003h35; Fri, 17 Mar 2023 15:18:12 +0100 From: Laurent Vivier To: qemu-devel@nongnu.org Cc: qemu-trivial@nongnu.org, Peter Maydell , Thomas Huth , Laurent Vivier Subject: [PULL 3/3] docs/sphinx/kerneldoc.py: Honour --enable-werror Date: Fri, 17 Mar 2023 15:18:08 +0100 Message-Id: <20230317141808.826875-4-laurent@vivier.eu> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230317141808.826875-1-laurent@vivier.eu> References: <20230317141808.826875-1-laurent@vivier.eu> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:48N5l6aiuxH0hdnn0k0TIWGrUEGIgZc5NQqJg76cXXi8XEoV+6I jizUdQQ6quBytLAw7DXT0xR0t5++T54bdMXJ2/I1Fy00AZPJur6EDXGBJ5LTy9bbLqWQJPi fCu4Y7IoUmr6l5chNGVztJ1W9kLRiQpO6CC4IboZXymtTx4oDC8U9guzDfwluIf2A1QoDu6 G1hyBDV4HTzR8MKgrxdWQ== UI-OutboundReport: notjunk:1;M01:P0:kpVQatv5Nr0=;AieoV6LN/5SkR94CDn3ejECo2Uo rnmqJAJOG9glKnlYFJikYzT29ic5bTiyJJjTShlmYqca1YhGwX16dIhNRz5t27hCjwSQ9SBU7 2FyAlJewKNtLAJC8Ao4gQErfaiyeX9P5bx8Wy4LKRuE5n4LXq810v+D4htv2j43aQfEmBUC2s 1O0NzkSc8t761Bceg7vhneutvNcFSyWDCHezHdreQkWvWUNT4aBHPTdERlogwzDuwTs+1rGjZ mxqmsE825Qvn5MlkqOicn9YdCkuHvkLrvHJg8GznLiUZbB2Ing7ZdyIZ4/W2oJH7ERiSh26m6 +Y6h7xe+Qh1dd12Qhpy2uoOZj59fHfbsPuESXdhOOYdAWiJNoHAQzzUxuyYlCZC/YKuVq9yHi FBvINxd62KgoXYXHg3yaJfWCpXlS844bgirA5EkWqL/mAL0dmIouvaK6ho2IgPaa048jzUZ5a +eBCryh5E/bFRsy4LF91NweUAuZQCKUV6WoSNsVAC4seIXxhyEPSQKwVC+/6UyGZ6G3jfvOpv bBXlmL2IBPi+7xzfCs8gyT4mw1N75e6r2oJ6RX7lo0qlVf8gUwjvF8P6LUTrjxcSI6LflaoHJ IpGLKj6UCZFB9eNkX8R07B3UaOoTsbEmqiLsYC6XOpF1cg4K7XovlqZ5oI0tmnq71tSiDoPhU iGUfGDHfpTDii3bguuh7Ka7moaVTmfoL4PIAMfo5cw== Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: none client-ip=212.227.17.10; envelope-from=laurent@vivier.eu; helo=mout.kundenserver.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1679062766039100005 Content-Type: text/plain; charset="utf-8" From: Peter Maydell Currently, the kerneldoc Sphinx plugin doesn't honour the --enable-werror configure option, so its warnings are never fatal. This is because although we do pass sphinx-build the -W switch, the warnings from kerneldoc are produced by the scripts/kernel-doc script directly and don't go through Sphinx's "emit a warning" function. When --enable-werror is in effect, pass sphinx-build an extra argument -Dkerneldoc_werror=3D1. The kerneldoc plugin can then use this to determine whether it should be passing the kernel-doc script -Werror. We do this because there is no documented mechanism for a Sphinx plugin to determine whether sphinx-build was passed -W or not; if one is provided then we can switch to that at a later date: https://github.com/sphinx-doc/sphinx/issues/11239 Signed-off-by: Peter Maydell Reviewed-by: Thomas Huth Message-Id: <20230314114431.1096972-1-peter.maydell@linaro.org> Signed-off-by: Laurent Vivier --- docs/meson.build | 2 +- docs/sphinx/kerneldoc.py | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/docs/meson.build b/docs/meson.build index bb72c10ea8c5..f220800e3e59 100644 --- a/docs/meson.build +++ b/docs/meson.build @@ -7,7 +7,7 @@ if sphinx_build.found() SPHINX_ARGS =3D ['env', 'CONFDIR=3D' + qemu_confdir, sphinx_build, '-q'] # If we're making warnings fatal, apply this to Sphinx runs as well if get_option('werror') - SPHINX_ARGS +=3D [ '-W' ] + SPHINX_ARGS +=3D [ '-W', '-Dkerneldoc_werror=3D1' ] endif =20 # This is a bit awkward but works: create a trivial document and diff --git a/docs/sphinx/kerneldoc.py b/docs/sphinx/kerneldoc.py index bf442150165f..72c403a73798 100644 --- a/docs/sphinx/kerneldoc.py +++ b/docs/sphinx/kerneldoc.py @@ -74,6 +74,10 @@ def run(self): # Sphinx versions cmd +=3D ['-sphinx-version', sphinx.__version__] =20 + # Pass through the warnings-as-errors flag + if env.config.kerneldoc_werror: + cmd +=3D ['-Werror'] + filename =3D env.config.kerneldoc_srctree + '/' + self.arguments[0] export_file_patterns =3D [] =20 @@ -167,6 +171,7 @@ def setup(app): app.add_config_value('kerneldoc_bin', None, 'env') app.add_config_value('kerneldoc_srctree', None, 'env') app.add_config_value('kerneldoc_verbosity', 1, 'env') + app.add_config_value('kerneldoc_werror', 0, 'env') =20 app.add_directive('kernel-doc', KernelDocDirective) =20 --=20 2.39.2