From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pavel Machek Subject: Re: [PATCH 0/2][concept RFC] x86: BIOS-save kernel log to disk upon panic Date: Thu, 3 Feb 2011 15:36:45 +0100 Message-ID: <20110203143644.GA4085@ucw.cz> References: <20110125134748.GA10051@laptop> <20110125140948.GA26762@elte.hu> <20110125150834.GD27510@htj.dyndns.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from ksp.mff.cuni.cz ([195.113.26.206]:50630 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750920Ab1BCOg5 (ORCPT ); Thu, 3 Feb 2011 09:36:57 -0500 Content-Disposition: inline In-Reply-To: <20110125150834.GD27510@htj.dyndns.org> Sender: linux-ide-owner@vger.kernel.org List-Id: linux-ide@vger.kernel.org To: Tejun Heo Cc: Ingo Molnar , "Ahmed S. Darwish" , "H. Peter Anvin" , Thomas Gleixner , Ingo Molnar , X86-ML , Tony Luck , Dave Jones , Andrew Morton , Randy Dunlap , Willy Tarreau , Willy Tarreau , Dirk Hohndel , Dirk.Hohndel@intel.com, IDE-ML , LKML , Linus Torvalds , Peter Zijlstra , Fr?d?ric Weisbecker , Borislav Petkov , Arjan van de Ven Hi! > > I think the biggest areas of practical concern would be: > > > > - Can this mechanism ever, under any circumstance corrupt any real > > data, destroy the MBR or do other nasties. Can you think of any > > additional fail-safe measures where you could _further robustify > > the BIOS calls_ to make sure it can never go to the wrong > > sector(s)? I really do not want to think of trusting a BIOS to > > _write to my disk_. > > It's quite unlikely but I wouldn't say it's completely impossible. > It's common for ATA controllers to have dual modes of operation - the > old IDE compatible interface by emulation which is used by BIOS and > older operating systems and newer interface (ahci) to be used by > modern OS. Some need to be explicitly switched and some just need to > be accessed carefully. If the controller is accessed by bIOS after > switched to ahci or commands are in progress via ahci, anything can > happen. Could we read the log area, first, verify it contains signature, write it back? Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html