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, 9 Jun 2015 15:19:38 +0600
From:	Alexander Kuleshov <kuleshovmail@...il.com>
To:	Borislav Petkov <bp@...e.de>
Cc:	Thomas Gleixner <tglx@...utronix.de>,
	Ingo Molnar <mingo@...hat.com>,
	"H. Peter Anvin" <hpa@...or.com>,
	Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
	LKML <linux-kernel@...r.kernel.org>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Mark Rustad <mark.d.rustad@...el.com>,
	Yinghai Lu <yinghai@...nel.org>
Subject: Re: [PATCH v10 3/3] x86/earlyprintk: setup earlyprintk as early as possible

2015-06-08 15:33 GMT+06:00 Borislav Petkov <bp@...e.de>:
> On Sun, Jun 07, 2015 at 08:14:37PM +0600, Alexander Kuleshov wrote:
>> diff --git a/arch/x86/kernel/head64.c b/arch/x86/kernel/head64.c
>> index 1e5f064..769d411 100644
>> --- a/arch/x86/kernel/head64.c
>> +++ b/arch/x86/kernel/head64.c
>> @@ -174,7 +174,12 @@ asmlinkage __visible void __init x86_64_start_kernel(char * real_mode_data)
>>
>>       setup_builtin_cmdline();
>>
>> +     lockdep_init();
>
> So you've added that lockdep_init() call here and above on the 32-bit
> path and haven't removed the one in start_kernel().
>

Hello Borislav,

Yes, I've left the lockdep_init in the start_kernel because there are a
couple architectures (arm,arm64 and etc...) who have support of the lockdep,
but have do not call lockdep_init in their architecture-specific code from the
arch/*.

> * Then, your patches don't apply. Something garbles them insanely so that
> not even fuzzy, ignore-context patch --merge works. Please fix your
> setup. For that, send your patches to yourself and try applying them.
> Send them out only if they apply cleanly.
>
> And do them against tip/master or latest Linus rc, alternatively.

Yes, sorry, will fix it.

> * To that patchset: I did the diff below ontop of yours to check whether
> that early printk actually works.
>
> And it doesn't on my test box here.
>
> The beginning of my dmesg contains:
>
> [    0.000000] bootconsole [earlyser0] enabled
> [    0.000000] Initializing cgroup subsys cpuset
> [    0.000000] Initializing cgroup subsys cpu
> [    0.000000] Initializing cgroup subsys cpuacct
> [    0.000000] Linux version 4.1.0-rc6+ (root@...dor) (gcc version 4.9.1 (Debian 4.9.1-19) ) #2 SMP PREEMPT Mon Jun 8 11:10:00 CEST 2015
> [    0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-4.1.0-rc6+ root=/dev/sda7 ro earlyprintk=ttyS0,115200 console=ttyS0,115200 console=tty0 root=/dev/sda7 log_buf_len=10M resume=/dev/sda5 no_console_suspend ignore_loglevel
> [    0.000000] KERNEL supported cpus:
> [    0.000000]   Intel GenuineIntel
> [    0.000000]   AMD AuthenticAMD
> [    0.000000]   Centaur CentaurHauls
> [    0.000000] x86/fpu: xstate_offset[2]: 0240, xstate_sizes[2]: 0100
> [    0.000000] x86/fpu: Supporting XSAVE feature 0x01: 'x87 floating point registers'
> [    0.000000] x86/fpu: Supporting XSAVE feature 0x02: 'SSE registers'
> [    0.000000] x86/fpu: Supporting XSAVE feature 0x04: 'AVX registers'
> [    0.000000] x86/fpu: Enabled xstate features 0x7, context size is 0x340 bytes, using 'standard' format.
> [    0.000000] x86/fpu: Using 'eager' FPU context switches.
> [    0.000000] e820: BIOS-provided physical RAM map:
> ...
>
> and I have CONFIG_EARLY_PRINTK=y. So provided I'm not missing anything,
> I'd say you'd need to do more staring.
>

I've tested this and does not see early_printk output too on the hardware, but
only with qemu when I setup serial connection... The problem here that the
early_printk function does not use the log_buf to store its messages
as it printk does.

How to be with this? Is early_printk must to store its messages in the log_buf?

Thank you.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ