[{"id":1761541,"web_url":"http://patchwork.ozlabs.org/comment/1761541/","msgid":"<CAKv+Gu84njSF5uOvNtknGdOd5auU7zw9scFeTq5v-=OhExgOqA@mail.gmail.com>","date":"2017-09-01T09:21:28","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":26857,"url":"http://patchwork.ozlabs.org/api/people/26857/","name":"Ard Biesheuvel","email":"ard.biesheuvel@linaro.org"},"content":"On 1 September 2017 at 08:27, Daniel Axtens <dja@axtens.net> wrote:\n> This patch set:\n>\n>  - splits the default display handling out from VGA arbiter, into its\n>    own file and behind its own Kconfig option (and gives the functions\n>    better names).\n>\n>  - adds extra detection of default devices. To be nominated, the vga\n>    arbiter and platform hooks must not have nominated a default. A\n>    card will then only be nominated if it has a driver attached and\n>    has IO or memory decoding enabled.\n>\n>  - adds relevant documentation.\n>\n> The practical impact of this is improved X autoconfiguration on some\n> arm64 systems.\n>\n> Changes in v3:\n>\n>  - Add documentation - thanks Daniel Vetter for pointing it out.\n>\n>  - Clarify explanations. Thanks to everyone for continuing to bear\n>    with my incomplete understanding of PCI and provide some clarity.\n>\n>  - Split refactoring and adding functionality.\n>\n> Changes in v2: https://www.spinics.net/lists/linux-pci/msg64007.html\n>\n> Drop all the powerpc patches. [explanation snipped]\n>\n> v1: https://www.spinics.net/lists/linux-pci/msg63581.html\n>\n\nIf we are all in agreement that fixing X is not an option, I think\nthis is a reasonable approach\n\nAcked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xkDLB3KBDz9s7C\n\tfor <patchwork-incoming@ozlabs.org>;\n\tFri,  1 Sep 2017 19:22:58 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3xkDLB28TNzDqnm\n\tfor <patchwork-incoming@ozlabs.org>;\n\tFri,  1 Sep 2017 19:22:58 +1000 (AEST)","from mail-io0-x22d.google.com (mail-io0-x22d.google.com\n\t[IPv6:2607:f8b0:4001:c06::22d])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3xkDJW0z0BzDqZ1\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tFri,  1 Sep 2017 19:21:31 +1000 (AEST)","by mail-io0-x22d.google.com with SMTP id b2so13247167iof.0\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tFri, 01 Sep 2017 02:21:31 -0700 (PDT)","by 10.107.162.1 with HTTP; Fri, 1 Sep 2017 02:21:28 -0700 (PDT)"],"Authentication-Results":["ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=linaro.org header.i=@linaro.org\n\theader.b=\"LX2pt3Hp\"; dkim-atps=neutral","lists.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=linaro.org header.i=@linaro.org\n\theader.b=\"LX2pt3Hp\"; dkim-atps=neutral","lists.ozlabs.org; dkim=pass (1024-bit key;\n\tunprotected) header.d=linaro.org header.i=@linaro.org\n\theader.b=\"LX2pt3Hp\"; dkim-atps=neutral"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google;\n\th=mime-version:in-reply-to:references:from:date:message-id:subject:to\n\t:cc; bh=vUu84/h/jvtCItaGwo1bc5wC7lcY/Sh/FYatpb3W5IU=;\n\tb=LX2pt3HpWW4ieJq0Quy+9dCS4JRP3kDHv1UBqMlco+SGlzCRw6t3ywr64J8ayjFmaQ\n\thMi/M71fi9XCoxqnu2EGpjHVeO/5hT8VEzgO1OC8zoYGLK1D/f6Gd+UuNXgbPtZ15gSI\n\tjOEzQuOrbCcb+3yKSsbayDB44mFD6zqiS1coY=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:mime-version:in-reply-to:references:from:date\n\t:message-id:subject:to:cc;\n\tbh=vUu84/h/jvtCItaGwo1bc5wC7lcY/Sh/FYatpb3W5IU=;\n\tb=Hg7zsizKcOkm+2W325xyCuHyOzFgc7WDTBhiPBmufU64v8kyxSh+lOQ3NBPeMdXuJ2\n\tCoc1+5uFRN6DYLiYU4dpZS442GeNGAtSfHT6eQS100crrmR4WvapiPuYrERoGMGdQwRF\n\t4fuyJyFbpG/x4+6a3u3oRUxAsdR8rQRi4Hm9CZx4f7CtlFaLjyXWKyMJlhnzgvKo2zRt\n\tw0CgZ74tpWjqqCYc5cHsCBA34JYSKdD7PNs7adrqeK0Z68EzgGGYgCUfcBBBkkQJZyx+\n\t9MitBFenXxQPndVZJbbyM/PvxEdte6s/3lMr7Qpiz4T3aJE9jPSKmRnfqCRQBjJDZXww\n\t/Wkw==","X-Gm-Message-State":"AHPjjUgDnkjOUscKSbEJ5Pw6y5Qkq+JjHiH2FDmrFwGyJtNpEH2RkFHB\n\taw1QGOIKGO148KUD+DROJV6U8AP47mlh","X-Google-Smtp-Source":"ADKCNb4iKKv5ao+lHVeCqJiTNjesZPYM/oP+erkLwKZ6hGQLVGPEd2xVZkVmmcgf3TieP27Fcp8VlmLHLmS4//zv4To=","X-Received":"by 10.107.157.78 with SMTP id g75mr939055ioe.190.1504257689324; \n\tFri, 01 Sep 2017 02:21:29 -0700 (PDT)","MIME-Version":"1.0","In-Reply-To":"<20170901072744.2409-1-dja@axtens.net>","References":"<20170901072744.2409-1-dja@axtens.net>","From":"Ard Biesheuvel <ard.biesheuvel@linaro.org>","Date":"Fri, 1 Sep 2017 10:21:28 +0100","Message-ID":"<CAKv+Gu84njSF5uOvNtknGdOd5auU7zw9scFeTq5v-=OhExgOqA@mail.gmail.com>","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","To":"Daniel Axtens <dja@axtens.net>","Content-Type":"text/plain; charset=\"UTF-8\"","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.23","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>,\n\tCatalin Marinas <catalin.marinas@arm.com>,\n\tGabriele Paoloni <gabriele.paoloni@huawei.com>,\n\tDavid Airlie <airlied@linux.ie>, linux-pci <linux-pci@vger.kernel.org>,\n\tWill Deacon <will.deacon@arm.com>,\n\tdri-devel <dri-devel@lists.freedesktop.org>, \n\t\"Liuxinliang \\(Matthew Liu\\)\" <z.liuxinliang@hisilicon.com>,\n\tAlex Williamson <alex.williamson@redhat.com>,\n\tLukas Wunner <lukas@wunner.de>, Bjorn Helgaas <helgaas@kernel.org>,\n\tZou Rongrong <zourongrong@gmail.com>, \n\t\"Vetter, Daniel\" <daniel.vetter@intel.com>,\n\tlinuxppc-dev <linuxppc-dev@lists.ozlabs.org>,\n\t\"linux-arm-kernel@lists.infradead.org\"\n\t<linux-arm-kernel@lists.infradead.org>","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}},{"id":1761606,"web_url":"http://patchwork.ozlabs.org/comment/1761606/","msgid":"<877exi4pqs.fsf@linkitivity.dja.id.au>","date":"2017-09-01T11:34:03","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":65792,"url":"http://patchwork.ozlabs.org/api/people/65792/","name":"Daniel Axtens","email":"dja@axtens.net"},"content":"Hi Ard,\n\n> If we are all in agreement that fixing X is not an option, I think\n> this is a reasonable approach\n\nThis did come up in discussion at some earlier point in one of the many\nspins we've done of this - I don't remember if you brought it up or\nsomeone else did - but my concern was this: If it were just X we would\nbe fine, but if we go down that path I'm worried about also having to\nfix Mir/Wayland/whatever-the-new-exciting-display-server-is-this-week,\nad nauseum.\n\n> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>\n\nThanks!\n\nRegards,\nDaniel","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xkHJr2pXzz9sRV\n\tfor <patchwork-incoming@ozlabs.org>;\n\tFri,  1 Sep 2017 21:37:00 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3xkHJr1RzzzDqjy\n\tfor <patchwork-incoming@ozlabs.org>;\n\tFri,  1 Sep 2017 21:37:00 +1000 (AEST)","from mail-pf0-x22c.google.com (mail-pf0-x22c.google.com\n\t[IPv6:2607:f8b0:400e:c00::22c])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3xkHFZ1c8yzDqfx\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tFri,  1 Sep 2017 21:34:10 +1000 (AEST)","by mail-pf0-x22c.google.com with SMTP id g13so7404444pfm.2\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tFri, 01 Sep 2017 04:34:10 -0700 (PDT)","from localhost (124-171-202-56.dyn.iinet.net.au. [124.171.202.56])\n\tby smtp.gmail.com with ESMTPSA id\n\ti186sm3396283pfg.81.2017.09.01.04.34.06\n\t(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);\n\tFri, 01 Sep 2017 04:34:07 -0700 (PDT)"],"Authentication-Results":["ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"jpF9V08N\"; dkim-atps=neutral","lists.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"jpF9V08N\"; dkim-atps=neutral","lists.ozlabs.org; dkim=pass (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"jpF9V08N\"; dkim-atps=neutral"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=axtens.net; s=google;\n\th=from:to:cc:subject:in-reply-to:references:date:message-id\n\t:mime-version; bh=qWGL5c4JBTLwNXuqKxllXPmtqu9UUSkea6L203jvn5M=;\n\tb=jpF9V08NvdX2YZfEkbWfnlzUovqjv/160WGos83bRhvGLxz1oKPqqIRhIskT2YXPnn\n\tkP38Xx6rRTMQOCW4deR6W5T28kLRAgPrxA8NS2W20Fm1HXSqak60xDW9N1Rb+fCfbPdb\n\td2P9f+hR3hQjmrPUtK5H9SyDMvoooaii2fEJ4=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date\n\t:message-id:mime-version;\n\tbh=qWGL5c4JBTLwNXuqKxllXPmtqu9UUSkea6L203jvn5M=;\n\tb=b//LGY6GROZmD0hj4V13Dca+KXEhi6xQS+CnbGDpBhnGZqF3qvng6/cdmZO55KwD3N\n\tQ6zVRqO+fQlG0vomuh2OsvrpaJx7VOGPj/zc68/ju6PLQLnqoHJYv76HpmyTHiwQNGdR\n\tNC8jbX0ItsZvayMStKJv6/4KYUNXIGXw1T1Zd6xGSvIOy/PbbOonzB2dUmi29cz/ueZM\n\ty0MU1i8czXZW/81gZzzEh0utEMdWDV2zLmS1yaM1rPiqDfPZO+K1Cfez0A/TL/DyV9vm\n\tehKchH7wPWfNkopYF7J/Hgsrr+lRXQbzf8yiazn+1D9/2jVNk5eKuWPVBDLmGsTqvvz1\n\tciAQ==","X-Gm-Message-State":"AHPjjUioHB5fHbRgbU4aQ1tGKMv9OJ6eskDlbEaISuyJjbY9clJsVMby\n\tTS4OkFpMbAswuUdo","X-Google-Smtp-Source":"ADKCNb5q/niM3gxxOq005BTvH+03JTr/qks3Gpc4iymYQD4huGxKIUGsgc/cuT7PbzcybDJrQSYmng==","X-Received":"by 10.98.215.80 with SMTP id v16mr1937136pfl.342.1504265647741; \n\tFri, 01 Sep 2017 04:34:07 -0700 (PDT)","From":"Daniel Axtens <dja@axtens.net>","To":"Ard Biesheuvel <ard.biesheuvel@linaro.org>","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","In-Reply-To":"<CAKv+Gu84njSF5uOvNtknGdOd5auU7zw9scFeTq5v-=OhExgOqA@mail.gmail.com>","References":"<20170901072744.2409-1-dja@axtens.net>\n\t<CAKv+Gu84njSF5uOvNtknGdOd5auU7zw9scFeTq5v-=OhExgOqA@mail.gmail.com>","Date":"Fri, 01 Sep 2017 21:34:03 +1000","Message-ID":"<877exi4pqs.fsf@linkitivity.dja.id.au>","MIME-Version":"1.0","Content-Type":"text/plain","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.23","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>,\n\tCatalin Marinas <catalin.marinas@arm.com>,\n\tGabriele Paoloni <gabriele.paoloni@huawei.com>,\n\tDavid Airlie <airlied@linux.ie>, linux-pci <linux-pci@vger.kernel.org>,\n\tWill Deacon <will.deacon@arm.com>,\n\tdri-devel <dri-devel@lists.freedesktop.org>, \n\t\"Liuxinliang \\(Matthew Liu\\)\" <z.liuxinliang@hisilicon.com>,\n\tAlex Williamson <alex.williamson@redhat.com>,\n\tLukas Wunner <lukas@wunner.de>, Bjorn Helgaas <helgaas@kernel.org>,\n\tZou Rongrong <zourongrong@gmail.com>, \n\t\"Vetter, Daniel\" <daniel.vetter@intel.com>,\n\tlinuxppc-dev <linuxppc-dev@lists.ozlabs.org>,\n\t\"linux-arm-kernel@lists.infradead.org\"\n\t<linux-arm-kernel@lists.infradead.org>","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}},{"id":1769876,"web_url":"http://patchwork.ozlabs.org/comment/1769876/","msgid":"<87d16oeeti.fsf@linkitivity.dja.id.au>","date":"2017-09-18T05:49:45","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":65792,"url":"http://patchwork.ozlabs.org/api/people/65792/","name":"Daniel Axtens","email":"dja@axtens.net"},"content":"Hi all,\n\nThe merge window is well over by now - is there anything else I can do\nto get this series to a mergeable state? I'm not particularly across the\nrules for drm-misc, so please let me know if there are things I need to\nbe doing.\n\nRegards,\nDaniel\n\nDaniel Axtens <dja@axtens.net> writes:\n\n> This patch set:\n>\n>  - splits the default display handling out from VGA arbiter, into its\n>    own file and behind its own Kconfig option (and gives the functions\n>    better names).\n>\n>  - adds extra detection of default devices. To be nominated, the vga\n>    arbiter and platform hooks must not have nominated a default. A\n>    card will then only be nominated if it has a driver attached and\n>    has IO or memory decoding enabled.\n>\n>  - adds relevant documentation.\n>\n> The practical impact of this is improved X autoconfiguration on some\n> arm64 systems.\n>\n> Changes in v3:\n>\n>  - Add documentation - thanks Daniel Vetter for pointing it out.\n>\n>  - Clarify explanations. Thanks to everyone for continuing to bear\n>    with my incomplete understanding of PCI and provide some clarity.\n>\n>  - Split refactoring and adding functionality.\n>\n> Changes in v2: https://www.spinics.net/lists/linux-pci/msg64007.html\n>\n> Drop all the powerpc patches. [explanation snipped]\n>\n> v1: https://www.spinics.net/lists/linux-pci/msg63581.html\n>\n> Regards,\n> Daniel\n>\n> Daniel Axtens (3):\n>   drm: split default display handler out of VGA arbiter\n>   drm: add fallback default device detection\n>   drm: documentation for default display device\n>\n>  Documentation/gpu/default_display.rst |  93 +++++++++++++++++++\n>  Documentation/gpu/index.rst           |   1 +\n>  arch/ia64/pci/fixup.c                 |   6 +-\n>  arch/powerpc/kernel/pci-common.c      |   6 +-\n>  arch/x86/pci/fixup.c                  |   6 +-\n>  arch/x86/video/fbdev.c                |   4 +-\n>  drivers/gpu/vga/Kconfig               |  12 +++\n>  drivers/gpu/vga/Makefile              |   1 +\n>  drivers/gpu/vga/default_display.c     | 163 ++++++++++++++++++++++++++++++++++\n>  drivers/gpu/vga/vga_switcheroo.c      |   8 +-\n>  drivers/gpu/vga/vgaarb.c              |  61 +++----------\n>  drivers/pci/pci-sysfs.c               |   4 +-\n>  include/linux/default_display.h       |  44 +++++++++\n>  include/linux/vgaarb.h                |  15 ----\n>  14 files changed, 344 insertions(+), 80 deletions(-)\n>  create mode 100644 Documentation/gpu/default_display.rst\n>  create mode 100644 drivers/gpu/vga/default_display.c\n>  create mode 100644 include/linux/default_display.h\n>\n> -- \n> 2.11.0","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xwZs12CVKz9s7F\n\tfor <patchwork-incoming@ozlabs.org>;\n\tMon, 18 Sep 2017 15:52:05 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3xwZs10zsHzDrbS\n\tfor <patchwork-incoming@ozlabs.org>;\n\tMon, 18 Sep 2017 15:52:05 +1000 (AEST)","from mail-pg0-x241.google.com (mail-pg0-x241.google.com\n\t[IPv6:2607:f8b0:400e:c05::241])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3xwZpS6jsPzDrW0\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tMon, 18 Sep 2017 15:49:52 +1000 (AEST)","by mail-pg0-x241.google.com with SMTP id v82so4753772pgb.1\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tSun, 17 Sep 2017 22:49:51 -0700 (PDT)","from localhost (114-198-116-25.dyn.iinet.net.au. [114.198.116.25])\n\tby smtp.gmail.com with ESMTPSA id\n\tm69sm7786579pfc.38.2017.09.17.22.49.48\n\t(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);\n\tSun, 17 Sep 2017 22:49:49 -0700 (PDT)"],"Authentication-Results":["ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"nn9R1Un/\"; dkim-atps=neutral","lists.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"nn9R1Un/\"; dkim-atps=neutral","ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=axtens.net\n\t(client-ip=2607:f8b0:400e:c05::241; helo=mail-pg0-x241.google.com;\n\tenvelope-from=dja@axtens.net; receiver=<UNKNOWN>)","lists.ozlabs.org; dkim=pass (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"nn9R1Un/\"; dkim-atps=neutral"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=axtens.net; s=google;\n\th=from:to:cc:subject:in-reply-to:references:date:message-id\n\t:mime-version; bh=pCA2819zwHAt1VdndIDBz0V+VQcLAvdGTW+mM48T/7c=;\n\tb=nn9R1Un/z+2Fh3nI7amwmqYtH9/aXcjo/JHUaLllfRwSoapbIXcoMaaCYR/AjIL+bA\n\tSURFccCezbVXGh3vk0ou1F/kG6FBQQVj7JQWM3xCt72O/OdSLagokw9dy0fYV03mDcWg\n\tWkmm+R3+2MBmmZUb0JirSOe4ieNSr8MuZhThI=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date\n\t:message-id:mime-version;\n\tbh=pCA2819zwHAt1VdndIDBz0V+VQcLAvdGTW+mM48T/7c=;\n\tb=YyJ/EPHdKj6mfgmDEAx6suJfjljDtK8Et0C9aUB7XXCQQWZ5Ii1/TZzh/7L4dr9C+A\n\thqcUd9AvhzF4MFti9zASUgRRFagUhJ9FAP7NnYMbLrtsXKsAlxWIGQE9BtgoC/Rz85sh\n\tnzgoKfQYh3dFBvk8DSRT6v914KmmJ+RdyOP2W9JeE2s/lZ0dXZloC8iVdjxOn9cwr0Fp\n\tbREowvgBLWhgbgFhVgBtFqDDU3UAbG7buyvZIUdofCuVW/toKx4/11YGu7BzC1qNNjo2\n\tpJRDSX9fNsc/UteiaiVbGiFdHcS1sjZmuFNV3VBFodlDayTCORoqLw13Z4DRWuGQW34P\n\tE5Fw==","X-Gm-Message-State":"AHPjjUh+LOfgfg909RQple+Z3Nwhwa/25OMkfbfddGQv5ZlrX9pC0X8+\n\tPIrZrd+3cfrUUUpf","X-Google-Smtp-Source":"ADKCNb6kWuPU7FEBb2YDGmvP+hOaGXyvA+wxizNis+N7NuqFOFoiGHfQ1+Ev2rz/b63uRfAV1P61dg==","X-Received":"by 10.99.120.197 with SMTP id t188mr31228675pgc.3.1505713789866; \n\tSun, 17 Sep 2017 22:49:49 -0700 (PDT)","From":"Daniel Axtens <dja@axtens.net>","To":"linux-pci@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,\n\tlinux-arm-kernel@lists.infradead.org","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","In-Reply-To":"<20170901072744.2409-1-dja@axtens.net>","References":"<20170901072744.2409-1-dja@axtens.net>","Date":"Mon, 18 Sep 2017 15:49:45 +1000","Message-ID":"<87d16oeeti.fsf@linkitivity.dja.id.au>","MIME-Version":"1.0","Content-Type":"text/plain","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.24","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"lorenzo.pieralisi@arm.com, gabriele.paoloni@huawei.com,\n\tard.biesheuvel@linaro.org, airlied@linux.ie, will.deacon@arm.com,\n\tdri-devel@lists.freedesktop.org, z.liuxinliang@hisilicon.com,\n\talex.williamson@redhat.com, lukas@wunner.de, helgaas@kernel.org,\n\tcatalin.marinas@arm.com, zourongrong@gmail.com, daniel.vetter@intel.com","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}},{"id":1774849,"web_url":"http://patchwork.ozlabs.org/comment/1774849/","msgid":"<20170925163948.GD15970@bhelgaas-glaptop.roam.corp.google.com>","date":"2017-09-25T16:39:48","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":67298,"url":"http://patchwork.ozlabs.org/api/people/67298/","name":"Bjorn Helgaas","email":"helgaas@kernel.org"},"content":"On Fri, Sep 01, 2017 at 05:27:41PM +1000, Daniel Axtens wrote:\n> This patch set:\n> \n>  - splits the default display handling out from VGA arbiter, into its\n>    own file and behind its own Kconfig option (and gives the functions\n>    better names).\n> \n>  - adds extra detection of default devices. To be nominated, the vga\n>    arbiter and platform hooks must not have nominated a default. A\n>    card will then only be nominated if it has a driver attached and\n>    has IO or memory decoding enabled.\n> \n>  - adds relevant documentation.\n> \n> The practical impact of this is improved X autoconfiguration on some\n> arm64 systems.\n\nI think I gave you bad advice about trying to separate the \"default\ndevice\" idea from the VGA arbiter.\n\nIt is true that the \"VGA arbiter\" per se is related to routing the\nlegacy VGA resources, and the arbiter currently only selects a default\ndevice if it finds a device to which those resources are routed.\n\nWe have some cases where we want to select a default device that may\nnot support the legacy VGA resources, or where they might not be\nrouted to the device:\n\n  - systems where we match the EFI framebuffer address with a BAR, and\n    select that device as default,\n\n  - powerpc systems where there may be no host bridge window that maps\n    to the legacy VGA resources,\n\n  - your ARM64 systems where the default device may be behind a bridge\n    that doesn't support legacy VGA routing (PCI_BRIDGE_CTL_VGA)\n\nBut I think trying to split the \"default device\" part out from the VGA\narbiter ends up being overkill and making things more complicated\ninstead of simpler.\n\nWould something like the following work for you as well as the powerpc\ncase?  On powerpc, we already use vga_set_default_device() to select a\ndevice that doesn't use legacy VGA resources, so maybe we can just do\nthe same on ARM64?\n\nI suppose there might be wrinkles in how the arbiter deals with\nmultiple graphics devices on those systems, since I don't think it\nidentifies these devices that don't use the legacy resources, but it\nseems like we live with whatever those on are powerpc and probably can\non ARM64 as well.\n\n\ndiff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c\nindex 02831a396419..0ac7aa346c69 100644\n--- a/arch/powerpc/kernel/pci-common.c\n+++ b/arch/powerpc/kernel/pci-common.c\n@@ -1740,15 +1740,3 @@ static void fixup_hide_host_resource_fsl(struct pci_dev *dev)\n }\n DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_MOTOROLA, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_FREESCALE, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n-\n-static void fixup_vga(struct pci_dev *pdev)\n-{\n-\tu16 cmd;\n-\n-\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n-\tif ((cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) || !vga_default_device())\n-\t\tvga_set_default_device(pdev);\n-\n-}\n-DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,\n-\t\t\t      PCI_CLASS_DISPLAY_VGA, 8, fixup_vga);\ndiff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c\nindex 76875f6299b8..9df4802c5f04 100644\n--- a/drivers/gpu/vga/vgaarb.c\n+++ b/drivers/gpu/vga/vgaarb.c\n@@ -1468,6 +1468,21 @@ static int __init vga_arb_device_init(void)\n \t\t\tvgaarb_info(dev, \"no bridge control possible\\n\");\n \t}\n \n+\tif (!vga_default_device()) {\n+\t\tlist_for_each_entry(vgadev, &vga_list, list) {\n+\t\t\tstruct device *dev = &vgadev->pdev->dev;\n+\t\t\tu16 cmd;\n+\n+\t\t\tpdev = vgadev->pdev;\n+\t\t\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n+\t\t\tif (cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) {\n+\t\t\t\tvgaarb_info(dev, \"setting as boot device\\n\");\n+\t\t\t\tvga_set_default_device(pdev);\n+\t\t\t\tbreak;\n+\t\t\t}\n+\t\t}\n+\t}\n+\n \tpr_info(\"loaded\\n\");\n \treturn rc;\n }","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3y18wX4Mx7z9t3k\n\tfor <patchwork-incoming@ozlabs.org>;\n\tTue, 26 Sep 2017 02:41:00 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3y18wX3SyyzDsPd\n\tfor <patchwork-incoming@ozlabs.org>;\n\tTue, 26 Sep 2017 02:41:00 +1000 (AEST)","from mail.kernel.org (mail.kernel.org [198.145.29.99])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3y18vF3FdszDsN9\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tTue, 26 Sep 2017 02:39:53 +1000 (AEST)","from localhost (unknown [69.71.4.159])\n\t(using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits))\n\t(No client certificate requested)\n\tby mail.kernel.org (Postfix) with ESMTPSA id 5A84A2148C;\n\tMon, 25 Sep 2017 16:39:50 +0000 (UTC)"],"Authentication-Results":["ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=kernel.org\n\t(client-ip=198.145.29.99; helo=mail.kernel.org;\n\tenvelope-from=helgaas@kernel.org; receiver=<UNKNOWN>)","mail.kernel.org;\n\tdmarc=none (p=none dis=none) header.from=kernel.org","mail.kernel.org;\n\tspf=none smtp.mailfrom=helgaas@kernel.org"],"DMARC-Filter":"OpenDMARC Filter v1.3.2 mail.kernel.org 5A84A2148C","Date":"Mon, 25 Sep 2017 11:39:48 -0500","From":"Bjorn Helgaas <helgaas@kernel.org>","To":"Daniel Axtens <dja@axtens.net>","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","Message-ID":"<20170925163948.GD15970@bhelgaas-glaptop.roam.corp.google.com>","References":"<20170901072744.2409-1-dja@axtens.net>","MIME-Version":"1.0","Content-Type":"text/plain; charset=us-ascii","Content-Disposition":"inline","In-Reply-To":"<20170901072744.2409-1-dja@axtens.net>","User-Agent":"Mutt/1.5.21 (2010-09-15)","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.24","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"lorenzo.pieralisi@arm.com, catalin.marinas@arm.com,\n\tgabriele.paoloni@huawei.com, ard.biesheuvel@linaro.org,\n\tairlied@linux.ie, linux-pci@vger.kernel.org, will.deacon@arm.com,\n\tdri-devel@lists.freedesktop.org, z.liuxinliang@hisilicon.com,\n\talex.williamson@redhat.com, lukas@wunner.de, zourongrong@gmail.com,\n\tdaniel.vetter@intel.com, linuxppc-dev@lists.ozlabs.org,\n\tlinux-arm-kernel@lists.infradead.org","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}},{"id":1775039,"web_url":"http://patchwork.ozlabs.org/comment/1775039/","msgid":"<87zi9ixsfn.fsf@linkitivity.dja.id.au>","date":"2017-09-25T23:35:40","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":65792,"url":"http://patchwork.ozlabs.org/api/people/65792/","name":"Daniel Axtens","email":"dja@axtens.net"},"content":"Hi Bjorn,\n\n> But I think trying to split the \"default device\" part out from the VGA\n> arbiter ends up being overkill and making things more complicated\n> instead of simpler.\nFair enough.\n\n> Would something like the following work for you as well as the powerpc\n> case?  On powerpc, we already use vga_set_default_device() to select a\n> device that doesn't use legacy VGA resources, so maybe we can just do\n> the same on ARM64?\n\nIt looks good. I'll try to get some time on the test system to test it\nand I'll pester my friends at IBM to give it a go as well.\n\n> I suppose there might be wrinkles in how the arbiter deals with\n> multiple graphics devices on those systems, since I don't think it\n> identifies these devices that don't use the legacy resources, but it\n> seems like we live with whatever those on are powerpc and probably can\n> on ARM64 as well.\n\nI would say so, yes.\n\nThanks for sticking with this!\n\nRegards,\nDaniel\n\n>\n>\n> diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c\n> index 02831a396419..0ac7aa346c69 100644\n> --- a/arch/powerpc/kernel/pci-common.c\n> +++ b/arch/powerpc/kernel/pci-common.c\n> @@ -1740,15 +1740,3 @@ static void fixup_hide_host_resource_fsl(struct pci_dev *dev)\n>  }\n>  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_MOTOROLA, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n>  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_FREESCALE, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n> -\n> -static void fixup_vga(struct pci_dev *pdev)\n> -{\n> -\tu16 cmd;\n> -\n> -\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n> -\tif ((cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) || !vga_default_device())\n> -\t\tvga_set_default_device(pdev);\n> -\n> -}\n> -DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,\n> -\t\t\t      PCI_CLASS_DISPLAY_VGA, 8, fixup_vga);\n> diff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c\n> index 76875f6299b8..9df4802c5f04 100644\n> --- a/drivers/gpu/vga/vgaarb.c\n> +++ b/drivers/gpu/vga/vgaarb.c\n> @@ -1468,6 +1468,21 @@ static int __init vga_arb_device_init(void)\n>  \t\t\tvgaarb_info(dev, \"no bridge control possible\\n\");\n>  \t}\n>  \n> +\tif (!vga_default_device()) {\n> +\t\tlist_for_each_entry(vgadev, &vga_list, list) {\n> +\t\t\tstruct device *dev = &vgadev->pdev->dev;\n> +\t\t\tu16 cmd;\n> +\n> +\t\t\tpdev = vgadev->pdev;\n> +\t\t\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n> +\t\t\tif (cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) {\n> +\t\t\t\tvgaarb_info(dev, \"setting as boot device\\n\");\n> +\t\t\t\tvga_set_default_device(pdev);\n> +\t\t\t\tbreak;\n> +\t\t\t}\n> +\t\t}\n> +\t}\n> +\n>  \tpr_info(\"loaded\\n\");\n>  \treturn rc;\n>  }","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3y1L9D7365z9t2Q\n\tfor <patchwork-incoming@ozlabs.org>;\n\tTue, 26 Sep 2017 09:37:36 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3y1L9D5wZbzDsPQ\n\tfor <patchwork-incoming@ozlabs.org>;\n\tTue, 26 Sep 2017 09:37:36 +1000 (AEST)","from mail-pf0-x242.google.com (mail-pf0-x242.google.com\n\t[IPv6:2607:f8b0:400e:c00::242])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3y1L766mHszDsPs\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tTue, 26 Sep 2017 09:35:46 +1000 (AEST)","by mail-pf0-x242.google.com with SMTP id a7so4236608pfj.5\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tMon, 25 Sep 2017 16:35:46 -0700 (PDT)","from localhost (114-198-116-25.dyn.iinet.net.au. [114.198.116.25])\n\tby smtp.gmail.com with ESMTPSA id\n\tx8sm13209181pff.104.2017.09.25.16.35.42\n\t(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);\n\tMon, 25 Sep 2017 16:35:43 -0700 (PDT)"],"Authentication-Results":["ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"egmHQ8Gs\"; dkim-atps=neutral","lists.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"egmHQ8Gs\"; dkim-atps=neutral","ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=axtens.net\n\t(client-ip=2607:f8b0:400e:c00::242; helo=mail-pf0-x242.google.com;\n\tenvelope-from=dja@axtens.net; receiver=<UNKNOWN>)","lists.ozlabs.org; dkim=pass (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"egmHQ8Gs\"; dkim-atps=neutral"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=axtens.net; s=google;\n\th=from:to:cc:subject:in-reply-to:references:date:message-id\n\t:mime-version; bh=V50pAjIi0RbEDtISkae4udQJQ7u8Q3BoSX6Zv1wU0Wo=;\n\tb=egmHQ8Gs1ZVqN/4IfyIPODIjgLEQLql4F0qPThFBRs+JBuP0o4Jgg3F+3h0L49IaUb\n\tgpxDute4dE76JD/shkeWG/lJ4WxzdML+bRMnol3FRpclDLaOwqMyadI2aK2p1HW2ciyE\n\tJ7sIxNLA5n443ezqweGuSyC39rbVluAnYDyIs=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date\n\t:message-id:mime-version;\n\tbh=V50pAjIi0RbEDtISkae4udQJQ7u8Q3BoSX6Zv1wU0Wo=;\n\tb=QZc7wfiv3kVu9YhB/edL2WtoSSqkuGGHs13NgiKOpaTUalvOeqqf432YhDMJoRMHq0\n\tFEpkRkVb6MXEaV5LjRM9Xd3iVGEiH6NoWtLk1q/g2Dui34e6VIXtWIh647A4hstNRfOH\n\tA38870soNi42SCwBaTP/qgv4Gwe1Um3QH7rncxLlMtHps0T1KasELZqeJURXDWr+KnVq\n\t+rYlnQraFga0f5qVKjRkcQJzPXLDepBDNjTZk4/Uj5O/49pusbPIayErsSvrO2axe5VT\n\tL9D2+1y2Vtqi43k0bYD6PatyQbxVWm7WIYAs5uS2KQeUPPu0nf/xBw5WUmPYhc1qo/JD\n\tMBdA==","X-Gm-Message-State":"AHPjjUg0P828UH3g2Kc2c7PBWHofVTLtAuFZ0SNcoy+x5mhOjvTCX0m0\n\tRnrDc5qKYCId8bKylmtSq5VVhg==","X-Google-Smtp-Source":"AOwi7QBpwdjXnt+2YxQ8SdiYlmt4u7cQUk48lCNIS4wDX6xvRUeAgBUFr19MYh0Te0ApD6v0lXEkiw==","X-Received":"by 10.159.198.11 with SMTP id f11mr9057924plo.290.1506382544519; \n\tMon, 25 Sep 2017 16:35:44 -0700 (PDT)","From":"Daniel Axtens <dja@axtens.net>","To":"Bjorn Helgaas <helgaas@kernel.org>","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","In-Reply-To":"<20170925163948.GD15970@bhelgaas-glaptop.roam.corp.google.com>","References":"<20170901072744.2409-1-dja@axtens.net>\n\t<20170925163948.GD15970@bhelgaas-glaptop.roam.corp.google.com>","Date":"Tue, 26 Sep 2017 09:35:40 +1000","Message-ID":"<87zi9ixsfn.fsf@linkitivity.dja.id.au>","MIME-Version":"1.0","Content-Type":"text/plain","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.24","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"lorenzo.pieralisi@arm.com, catalin.marinas@arm.com,\n\tgabriele.paoloni@huawei.com, ard.biesheuvel@linaro.org,\n\tairlied@linux.ie, linux-pci@vger.kernel.org, will.deacon@arm.com,\n\tdri-devel@lists.freedesktop.org, z.liuxinliang@hisilicon.com,\n\talex.williamson@redhat.com, lukas@wunner.de, zourongrong@gmail.com,\n\tdaniel.vetter@intel.com, linuxppc-dev@lists.ozlabs.org,\n\tlinux-arm-kernel@lists.infradead.org","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}},{"id":1775151,"web_url":"http://patchwork.ozlabs.org/comment/1775151/","msgid":"<CAKMK7uFq=WEYoeBBvBgSeFq9PCsqzbGiq6KiC10b1KabcayDQA@mail.gmail.com>","date":"2017-09-26T04:50:47","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":1959,"url":"http://patchwork.ozlabs.org/api/people/1959/","name":"Daniel Vetter","email":"daniel@ffwll.ch"},"content":"On Mon, Sep 18, 2017 at 7:49 AM, Daniel Axtens <dja@axtens.net> wrote:\n> Hi all,\n>\n> The merge window is well over by now - is there anything else I can do\n> to get this series to a mergeable state? I'm not particularly across the\n> rules for drm-misc, so please let me know if there are things I need to\n> be doing.\n\ndrm-misc is always open for feature merging, but the patch series\nlacks full r-b by someone with clue on this stuff (i.e. probably not\nme). Pls find someone who can do the in-depth review. Just an Ack\nfeels a bit thin.\n-Daniel\n\n>\n> Regards,\n> Daniel\n>\n> Daniel Axtens <dja@axtens.net> writes:\n>\n>> This patch set:\n>>\n>>  - splits the default display handling out from VGA arbiter, into its\n>>    own file and behind its own Kconfig option (and gives the functions\n>>    better names).\n>>\n>>  - adds extra detection of default devices. To be nominated, the vga\n>>    arbiter and platform hooks must not have nominated a default. A\n>>    card will then only be nominated if it has a driver attached and\n>>    has IO or memory decoding enabled.\n>>\n>>  - adds relevant documentation.\n>>\n>> The practical impact of this is improved X autoconfiguration on some\n>> arm64 systems.\n>>\n>> Changes in v3:\n>>\n>>  - Add documentation - thanks Daniel Vetter for pointing it out.\n>>\n>>  - Clarify explanations. Thanks to everyone for continuing to bear\n>>    with my incomplete understanding of PCI and provide some clarity.\n>>\n>>  - Split refactoring and adding functionality.\n>>\n>> Changes in v2: https://www.spinics.net/lists/linux-pci/msg64007.html\n>>\n>> Drop all the powerpc patches. [explanation snipped]\n>>\n>> v1: https://www.spinics.net/lists/linux-pci/msg63581.html\n>>\n>> Regards,\n>> Daniel\n>>\n>> Daniel Axtens (3):\n>>   drm: split default display handler out of VGA arbiter\n>>   drm: add fallback default device detection\n>>   drm: documentation for default display device\n>>\n>>  Documentation/gpu/default_display.rst |  93 +++++++++++++++++++\n>>  Documentation/gpu/index.rst           |   1 +\n>>  arch/ia64/pci/fixup.c                 |   6 +-\n>>  arch/powerpc/kernel/pci-common.c      |   6 +-\n>>  arch/x86/pci/fixup.c                  |   6 +-\n>>  arch/x86/video/fbdev.c                |   4 +-\n>>  drivers/gpu/vga/Kconfig               |  12 +++\n>>  drivers/gpu/vga/Makefile              |   1 +\n>>  drivers/gpu/vga/default_display.c     | 163 ++++++++++++++++++++++++++++++++++\n>>  drivers/gpu/vga/vga_switcheroo.c      |   8 +-\n>>  drivers/gpu/vga/vgaarb.c              |  61 +++----------\n>>  drivers/pci/pci-sysfs.c               |   4 +-\n>>  include/linux/default_display.h       |  44 +++++++++\n>>  include/linux/vgaarb.h                |  15 ----\n>>  14 files changed, 344 insertions(+), 80 deletions(-)\n>>  create mode 100644 Documentation/gpu/default_display.rst\n>>  create mode 100644 drivers/gpu/vga/default_display.c\n>>  create mode 100644 include/linux/default_display.h\n>>\n>> --\n>> 2.11.0\n> _______________________________________________\n> dri-devel mailing list\n> dri-devel@lists.freedesktop.org\n> https://lists.freedesktop.org/mailman/listinfo/dri-devel","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3y1T8T5XlQz9sNr\n\tfor <patchwork-incoming@ozlabs.org>;\n\tTue, 26 Sep 2017 14:52:25 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3y1T8T4PMbzDsPQ\n\tfor <patchwork-incoming@ozlabs.org>;\n\tTue, 26 Sep 2017 14:52:25 +1000 (AEST)","from mail-io0-x242.google.com (mail-io0-x242.google.com\n\t[IPv6:2607:f8b0:4001:c06::242])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3y1T6k0fWkzDsMB\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tTue, 26 Sep 2017 14:50:51 +1000 (AEST)","by mail-io0-x242.google.com with SMTP id d16so3958832ioj.2\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tMon, 25 Sep 2017 21:50:51 -0700 (PDT)","by 10.79.196.218 with HTTP; Mon, 25 Sep 2017 21:50:47 -0700 (PDT)"],"Authentication-Results":["ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ffwll.ch header.i=@ffwll.ch header.b=\"H3Tzntws\";\n\tdkim-atps=neutral","lists.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ffwll.ch header.i=@ffwll.ch header.b=\"H3Tzntws\";\n\tdkim-atps=neutral","ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=ffwll.ch\n\t(client-ip=2607:f8b0:4001:c06::242; helo=mail-io0-x242.google.com;\n\tenvelope-from=daniel.vetter@ffwll.ch; receiver=<UNKNOWN>)","lists.ozlabs.org; dkim=pass (1024-bit key;\n\tunprotected) header.d=ffwll.ch header.i=@ffwll.ch header.b=\"H3Tzntws\";\n\tdkim-atps=neutral"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; \n\th=mime-version:sender:in-reply-to:references:from:date:message-id\n\t:subject:to:cc;\n\tbh=ALaR7ZPUKJAvxC9ec44smT1itV2hk5mm+wlcPk8/Szg=;\n\tb=H3TzntwsJBGEkgqCp7bqNqVAnMqbFwSSH2E95Ou3WUuDVd5JsaLsgLF4YcIwyPkJMk\n\tZEgxSqqDEqFDauZLW37YUw9+qOpkN8diLKlahoaIBR+cRlvKN2wJn8xYvqu/qotfvZLV\n\t5I5PoXdqYkn+RuFLzo5XXOqu1qI08dsJfAnx0=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:mime-version:sender:in-reply-to:references:from\n\t:date:message-id:subject:to:cc;\n\tbh=ALaR7ZPUKJAvxC9ec44smT1itV2hk5mm+wlcPk8/Szg=;\n\tb=E7N4vBXiZDU+8ZYC3m7FhqtDfMpRhExYDP4LzgU1olhIIqCJl+8PGdZhTVq1tzt+sa\n\tehZINM0gMhXx42h10gnVUit9tvJQ5+ji28VGAe2KawogIBjPk/EgzAIdxk3i1DA3NwXZ\n\tEpNtwgPaLq4kOdOvwMSab4QEEIrDW4cLbJT6S+3A4kRFvtHBvPyIOsRuAzq1zTEEQLWb\n\t1Kin3kWCgm/9lXWTF6D4gW4J+c3rklVoqhyttOwKDaKKRDAWc7t//ReyFMx9XB8zAFCl\n\tDRyceTrzzCY/9msB0UWNa9G6jDlerZ5nb3xiPOeRPIM/YIyNXIpPdDbJTjOHq3xWSBpl\n\tm2BQ==","X-Gm-Message-State":"AHPjjUgP89bZSLYqjGfTDUin7cdnfsJ6D0IbZhuN1p6pw9IfKGwS46gP\n\tpb100eDnuNvT4+OdJA2cxmf4al4i4cYVkRiJxnjZjQ==","X-Google-Smtp-Source":"AOwi7QADp6IJE9+VdK2+9dma+1Tid9d28AIGXgaKl9CJgflJRkz0V4PyriRhq7Yyp71wP9xnA2xbIRFRSe8qgVZ/RJ8=","X-Received":"by 10.107.78.19 with SMTP id c19mr12199367iob.205.1506401447938; \n\tMon, 25 Sep 2017 21:50:47 -0700 (PDT)","MIME-Version":"1.0","X-Originating-IP":"[2a02:168:5635:0:39d2:f87e:2033:9f6]","In-Reply-To":"<87d16oeeti.fsf@linkitivity.dja.id.au>","References":"<20170901072744.2409-1-dja@axtens.net>\n\t<87d16oeeti.fsf@linkitivity.dja.id.au>","From":"Daniel Vetter <daniel@ffwll.ch>","Date":"Tue, 26 Sep 2017 06:50:47 +0200","X-Google-Sender-Auth":"rri8DyWNfxLwjPRRXClnCNPlmLM","Message-ID":"<CAKMK7uFq=WEYoeBBvBgSeFq9PCsqzbGiq6KiC10b1KabcayDQA@mail.gmail.com>","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","To":"Daniel Axtens <dja@axtens.net>","Content-Type":"text/plain; charset=\"UTF-8\"","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.24","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"lorenzo.pieralisi@arm.com, gabriele.paoloni@huawei.com,\n\tard.biesheuvel@linaro.org, Linux PCI <linux-pci@vger.kernel.org>,\n\tWill Deacon <will.deacon@arm.com>,\n\tdri-devel <dri-devel@lists.freedesktop.org>, \n\tXinliang Liu <z.liuxinliang@hisilicon.com>,\n\tAlex Williamson <alex.williamson@redhat.com>,\n\tBjorn Helgaas <helgaas@kernel.org>,\n\tCatalin Marinas <catalin.marinas@arm.com>, \n\tRongrong Zou <zourongrong@gmail.com>,\n\tDaniel Vetter <daniel.vetter@intel.com>, \n\tlinuxppc-dev <linuxppc-dev@lists.ozlabs.org>,\n\t\"linux-arm-kernel@lists.infradead.org\"\n\t<linux-arm-kernel@lists.infradead.org>","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}},{"id":1776020,"web_url":"http://patchwork.ozlabs.org/comment/1776020/","msgid":"<87k20kyezs.fsf@linkitivity.dja.id.au>","date":"2017-09-27T03:52:55","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":65792,"url":"http://patchwork.ozlabs.org/api/people/65792/","name":"Daniel Axtens","email":"dja@axtens.net"},"content":"Hi Bjorn,\n\nYes, this works:\n\nTested-by: Daniel Axtens <dja@axtens.net> # arm64, ppc64-qemu-tcg\n\n\nRegards,\nDaniel\n> On Fri, Sep 01, 2017 at 05:27:41PM +1000, Daniel Axtens wrote:\n>> This patch set:\n>> \n>>  - splits the default display handling out from VGA arbiter, into its\n>>    own file and behind its own Kconfig option (and gives the functions\n>>    better names).\n>> \n>>  - adds extra detection of default devices. To be nominated, the vga\n>>    arbiter and platform hooks must not have nominated a default. A\n>>    card will then only be nominated if it has a driver attached and\n>>    has IO or memory decoding enabled.\n>> \n>>  - adds relevant documentation.\n>> \n>> The practical impact of this is improved X autoconfiguration on some\n>> arm64 systems.\n>\n> I think I gave you bad advice about trying to separate the \"default\n> device\" idea from the VGA arbiter.\n>\n> It is true that the \"VGA arbiter\" per se is related to routing the\n> legacy VGA resources, and the arbiter currently only selects a default\n> device if it finds a device to which those resources are routed.\n>\n> We have some cases where we want to select a default device that may\n> not support the legacy VGA resources, or where they might not be\n> routed to the device:\n>\n>   - systems where we match the EFI framebuffer address with a BAR, and\n>     select that device as default,\n>\n>   - powerpc systems where there may be no host bridge window that maps\n>     to the legacy VGA resources,\n>\n>   - your ARM64 systems where the default device may be behind a bridge\n>     that doesn't support legacy VGA routing (PCI_BRIDGE_CTL_VGA)\n>\n> But I think trying to split the \"default device\" part out from the VGA\n> arbiter ends up being overkill and making things more complicated\n> instead of simpler.\n>\n> Would something like the following work for you as well as the powerpc\n> case?  On powerpc, we already use vga_set_default_device() to select a\n> device that doesn't use legacy VGA resources, so maybe we can just do\n> the same on ARM64?\n>\n> I suppose there might be wrinkles in how the arbiter deals with\n> multiple graphics devices on those systems, since I don't think it\n> identifies these devices that don't use the legacy resources, but it\n> seems like we live with whatever those on are powerpc and probably can\n> on ARM64 as well.\n>\n>\n> diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c\n> index 02831a396419..0ac7aa346c69 100644\n> --- a/arch/powerpc/kernel/pci-common.c\n> +++ b/arch/powerpc/kernel/pci-common.c\n> @@ -1740,15 +1740,3 @@ static void fixup_hide_host_resource_fsl(struct pci_dev *dev)\n>  }\n>  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_MOTOROLA, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n>  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_FREESCALE, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n> -\n> -static void fixup_vga(struct pci_dev *pdev)\n> -{\n> -\tu16 cmd;\n> -\n> -\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n> -\tif ((cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) || !vga_default_device())\n> -\t\tvga_set_default_device(pdev);\n> -\n> -}\n> -DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,\n> -\t\t\t      PCI_CLASS_DISPLAY_VGA, 8, fixup_vga);\n> diff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c\n> index 76875f6299b8..9df4802c5f04 100644\n> --- a/drivers/gpu/vga/vgaarb.c\n> +++ b/drivers/gpu/vga/vgaarb.c\n> @@ -1468,6 +1468,21 @@ static int __init vga_arb_device_init(void)\n>  \t\t\tvgaarb_info(dev, \"no bridge control possible\\n\");\n>  \t}\n>  \n> +\tif (!vga_default_device()) {\n> +\t\tlist_for_each_entry(vgadev, &vga_list, list) {\n> +\t\t\tstruct device *dev = &vgadev->pdev->dev;\n> +\t\t\tu16 cmd;\n> +\n> +\t\t\tpdev = vgadev->pdev;\n> +\t\t\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n> +\t\t\tif (cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) {\n> +\t\t\t\tvgaarb_info(dev, \"setting as boot device\\n\");\n> +\t\t\t\tvga_set_default_device(pdev);\n> +\t\t\t\tbreak;\n> +\t\t\t}\n> +\t\t}\n> +\t}\n> +\n>  \tpr_info(\"loaded\\n\");\n>  \treturn rc;\n>  }","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3y23qB5xHtz9s9Y\n\tfor <patchwork-incoming@ozlabs.org>;\n\tWed, 27 Sep 2017 13:54:30 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3y23qB3PfpzDsPt\n\tfor <patchwork-incoming@ozlabs.org>;\n\tWed, 27 Sep 2017 13:54:30 +1000 (AEST)","from mail-pg0-x244.google.com (mail-pg0-x244.google.com\n\t[IPv6:2607:f8b0:400e:c05::244])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3y23nV4XLJzDqNm\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tWed, 27 Sep 2017 13:53:01 +1000 (AEST)","by mail-pg0-x244.google.com with SMTP id j16so7952074pga.2\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tTue, 26 Sep 2017 20:53:01 -0700 (PDT)","from localhost (114-198-116-25.dyn.iinet.net.au. [114.198.116.25])\n\tby smtp.gmail.com with ESMTPSA id\n\tz78sm122006pfd.178.2017.09.26.20.52.58\n\t(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);\n\tTue, 26 Sep 2017 20:52:58 -0700 (PDT)"],"Authentication-Results":["ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"rXPPJvwL\"; dkim-atps=neutral","lists.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"rXPPJvwL\"; dkim-atps=neutral","ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=axtens.net\n\t(client-ip=2607:f8b0:400e:c05::244; helo=mail-pg0-x244.google.com;\n\tenvelope-from=dja@axtens.net; receiver=<UNKNOWN>)","lists.ozlabs.org; dkim=pass (1024-bit key;\n\tunprotected) header.d=axtens.net header.i=@axtens.net\n\theader.b=\"rXPPJvwL\"; dkim-atps=neutral"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=axtens.net; s=google;\n\th=from:to:cc:subject:in-reply-to:references:date:message-id\n\t:mime-version; bh=2zm4YkB0xmZwxQhUEwq4HYM1b/zI46iK9KMneDwvCUU=;\n\tb=rXPPJvwLKHOeSbR26eQ6xU1ltTjGi6qggEG65sWa+Nk6I2PZs0dwToFPzYdW75/s+p\n\ts2kpIaK3wwR7Al0giHIcQS3KBkCA58a8tGemhWvIbY0XJJ+KZ2/+iAu8MRrEgkrahaEp\n\tuuE6NFLCVbz71vuvCjNivYMFd7tka/3wpGwuo=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date\n\t:message-id:mime-version;\n\tbh=2zm4YkB0xmZwxQhUEwq4HYM1b/zI46iK9KMneDwvCUU=;\n\tb=VkVEhAycUB4bWeB6UIkRWAQX7uI+PXpbpRMDn6JgC6ZauCYMKdgjHIsNsqauAmLwo2\n\tJZv3Fk1UAXtzkqDiy+4ma92fJ6Q5z5cD3YKf/464U0j5qvKEfEMwo+JCu//5CyAaoUhZ\n\tBq6z/yJaF/lWsZSPJASBLtPgFwFNcvhpaSelh0frzEv1nLWduRwsH1J2yNWoAaCDofIt\n\tj5DDcgb0QOaocJcRHxDj2/bVeP5wiZFX1ThT9ClShbQMDCCqsyJGMbEJkqdyPDpUsUNx\n\tQno9qjtYLzgiut/wpD59fHvNBI9wnHOlwRgOFfCI+bkq94ltX0Wj42gaf9t2zREJo5jj\n\tP1fw==","X-Gm-Message-State":"AHPjjUiLHvn/WjGt2p0+sxSGux19cejvaXlS8OhcC/VPAGylxiFca0Pf\n\tuL1P4pH0LDWY6xW6Euv6d5M2TA==","X-Google-Smtp-Source":"AOwi7QAQ4+M6mdFDpdv+DrhRjLZlPoXg+niDkoqCZTtj3f8jNq0Srv24b4sdw/kwsi5gdVbUAglWxQ==","X-Received":"by 10.99.104.6 with SMTP id d6mr82666pgc.168.1506484379705;\n\tTue, 26 Sep 2017 20:52:59 -0700 (PDT)","From":"Daniel Axtens <dja@axtens.net>","To":"Bjorn Helgaas <helgaas@kernel.org>","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","In-Reply-To":"<20170925163948.GD15970@bhelgaas-glaptop.roam.corp.google.com>","References":"<20170901072744.2409-1-dja@axtens.net>\n\t<20170925163948.GD15970@bhelgaas-glaptop.roam.corp.google.com>","Date":"Wed, 27 Sep 2017 13:52:55 +1000","Message-ID":"<87k20kyezs.fsf@linkitivity.dja.id.au>","MIME-Version":"1.0","Content-Type":"text/plain","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.24","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"lorenzo.pieralisi@arm.com, catalin.marinas@arm.com,\n\tgabriele.paoloni@huawei.com, ard.biesheuvel@linaro.org,\n\tairlied@linux.ie, linux-pci@vger.kernel.org, will.deacon@arm.com,\n\tdri-devel@lists.freedesktop.org, z.liuxinliang@hisilicon.com,\n\talex.williamson@redhat.com, lukas@wunner.de, zourongrong@gmail.com,\n\tdaniel.vetter@intel.com, linuxppc-dev@lists.ozlabs.org,\n\tlinux-arm-kernel@lists.infradead.org","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}},{"id":1781873,"web_url":"http://patchwork.ozlabs.org/comment/1781873/","msgid":"<20171006195118.GG25517@bhelgaas-glaptop.roam.corp.google.com>","date":"2017-10-06T19:51:18","subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","submitter":{"id":67298,"url":"http://patchwork.ozlabs.org/api/people/67298/","name":"Bjorn Helgaas","email":"helgaas@kernel.org"},"content":"On Wed, Sep 27, 2017 at 01:52:55PM +1000, Daniel Axtens wrote:\n> Hi Bjorn,\n> \n> Yes, this works:\n> \n> Tested-by: Daniel Axtens <dja@axtens.net> # arm64, ppc64-qemu-tcg\n\nI guess I was assuming you'd pick this up, but that doesn't really\nmake sense because I didn't give you a signed-off-by or anything.\nI'll post this with a changelog and signed-off-by so it doesn't get\nlost.\n\nI also noticed that I didn't correctly handle the powerpc quirk case\nwhere it doesn't require the device to be enabled at all.  I'll try to\nfix that up, too.\n\nBjorn\n\n> > On Fri, Sep 01, 2017 at 05:27:41PM +1000, Daniel Axtens wrote:\n> >> This patch set:\n> >> \n> >>  - splits the default display handling out from VGA arbiter, into its\n> >>    own file and behind its own Kconfig option (and gives the functions\n> >>    better names).\n> >> \n> >>  - adds extra detection of default devices. To be nominated, the vga\n> >>    arbiter and platform hooks must not have nominated a default. A\n> >>    card will then only be nominated if it has a driver attached and\n> >>    has IO or memory decoding enabled.\n> >> \n> >>  - adds relevant documentation.\n> >> \n> >> The practical impact of this is improved X autoconfiguration on some\n> >> arm64 systems.\n> >\n> > I think I gave you bad advice about trying to separate the \"default\n> > device\" idea from the VGA arbiter.\n> >\n> > It is true that the \"VGA arbiter\" per se is related to routing the\n> > legacy VGA resources, and the arbiter currently only selects a default\n> > device if it finds a device to which those resources are routed.\n> >\n> > We have some cases where we want to select a default device that may\n> > not support the legacy VGA resources, or where they might not be\n> > routed to the device:\n> >\n> >   - systems where we match the EFI framebuffer address with a BAR, and\n> >     select that device as default,\n> >\n> >   - powerpc systems where there may be no host bridge window that maps\n> >     to the legacy VGA resources,\n> >\n> >   - your ARM64 systems where the default device may be behind a bridge\n> >     that doesn't support legacy VGA routing (PCI_BRIDGE_CTL_VGA)\n> >\n> > But I think trying to split the \"default device\" part out from the VGA\n> > arbiter ends up being overkill and making things more complicated\n> > instead of simpler.\n> >\n> > Would something like the following work for you as well as the powerpc\n> > case?  On powerpc, we already use vga_set_default_device() to select a\n> > device that doesn't use legacy VGA resources, so maybe we can just do\n> > the same on ARM64?\n> >\n> > I suppose there might be wrinkles in how the arbiter deals with\n> > multiple graphics devices on those systems, since I don't think it\n> > identifies these devices that don't use the legacy resources, but it\n> > seems like we live with whatever those on are powerpc and probably can\n> > on ARM64 as well.\n> >\n> >\n> > diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c\n> > index 02831a396419..0ac7aa346c69 100644\n> > --- a/arch/powerpc/kernel/pci-common.c\n> > +++ b/arch/powerpc/kernel/pci-common.c\n> > @@ -1740,15 +1740,3 @@ static void fixup_hide_host_resource_fsl(struct pci_dev *dev)\n> >  }\n> >  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_MOTOROLA, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n> >  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_FREESCALE, PCI_ANY_ID, fixup_hide_host_resource_fsl);\n> > -\n> > -static void fixup_vga(struct pci_dev *pdev)\n> > -{\n> > -\tu16 cmd;\n> > -\n> > -\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n> > -\tif ((cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) || !vga_default_device())\n> > -\t\tvga_set_default_device(pdev);\n> > -\n> > -}\n> > -DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,\n> > -\t\t\t      PCI_CLASS_DISPLAY_VGA, 8, fixup_vga);\n> > diff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c\n> > index 76875f6299b8..9df4802c5f04 100644\n> > --- a/drivers/gpu/vga/vgaarb.c\n> > +++ b/drivers/gpu/vga/vgaarb.c\n> > @@ -1468,6 +1468,21 @@ static int __init vga_arb_device_init(void)\n> >  \t\t\tvgaarb_info(dev, \"no bridge control possible\\n\");\n> >  \t}\n> >  \n> > +\tif (!vga_default_device()) {\n> > +\t\tlist_for_each_entry(vgadev, &vga_list, list) {\n> > +\t\t\tstruct device *dev = &vgadev->pdev->dev;\n> > +\t\t\tu16 cmd;\n> > +\n> > +\t\t\tpdev = vgadev->pdev;\n> > +\t\t\tpci_read_config_word(pdev, PCI_COMMAND, &cmd);\n> > +\t\t\tif (cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) {\n> > +\t\t\t\tvgaarb_info(dev, \"setting as boot device\\n\");\n> > +\t\t\t\tvga_set_default_device(pdev);\n> > +\t\t\t\tbreak;\n> > +\t\t\t}\n> > +\t\t}\n> > +\t}\n> > +\n> >  \tpr_info(\"loaded\\n\");\n> >  \treturn rc;\n> >  }\n> \n>","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3y80fN0cj4z9t34\n\tfor <patchwork-incoming@ozlabs.org>;\n\tSat,  7 Oct 2017 06:52:28 +1100 (AEDT)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3y80fM6bJVzDqy4\n\tfor <patchwork-incoming@ozlabs.org>;\n\tSat,  7 Oct 2017 06:52:27 +1100 (AEDT)","from mail.kernel.org (mail.kernel.org [198.145.29.99])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3y80d55cfKzDqlT\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tSat,  7 Oct 2017 06:51:21 +1100 (AEDT)","from localhost (unknown [69.55.156.165])\n\t(using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits))\n\t(No client certificate requested)\n\tby mail.kernel.org (Postfix) with ESMTPSA id 5782A217C5;\n\tFri,  6 Oct 2017 19:51:19 +0000 (UTC)"],"Authentication-Results":["ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=kernel.org\n\t(client-ip=198.145.29.99; helo=mail.kernel.org;\n\tenvelope-from=helgaas@kernel.org; receiver=<UNKNOWN>)","mail.kernel.org;\n\tdmarc=none (p=none dis=none) header.from=kernel.org","mail.kernel.org;\n\tspf=none smtp.mailfrom=helgaas@kernel.org"],"DMARC-Filter":"OpenDMARC Filter v1.3.2 mail.kernel.org 5782A217C5","Date":"Fri, 6 Oct 2017 14:51:18 -0500","From":"Bjorn Helgaas <helgaas@kernel.org>","To":"Daniel Axtens <dja@axtens.net>","Subject":"Re: [PATCH v3 0/3] Split default display handling out from VGA\n\tarbiter","Message-ID":"<20171006195118.GG25517@bhelgaas-glaptop.roam.corp.google.com>","References":"<20170901072744.2409-1-dja@axtens.net>\n\t<20170925163948.GD15970@bhelgaas-glaptop.roam.corp.google.com>\n\t<87k20kyezs.fsf@linkitivity.dja.id.au>","MIME-Version":"1.0","Content-Type":"text/plain; charset=us-ascii","Content-Disposition":"inline","In-Reply-To":"<87k20kyezs.fsf@linkitivity.dja.id.au>","User-Agent":"Mutt/1.5.21 (2010-09-15)","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.24","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"lorenzo.pieralisi@arm.com, catalin.marinas@arm.com,\n\tgabriele.paoloni@huawei.com, ard.biesheuvel@linaro.org,\n\tairlied@linux.ie, linux-pci@vger.kernel.org, will.deacon@arm.com,\n\tdri-devel@lists.freedesktop.org, z.liuxinliang@hisilicon.com,\n\talex.williamson@redhat.com, lukas@wunner.de, zourongrong@gmail.com,\n\tdaniel.vetter@intel.com, linuxppc-dev@lists.ozlabs.org,\n\tlinux-arm-kernel@lists.infradead.org","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}}]