From patchwork Tue May 14 16:07:01 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Jean-Philippe_Fran=C3=83=C2=A7ois?= X-Patchwork-Id: 2568781 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) by patchwork2.kernel.org (Postfix) with ESMTP id 32719DF24C for ; Tue, 14 May 2013 21:31:19 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UcHv4-000758-B2; Tue, 14 May 2013 16:17:57 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UcHln-0002ox-PM; Tue, 14 May 2013 16:08:07 +0000 Received: from mail-wi0-x231.google.com ([2a00:1450:400c:c05::231]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UcHlf-0002oB-TP for linux-arm-kernel@lists.infradead.org; Tue, 14 May 2013 16:08:01 +0000 Received: by mail-wi0-f177.google.com with SMTP id hr14so664076wib.4 for ; Tue, 14 May 2013 09:07:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:from:to:cc:subject:date:message-id:x-mailer; bh=i/eb7a6Xok+qFTo2ZGjXMhDDn0okVldcJelvsOaFHdE=; b=n4zUt3AvLvh4+WlXUlIFsB/mDJz9zRmeFbQiPRgXXhhG0sZ/1JCxloGn2oKl1+SD/w ZLY8DfOaKaEaRljIYkkZtOcxuf3oBzNbE6PbCMFtG4lrCJ8lTgjiEDoDKl47tcJa1VIy ftmFVb7Xt/1WBUOWZ2FR0+P5mSFEcL0tC+3GyXlF4x61J/n2NbxB7KOBVknYbuhAbWNR KUQl74vCoLJO0f4a5tx5fXqv1NbsMM4bnSd5s9Vytjumb5/xemwKDdNiHDi+qi96Qb3X AkWrncai/w3bL1hI+JkXAoKqZsEGPl9Ut3T9ihcsvGSiVUnyyp364MzyytQjrMUBVOt/ Vvrw== X-Received: by 10.180.37.109 with SMTP id x13mr7767527wij.20.1368547657074; Tue, 14 May 2013 09:07:37 -0700 (PDT) Received: from localhost.localdomain (vil35-1-82-67-117-55.fbx.proxad.net. [82.67.117.55]) by mx.google.com with ESMTPSA id dq8sm24799434wib.1.2013.05.14.09.07.35 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 14 May 2013 09:07:36 -0700 (PDT) From: jp.francois@cynove.com To: khilman@linaro.org Subject: [PATCH] ARM : omap : remove __init for _enable_preprogram Date: Tue, 14 May 2013 18:07:01 +0200 Message-Id: <1368547621-8570-1-git-send-email-jp.francois@cynove.com> X-Mailer: git-send-email 1.7.0.4 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130514_120800_097681_61C35956 X-CRM114-Status: UNSURE ( 7.64 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (jphilippe.francois[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature Cc: paul@pwsan.com, linux-omap@vger.kernel.org, =?UTF-8?q?Jean-Philippe=20Fran=C3=A7ois?= , stable@vger.kernel.org, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org _enable_preprogram is marked as __init, but is called from _enable which is not. This results in oops once init is freed. Fix this by removing the __init marker. Signed-off-by: Jean-Philippe François Index: b/arch/arm/mach-omap2/omap_hwmod.c =================================================================== --- a/arch/arm/mach-omap2/omap_hwmod.c +++ b/arch/arm/mach-omap2/omap_hwmod.c @@ -2066,7 +2066,7 @@ * do so is present in the hwmod data, then call it and pass along the * return value; otherwise, return 0. */ -static int __init _enable_preprogram(struct omap_hwmod *oh) +static int _enable_preprogram(struct omap_hwmod *oh) { if (!oh->class->enable_preprogram) return 0;