lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aSYQgZR1YoVQkbxC@smile.fi.intel.com>
Date: Tue, 25 Nov 2025 22:24:33 +0200
From: Andy Shevchenko <andriy.shevchenko@...el.com>
To: Mikhail Kshevetskiy <mikhail.kshevetskiy@...sys.eu>
Cc: Lorenzo Bianconi <lorenzo@...nel.org>, Ray Liu <ray.liu@...oha.com>,
	Mark Brown <broonie@...nel.org>, Rob Herring <robh@...nel.org>,
	Krzysztof Kozlowski <krzk+dt@...nel.org>,
	Conor Dooley <conor+dt@...nel.org>,
	Matthias Brugger <matthias.bgg@...il.com>,
	AngeloGioacchino Del Regno <angelogioacchino.delregno@...labora.com>,
	Andy Shevchenko <andy@...nel.org>,
	linux-arm-kernel@...ts.infradead.org, linux-spi@...r.kernel.org,
	devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
	linux-mediatek@...ts.infradead.org,
	Andreas Gnau <andreas.gnau@...sys.eu>
Subject: Re: [PATCH v5 1/3] spi: airoha-snfi: en7523: workaround flash
 damaging if UART_TXD was short to GND

On Tue, Nov 25, 2025 at 10:16:33PM +0300, Mikhail Kshevetskiy wrote:

...

> +			dev_warn(dev, "Detected booting in RESERVED mode (UART_TXD was short to GND).\n");
> +			dev_warn(dev, "This mode is known for incorrect DMA reading of some flashes.\n");
> +			dev_warn(dev, "Usage of DMA for flash operations will be disabled to prevent data\n");
> +			dev_warn(dev, "damage. Unplug your serial console and power cycle the board\n");
> +			dev_warn(dev, "to boot with full performance.\n");

One non-critical remark (for the future), the '\n' in the string literals when
we print messages has two meanings:
 - (obviously) new line
 - (seems not so obvious for people) flush the line to the output device

Due to the second property the messages might be interleaved with the other
messages (assuming SMP machine actively doing and printing something), hence
your messages might be split with other and imagine the user who gets in the
middle of the text something like

"Usage of DMA for flash operations will be disabled to prevent data"

The first thought will be "what the heck does this mean?"

TL;DR: place '\n' with a care in the messages to print not only here,
but in general.

-- 
With Best Regards,
Andy Shevchenko



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ