From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mika Westerberg Subject: Re: [PATCH] i2c: Not all adapters have a parent Date: Thu, 10 Oct 2013 09:15:34 +0300 Message-ID: <20131010061534.GC3521@intel.com> References: <20131010080406.3e0fd78e@endymion.delvare> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <20131010080406.3e0fd78e-R0o5gVi9kd7kN2dkZ6Wm7A@public.gmane.org> Sender: linux-i2c-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Jean Delvare Cc: Linux I2C , Wolfram Sang , "Rafael J. Wysocki" List-Id: linux-i2c@vger.kernel.org On Thu, Oct 10, 2013 at 08:04:06AM +0200, Jean Delvare wrote: > The code in acpi_i2c_register_devices() assumes that all i2c adapters > have a parent. This is not necessarily the case, for example the > i2c-stub driver instantiate a virtual i2c adapter without a parent. > Check for this to avoid a NULL pointer deference. > > Signed-off-by: Jean Delvare > Cc: Wolfram Sang > Cc: Mika Westerberg > Cc: "Rafael J. Wysocki" Oh, I didn't know that. Thanks for the information. Acked-by: Mika Westerberg Probably should go to stable as well.