Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp2475903imm; Mon, 28 May 2018 08:48:35 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqnQJFdkGVFQoAcfl22Wg+1DgxuVJ88pxOKCprtVhkJNO0lNNWelYkqdvW4eZJ5LVcTLZhO X-Received: by 2002:a17:902:b60b:: with SMTP id b11-v6mr14358700pls.330.1527522515626; Mon, 28 May 2018 08:48:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527522515; cv=none; d=google.com; s=arc-20160816; b=CrlLaQ+z4OrZ3k5tKrlXEJY3s90KN8vFsKdIjJlxHBgrXzOMcL7aFroSoIToWalLk2 nasog/Mhm3rNaqQ+sxFyDbD3pHOuuW7qS4GXoZmLj9ELdAthIPamhGF0SP5j2fufet0d DvWVyEBSlcS1w8bAh1z5EBWq6Z5wdinP1sJaSlhWB4v85ZbugUrOpHWYNgPKEgHWZcaO s/c5hxDD0OsVpxMvt0lbGUHPeyiPdGCmqD4gx1aAAs6PKvFcYgKirQub8Ux8kO/aM4PM VqIGc/iHSSxq0mdNY7Xavl2P+jHD4vqva/szYp6hLirlkPdctuNCp/JczVxXYMsuzxNW zS1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=dgFsD8kQDko0gGC9EBXdKRyTGDixetPauR8pH/OxL0E=; b=MbQwYpKuLDSTL7s+TwBAj3BTlcWFY22t8DPXTbvXfJXzVgKGJCrps1slrQQke5zN45 sf7FMoMIPgke4xtetGSCiucrJuKuK1qTz8EXj24NwYRu3RMmmQCEKvxVDbsGpCG9mVuv hKFGBWTCFgdF2FeM6slTDaK3+ylBRdqXRzcKg8jCjsTnlaVJnVcV5crNdhT0sfNxKTyH TJfrIL6rXP750ubRhgWz4t0BkpfpIsy4IRF7j2qzlI1EnHK/tfJtpLpupcL0oxr54fET LqN5iZJxB0aO4OExM2uqW5tjMeEu+hMPT7M8f7D088Bvr+pMTz1yCvawRyruGEqlv9G+ s3MA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=uVkmV3JA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w23-v6si14271478ply.563.2018.05.28.08.48.20; Mon, 28 May 2018 08:48:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=uVkmV3JA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S968541AbeE1KQj (ORCPT + 99 others); Mon, 28 May 2018 06:16:39 -0400 Received: from mail.kernel.org ([198.145.29.99]:36690 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S968516AbeE1KQd (ORCPT ); Mon, 28 May 2018 06:16:33 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9C5C1206B7; Mon, 28 May 2018 10:16:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1527502593; bh=nlkDnhneFfBAVkK+v7cMHQ0fNFWzRY6to3BTlGdZBhk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uVkmV3JAfPpCBiCjqiwU5Gw3hykyE8cDjuG0S5uRZdZB401RrJjZcDvT+rCndwb9L JaUIfJqXFLeGdLR+scMGc4wIdfS28NZWoK0TJBjGMcNExn/9cPr3zgf3thbk+oFmNG ZAd0Dggg+/nwkSI3+mhsV/1neY8ywX05cbLmsh7Q= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Matt Redfearn , James Hogan , Ralf Baechle , linux-mips@linux-mips.org, Sasha Levin Subject: [PATCH 4.4 058/268] MIPS: TXx9: use IS_BUILTIN() for CONFIG_LEDS_CLASS Date: Mon, 28 May 2018 12:00:32 +0200 Message-Id: <20180528100208.545896683@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180528100202.045206534@linuxfoundation.org> References: <20180528100202.045206534@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.4-stable review patch. If anyone has any objections, please let me know. ------------------ From: Matt Redfearn [ Upstream commit 0cde5b44a30f1daaef1c34e08191239dc63271c4 ] When commit b27311e1cace ("MIPS: TXx9: Add RBTX4939 board support") added board support for the RBTX4939, it added a call to led_classdev_register even if the LED class is built as a module. Built-in arch code cannot call module code directly like this. Commit b33b44073734 ("MIPS: TXX9: use IS_ENABLED() macro") subsequently changed the inclusion of this code to a single check that CONFIG_LEDS_CLASS is either builtin or a module, but the same issue remains. This leads to MIPS allmodconfig builds failing when CONFIG_MACH_TX49XX=y is set: arch/mips/txx9/rbtx4939/setup.o: In function `rbtx4939_led_probe': setup.c:(.init.text+0xc0): undefined reference to `of_led_classdev_register' make: *** [Makefile:999: vmlinux] Error 1 Fix this by using the IS_BUILTIN() macro instead. Fixes: b27311e1cace ("MIPS: TXx9: Add RBTX4939 board support") Signed-off-by: Matt Redfearn Reviewed-by: James Hogan Cc: Ralf Baechle Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/18544/ Signed-off-by: James Hogan Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- arch/mips/txx9/rbtx4939/setup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/arch/mips/txx9/rbtx4939/setup.c +++ b/arch/mips/txx9/rbtx4939/setup.c @@ -186,7 +186,7 @@ static void __init rbtx4939_update_ioc_p #define RBTX4939_MAX_7SEGLEDS 8 -#if IS_ENABLED(CONFIG_LEDS_CLASS) +#if IS_BUILTIN(CONFIG_LEDS_CLASS) static u8 led_val[RBTX4939_MAX_7SEGLEDS]; struct rbtx4939_led_data { struct led_classdev cdev; @@ -261,7 +261,7 @@ static inline void rbtx4939_led_setup(vo static void __rbtx4939_7segled_putc(unsigned int pos, unsigned char val) { -#if IS_ENABLED(CONFIG_LEDS_CLASS) +#if IS_BUILTIN(CONFIG_LEDS_CLASS) unsigned long flags; local_irq_save(flags); /* bit7: reserved for LED class */