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 X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 95AADC433B4 for ; Thu, 15 Apr 2021 08:21:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5A4A16124B for ; Thu, 15 Apr 2021 08:21:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231553AbhDOIVk (ORCPT ); Thu, 15 Apr 2021 04:21:40 -0400 Received: from mga02.intel.com ([134.134.136.20]:40204 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231518AbhDOIVk (ORCPT ); Thu, 15 Apr 2021 04:21:40 -0400 IronPort-SDR: vLJQUkkVU4UnMXOO4aH9YLwwxslpLorRIsDT95wfQB7Dakfg2ux4x78x+5QmmK7iITM5NnC8yc V6iiuz3Q7kBg== X-IronPort-AV: E=McAfee;i="6200,9189,9954"; a="181935151" X-IronPort-AV: E=Sophos;i="5.82,223,1613462400"; d="scan'208";a="181935151" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Apr 2021 01:20:52 -0700 IronPort-SDR: 1lU7OEfzIb1pcf5QGGkQIq6NSWFeXJshxPIiKQv7zc0HQF052LS/JhAZBIYs638sShagaId8DW sSRCMj1iK0og== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.82,223,1613462400"; d="scan'208";a="421622671" Received: from dengjie-mobl1.ccr.corp.intel.com (HELO [10.239.154.55]) ([10.239.154.55]) by orsmga007.jf.intel.com with ESMTP; 15 Apr 2021 01:20:47 -0700 Subject: Re: [PATCH v10] i2c: virtio: add a virtio i2c frontend driver To: Wolfram Sang , Viresh Kumar , Arnd Bergmann , Linux I2C , virtualization@lists.linux-foundation.org, Linux Kernel Mailing List , "Michael S. Tsirkin" , Jason Wang , Andy Shevchenko , conghui.chen@intel.com, kblaiech@mellanox.com, jarkko.nikula@linux.intel.com, Sergey Semin , Mike Rapoport , loic.poulain@linaro.org, Tali Perry , =?UTF-8?Q?Uwe_Kleine-K=c3=b6nig?= , Bjorn Andersson , yu1.wang@intel.com, shuo.a.liu@intel.com, Stefan Hajnoczi , Paolo Bonzini References: <226a8d5663b7bb6f5d06ede7701eedb18d1bafa1.1616493817.git.jie.deng@intel.com> <20210323072704.rgoelmq62fl2wjjf@vireshk-i7> <20210415064538.a4vf7egk6l3u6zfz@vireshk-i7> <20210415072131.GA1006@kunai> <20210415072431.apntpcwrk5hp6zg4@vireshk-i7> <20210415072823.GB1006@kunai> <6849a8f0-204a-362a-ed97-e910065ab14f@intel.com> <20210415081828.GD1006@kunai> From: Jie Deng Message-ID: Date: Thu, 15 Apr 2021 16:20:47 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.7.0 MIME-Version: 1.0 In-Reply-To: <20210415081828.GD1006@kunai> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: linux-i2c@vger.kernel.org On 2021/4/15 16:18, Wolfram Sang wrote: > On Thu, Apr 15, 2021 at 04:15:07PM +0800, Jie Deng wrote: >> On 2021/4/15 15:28, Wolfram Sang wrote: >> >>>> Now that we were able to catch you, I will use the opportunity to >>>> clarify the doubts I had. >>>> >>>> - struct mutex lock in struct virtio_i2c, I don't think this is >>>> required since the core takes care of locking in absence of this. >>> This is likely correct. >> OK. Then I will remove the lock. > Let me have a look first, please. Sure. Thank you. >>>> - Use of I2C_CLASS_DEPRECATED flag, I don't think it is required for >>>> new drivers. >>> This is definately correct :) >> Do you mean a new driver doesn't need to set the following ? >> >> vi->adap.class = I2C_CLASS_DEPRECATED; >> >> Just leave the class to be 0 ? > Yes. DEPRECATED is only for drivers which used to have a class and then > chose to remove it. Got it. Thanks for your clarification. 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 X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 99E21C433B4 for ; Thu, 15 Apr 2021 08:20:58 +0000 (UTC) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1707B611F1 for ; Thu, 15 Apr 2021 08:20:58 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1707B611F1 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=virtualization-bounces@lists.linux-foundation.org Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id D056E60D85; Thu, 15 Apr 2021 08:20:57 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id eHu6QfE_h5ab; Thu, 15 Apr 2021 08:20:57 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp3.osuosl.org (Postfix) with ESMTP id 75C1160D83; Thu, 15 Apr 2021 08:20:56 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 5F2D0C000C; Thu, 15 Apr 2021 08:20:56 +0000 (UTC) Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) by lists.linuxfoundation.org (Postfix) with ESMTP id B8D02C000A for ; Thu, 15 Apr 2021 08:20:54 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id A747482A4F for ; Thu, 15 Apr 2021 08:20:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0t8mm4NwIgQQ for ; Thu, 15 Apr 2021 08:20:54 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by smtp1.osuosl.org (Postfix) with ESMTPS id 06CCF82909 for ; Thu, 15 Apr 2021 08:20:53 +0000 (UTC) IronPort-SDR: aRw6TA6ghXWeMBb6WhNf7VWy1neWzvspm+1r+oio4rp3tAxF4JbBezOXVsKodkNX2LyiABcFh8 XgNi3lzQEnXg== X-IronPort-AV: E=McAfee;i="6200,9189,9954"; a="194839148" X-IronPort-AV: E=Sophos;i="5.82,223,1613462400"; d="scan'208";a="194839148" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Apr 2021 01:20:52 -0700 IronPort-SDR: 1lU7OEfzIb1pcf5QGGkQIq6NSWFeXJshxPIiKQv7zc0HQF052LS/JhAZBIYs638sShagaId8DW sSRCMj1iK0og== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.82,223,1613462400"; d="scan'208";a="421622671" Received: from dengjie-mobl1.ccr.corp.intel.com (HELO [10.239.154.55]) ([10.239.154.55]) by orsmga007.jf.intel.com with ESMTP; 15 Apr 2021 01:20:47 -0700 Subject: Re: [PATCH v10] i2c: virtio: add a virtio i2c frontend driver To: Wolfram Sang , Viresh Kumar , Arnd Bergmann , Linux I2C , virtualization@lists.linux-foundation.org, Linux Kernel Mailing List , "Michael S. Tsirkin" , Jason Wang , Andy Shevchenko , conghui.chen@intel.com, kblaiech@mellanox.com, jarkko.nikula@linux.intel.com, Sergey Semin , Mike Rapoport , loic.poulain@linaro.org, Tali Perry , =?UTF-8?Q?Uwe_Kleine-K=c3=b6nig?= , Bjorn Andersson , yu1.wang@intel.com, shuo.a.liu@intel.com, Stefan Hajnoczi , Paolo Bonzini References: <226a8d5663b7bb6f5d06ede7701eedb18d1bafa1.1616493817.git.jie.deng@intel.com> <20210323072704.rgoelmq62fl2wjjf@vireshk-i7> <20210415064538.a4vf7egk6l3u6zfz@vireshk-i7> <20210415072131.GA1006@kunai> <20210415072431.apntpcwrk5hp6zg4@vireshk-i7> <20210415072823.GB1006@kunai> <6849a8f0-204a-362a-ed97-e910065ab14f@intel.com> <20210415081828.GD1006@kunai> From: Jie Deng Message-ID: Date: Thu, 15 Apr 2021 16:20:47 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.7.0 MIME-Version: 1.0 In-Reply-To: <20210415081828.GD1006@kunai> Content-Language: en-US X-BeenThere: virtualization@lists.linux-foundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Linux virtualization List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: virtualization-bounces@lists.linux-foundation.org Sender: "Virtualization" On 2021/4/15 16:18, Wolfram Sang wrote: > On Thu, Apr 15, 2021 at 04:15:07PM +0800, Jie Deng wrote: >> On 2021/4/15 15:28, Wolfram Sang wrote: >> >>>> Now that we were able to catch you, I will use the opportunity to >>>> clarify the doubts I had. >>>> >>>> - struct mutex lock in struct virtio_i2c, I don't think this is >>>> required since the core takes care of locking in absence of this. >>> This is likely correct. >> OK. Then I will remove the lock. > Let me have a look first, please. Sure. Thank you. >>>> - Use of I2C_CLASS_DEPRECATED flag, I don't think it is required for >>>> new drivers. >>> This is definately correct :) >> Do you mean a new driver doesn't need to set the following ? >> >> vi->adap.class = I2C_CLASS_DEPRECATED; >> >> Just leave the class to be 0 ? > Yes. DEPRECATED is only for drivers which used to have a class and then > chose to remove it. Got it. Thanks for your clarification. _______________________________________________ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization