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] [day] [month] [year] [list]
Message-ID: <aD8X1cNBesu71yy3@agluck-desk3>
Date: Tue, 3 Jun 2025 08:42:13 -0700
From: "Luck, Tony" <tony.luck@...el.com>
To: Borislav Petkov <bp@...en8.de>
Cc: Zaid Alali <zaidal@...amperecomputing.com>, rafael@...nel.org,
	lenb@...nel.org, james.morse@....com, robert.moore@...el.com,
	Jonathan.Cameron@...wei.com, ira.weiny@...el.com,
	Benjamin.Cheatham@....com, dan.j.williams@...el.com, arnd@...db.de,
	Avadhut.Naik@....com, john.allen@....com,
	linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org,
	acpica-devel@...ts.linux.dev
Subject: Re: [PATCH v7 9/9] ACPI: APEI: EINJ: Update the documentation for
 EINJv2 support

On Tue, Jun 03, 2025 at 10:31:57AM +0200, Borislav Petkov wrote:
> On Mon, Jun 02, 2025 at 10:02:15AM -0700, Luck, Tony wrote:
> > This is just an improvement on my "option 1" (improved because all-ones
> > for the component ID is going to be invalid for sure, while all zeroes
> > could be a valid component).
> 
> Right, you need to know at injection time which of the components are valid
> and which are not.
> 
> > Or just stop collecting on the first invalid one.
> 
> That would mean that you punish the user at the first typo. :-P
> 
> Considering how complex those interfaces become perhaps not such a good
> idea...

Here's what EINJ V2 injection looks like to a user (to be included in
Documentation/firmware-guide/acpi/apei/einj.rst):

An EINJv2 error injection example::

  # cd /sys/kernel/debug/apei/einj
  # cat available_error_type                    # See which errors can be injected
  0x00000002    Processor Uncorrectable non-fatal
  0x00000008    Memory Correctable
  0x00000010    Memory Uncorrectable non-fatal
  V2_0x00000001 EINJV2 Processor Error
  V2_0x00000002 EINJV2 Memory Error

  # echo 0x12345000 > param1                    # Set memory address for injection
  # echo 0xfffffffffffff000 > param2            # Range - anywhere in this page
  # echo 0x1 > component_id0                    # First device ID
  # echo 0x4 > component_syndrome0              # First error syndrome
  # echo 0x2 > component_id1                    # Second device ID
  # echo 0x4 > component_syndrome1              # Second error syndrome
  # echo '' > component_id2                     # Mark id2 invalid to terminate list
  # echo V2_0x2 > error_type                    # Choose EINJv2 memory error
  # echo 0xa > flags                            # set flags to indicate EINJv2
  # echo 1 > error_inject                       # Inject now

Note the shorthand to write all-ones using an empty line because
typing:

  # echo fffffffffffffffffffffffffffffff > component_id2

would:
1) give carpal tunnel syndrome
2) wear out the "f" key on my keyboard
3) run the risk of miscounting the number of 'f' characters
   (above is wrong because there are only 31, but hard to spot that).

-Tony

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ