From mboxrd@z Thu Jan 1 00:00:00 1970 From: Archit Taneja Date: Fri, 28 Sep 2012 11:12:21 +0000 Subject: Re: [PATCH 1/6] OMAPDSS: add omapdss_version Message-Id: <50658345.5050403@ti.com> List-Id: References: <1348828527-13309-1-git-send-email-tomi.valkeinen@ti.com> <1348828527-13309-2-git-send-email-tomi.valkeinen@ti.com> In-Reply-To: <1348828527-13309-2-git-send-email-tomi.valkeinen@ti.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Tomi Valkeinen Cc: linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org, Chandrabhanu Mahapatra , =?ISO-8859-1?Q?Rapha=EBl_Ass=E9nat?= , Tony Lindgren On Friday 28 September 2012 04:05 PM, Tomi Valkeinen wrote: > Add new enum, omapdss_version, that is used to tell which DSS hardware > version the SoC has. This enum is initialized during platform init, and > passed in the platform data to omapdss driver. > > Note that the versions are not "continuous", that is, you cannot check > if the version is less or greater than something, but you need to check > for exact version match. In other words, this is invalid: > > /* test if DSS is 3630 or earlier */ > if (ver <= OMAPDSS_VER_OMAP3630) > ... > > Signed-off-by: Tomi Valkeinen > --- > arch/arm/mach-omap2/display.c | 38 ++++++++++++++++++++++++++++++++++++++ > include/video/omapdss.h | 14 ++++++++++++++ > 2 files changed, 52 insertions(+) > > diff --git a/arch/arm/mach-omap2/display.c b/arch/arm/mach-omap2/display.c > index ee40739..33555da 100644 > --- a/arch/arm/mach-omap2/display.c > +++ b/arch/arm/mach-omap2/display.c > @@ -284,6 +284,35 @@ err: > return ERR_PTR(r); > } > > +static enum omapdss_version omap_display_get_version(void) We could add a __init for this function? Archit