Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp7102774rwd; Tue, 6 Jun 2023 06:28:37 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6LWZjfuXk32++45zujMKP75hJ2P0Zk8QlxT7FP7yEue+4w9Sn8xcK/lR1vVwzzCY0Begag X-Received: by 2002:a05:620a:4889:b0:75b:23a0:e7c9 with SMTP id ea9-20020a05620a488900b0075b23a0e7c9mr1700214qkb.42.1686058117532; Tue, 06 Jun 2023 06:28:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686058117; cv=none; d=google.com; s=arc-20160816; b=b2XZ7QE1ms5H5iEK4huD2sSb9ehtxBIZ75/qNuZiIWrR1PmqQ2rL5dqZFQTFdZpw7q CwiyWiyxRR89yga65gkI4iRUPWlNTe2rCR4qJhaZfHp/x01cwSSi0aUjErPEasimHqi8 15jwSqSYJlUGm1Dfz73OxodOvFBlDQw326bRfesMfNTFLRxgy2B2Sm4sZKWwYVsezmG5 Un5uybVb+qOTuKtM372pScUN1myOucbX6yI2wrTzy/K4M8IF5ObcMURG/YPkq7BLzwzo +tsqPTg5zpqo1+pEbuIHSqeQeaul3SvDth8YYecklTT7l5twY3dfb77dI3SEDHxVqQ/c H1Tg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :organization:in-reply-to:subject:cc:to:from:dkim-signature; bh=i7xOkIK1TrLXFama5gktRqgISCAbAaF+QEHFux5NNSg=; b=G/0zUO4BVzCR2Rfwn52FSPrugdl33FG1BkVtDBWXW+BCEBm6ywNXyt8VoyN3WpUPl5 3bShOUozqOz5CcUoWWSsxmzhQKHocPxrsqVJhUSXqIbxDqNCHy+893e8vPvPJxoLqtXt gsXEB3GLIjNk6V0hY332FE3dLSo9uYUdbuVpYI8jTeZn+fNF39xhibC6bnl9mSDgq7wf f+3m9npTkNAWfMNffPplwPeeEcD3OJKqtqxcShlBUfDP6sl3TKqysXKQGyGray+0TJ6/ S+oiSm5B1fm7cfKiaf0QUkvAFm7jLyk3DO36WrIZlN2kQf+GVXzkmRwou5CjuMPtYk+c KzSQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=HuuuH8Ua; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y72-20020a62644b000000b006434e20d01asi6989407pfb.199.2023.06.06.06.28.24; Tue, 06 Jun 2023 06:28:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=HuuuH8Ua; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238011AbjFFNI4 (ORCPT + 99 others); Tue, 6 Jun 2023 09:08:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37766 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237768AbjFFNIy (ORCPT ); Tue, 6 Jun 2023 09:08:54 -0400 Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 31F2F170F for ; Tue, 6 Jun 2023 06:08:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1686056915; x=1717592915; h=from:to:cc:subject:in-reply-to:references:date: message-id:mime-version; bh=EGypTDkiiflKHYna6oC/dC9BQiC2e9SaCPgHT4ONrUQ=; b=HuuuH8UalcIaVBXkDeVDDr5dzhozbp2jx3OM2CafOpBYcyzU6LH1gJnm Z2jVzcy3VQkXzLXVA7jUnBLYW/I4AI8MpB8lE0Q27bbFWrAM0hU3ZOCLQ Gs2A+PXqiQ9TGYwSKet3ioRC6r+jwX/LvAwEvQQ8OHlEI8MJDL3tllsWp uXxq7oroJA47llteKIJ5xu/x//Mr5OqbFqFfEPoNkWcSf1AF+NBUvfPsk HiXpYwi+tFqiqv9WZugd8ABSxxwsafWNu7WIVjAQUPVS5nlwF+IIiVqJP plt3qdBrysvZ/GwB0CEmQlrtz54HvbZ6x6Tf67w2/vuOSHvsmG3bP81aK A==; X-IronPort-AV: E=McAfee;i="6600,9927,10732"; a="443041112" X-IronPort-AV: E=Sophos;i="6.00,221,1681196400"; d="scan'208";a="443041112" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Jun 2023 06:07:58 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10732"; a="821626227" X-IronPort-AV: E=Sophos;i="6.00,221,1681196400"; d="scan'208";a="821626227" Received: from abobyr-mobl1.ccr.corp.intel.com (HELO localhost) ([10.252.59.4]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Jun 2023 06:07:53 -0700 From: Jani Nikula To: Laurent Pinchart , Siddh Raman Pant Cc: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Suraj Upadhyay Subject: Re: [PATCH v9 1/8] Revert "drm: mipi-dsi: Convert logging to drm_* functions." In-Reply-To: <20230606125537.GC25774@pendragon.ideasonboard.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo References: <20230606125537.GC25774@pendragon.ideasonboard.com> Date: Tue, 06 Jun 2023 16:07:47 +0300 Message-ID: <87pm68u4bg.fsf@intel.com> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 06 Jun 2023, Laurent Pinchart wrote: > Hi Siddh, > > Thank you for the patch. > > On Tue, Jun 06, 2023 at 04:15:15PM +0530, Siddh Raman Pant wrote: >> This reverts commit 1040e424353f5f4d39f6f3aa8723eb3bd6ea6446. >> >> It used an incorrect way to use drm_* functions. Only drm_device ptrs >> should be passed, but the mentioned commit passed mipi_dsi_host ptr. >> It worked by accident due to macro magic. >> >> Reported-by: Jani Nikula >> Reviewed-by: Jani Nikula >> Signed-off-by: Siddh Raman Pant > > Reviewed-by: Laurent Pinchart > > Any chance we could prevent this from happening by turning the macros > into inline functions ? Patch 2 adds static inline struct device *__drm_dev_ptr(const struct drm_device *drm) which should tackle this. BR, Jani. > >> --- >> drivers/gpu/drm/drm_mipi_dsi.c | 15 ++++++++------- >> 1 file changed, 8 insertions(+), 7 deletions(-) >> >> diff --git a/drivers/gpu/drm/drm_mipi_dsi.c b/drivers/gpu/drm/drm_mipi_dsi.c >> index 3fd6c733ff4e..a37af4edf394 100644 >> --- a/drivers/gpu/drm/drm_mipi_dsi.c >> +++ b/drivers/gpu/drm/drm_mipi_dsi.c >> @@ -33,7 +33,6 @@ >> >> #include >> #include >> -#include >> >> #include