From patchwork Wed May 27 10:06:33 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Magnus Damm X-Patchwork-Id: 26418 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 n4RA8vkb022527 for ; Wed, 27 May 2009 10:09:45 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756567AbZE0KJm (ORCPT ); Wed, 27 May 2009 06:09:42 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1758598AbZE0KJm (ORCPT ); Wed, 27 May 2009 06:09:42 -0400 Received: from rv-out-0506.google.com ([209.85.198.225]:28594 "EHLO rv-out-0506.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756567AbZE0KJl (ORCPT ); Wed, 27 May 2009 06:09:41 -0400 Received: by rv-out-0506.google.com with SMTP id f9so1424878rvb.1 for ; Wed, 27 May 2009 03:09:43 -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 :in-reply-to:references:subject; bh=/z8JDZOTsv2TZYxNNoi+lR+ijqqTn26iVd4hlT2GTgY=; b=aPqnnPsT4FeZnVSzHjEUFQmnmvJjyYrxPTGdlw0kZxFIfGHJFq0EuxvwFlJYRty+df WjOnTJ57n1YAa4bhS/hkuBPw75sKOPfET/ulo3W65PusxrK3RYpwHq82IkRrPrL7bvZG IjaV7v7oI2c6SW4JVZ7jrQivyQS13d5v82Ogg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:date:message-id:in-reply-to:references:subject; b=xYPxE2mSQ6v4uBh1uJCpVBHTbZ7RS2p1aHwhsQv3Ng6Urp36cospOpBgCH3qghuSmH 50Ms1iCbXWtX0yDXP3ReqvE03GwGwmoVMW81Ep9NLoz3/aKTJxwmz87+V8ffNb2HqO0F GaUi++gUAOhZUpSnaXt6ycxD3ma/jQNfqJk8k= Received: by 10.140.141.16 with SMTP id o16mr3656114rvd.70.1243418983640; Wed, 27 May 2009 03:09:43 -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 f42sm2413813rvb.11.2009.05.27.03.09.41 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 27 May 2009 03:09:43 -0700 (PDT) From: Magnus Damm To: linux-pm@lists.linux-foundation.org Cc: paul@pwsan.com, linux-sh@vger.kernel.org, khilman@deeprootsystems.com, gregkh@suse.de, rjw@sisk.pl, lethal@linux-sh.org, stern@rowland.harvard.edu, Magnus Damm Date: Wed, 27 May 2009 19:06:33 +0900 Message-Id: <20090527100633.29671.83531.sendpatchset@rx1.opensource.se> In-Reply-To: <20090527100625.29671.43166.sendpatchset@rx1.opensource.se> References: <20090527100625.29671.43166.sendpatchset@rx1.opensource.se> Subject: [PATCH 01/04] Driver Core: Add platform device arch data Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org From: Magnus Damm Allow architecture specific data in struct platform_device. Platform device data is needed by the runtime pm code. A similar struct already exists for struct device. The architecture specific asm/device.h file needs to provide struct pdev_archdata if CONFIG_HAVE_PLATFORM_DEVICE_DATA is set. Signed-off-by: Magnus Damm --- Optionally we can make use of struct device archdata instead, but since the runtime device pm is limited to platform devices it makes sense to make this data platform device specific imo. arch/Kconfig | 3 +++ include/linux/platform_device.h | 5 +++++ 2 files changed, 8 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/Kconfig +++ work/arch/Kconfig 2009-05-15 14:51:35.000000000 +0900 @@ -112,3 +112,6 @@ config HAVE_DMA_API_DEBUG config HAVE_DEFAULT_NO_SPIN_MUTEXES bool + +config HAVE_PLATFORM_DEVICE_ARCHDATA + bool --- 0001/include/linux/platform_device.h +++ work/include/linux/platform_device.h 2009-05-15 16:59:01.000000000 +0900 @@ -23,6 +23,11 @@ struct platform_device { void *platform_data; struct platform_device_id *id_entry; + +#ifdef CONFIG_HAVE_PLATFORM_DEVICE_ARCHDATA + /* arch specific additions */ + struct pdev_archdata archdata; +#endif }; #define platform_get_device_id(pdev) ((pdev)->id_entry)