Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp947360iob; Fri, 13 May 2022 17:22:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw8mSOOwaFBxNx1Jqrq50wMfZL6ia8oHVtlUzwcALtOAAMvBE2zslbeehk0Vjuc0CrR4owD X-Received: by 2002:a05:600c:1f0b:b0:395:c014:8cf with SMTP id bd11-20020a05600c1f0b00b00395c01408cfmr6727523wmb.32.1652487771776; Fri, 13 May 2022 17:22:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652487771; cv=none; d=google.com; s=arc-20160816; b=Rd4VebVuiyimnnBymuNXHZo6/VvMmQmvusfuaawGlfrJe9zzMVJSLuP9hTzklgLQUS FyXWIVMa4Z86v8UU+TzaBI+Q1PVEzNjNCjE9PDd2NvIn/3LEZO+VpGpt/KWyP90gN8wR FOXMTDUnpt4N5J3o9wlcZySxr9c5wIUMUPLtX/KBfI1i+17oKPFsu0ZqtLrXuN2LPXoV nAD1B+KcreuzfwTpcXTn6A4cXLwM/ZptiL2r0M6FH3wNhiI4aK1uMxfy8UbkV7uVYKXv Xk4DItfn7qJuJBeXfYMf2+8QTpEvwg5l5xeekzO1LQv/4Fa2S/zApBTBqPL9EjUjMG9Z eG3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:cc:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=rPnOfJw0T6UU7cqpzZ+d/TG5zakVBK0RQfAjuTld5dc=; b=Nn7nL8LjzYY3Uq+RAzKoeqX4qphIWrb3nkOMJHl8Q8MhCRkIYxcsj/G8uGm0Eaa1T9 U6GJZwqdMdKQFaL3IcjfacqZgZHmX5p6wK5dnirfvuHAHjArrMrStTqNvYEhn4SHaC/L E1CT25eie20sP7wUnduuiwiRBp6r3LFOFhp9fYPf+VIbz5uLl269S5zwX5ZMeUd4L4CV jg5ZF2kmHPt2aDcBoqeGKEW37Zpj1/2eq4vjuBEwtvG88Dg46MV+VDcblozowJCtBOCV PmgG/Wg5/Z6gX/QTEfeR+gPulad5WOumZ1U5iJqD/qcbWt26vgibAvWhWCjyfCxvzlww tp9g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=YZXHaZtN; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id y17-20020a056000109100b0020c53d7c75fsi2825618wrw.408.2022.05.13.17.22.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 May 2022 17:22:51 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=YZXHaZtN; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 57724B042F; Fri, 13 May 2022 16:18:16 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1355228AbiELOWn (ORCPT + 99 others); Thu, 12 May 2022 10:22:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40278 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1355263AbiELOWk (ORCPT ); Thu, 12 May 2022 10:22:40 -0400 Received: from mail-lf1-x12e.google.com (mail-lf1-x12e.google.com [IPv6:2a00:1450:4864:20::12e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7A3CB22440A for ; Thu, 12 May 2022 07:22:33 -0700 (PDT) Received: by mail-lf1-x12e.google.com with SMTP id t25so9363631lfg.7 for ; Thu, 12 May 2022 07:22:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:cc; bh=rPnOfJw0T6UU7cqpzZ+d/TG5zakVBK0RQfAjuTld5dc=; b=YZXHaZtN+wM0fntocGWGb1b1EH/wlmqNG9zz7r6nNiH2kTuGiEqXe/N32kDJ2Zo/BJ mnz3wtKsE8mQPjpUSr2RnYxmu8H6W0hhfgVhFMs5gM4gGOTN7N9E06ILVUV1fAMC6Q3x ch01vrumcL3PpLSBYwrsw/vXASJ/qbK2lGf8I= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:cc; bh=rPnOfJw0T6UU7cqpzZ+d/TG5zakVBK0RQfAjuTld5dc=; b=qWxo4EJO3Vf6seUpwkhz/2CtlVUsh/kCzGrxtYRX0NI+AgVc/MbpvQ+Jqbg2vBVeGn QJQJlhtBF7+HnT+wQ6t2bUjUb6/3Rwr18qPtjTOFdhT94NFl/6Ub7qpwLbGygg0xRuNn xwq/7aEltLF65ABTvPcdpmT4M4NBA4a1ZsImViabwSZ6L5KnhLms1G0AH/1KDLBcotGi VYIlll5damjp9Lbjrn0iMKj5eyKn+Ss2h88ZZxYfz1HSLGp/dDyZBAniNZG6xFJRADpw VDw6BBZ9fCTgcHHGnahUUYJsRpaJqZZ9sXicri2Vm80pW0JqALBNo5VSBz3dj4LQ8FJc GWDg== X-Gm-Message-State: AOAM531FieEe9qaBkq8Uany6Ng1I5NiPjBeUjdGS8XBzEWZ8efZnCfix kP2aDTO4cUaEHC5s/w5LB4n69iYcQG+QewdexUklUQ== X-Received: by 2002:a05:6512:e87:b0:44a:5117:2b2b with SMTP id bi7-20020a0565120e8700b0044a51172b2bmt9450lfb.275.1652365351715; Thu, 12 May 2022 07:22:31 -0700 (PDT) MIME-Version: 1.0 References: <20220510182810.1223574-1-markyacoub@chromium.org> In-Reply-To: <20220510182810.1223574-1-markyacoub@chromium.org> From: Mark Yacoub Date: Thu, 12 May 2022 10:22:21 -0400 Message-ID: Subject: Re: [PATCH] drm: Add a debug message when getting a prop is missing Cc: seanpaul@chromium.org, markyacoub@google.com, Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org friendly ping :) On Tue, May 10, 2022 at 2:28 PM Mark Yacoub wrote: > > [Why] > If a connector property is attached but > drm_atomic_connector_get_property doesn't handle a case for it, > modeteset will crash with a segfault without. > > [How] > Add a debug message indicating that a connector property is not handled > when user space is trying to read it. > > TEST=modetest > > Signed-off-by: Mark Yacoub > --- > drivers/gpu/drm/drm_atomic_uapi.c | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/drivers/gpu/drm/drm_atomic_uapi.c b/drivers/gpu/drm/drm_atomic_uapi.c > index acb1ee93d206..36b0f664dd80 100644 > --- a/drivers/gpu/drm/drm_atomic_uapi.c > +++ b/drivers/gpu/drm/drm_atomic_uapi.c > @@ -884,6 +884,12 @@ drm_atomic_connector_get_property(struct drm_connector *connector, > return connector->funcs->atomic_get_property(connector, > state, property, val); > } else { > + // LOG that the kernel is missing handling this property as a case here. > + drm_dbg_atomic( > + dev, > + "[CONNECTOR:%d:%s] Get Property [PROP:%d:%s] is not handled\n", > + connector->base.id, connector->name, property->base.id, > + property->name); > return -EINVAL; > } > > -- > 2.36.0.512.ge40c2bad7a-goog >