From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f49.google.com (mail-wm1-f49.google.com [209.85.128.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2073333345E for ; Mon, 1 Dec 2025 16:14:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.49 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764605696; cv=none; b=jMi4HKppWRYG5HfENAFdDD8oC0Z0CVfYH4qOWUWmRJ9gls008S7EvR12qJV4AHRI+z5l7lRXBYDCAJMw8AFocoqfmxGD45m4yUBKdQ6GVZ3ucjy/J2iK2xP+KfItrifGq7rR2BFDM3fYldiCdTgQ7I9dDe6c0RSrRlDSAHLlef0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764605696; c=relaxed/simple; bh=B0VD/7ecue9RxfUijHuGcnYWwiHW9gfciNZxDUoKYrw=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition; b=jlH9vtBkeUaiCpuS8nNLDRYElPXDdh995M7cAd+QJe6hdvPIapQepagHfyon1VNWPpR05acoVh3/J+5i6pbG8Dz4cXHfZLDclcS/Y5k44HzQahBNU3Utn0CR3OOCS6BP83u0ZDFb7izVKY3HWVPN3ssjwFHUNj2CgaGKC53E8h4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com; spf=pass smtp.mailfrom=suse.com; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b=Hj5KTPM/; arc=none smtp.client-ip=209.85.128.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b="Hj5KTPM/" Received: by mail-wm1-f49.google.com with SMTP id 5b1f17b1804b1-477a219db05so27953535e9.2 for ; Mon, 01 Dec 2025 08:14:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1764605692; x=1765210492; darn=vger.kernel.org; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=35ySUxjTarUCexl2inYBXR0f4rnnSG/Vofb6Hynh0u0=; b=Hj5KTPM/plZsmoy5bRrtceonNixBmFtPeoHr/7NdJekbg00bJIizR5edsxcd4xjVOz GhjbMSp4PMb5JhCxbj5URF4i/dIFsP2ASQWC19ythpzClujZ3OogtFkzA0I7gAYF/piO vSH+4HiRmQT+deHwMv2EpV4yncWU0mfG32E3A3va5N2Etf6YapoWTVTmH8/rDPXpThk2 pdY2uX8N811E8WtrIx2CPpefNtNIPv1/0rHMWo8RFTL+/JYvixk9riKtMSjnDxDPDna/ VD4CGotdnMf3zJoN0gfoC4i48D2SH44BCOcldfx5ZZL1XUXNoWkNMsVIMdjliHBnpQKj iL3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1764605692; x=1765210492; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=35ySUxjTarUCexl2inYBXR0f4rnnSG/Vofb6Hynh0u0=; b=cm3yS4/er29lIi7PTlqG/0fOYw8Xmt44htcq3OhU0GY6EqtyQZ0dvmyDLNesAjPi1C 0HWZ7aHNUMV3vKLpnheH1K6p8AQa1dfLNo6sxQ1Ilmk6NU2TfCNadIGhwC6TbNBRhQXF 10O/YI1m8k4b/yoiHD8iYjBlB0aBZ47Np9ggw7NbDmXtPabTj4ZEJLm25JZ9iO6AuLR6 CBCLHToBQjHNpjsdDhhAtxlKM3LPxLQJ8pjw9VfwU4EL96+J3tbqLG6RcX1x6y7ZEmOy OyjkTQgC4SlhHSjTyp10YTgdR1ktk7LkB4i0MY8YxyQC9U9wzzeGBZnQ2EzD1+VKqypc rh5w== X-Forwarded-Encrypted: i=1; AJvYcCXlTMX74WSmvDJZhmdXUdqEyiVH46Hv9UFXxaYg2RnfbqDSC1UoUcWQIE0HIOlmS4dtzt97I0/hemlYgrU=@vger.kernel.org X-Gm-Message-State: AOJu0Yykbhiw60DP6Ou/mDaJoi1mOf5BAzGsfsJA/7WzP7+zbOaMEcd2 URYPRpcID19/Koxpo6NHdRrJ65OrUEB7L7c4VYek1b8FOdgS4NrSiZ+sANayYcJ4TZw= X-Gm-Gg: ASbGncvQIfY2kvjWbBsTlk9ZvmtgitaZJsCvk7O3e/9f7YIPUTQimrp/vfvJW1KzDOt CVdYYcAcGbbdUZu3NuVDtygq87aXkcIbHVY17GrkLjPiVKkxROULg+bN6wq6GuMj3Yxv2QdXgZi Xg0AL7Kykw9KJ6qDdoscjYqZEcuFd8obait2Ezd5BsOXvWpbyKM/3cINlQG0Kw+iovzVbMYRxPn i5Xw55DPjW/dVkgJu9BughujAfV9ogk4FIipNA2YotHXTdBQbE4n8vv6RCndI3TqKuTc5IaPAV1 lGVYh1isbYixjUOtkWa3z00Va3LhdOgq/BbLL823wUzEEViegdAQCAJWDZTTcNXqiQ2j8Bp0g22 qL0Q3q6SuSP3ESrdeHxn6Gz95zkvQnUifz5Qhsi0E7vgI6vCzgO3qNIBmCTngPeGj6eBLSKN8lp X7JtB203Wy20NqLA== X-Google-Smtp-Source: AGHT+IFi85axKOvqCxxlmz0LhoRXHAYFj0CaDVm/M49/v0QCb67AxtkWmvPn647Gjvc+ye/Fiy/EZQ== X-Received: by 2002:a05:600c:310f:b0:475:de14:db1e with SMTP id 5b1f17b1804b1-477c1125568mr430138055e9.24.1764605692234; Mon, 01 Dec 2025 08:14:52 -0800 (PST) Received: from pathway.suse.cz ([176.114.240.130]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4790add60e2sm307024685e9.6.2025.12.01.08.14.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 Dec 2025 08:14:51 -0800 (PST) Date: Mon, 1 Dec 2025 17:14:49 +0100 From: Petr Mladek To: Linus Torvalds Cc: Sergey Senozhatsky , Steven Rostedt , John Ogness , Andy Shevchenko , Rasmus Villemoes , Peter Zijlstra , Petr Mladek , linux-kernel@vger.kernel.org Subject: [GIT PULL] printk for 6.19 Message-ID: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi Linus, please pull the latest printk changes from git://git.kernel.org/pub/scm/linux/kernel/git/printk/linux.git tags/printk-for-6.19 ================================================== - Allow to create nbcon console drivers with an unsafe write_atomic() callback. It can be called only by the final nbcon_atomic_flush_unsafe(). Otherwise, the driver would rely on the kthread. It is going to be used as the-best-effort approach for an experimental nbcon netconsole driver, see https://lore.kernel.org/r/20251121-nbcon-v1-2-503d17b2b4af@debian.org Note that a safe .write_atomic() callback is supposed to work in NMI context. But some networking drivers are not safe even in IRQ context, see https://lore.kernel.org/r/oc46gdpmmlly5o44obvmoatfqo5bhpgv7pabpvb6sjuqioymcg@gjsma3ghoz35 In the ideal world, all networking drivers were fixed first and the atomic flush would be blocked only in NMI context. But it brings the question how reliable are networking drivers when the system is in a bad state. They might block flushing more reliable serial consoles which are more suitable for serious debugging anyway. - Allow to use the last 4 bytes of the printk ring buffer. - Prevent queuing IRQ work and block printk kthreads when consoles are suspended. Otherwise, they create non-necessary churn or even block the suspend. - Release console_lock() between each record in the kthread used for legacy consoles on RT. It might significantly speed up the boot. - Release nbcon context between each record in the atomic flush. It prevents stalls of the related printk kthread after it has lost the ownership in the middle of a record. - Add support for NBCON consoles into KDB. - Add %ptsP modifier for printing struct timespec64 and use it where possible. - Misc code clean up. ---------------------------------------------------------------- Andrew Murray (2): printk: Introduce console_flush_one_record printk: Use console_flush_one_record for legacy printer kthread Andy Shevchenko (24): lib/vsprintf: Check pointer before dereferencing in time_and_date() lib/vsprintf: Deduplicate special hex number specifier data lib/vsprintf: Add specifier for printing struct timespec64 ceph: Switch to use %ptSp libceph: Switch to use %ptSp dma-buf: Switch to use %ptSp drm/amdgpu: Switch to use %ptSp drm/msm: Switch to use %ptSp drm/vblank: Switch to use %ptSp drm/xe: Switch to use %ptSp e1000e: Switch to use %ptSp igb: Switch to use %ptSp ipmi: Switch to use %ptSp media: av7110: Switch to use %ptSp mmc: mmc_test: Switch to use %ptSp net: dsa: sja1105: Switch to use %ptSp PCI: epf-test: Switch to use %ptSp pps: Switch to use %ptSp ptp: ocp: Switch to use %ptSp s390/dasd: Switch to use %ptSp scsi: fnic: Switch to use %ptSp scsi: snic: Switch to use %ptSp tracing: Switch to use %ptSp lib/vsprintf: Unify FORMAT_STATE_NUM handlers Daniil Tatianin (1): printk_ringbuffer: don't needlessly wrap data blocks around John Ogness (4): printk: nbcon: Allow unsafe write_atomic() for panic printk: Allow printk_trigger_flush() to flush all types printk: Avoid scheduling irq_work on suspend printk: Avoid irq_work for printk_deferred() on suspend Lukas Bulwahn (1): MAINTAINERS: add printk core-api doc file to PRINTK Marcos Paulo de Souza (8): printk: nbcon: Export console_is_usable printk: nbcon: Introduce KDB helpers printk: nbcon: Allow KDB to acquire the NBCON context printk: nbcon: Export nbcon_write_context_set_buf kdb: Adapt kdb_msg_write to work with NBCON consoles drivers: serial: kgdboc: Drop checks for CON_ENABLED and CON_BOOT arch: um: kmsg_dump: Use console_is_usable printk: Use console_is_usable on console_unblank Oleg Nesterov (1): printk_legacy_map: use LD_WAIT_CONFIG instead of LD_WAIT_SLEEP Petr Mladek (13): printk: console_flush_one_record() code cleanup printk/nbcon: Block printk kthreads when any CPU is in an emergency context printk/nbcon/panic: Allow printk kthread to sleep when the system is in panic printk/nbcon: Release nbcon consoles ownership in atomic flush after each emitted record printk_ringbuffer: Fix check of valid data size when blk_lpos overflows printk_ringbuffer: Create a helper function to decide whether more space is needed Merge branch 'for-6.19-vsprintf-timespec64' into for-linus Merge branch 'rework/atomic-flush-hardlockup' into for-linus Merge branch 'rework/nbcon-in-kdb' into for-linus Merge branch 'rework/preempt-legacy-kthread' into for-linus Merge branch 'rework/suspend-fixes' into for-linus Merge branch 'rework/threaded-printk' into for-linus Merge branch 'rework/write_atomic-unsafe' into for-linus Thorsten Blum (1): lib/vsprintf: Improve vsprintf + sprintf function comments Documentation/core-api/printk-formats.rst | 11 +- MAINTAINERS | 1 + arch/um/kernel/kmsg_dump.c | 2 +- drivers/char/ipmi/ipmi_si_intf.c | 3 +- drivers/char/ipmi/ipmi_ssif.c | 6 +- drivers/dma-buf/sync_debug.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_dev_coredump.c | 3 +- drivers/gpu/drm/drm_vblank.c | 6 +- drivers/gpu/drm/msm/disp/msm_disp_snapshot_util.c | 3 +- drivers/gpu/drm/msm/msm_gpu.c | 3 +- drivers/gpu/drm/xe/xe_devcoredump.c | 4 +- drivers/mmc/core/mmc_test.c | 20 +- drivers/net/dsa/sja1105/sja1105_tas.c | 8 +- drivers/net/ethernet/intel/e1000e/ptp.c | 7 +- drivers/net/ethernet/intel/igb/igb_ptp.c | 7 +- drivers/pci/endpoint/functions/pci-epf-test.c | 5 +- drivers/pps/generators/pps_gen_parport.c | 3 +- drivers/pps/kapi.c | 3 +- drivers/ptp/ptp_ocp.c | 13 +- drivers/s390/block/dasd.c | 3 +- drivers/scsi/fnic/fnic_trace.c | 55 ++-- drivers/scsi/snic/snic_debugfs.c | 10 +- drivers/scsi/snic/snic_trc.c | 5 +- drivers/staging/media/av7110/av7110.c | 2 +- drivers/tty/serial/kgdboc.c | 1 - fs/ceph/dir.c | 5 +- fs/ceph/inode.c | 49 ++-- fs/ceph/xattr.c | 6 +- include/linux/console.h | 68 +++++ include/linux/kdb.h | 16 ++ kernel/debug/kdb/kdb_io.c | 47 ++-- kernel/printk/internal.h | 53 +--- kernel/printk/nbcon.c | 174 ++++++++++-- kernel/printk/printk.c | 306 ++++++++++++++-------- kernel/printk/printk_ringbuffer.c | 67 ++++- kernel/trace/trace_output.c | 6 +- lib/tests/printf_kunit.c | 4 + lib/vsprintf.c | 80 +++--- net/ceph/messenger_v2.c | 6 +- 39 files changed, 682 insertions(+), 391 deletions(-)