Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2267919pxa; Fri, 7 Aug 2020 07:18:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxme3qnEridOl+NEOtUuvDvMnu0mWU7siOzbMedVZYICO/cgo1UUaEDYRjJ//JTDVKtVx4M X-Received: by 2002:a17:906:15cc:: with SMTP id l12mr9928528ejd.7.1596809899077; Fri, 07 Aug 2020 07:18:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596809899; cv=none; d=google.com; s=arc-20160816; b=FPamebBpdYwD+8iX4ICyWmrnQ7xzwwEHF0/gNI6J3JbLNwXCQT+n1gYkHJCnUg6go+ z5W89Vq9b1aI4AfkVyPaWj20B+tkZVjc9eutFuYB/EBkrcSazh/TRRs65PcxwZGw5TZ1 HCK7va3QoLhlU02opY/yF6nnGYc/h4An7uou9Mm4evMqK2E1iL6o3EAmwSgeKp3406z3 c8f5hDzFg5P6bYRVQl3wZ0FcVfaVeaQnVIEkWm7BNw4R9ojB4AGEMAh59+ZxN1H7s0Mn 89i6ue9s1tSH9QXXFM5rbW6GGlDxX5H8IGEyiwN/FLxFOAZmIsItA7gLEqzy0xzn5Rdd 5ICw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:mime-version:user-agent:date :message-id:autocrypt:from:references:cc:to:subject:dkim-signature; bh=3rNHsQd+IJnmQRGECHNVlsy5npf2obdnNWTh+jrObj0=; b=XqTwgHLZobEPSRBdAVWl/5IAn1D8xWXD8OE2ovRi11zkCpE8seJC/g2Nwe27pMecWN gyZYlsz3WDQTVSBOIi/Eqh7cMWpVOvLPKsallIurhwly1zCeTePmxqi9DewJaXM8/KFR AJlMCwEtve60Tr4ab+hKhnnOJrhcWlmpaEed9EtZxhcQsYpznbinnchtRNAaDpfghCcF HRZvDCest7SrLaypgo637jJZcNEzby9YarQr0Lgqd8l82YHu4+e4shAvnVlhJlTwaC7d Y1IaRcLoFNLndBkiZLQa8OypiVJc1MCSTzkXSk7v8bY7PUp8Fylbl8etqxce5IRPyRCt Sqpw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=invKBJUB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v10si5210161eds.470.2020.08.07.07.17.55; Fri, 07 Aug 2020 07:18:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=invKBJUB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726563AbgHGOPk (ORCPT + 99 others); Fri, 7 Aug 2020 10:15:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43334 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726159AbgHGOPj (ORCPT ); Fri, 7 Aug 2020 10:15:39 -0400 Received: from mail-pj1-x1044.google.com (mail-pj1-x1044.google.com [IPv6:2607:f8b0:4864:20::1044]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7C991C061756; Fri, 7 Aug 2020 07:15:39 -0700 (PDT) Received: by mail-pj1-x1044.google.com with SMTP id c6so946137pje.1; Fri, 07 Aug 2020 07:15:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:autocrypt:message-id:date :user-agent:mime-version:in-reply-to; bh=3rNHsQd+IJnmQRGECHNVlsy5npf2obdnNWTh+jrObj0=; b=invKBJUBBomIVacgxCMF4eSLms0SmO+PF198I/M24ObdPQArlyGpwIj4N/BkZ7Dnd0 aJYgskV+X+CRdkHfKmq3hWVG5RbhhRx5iaDFKQ9Z0E/BCdMrhcUmU8GATiPmCTriWxXr lxZwh8BDqtiDgu1USkp9IJXBq9M4d+iv/oC5wC3te1OEyRnFryPbhwwznYkz3DMisnOD TStqMMU5M1NnmmTSCAffcI3E4whisp3jkOusxDW1JyBGPUO1O84Dv3SUWoG6xdy4TL8U kAmAlLCsN9PfjABj0AlsFr9JisBpv7bmgIIJS6JSvQDYfKu3jmh/DbIlOkUL+7aX2Imh 70qw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:autocrypt :message-id:date:user-agent:mime-version:in-reply-to; bh=3rNHsQd+IJnmQRGECHNVlsy5npf2obdnNWTh+jrObj0=; b=ghvpsZ/L1zOPzMn3XpOoK2Hc8fhCCkBObI/yUCCD8RyvoWoPM46YTTmyDaZA02Tvkp Y8pparBL1IlHIwYD1iOh788xXDmyN6xZT32YmgvQPYWTfZr93/ut8uqyEFp246i+79ps XXnHTAKUMVqcHga4k/8BOc3n3OHUgYQwuH0FOulOyw64t/IvJC7F07Ah57AFdGeLfeWl UgMu7c2GgcUHbcbqy5eVelJyguFO6852Nur4oUR7NhJKGPlX5rZ66jr+uxpAfVbCWJtN MthP8BtUriB1NCHlNRuKU3MZ0OySZityn24tCob10agMdFfsfITvqnFN+lAcfhrDaZJT PPFw== X-Gm-Message-State: AOAM533tHbnEabOFpI4s8JWq+9cMa4r5rOGyX6fzuern8O3lbHRmlQiv loxUsabvDptWnpmRiAMp8bBKXZxJ X-Received: by 2002:a17:902:bb82:: with SMTP id m2mr12583154pls.115.1596809738865; Fri, 07 Aug 2020 07:15:38 -0700 (PDT) Received: from server.roeck-us.net ([2600:1700:e321:62f0:329c:23ff:fee3:9d7c]) by smtp.gmail.com with ESMTPSA id u24sm12671958pfm.20.2020.08.07.07.15.36 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 07 Aug 2020 07:15:37 -0700 (PDT) Subject: Re: [PATCH] hwmon/pmbus: use simple i2c probe function To: Stephen Kitt Cc: Jean Delvare , linux-hwmon@vger.kernel.org, linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org References: <20200806161645.9437-1-steve@sk2.org> <5f7b5828-cb7c-127a-e454-6c8b8d98777b@roeck-us.net> <20200806221232.278c3878@heffalump.sk2.org> <20200807082327.02e8a682@heffalump.sk2.org> From: Guenter Roeck Autocrypt: addr=linux@roeck-us.net; keydata= xsFNBE6H1WcBEACu6jIcw5kZ5dGeJ7E7B2uweQR/4FGxH10/H1O1+ApmcQ9i87XdZQiB9cpN RYHA7RCEK2dh6dDccykQk3bC90xXMPg+O3R+C/SkwcnUak1UZaeK/SwQbq/t0tkMzYDRxfJ7 nyFiKxUehbNF3r9qlJgPqONwX5vJy4/GvDHdddSCxV41P/ejsZ8PykxyJs98UWhF54tGRWFl 7i1xvaDB9lN5WTLRKSO7wICuLiSz5WZHXMkyF4d+/O5ll7yz/o/JxK5vO/sduYDIlFTvBZDh gzaEtNf5tQjsjG4io8E0Yq0ViobLkS2RTNZT8ICq/Jmvl0SpbHRvYwa2DhNsK0YjHFQBB0FX IdhdUEzNefcNcYvqigJpdICoP2e4yJSyflHFO4dr0OrdnGLe1Zi/8Xo/2+M1dSSEt196rXaC kwu2KgIgmkRBb3cp2vIBBIIowU8W3qC1+w+RdMUrZxKGWJ3juwcgveJlzMpMZNyM1jobSXZ0 VHGMNJ3MwXlrEFPXaYJgibcg6brM6wGfX/LBvc/haWw4yO24lT5eitm4UBdIy9pKkKmHHh7s jfZJkB5fWKVdoCv/omy6UyH6ykLOPFugl+hVL2Prf8xrXuZe1CMS7ID9Lc8FaL1ROIN/W8Vk BIsJMaWOhks//7d92Uf3EArDlDShwR2+D+AMon8NULuLBH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EsFKFOkynOs3pVbcbq1pxbhk3TRWCGRU5JolI4ohy/7JV1TVbjiDI HP/aVnm6NC8of26P40Pg8EdAhajZnHHjA7FrJXsy3cyIGqvg9os4rNkUWmrCfLLsZDHD8FnU mDW4+i+XlNFUPUYMrIKi9joBhu18ssf5i5Q= Message-ID: Date: Fri, 7 Aug 2020 07:15:35 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <20200807082327.02e8a682@heffalump.sk2.org> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="D3ziB1DQZlBAttgUfYcal3w192NzPdJNj" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --D3ziB1DQZlBAttgUfYcal3w192NzPdJNj Content-Type: multipart/mixed; boundary="JzkhzGad8BZEbvPNhybNQ4DCkage2QZje" --JzkhzGad8BZEbvPNhybNQ4DCkage2QZje Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 8/6/20 11:23 PM, Stephen Kitt wrote: > On Thu, 6 Aug 2020 14:48:58 -0700, Guenter Roeck w= rote: >> On 8/6/20 1:12 PM, Stephen Kitt wrote: >>> On Thu, 6 Aug 2020 12:15:55 -0700, Guenter Roeck = >>> wrote: =20 >>>> On 8/6/20 9:16 AM, Stephen Kitt wrote: =20 > [...] >>>> Also, I am not convinced that replacements such as >>>> >>>> - { "ipsps1", 0 }, >>>> + { .name =3D "ipsps1" }, >>>> >>>> are an improvement. I would suggest to leave that alone for >>>> consistency (and to make it easier to add more devices to the >>>> various drivers if that happens in the future). =20 >>> >>> From reading through all the drivers using id_table, it seems to me t= hat >>> we could do away with driver_data altogether and move all that to >>> driver-local structures, in many cases covering more than just an id.= By >>> only initialising the elements of the structure that are really neede= d, I >>> was hoping to (a) make it more obvious that driver_data isn=E2=80=99t= used, and >>> (b) allow removing it without touching all the code again. >>> =20 >> >> I don't see it as an improvement to replace a common data structure wi= th >> per-driver data structures. That sounds too much like "let's re-invent= >> the wheel over and over again". If that is where things are going, I'd= >> rather have it implemented everywhere else first. I am ok with the oth= er >> changes, but not with this. >=20 > I agree, and I wasn=E2=80=99t intending on encouraging re-inventing the= wheel in each > driver. Let=E2=80=99s focus on probe_new for now... >=20 > What did you mean by =E2=80=9Cto make it easier to add more devices to = the various > drivers if that happens in the future=E2=80=9D? There are already many = drivers with > multiple devices but no driver_data, dropping the explicit driver_data > initialisation doesn=E2=80=99t necessarily make it harder to add device= s, does it? >=20 There is an existing mechanism to identify devices based on the device ID= , should that be necessary. I am not inclined to let people invent a separate per-driver mechanism unless the kernel community decides that this is the way to go. Thanks, Guenter --JzkhzGad8BZEbvPNhybNQ4DCkage2QZje-- --D3ziB1DQZlBAttgUfYcal3w192NzPdJNj Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEiHPvMQj9QTOCiqgVyx8mb86fmYEFAl8tYgcACgkQyx8mb86f mYHgXA/9G2TBy36pfKt10TOh5xKEsal0OfqImvfi8xN8RFbEb9z4Lv1x/TGZA0g9 JxWzzesGB5ijrZJ+toXTfbn4Yz9Fa3QsdFs71LRV/pDu3mXvjiu/awJtX2ETf7wB 5kGx7ndUwrm5blXMkEiRf9mwOen4fof+hwxylJfm7UBKaspRsAQq4//ucH1uMjgy Lx0jR4ogwnvUGwWi95DqFQ98tyAuJKF6x65HwxYauA/XiyZXytjOzfrXUkePlhQJ x0gMfhLtOIMp+H0oMCqu1aKRrOfZYZi/oJ6aD+9B5Em2jL1LjVWUrrA1Ft0+30ES zFP0mwayGcnh0rGqEUp3GN1zlqnVsrkSDSC0Bh4OztZHD6h/bPo4T0Vg4v+eN/Hl JzauCcvGpN/lScQt75UD4PuLXEp3FWcEOyTuteqWO+jfZFTyjKlPI7qEgrZrvtR2 q9ULXRZF+Zg534crmbPyg5X7pUf1tyvX2Z+hJalCUREYBh+urxmUGko8afRnwg97 gEILEhVJZVsladGvsS8o+jrCzYMRBotDy+Ys42X63Wx3x3SurLS56W3KWHF3t6TQ CfQ2hMpouhvXZLDx9XlZ/9XuH5MA3LVkQwybwWL6nbWP5w6g3QQOZ97up7HjCU00 KIUNQl2PAnvb3TYBx0lZ4Wzj8yT7lhEYObv1sHvzNAjJCyk6MnE= =TNBo -----END PGP SIGNATURE----- --D3ziB1DQZlBAttgUfYcal3w192NzPdJNj--