From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755237Ab2AODg4 (ORCPT ); Sat, 14 Jan 2012 22:36:56 -0500 Received: from netrider.rowland.org ([192.131.102.5]:46257 "HELO netrider.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1753517Ab2AODgy (ORCPT ); Sat, 14 Jan 2012 22:36:54 -0500 Date: Sat, 14 Jan 2012 22:36:53 -0500 (EST) From: Alan Stern X-X-Sender: stern@netrider.rowland.org To: Greg KH cc: Tony Luck , Linus Torvalds , "Srivatsa S. Bhat" , Ming Lei , Djalal Harouni , Borislav Petkov , Hidetoshi Seto , Ingo Molnar , Andi Kleen , , Kay Sievers , , Marcos Souza , Linux PM mailing list , "Rafael J. Wysocki" , "tglx@linutronix.de" , , , Jeff Chua , Suresh B Siddha , Peter Zijlstra , Mel Gorman , Gilad Ben-Yossef Subject: Re: x86/mce: machine check warning during poweroff In-Reply-To: <20120115023404.GA4268@suse.de> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 14 Jan 2012, Greg KH wrote: > On Sat, Jan 14, 2012 at 06:05:24PM -0800, Tony Luck wrote: > > On Sat, Jan 14, 2012 at 8:30 AM, Alan Stern wrote: > > > The driver core isn't designed to handle device structures that get > > > unregistered and then spring back to life; callers are supposed to > > > allocate a fresh new structure instead. > > > > Does every caller use "kzalloc()" for this fresh new structure (or even > > for the original registration) rather than "kmalloc()"? > > They better, as that's what they are required to do :) > > The kernel would be crashing with slab debugging enabled, if it wasn't > so today. These are both important restrictions on the use of the driver core, and they don't seem to be explained anywhere in the kernel source. Would you like to receive a documentation patch? Alan Stern