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]
Date:   Tue, 19 Sep 2023 16:43:40 -0600
From:   Dan Raymond <draymond@...valley.net>
To:     Peter Zijlstra <peterz@...radead.org>
Cc:     linux-kernel@...r.kernel.org, x86@...nel.org, tglx@...utronix.de,
        mingo@...hat.com, bp@...en8.de, dave.hansen@...ux.intel.com,
        hpa@...or.com
Subject: Re: [PATCH v1] arch/x86: port I/O tracing on x86

On 9/19/2023 3:31 PM, Dan Raymond wrote:
> On 9/19/2023 3:12 PM, Peter Zijlstra wrote:
>>>> This means I can no longer use early_console->write() to print to my
>>>> early_serial_console.
>>>
>>> Why not?  Did you try it?
>>
>> I have tried debugging the kernel for the last 15+ years. The only
>> reliable way to get something out of the machine is outb on the serial
>> port. Anything else is a waste of time..
>>
>> Adding tracing to it (which relies on RCU, which might not be alive at
>> this point) which might itself be the problem, is a total no-go.
>>
>> You do not wreck early_serial_console.
> 
> But you didn't try my patch to see if it "wrecks" early_serial_console.
> I doubt it has any impact there because it does not get compiled into
> boot code.  Notice the BOOT_COMPRESSED_MISC_H and BOOT_BOOT_H checks.
> 
> I don't understand your general objection.  The kernel already has
> tracing for memory mapped I/O which includes serial ports.  This patch
> just extends that to include port I/O.

Another point: The tracing infrastructure uses RCU for management of
trace buffers.  If you don't explicitly enable portio tracing nothing
will get written to the trace buffers.  Nothing extra will be done
during outb() except for a quick check to see that tracing is disabled.
This check took only a few clock cycles on average during my testing.
This should be fine even during early boot.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ