Received: by 2002:a05:7412:da14:b0:e2:908c:2ebd with SMTP id fe20csp228193rdb; Fri, 6 Oct 2023 01:22:35 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH4MrCmleVml4vo1+L4yqYVwpO2zbpsY7zgG8mBfIc6I0y/+/D7H90sxZPkYS453Yoqbu9l X-Received: by 2002:a05:6a00:1a0c:b0:68e:2478:d6c9 with SMTP id g12-20020a056a001a0c00b0068e2478d6c9mr7347897pfv.2.1696580554934; Fri, 06 Oct 2023 01:22:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696580554; cv=none; d=google.com; s=arc-20160816; b=lHcDXLbaWjH5yza3RE+/602djR7FVPOJnvGgW8SWzR6+xU2Ihmb0KCtNqGqiHbgmnm sTC97Z9NmQZ8ov8CndZ/5l1dXSmWyh61CY+HrgnHSnbfQ1lmcQABcFpYZzEf7Pf3lPYC wr9augka0G+tsOhXYq4SnHV42QUa3vW9M6ivqy5MsvPQHoq0WWThuCUeSfRQIj5KduDr Wk2a82v3uJbYfQEVb8+edmT0jlBRzV5Z5RUW9XHAy87CiZruV75rkTqZrBUHxQZmAbjM G05BWCW/aoc5Vlfw8jvJ5PyULEX/dJpTrCsyEL7VlR4/laPzD5KGNPDI8/ycvVRmTrkL BoHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=iZ5AXY/iSp6d7wOgYZVKff+q84bButyby83sf6JatSs=; fh=Rkem9DZLVtB3ZM00Hf1TNke3sV6aftsNytr1Ms93Wzw=; b=fG5VA+yPA9WYmn5aRESMabGyY/vSglrCj9x+HEDt2rbseclnaaE/FnOmu23Eskce24 wV4JuUGrytV5WS1T3LWaCE0PYgmJfTT+JUx3gX95hioV3Au44WrQBarkS71rD3s3glsF 4+yNEPi/vRveAcvB75pWjehAxmSuUXqlQXik/lH5mUVYP/ljeGttMVdDhON9h/M8+SiN vLW2qI3ilpmypIQSYdCH4BLDrmew0Ursu9jARoe2BxEf2QW/xtQa+PNZAmEC2kBA8hJy yiWzyenGo4eF02iAA334In1pNOLba+4gGTS3dGbd/rm0z9lpXveiH3ZvQ6MiJktduCq+ qGmQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=Pv0DKj5s; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Return-Path: Received: from agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id l10-20020a63570a000000b00584a9290bd3si3104454pgb.522.2023.10.06.01.22.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Oct 2023 01:22:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=Pv0DKj5s; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 3A4E2817711C; Fri, 6 Oct 2023 01:22:21 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231129AbjJFIWH (ORCPT + 99 others); Fri, 6 Oct 2023 04:22:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48040 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231127AbjJFIWE (ORCPT ); Fri, 6 Oct 2023 04:22:04 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8118FEA for ; Fri, 6 Oct 2023 01:22:03 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id 03345210DB; Fri, 6 Oct 2023 08:22:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1696580522; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=iZ5AXY/iSp6d7wOgYZVKff+q84bButyby83sf6JatSs=; b=Pv0DKj5sGoRI6RO2qotcGL2p6IWVp0d6yGUpXMLLN56qKiS1Nql+W/uk9q9cBxLYZdb6Fv 0Fpz9cwjo1rWYuykovanKI1hFob8t5wMOyh80yg2px7ehNmz/2SBWVloIhLi6fj3NyyAg2 3+Po2oNpwJ/DB5taR2pNDHBWhBNCYEE= Received: from alley.nue2.suse.org (pmladek.udp.ovpn1.nue.suse.de [10.163.31.190]) by relay2.suse.de (Postfix) with ESMTP id 417DD2C142; Fri, 6 Oct 2023 08:22:01 +0000 (UTC) From: Petr Mladek To: John Ogness , Sergey Senozhatsky , Steven Rostedt Cc: Thomas Gleixner , Todd Brandt , linux-kernel@vger.kernel.org, Petr Mladek Subject: [PATCH v2 0/2] printk: Reduce unnecessary wait times by pr_flush() Date: Fri, 6 Oct 2023 10:21:49 +0200 Message-Id: <20231006082151.6969-1-pmladek@suse.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Fri, 06 Oct 2023 01:22:22 -0700 (PDT) This is an updated version of the patch https://lore.kernel.org/r/20230929113233.863824-1-john.ogness@linutronix.de Changes since v1: + Split reduction of the pooling time into separate patch. + Use jiffies to count the real sleeping time. Note that my original POC counted jiffies spent in the entire cycle. It would count also the time spent by console_lock() and by flushing the legacy consoles in console_unlock(). The current version counts only the time spent by msleep(1) aka the pooling interval. John Ogness (1): printk: flush consoles before checking progress Petr Mladek (1): printk: Reduce pr_flush() pooling time kernel/printk/printk.c | 34 ++++++++++++++++++++-------------- 1 file changed, 20 insertions(+), 14 deletions(-) -- 2.35.3