Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp3985976pxm; Tue, 1 Mar 2022 09:01:13 -0800 (PST) X-Google-Smtp-Source: ABdhPJy1B3oCg5aWo6+dMU5uXD8SWsft+5JKsKrfGkW5w+HWQtlermmlciX7cGmA7vOC+LrmV9Ks X-Received: by 2002:a05:6a02:184:b0:373:a24e:5ab with SMTP id bj4-20020a056a02018400b00373a24e05abmr22671050pgb.400.1646154073698; Tue, 01 Mar 2022 09:01:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646154073; cv=none; d=google.com; s=arc-20160816; b=bvs90ua0nqhbkpwKy06Eenp8vWGRWmDrUN/XJ5NI+zDjuo7wSbgFFlZN/MMS/wm6CZ KvYxysJHPDYQTP9SyJhZjaFRoOAPpituyBoEqVeibBoydzwjp3RWFceCuqBTpFeA9INH m5QapLVoRZA/0Ps7k8+czq/5SehBE9GRu7X1OEXYzoP/hJiP+rTBe56lApinvyLv3VDC u/kWefl+5vmnkV/DSQnnz3EK1+cC7As3lgYpbGF9Jsr03ZWhRzxnyVmyHvmj80zyoNHJ 6PyC8UkHzsoSK0ostvW2jEznSO9uNkgFFVBXTZpFJNusI2uPmryttP9HWov1uOhy3Ubq EWeA== 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=OVXnHx1+bUpU3p6Ka0LCONj//t9wynbM77Xx3/5dJlE=; b=wbhFC9jOblTIt2FHPILaNr9srPoH2Eo5ZDgD7TQybl+rPNwuqSFin9TosTEACOzczW qZLt4mkclwj5Uv72YmOkc6jfJTHg+yU0MuJBDOucC1RNDFfQxl7MFRgn9cPcy/e1Ntd/ WwevJe/Uy8F4RAqalQ0DGO98k2NJckGJJc4Y49J0bBKsEMaUAQ3vbtJQfMJ+6gs5KP57 +QcfsaA4++qXsthzGk7bwPJ+6MBNfGEdJzDarC59hEeD6Jk1d9dkpd/LnHotQhXZ/cgz tqSZXjkVd0TlFIyuHPgL4wFW9Hp5fVTyVc/rKv3bZQRvbvu1BtMj4RX+oA5+VvZp/+jf aI3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@axis.com header.s=axis-central1 header.b=mMUYuhOb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=axis.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 201-20020a6303d2000000b00338a8050e87si12475916pgd.739.2022.03.01.09.00.55; Tue, 01 Mar 2022 09:01:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@axis.com header.s=axis-central1 header.b=mMUYuhOb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=axis.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235371AbiCAOue (ORCPT + 99 others); Tue, 1 Mar 2022 09:50:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40258 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231776AbiCAOud (ORCPT ); Tue, 1 Mar 2022 09:50:33 -0500 Received: from smtp2.axis.com (smtp2.axis.com [195.60.68.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 75CD546B0D for ; Tue, 1 Mar 2022 06:49:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axis.com; q=dns/txt; s=axis-central1; t=1646146192; x=1677682192; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=OVXnHx1+bUpU3p6Ka0LCONj//t9wynbM77Xx3/5dJlE=; b=mMUYuhObYXgSSYr7J1qyb5m7aJ0+/Flg6J6J7WYTjkvf5yynlczR/NF5 vh3h0bb2DUJwQfSuBj3TRnSgcvwypT6gVBwpwXjG9Op4jTqJTg8OqWHyY uiB9pHdVXZpJt3tOzrsLckMo5z2Tf6ZAXNHmPWD45jl/mwyWFSt78fb8q NDVgIuN5uKHrxPMPc4Kr6Ww7lhKW40DHhOdGF7HRpjND1llXzM2wePhLp 1+vJfRqEXwiFBHuE/MyusDRRfxK0b1vFKv24OpC5EefYCnCZcfW+bcVEM lWm738BcP9rKR9QUhZ3MYq3QNtpXSTp79EyPUOxzoDMvSN7is7BRWm3MA Q==; From: Vincent Whitchurch To: Kees Cook , Anton Vorontsov , Colin Cross , Tony Luck CC: , Vincent Whitchurch , Subject: [PATCH] pstore: Add prefix to ECC messages Date: Tue, 1 Mar 2022 15:49:32 +0100 Message-ID: <20220301144932.89549-1-vincent.whitchurch@axis.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The "No errors detected" message from the ECC code is shown at the end of the pstore log and can be confusing or misleading, especially since it usually appears just after a kernel crash log which normally means quite the opposite of "no errors". Prefix the message to clarify that this message is only about ECC-detected errors. Signed-off-by: Vincent Whitchurch --- fs/pstore/ram_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/pstore/ram_core.c b/fs/pstore/ram_core.c index fe5305028c6e..a89e33719fcf 100644 --- a/fs/pstore/ram_core.c +++ b/fs/pstore/ram_core.c @@ -263,10 +263,10 @@ ssize_t persistent_ram_ecc_string(struct persistent_ram_zone *prz, if (prz->corrected_bytes || prz->bad_blocks) ret = snprintf(str, len, "" - "\n%d Corrected bytes, %d unrecoverable blocks\n", + "\nECC: %d Corrected bytes, %d unrecoverable blocks\n", prz->corrected_bytes, prz->bad_blocks); else - ret = snprintf(str, len, "\nNo errors detected\n"); + ret = snprintf(str, len, "\nECC: No errors detected\n"); return ret; } -- 2.34.1