From patchwork Mon Oct 9 16:06:04 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rob Herring X-Patchwork-Id: 115265 Delivered-To: patch@linaro.org Received: by 10.140.22.163 with SMTP id 32csp2718514qgn; Mon, 9 Oct 2017 09:06:11 -0700 (PDT) X-Received: by 10.99.182.5 with SMTP id j5mr9347228pgf.71.1507565171597; Mon, 09 Oct 2017 09:06:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1507565171; cv=none; d=google.com; s=arc-20160816; b=oVYX+0vKA+8X5J9FvVPJYoFQ/lRDfp7ZbVk/FpVnts4n4PbqyrqZ63nMYzOXNhn3nt uOFdCTFiBhHq2VUtuZwScsOfZXPD405cJjhxvpUXCFdYHAdDoSBByDB6JMTvuIkalz3H r5j0SxDxc/wh8vqIcY6/ETsTZirqYlLxaY4zW5U4+UEXUxV2IvJGAOCvS/XH0+hG3jLv 2FgDl/44qUMyJzoc5TOSSprb1jqrgYQxu9c9XXN9zn3aUUtd/YCNOrG66obI7SKNxTfT Dt58z1PPs3XRkRpIs/J3m2nRmVvcbZY2Lc/PkmutUT9pCEQMY8buS3CQc1lLSnFRUYEC 65/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:message-id:date:subject:to:from:delivered-to :arc-authentication-results; bh=4StV+nxsT3zMP950c2dXsGWgJ/3qlXCX+CR2Vo6H3qk=; b=mvMMchVh2ikKkdAva1deFBgyNsAwndCtc25ZE5r0dQpk9bFo11zTOI7HWbGojIaSww 6xCo2OAAo0goF5aI5gUWLrqNdhcQ3bTDkFelZO7B2fHtfwWyqPl2bGsmjeJnBMXPDp0a eB7pjJt8/USlqytKMbMYp+CnrvRPuRDc70z1NlLXxyKUkQHKXcR9Xr+JZVzWKqxQGXZT zHG0OKTZz0henXKpqfdBsXOrGjuCqwUYzHkoUPIsjhWVD0w7KustgwgPUp5IA5dsehsh 6485N5IhtWRId2ZmXqCsLX+Eqwfie71VXw5P/d8aQG3D2OfnBfFl2hlVupMAxcdHjl2z JV8A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTPS id b81si7330630pfm.54.2017.10.09.09.06.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 09 Oct 2017 09:06:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 63EFC6E12D; Mon, 9 Oct 2017 16:06:10 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-oi0-f65.google.com (mail-oi0-f65.google.com [209.85.218.65]) by gabe.freedesktop.org (Postfix) with ESMTPS id 356EC6E12D for ; Mon, 9 Oct 2017 16:06:09 +0000 (UTC) Received: by mail-oi0-f65.google.com with SMTP id j126so16995071oib.8 for ; Mon, 09 Oct 2017 09:06:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id; bh=mBeBEjHolpVWjkd0aTblSwPktE8QEupCgDQKhJzqTqU=; b=BDBnWo1fWuhybdxC/lCZdZY5DSZtPs99OPxSc1OrKdTdXkzhzfEiczgKK4L23W1ai1 pvoOcRSTnpds/wD6n4r4olyMoBh4nFTNEKShHLRGer3MYfzKAHG44jCNhjNgKzad/1x4 4m+c+Jc+0BknEk2r9/X5R8fxdF6Y0zrke1qSfTPwKr+zsZT64H38Z2ARv2HY73nQJ/UT PHByujWruvcskwSKlGn26s2Fr3y3bUfpJIW3e3vOub47HqRwDOvt6mMwhRW4pee5w54D mxabbQpkFotxTkTKzGKlMKKrWCGM5NdUu6GHtUM/u2fFNAodjgUlq3VuflsdnfJZ/hCi uitA== X-Gm-Message-State: AMCzsaV3KAe97pLI2H/2lXUl5IFuk5/bF6IwdMyNfiz5gcrG+bvN4Mct VnuQszG8D9fb0Mg0HGAaoDnmWZk= X-Google-Smtp-Source: AOwi7QCoNXeLvry/JHNFOwSO7G2mypsBNgZd5/mu/+Blp6f5BBZVRN0YDbhFsArmN8dyVISFwudPGA== X-Received: by 10.202.192.8 with SMTP id q8mr5053843oif.243.1507565168166; Mon, 09 Oct 2017 09:06:08 -0700 (PDT) Received: from localhost.localdomain (216-188-254-6.dyn.grandenetworks.net. [216.188.254.6]) by smtp.googlemail.com with ESMTPSA id e124sm83375oia.30.2017.10.09.09.06.07 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 09 Oct 2017 09:06:07 -0700 (PDT) From: Rob Herring To: dri-devel@lists.freedesktop.org Subject: [PATCH hwc] drm_hwcomposer: fix return values for ValidateDisplay Date: Mon, 9 Oct 2017 11:06:04 -0500 Message-Id: <20171009160604.24008-1-robh@kernel.org> X-Mailer: git-send-email 2.11.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" According to the API documentation, if we've set num_types, then the return value should be HWC2::Error::HasChanges. Signed-off-by: Rob Herring --- drmhwctwo.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drmhwctwo.cpp b/drmhwctwo.cpp index 89399bf1ba33..0f258770a8bb 100644 --- a/drmhwctwo.cpp +++ b/drmhwctwo.cpp @@ -701,7 +701,7 @@ HWC2::Error DrmHwcTwo::HwcDisplay::ValidateDisplay(uint32_t *num_types, break; } } - return HWC2::Error::None; + return *num_types ? HWC2::Error::HasChanges : HWC2::Error::None; } HWC2::Error DrmHwcTwo::HwcLayer::SetCursorPosition(int32_t x, int32_t y) {