From: Tomi Valkeinen Subject: Re: [PATCH v3 2/2] OMAP: DSS2: Use dss_features framework on DSS2 code Date: Wed, 15 Sep 2010 11:31:01 +0300 Message-ID: <1284539461.2522.117.camel@tubuntu.research.nokia.com> References: <1284355810-20899-1-git-send-email-archit@ti.com> <1284355810-20899-3-git-send-email-archit@ti.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: Received: from smtp.nokia.com ([147.243.1.47]:35732 "EHLO mgw-sa01.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752517Ab0IOIbI (ORCPT ); Wed, 15 Sep 2010 04:31:08 -0400 In-Reply-To: <1284355810-20899-3-git-send-email-archit@ti.com> Sender: linux-omap-owner@vger.kernel.org List-Id: linux-omap@vger.kernel.org To: ext Archit Taneja Cc: "linux-omap@vger.kernel.org" On Mon, 2010-09-13 at 07:30 +0200, ext Archit Taneja wrote: > Calls init functions of dss_features during dss_probe, and the following > features are made omapxxxx independent: > - number of managers, overlays > - supported color modes for each overlay > - supported displays for each manager > - global aplha, and restriction of global alpha for video1 pipeline > - The register field ranges : FIRHINC, FIRVINC, FIFOHIGHTHRESHOLD > FIFOLOWTHRESHOLD and FIFOSIZE > > Signed-off-by: Archit Taneja > --- > arch/arm/plat-omap/include/plat/display.h | 31 ---------------- > drivers/video/omap2/dss/core.c | 3 ++ > drivers/video/omap2/dss/dispc.c | 56 ++++++++++++++++------------- > drivers/video/omap2/dss/manager.c | 33 ++++++++--------- > drivers/video/omap2/dss/overlay.c | 24 +++++------- > 5 files changed, 60 insertions(+), 87 deletions(-) snip > static void _dispc_setup_global_alpha(enum omap_plane plane, u8 global_alpha) > { > - > - BUG_ON(plane == OMAP_DSS_VIDEO1); > - > - if (cpu_is_omap24xx()) > + if (!dss_has_feature(FEAT_GLOBAL_ALPHA)) > return; > > + BUG_ON(!dss_has_feature(FEAT_GLOBAL_ALPHA_VID1) && > + plane == OMAP_DSS_VIDEO1); > + > if (plane == OMAP_DSS_GFX) > REG_FLD_MOD(DISPC_GLOBAL_ALPHA, global_alpha, 7, 0); > else if (plane == OMAP_DSS_VIDEO2) > @@ -949,17 +950,14 @@ static void dispc_read_plane_fifo_sizes(void) > DISPC_VID_FIFO_SIZE_STATUS(1) }; > u32 size; > int plane; > + u8 size1, size2; You have a bit inconsistent naming with these. The function is defined as accepting start and end, here you use size1 and size2, below you have foo1 and foo2. Size is not a good name, as it's not size at all. Perhaps foo_start and foo_end (or just start and end if there's only one feat being used)? Or foo_msb and foo_lsb (as in most/least significant bit)? Otherwise looks good. Tomi