From patchwork Mon Dec 4 13:16:48 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Alexey Brodkin X-Patchwork-Id: 844236 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=65.50.211.133; helo=bombadil.infradead.org; envelope-from=linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="YsIJJIwv"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3yr55C6CGyz9sRV for ; Tue, 5 Dec 2017 00:17:19 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-ID:In-Reply-To: References:Message-ID:Date:Subject:To:From:Reply-To:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ofW6YQ5Q13OS8868H0Tj2XkmM5DLMMVKgWKyr9Sx0oo=; b=YsIJJIwvU9a5aJ fuxeI86cvcGp21IWhmzH2LTezCgVqiyue7iAoAUwOyg0aPxXep41FiMJm+D2AhlWZ0AoOQSkn4mcB w47XmsL8uuR07lHS7Dx+oYCmlYC6nLwMKESmQU2YkYUrPcZFKGdqEdKcieialt2WJqCWH0+/W8OsH /dyrqVezkonwVHieVHuKuZnEcfM90hfdmZagGCaez1cSc0bfatfJPOkBonWFUQSxVhLX9emwb0yyK 8T+xeHmw+XmybJCcn1JpQY4NTD080YvRAeingMJugl4gzdv4MGHidA3UAaRkIu//awWcW48lYIiTa kJ5ljaoqqGY5ZY8RjdXw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1eLqcY-0003m8-Ap; Mon, 04 Dec 2017 13:17:18 +0000 Received: from us01smtprelay-2.synopsys.com ([198.182.47.9] helo=smtprelay.synopsys.com) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eLqcU-0003jo-82 for linux-snps-arc@lists.infradead.org; Mon, 04 Dec 2017 13:17:16 +0000 Received: from mailhost.synopsys.com (mailhost1.synopsys.com [10.12.238.239]) by smtprelay.synopsys.com (Postfix) with ESMTP id BC1DC24E0506; Mon, 4 Dec 2017 05:16:52 -0800 (PST) Received: from mailhost.synopsys.com (localhost [127.0.0.1]) by mailhost.synopsys.com (Postfix) with ESMTP id 41EA8E64; Mon, 4 Dec 2017 05:16:52 -0800 (PST) Received: from US01WEHTC2.internal.synopsys.com (us01wehtc2-vip.internal.synopsys.com [10.12.239.238]) by mailhost.synopsys.com (Postfix) with ESMTP id 02041E63; Mon, 4 Dec 2017 05:16:51 -0800 (PST) Received: from DE02WEHTCA.internal.synopsys.com (10.225.19.92) by US01WEHTC2.internal.synopsys.com (10.12.239.237) with Microsoft SMTP Server (TLS) id 14.3.266.1; Mon, 4 Dec 2017 05:16:51 -0800 Received: from DE02WEMBXB.internal.synopsys.com ([fe80::95ce:118a:8321:a099]) by DE02WEHTCA.internal.synopsys.com ([::1]) with mapi id 14.03.0266.001; Mon, 4 Dec 2017 14:16:49 +0100 From: Alexey Brodkin To: "l.stach@pengutronix.de" , Jose Abreu Subject: xf86-video-armada via UDL [was: Re: UDL's fbdev doesn't work for user-space apps] Thread-Topic: xf86-video-armada via UDL [was: Re: UDL's fbdev doesn't work for user-space apps] Thread-Index: AQHTbQIkipqBBGWFjUqX7bL3/pGn2w== Date: Mon, 4 Dec 2017 13:16:48 +0000 Message-ID: <1512393408.4977.44.camel@synopsys.com> References: <1512387175.4977.24.camel@synopsys.com> <86238def-82be-2ad1-63d0-b9a8dbf83db6@synopsys.com> In-Reply-To: <86238def-82be-2ad1-63d0-b9a8dbf83db6@synopsys.com> Accept-Language: en-US, ru-RU Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.225.15.245] Content-ID: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171204_051714_338351_03602138 X-CRM114-Status: GOOD ( 14.16 ) X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [198.182.47.9 listed in list.dnswl.org] -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -0.0 RCVD_IN_MSPIKE_H4 RBL: Very Good reputation (+4) [198.182.47.9 listed in wl.mailspike.net] -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.0 RCVD_IN_MSPIKE_WL Mailspike good senders X-BeenThere: linux-snps-arc@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux on Synopsys ARC Processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "daniel.vetter@ffwll.ch" , "linux-kernel@vger.kernel.org" , "dri-devel@lists.freedesktop.org" , "airlied@redhat.com" , "linux-snps-arc@lists.infradead.org" , "airlied@gmail.com" Sender: "linux-snps-arc" Errors-To: linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Hi Jose, On Mon, 2017-12-04 at 11:50 +0000, Jose Abreu wrote: > Hi Alexey, > > On 04-12-2017 11:32, Alexey Brodkin wrote: > > > > My first [probably incorrect] assumption is Xserver requires fbdev (/dev/fbX) > > and it cannot use DRI video card natively. Is that correct? > > > > > > Xserver can use DRI directly, you need to enable modesetting > driver in Xorg config or use the designated driver for your card > (if there is any). Ok that makes sense. I didn't think about generic modesetting driver for Xserver. And that indeed works. This is my xorg.conf: ----------------------->8---------------------- # cat /etc/X11/xorg.conf  Section "Device"         Identifier      "Driver0"         Screen          0         Driver          "modesetting"         Option          "kmsdev" "/dev/dri/card1" EndSection ----------------------->8---------------------- I do see xclock is rendered fine. Now I guess is getting closer to what I really need :) In the end I wanted to get 3D rendered by Vivante GPU to be displayed on UDL. My assumption was very simple - if IMX-DRM+Etnaviv work fine it should be straight-forward to swap IMX-DRM bitstreamer with UDL and we're golden. That might be more a question to Lucas now. I use xorg.conf as found here: http://git.arm.linux.org.uk/cgit/xf86-video-armada.git/tree/conf/xorg-sample.conf?h=unstable-devel That's what it has: ----------------------->8---------------------- Section "Device" Identifier "Driver0" Screen 0 Driver "armada" # Support hotplugging displays? # Option "Hotplug" "TRUE" # Support hardware cursor if available? # Option "HWCursor" "TRUE" # Use GPU acceleration? # Option "UseGPU" "TRUE" # Provide Xv interfaces? # Option "XvAccel" "TRUE" # Prefer overlay for Xv (TRUE for armada-drm, FALSE for imx-drm) # Option "XvPreferOverlay" "TRUE" # Which accelerator module to load (automatically found if commented out) # Option "AccelModule" "etnadrm_gpu" # Option "AccelModule" "etnaviv_gpu" # Support DRI2 interfaces? # Option "DRI" "TRUE" EndSection ----------------------->8---------------------- Indeed I uncommented all the lines and then it allows to see for example glmark2-es2 working on Wandboard (that's exactly where "imx-drm + etnaviv" combo is used). But if I swap "imx-drm" to "udl" I don't see anything on my screen (connected via UDL) even though Xserver seems to really start claiming the screen (so I see it becomes black, effectively overriding whatever was there before) and glmark benchmark prints results. Maybe I'm missing some additional glue for UDL in "xf86-video-armada" except the simple one: ----------------------->8---------------------- linux-snps-arc mailing list linux-snps-arc@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-snps-arc --- a/src/armada_module.c +++ b/src/armada_module.c @@ -26,7 +26,7 @@  #define ARMADA_NAME            "armada"  #define ARMADA_DRIVER_NAME     "armada"   -#define DRM_MODULE_NAMES       "armada-drm", "imx-drm" +#define DRM_MODULE_NAMES       "armada-drm", "imx-drm", "udl"  #define DRM_DEFAULT_BUS_ID     NULL    static const char *drm_module_names[] = { DRM_MODULE_NAMES }; @@ -43,6 +43,11 @@ static SymTabRec ipu_chipsets[] = {         { -1, NULL }  };   +static SymTabRec udl_chipsets[] = { +       {  0, "UDL" }, +       { -1, NULL } +}; +  static const OptionInfoRec * const options[] = {         armada_drm_options,         common_drm_options, @@ -115,6 +120,8 @@ static void armada_identify(int flags)                           armada_chipsets);         xf86PrintChipsets(ARMADA_NAME, "Support for Freescale IPU",                           ipu_chipsets); +       xf86PrintChipsets(ARMADA_NAME, "Support DisplayLink USB2.0", +                         udl_chipsets);  } ----------------------->8---------------------- -Alexey _______________________________________________