From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B2DBFC2D0CC for ; Thu, 15 Dec 2022 14:25:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229562AbiLOOZi (ORCPT ); Thu, 15 Dec 2022 09:25:38 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47100 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229517AbiLOOZg (ORCPT ); Thu, 15 Dec 2022 09:25:36 -0500 Received: from smtp-fw-80007.amazon.com (smtp-fw-80007.amazon.com [99.78.197.218]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 81F212A271; Thu, 15 Dec 2022 06:25:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1671114336; x=1702650336; h=message-id:date:mime-version:to:cc:references:from: in-reply-to:content-transfer-encoding:subject; bh=fB0YJoTNZ13u7b2pqa9Vd0vWw8xXi7NcxGaEYks4tfA=; b=gKIoJFpcY80ieHrgK6Ur86U8vYFs6i0G4lMGVecIwJUxkTW9HNaqYNPU S5y5+eVHy71qOAn5BKTfh+GqVGVnC0p14L9hKpNBI8WHv9AhjnpYRP9bW 52oQUoO44Gm27E7K9Tl25ulDT6fd91IDNiuE/pPyvmu50WtNiZPjQcXuG 0=; X-IronPort-AV: E=Sophos;i="5.96,247,1665446400"; d="scan'208";a="161790187" Subject: Re: [PATCH v2 1/1] i2c: designware: set pinctrl recovery information from device pinctrl Received: from pdx4-co-svc-p1-lb2-vlan3.amazon.com (HELO email-inbound-relay-iad-1e-m6i4x-6e7a78d7.us-east-1.amazon.com) ([10.25.36.214]) by smtp-border-fw-80007.pdx80.corp.amazon.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Dec 2022 14:25:33 +0000 Received: from EX13MTAUWB001.ant.amazon.com (iad12-ws-svc-p26-lb9-vlan2.iad.amazon.com [10.40.163.34]) by email-inbound-relay-iad-1e-m6i4x-6e7a78d7.us-east-1.amazon.com (Postfix) with ESMTPS id CAAE78224C; Thu, 15 Dec 2022 14:25:29 +0000 (UTC) Received: from EX19D013UWB003.ant.amazon.com (10.13.138.111) by EX13MTAUWB001.ant.amazon.com (10.43.161.207) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Thu, 15 Dec 2022 14:25:29 +0000 Received: from EX13MTAUWB001.ant.amazon.com (10.43.161.207) by EX19D013UWB003.ant.amazon.com (10.13.138.111) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA) id 15.2.1118.20; Thu, 15 Dec 2022 14:25:29 +0000 Received: from [192.168.110.120] (10.85.143.173) by mail-relay.amazon.com (10.43.161.249) with Microsoft SMTP Server id 15.0.1497.42 via Frontend Transport; Thu, 15 Dec 2022 14:25:24 +0000 Message-ID: <9a31329e-ca83-84de-7958-4c795c2ccda6@amazon.com> Date: Thu, 15 Dec 2022 16:25:24 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.5.0 Content-Language: en-US To: Linus Walleij , Andy Shevchenko CC: Wolfram Sang , , , , , , , , , , , , , References: <20221214142725.23881-1-hhhawa@amazon.com> From: "Hawa, Hanna" In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 12/15/2022 4:06 PM, Linus Walleij wrote: >> Getter with a stub sounds better to me, so you won't access some device core >> fields. >> >> Linus, what do you think about all these (including previous paragraph)? > A getter may be a good solution, it depends, it can also be pushed > somewhere local in the designware i2c driver can it not? > I am thinking that the rest of the code that is using that field is > certainly not going to work without pinctrl either. the compilation failure occurs on platform which not define the CONFIG_PINCTRL , most of the pinctrl APIs are wrapped with PINCTRL config, for example pinctrl_select_state() or devm_pinctrl_get(). In addition if we add the getter in pinctrl/devinfo.h other drivers may access the pins field without re-call devm_pinctrl_get(). Thanks, Hanna