Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933450AbYBMQv4 (ORCPT ); Wed, 13 Feb 2008 11:51:56 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1758887AbYBMQvo (ORCPT ); Wed, 13 Feb 2008 11:51:44 -0500 Received: from bzq-219-195-70.pop.bezeqint.net ([62.219.195.70]:46665 "EHLO bh-buildlin2.bhalevy.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1760558AbYBMQvm (ORCPT ); Wed, 13 Feb 2008 11:51:42 -0500 Message-ID: <47B31FC2.4040206@panasas.com> Date: Wed, 13 Feb 2008 18:50:10 +0200 From: Boaz Harrosh User-Agent: Thunderbird 2.0.0.9 (X11/20071031) MIME-Version: 1.0 To: James Bottomley CC: =?UTF-8?B?U3ZlbiBLw7ZobGVy?= , Christoph Hellwig , Jeff Garzik , linux-scsi , linux-kernel@vger.kernel.org, Joerg Dorchain , Jon Chelton , Stefan Priebe - allied internet ag Subject: Re: [BUGFIX 2/2] gdth: bugfix for the Timer at exit crash References: <47A19E26.30107@panasas.com> <47B1D7A8.8010108@panasas.com> <47B1DA2A.1060904@panasas.com> <1202917468.3109.5.camel@localhost.localdomain> <47B312B3.3010200@panasas.com> <47B31BDE.2030408@panasas.com> <1202921122.3109.31.camel@localhost.localdomain> In-Reply-To: <1202921122.3109.31.camel@localhost.localdomain> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1781 Lines: 47 On Wed, Feb 13 2008 at 18:45 +0200, James Bottomley wrote: > On Wed, 2008-02-13 at 18:33 +0200, Boaz Harrosh wrote: >> On Wed, Feb 13 2008 at 17:54 +0200, Boaz Harrosh wrote: >>> On Wed, Feb 13 2008 at 17:44 +0200, James Bottomley wrote: >>>> On Tue, 2008-02-12 at 19:40 +0200, Boaz Harrosh wrote: >>>>> - gdth_flush(ha); >>>>> - >>>> This piece doesn't look right. gdth_flush() forces the internal cache >>>> to disk backing. If you remove it, you're taking the chance that the >>>> machine will be powered off without a writeback which can cause data >>>> corruption. >>>> >>>> James >>>> >>> Yes. >>> I have more problems reported, with exit, and am just sending one more patch that puts >>> this back in. Which was tested. >>> >>> So I will resend this one plus one new one. >>> >>> Boaz >>> >> The gdth driver would do a register_reboot_notifier(&gdth_notifier); >> to a gdth_halt() function, which would then redo half of what gdth_exit >> does, and wrongly so, and crash. >> >> Are we guaranteed in todays kernel that modules .exit function be called >> on an halt or reboot? If so then there is no need for duplications and >> the gdth_halt() should go. > > No. The __exit section is actually discardable if you promise never to > remove the module. > I don't understand please explain. What does a driver need to do if it needs a consistent shutdown retine? module or built in? unload or shutdown? > James > > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/