From patchwork Thu Aug 6 15:03:43 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Magnus Damm X-Patchwork-Id: 39629 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n76F7lOw006908 for ; Thu, 6 Aug 2009 15:07:56 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750857AbZHFPHz (ORCPT ); Thu, 6 Aug 2009 11:07:55 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755709AbZHFPHz (ORCPT ); Thu, 6 Aug 2009 11:07:55 -0400 Received: from rv-out-0506.google.com ([209.85.198.226]:6688 "EHLO rv-out-0506.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750857AbZHFPHy (ORCPT ); Thu, 6 Aug 2009 11:07:54 -0400 Received: by rv-out-0506.google.com with SMTP id f6so171544rvb.1 for ; Thu, 06 Aug 2009 08:07:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:date:message-id :subject; bh=Rq1YLtlXskNsef3QvFJRHMMuCYZe9LJgU8W1coIXhJ0=; b=PdqjuNBdbCYo0C2uup938QnQ7jWVqw3im+2KcpJMqaoXNMRtCjSDHwAWcO/MCXq4QN WFi57k/PlAAP0WORDvQWzRfCARljb6MHoeImHPfJEzoxnvmwzG0N9rj3maZ1CfN3z8Qf 1VfjKGMJweUTQw90vdVkFo0QKODGGJ0truqk0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:date:message-id:subject; b=AhVMtbddwk81jyxqcePs3SHNqcZdEA0BRF7QeNYbXsDGfbed/N00RMJg3gGA13tA9f 6vyqkrrAJDvY+5dSozR+7N78p5AM0EWVzUEElKVOCuFaHX7IV249ArxrNOugwBAyq05v h22Tm9eBWOsCQLWp6JNhs4j6eVcNDH31xctg4= Received: by 10.140.166.8 with SMTP id o8mr6345371rve.203.1249571275129; Thu, 06 Aug 2009 08:07:55 -0700 (PDT) Received: from rx1.opensource.se (210.5.32.202.bf.2iij.net [202.32.5.210]) by mx.google.com with ESMTPS id c20sm354234rvf.51.2009.08.06.08.07.53 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 06 Aug 2009 08:07:54 -0700 (PDT) From: Magnus Damm To: linux-sh@vger.kernel.org Cc: Magnus Damm , lethal@linux-sh.org Date: Fri, 07 Aug 2009 00:03:43 +0900 Message-Id: <20090806150343.4770.1714.sendpatchset@rx1.opensource.se> Subject: [PATCH] sh: LED9, LED10 and LED11 support for Solution Engine 7724 Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org From: Magnus Damm This patch adds support for LED9, LED10 and LED11 on the Solution Engine 7724 board. If CONFIG_PM is enabled then these LEDs are used to show the hardware sleep mode used by the processor. Useful to debug cpuidle. Signed-off-by: Magnus Damm --- arch/sh/boards/mach-se/7724/setup.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- 0001/arch/sh/boards/mach-se/7724/setup.c +++ work/arch/sh/boards/mach-se/7724/setup.c 2009-08-05 15:22:48.000000000 +0900 @@ -429,6 +429,32 @@ static int __init devices_setup(void) /* turn on USB clocks, use external clock */ ctrl_outw((ctrl_inw(PORT_MSELCRB) & ~0xc000) | 0x8000, PORT_MSELCRB); +#ifdef CONFIG_PM + /* Let LED9 show STATUS2 */ + gpio_request(GPIO_FN_STATUS2, NULL); + + /* Lit LED10 show STATUS0 */ + gpio_request(GPIO_FN_STATUS0, NULL); + + /* Lit LED11 show PDSTATUS */ + gpio_request(GPIO_FN_PDSTATUS, NULL); +#else + /* Lit LED9 */ + gpio_request(GPIO_PTJ6, NULL); + gpio_direction_output(GPIO_PTJ6, 1); + gpio_export(GPIO_PTJ6, 0); + + /* Lit LED10 */ + gpio_request(GPIO_PTJ5, NULL); + gpio_direction_output(GPIO_PTJ5, 1); + gpio_export(GPIO_PTJ5, 0); + + /* Lit LED11 */ + gpio_request(GPIO_PTJ7, NULL); + gpio_direction_output(GPIO_PTJ7, 1); + gpio_export(GPIO_PTJ7, 0); +#endif + /* enable USB0 port */ ctrl_outw(0x0600, 0xa40501d4);