Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1103619pxu; Sat, 5 Dec 2020 04:17:22 -0800 (PST) X-Google-Smtp-Source: ABdhPJwIkWAW8zWevlgylPhrtZn0jqbY8cMU7fPMZeHTtfyfxiWrmuatCTjAcvgH+cRAAePDPDgw X-Received: by 2002:a17:906:c087:: with SMTP id f7mr5508776ejz.492.1607170642499; Sat, 05 Dec 2020 04:17:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607170642; cv=none; d=google.com; s=arc-20160816; b=XYRZhYFp7GOw9UvlMVpZdoiIkJbz6I0Abvv18dPPmr1mVYifncdRl2J8btZvjBEiNG VWn3cvdgSC8IucD59VfySbzLvRJHn5W4n59I8KfXApVAMNjzAbOZZfU+/GrpI8yJl+O6 janjQElMuJjKGkNmgQorKLkMXD+1v2DybMIRTnAMMsMMEcAFrCoxmhm8RBhQd3i/Db4q vad/1clKOPUQoxf7+wRLjqo/VqbEnsyl0ve8bBSKcskVyxSSwuBalwQXEYpmSfKeUR7W sYfKr5AoTJDXj3W5UGKquif0RxxCxIIyOvsR+a/IN/gPv1fFzKptjGMDTDxYyeIt0lRl cLIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:to:from; bh=LPghepud87i+Aav/otjYmL5cyvDVoCdMnb+eynbgYts=; b=AvAdyLzDqDGLHCdv1kLhQkn234DI/mo1YusfaKua8WNoe5wkvqKWGQ8KNBLWLI+QYo NKyrpcudoEzUDi0dtR4EJ6tDTDO/lIosA2JclbLX9PWIIzWrsNQq9sx/KWLcrhavtYjn ZOYjys18MFx9CpEBPeRU4AXrdvPOztHkrsY0LHPivl+4VznuzNw77jExB24NnN2B0Ssq 7ZbMX9IX2f0kJTmt0898mUhMbYuE+LsPzH0V59Nxl33PCJBxj5ZAHrhACuidW5MO1daw L48o7hcR1PM1VfaVPmc+x0KcIB+oOpwUfG8Xmq0t91M0dpZ+5BlWwCRxSMpcP0ziysP2 HCig== ARC-Authentication-Results: i=1; mx.google.com; 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 q12si4690751edi.141.2020.12.05.04.16.58; Sat, 05 Dec 2020 04:17:22 -0800 (PST) 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; 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 S1729578AbgLELVU (ORCPT + 99 others); Sat, 5 Dec 2020 06:21:20 -0500 Received: from honk.sigxcpu.org ([24.134.29.49]:56916 "EHLO honk.sigxcpu.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729531AbgLELQL (ORCPT ); Sat, 5 Dec 2020 06:16:11 -0500 Received: from localhost (localhost [127.0.0.1]) by honk.sigxcpu.org (Postfix) with ESMTP id C7B8FFB04; Sat, 5 Dec 2020 12:13:29 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at honk.sigxcpu.org Received: from honk.sigxcpu.org ([127.0.0.1]) by localhost (honk.sigxcpu.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZAMH5zkM__qE; Sat, 5 Dec 2020 12:13:28 +0100 (CET) Received: by bogon.sigxcpu.org (Postfix, from userid 1000) id 59BB14068E; Sat, 5 Dec 2020 12:13:26 +0100 (CET) From: =?UTF-8?q?Guido=20G=C3=BCnther?= To: Heikki Krogerus , Greg Kroah-Hartman , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, Andy Shevchenko Subject: [PATCH v5 0/2] usb: typec: tps6598x: Export some power supply properties Date: Sat, 5 Dec 2020 12:13:24 +0100 Message-Id: X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This allows downstream supplies and userspace to detect whether external power is supplied. The Librem 5 has the tp65982 in front of bq25980 charge controller. Since that is capable of sinking and sourcing power the online property helps to decide what to do. It also makes upower happy. There will be follow up patches providing more properties but these need some more time to cook and i wanted to check if this is the right way to go? changes from v4 - As per review comments from Andy Shevchenko https://lore.kernel.org/linux-usb/CAHp75Vfws_WMDxxpCpB1zSgbWucYx7-qeev6=mKE+znXSSPWSA@mail.gmail.com/T/#mb90b0f7dc49c4929590fa7fa0df53631b47a9285 - Use devm_kasprintf() - Add reviewed by from Andy Shevchenko, thanks! https://lore.kernel.org/linux-usb/CAHp75Vfws_WMDxxpCpB1zSgbWucYx7-qeev6=mKE+znXSSPWSA@mail.gmail.com/ changes from v3 - As per review comments from Andy Shevchenko https://lore.kernel.org/linux-usb/CAHp75VeLZtm85Y=3QMkPGb332wn05-zr-_mrrwXvnqLhazR1Gg@mail.gmail.com/ - Use positive conditionals - Add reviewed by from Heikki Krogerus https://lore.kernel.org/linux-usb/20201130102720.GA2911464@kuha.fi.intel.com/T/#u https://lore.kernel.org/linux-usb/20201130102942.GB2911464@kuha.fi.intel.com/T/#u - Fix typc vs typec typo in commit message changes from v2 - As per kernel test robot https://lore.kernel.org/linux-usb/202011271005.zJVawX74-lkp@intel.com/ - Flip USB_ROLE_SWITCH and REGMAP_I2C from 'depends on' to 'select' This matches tcpm and avoids a config symbol recursion which went unnoticed on my arm64 build but trips up x86_64. changes from v1 - As per review comments from Heikki Krogerus https://lore.kernel.org/linux-usb/20201126123552.GP1008337@kuha.fi.intel.com/ - select POWER_SUPPLY - use POWER_SUPPLY_USB_TYPE_PD when a PD contract got negotiated Guido Günther (2): usb: typec: tps6598x: Select USB_ROLE_SWITCH and REGMAP_I2C usb: typec: tps6598x: Export some power supply properties drivers/usb/typec/Kconfig | 5 +- drivers/usb/typec/tps6598x.c | 103 +++++++++++++++++++++++++++++++++++ 2 files changed, 106 insertions(+), 2 deletions(-) -- 2.29.2