Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753104AbbH2AAo (ORCPT ); Fri, 28 Aug 2015 20:00:44 -0400 Received: from mail-ob0-f176.google.com ([209.85.214.176]:32896 "EHLO mail-ob0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752850AbbH2AAn (ORCPT ); Fri, 28 Aug 2015 20:00:43 -0400 MIME-Version: 1.0 In-Reply-To: <20150827165909.GA5506@goodgumbo.baconseed.org> References: <20150827165909.GA5506@goodgumbo.baconseed.org> Date: Fri, 28 Aug 2015 17:00:42 -0700 Message-ID: Subject: Re: [PATCH 2/6] input: pwm-beeper: Fix module autoload for OF platform driver From: Dmitry Torokhov To: Luis de Bethencourt Cc: lkml , Jingoo Han , Wolfram Sang , Olivier Sobrie , "linux-input@vger.kernel.org" , Javier Martinez Canillas Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1259 Lines: 42 Hi Luis, On Thu, Aug 27, 2015 at 9:59 AM, Luis de Bethencourt wrote: > This platform driver has a OF device ID table but the OF module > alias information is not created so module autoloading won't work. > > Signed-off-by: Luis de Bethencourt > --- > drivers/input/misc/pwm-beeper.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/input/misc/pwm-beeper.c b/drivers/input/misc/pwm-beeper.c > index e82edf8..a02b9a4 100644 > --- a/drivers/input/misc/pwm-beeper.c > +++ b/drivers/input/misc/pwm-beeper.c > @@ -175,6 +175,8 @@ static const struct of_device_id pwm_beeper_match[] = { > }; > #endif > > +MODULE_DEVICE_TABLE(of, pwm_beeper_match); > + I'm fairly certain this (ano others) blow up in case of !CONFIG_OF. Please bring MODULE_DEVICE_TABLE into #ifdef block above. > static struct platform_driver pwm_beeper_driver = { > .probe = pwm_beeper_probe, > .remove = pwm_beeper_remove, > -- > 2.4.6 > Thanks. -- Dmitry -- 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/