Message ID | 1525307094-27402-14-git-send-email-jun.li@nxp.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-usb-owner@kernel.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id EFA3F60384 for <patchwork-linux-usb@patchwork.kernel.org>; Thu, 3 May 2018 00:42:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E080429137 for <patchwork-linux-usb@patchwork.kernel.org>; Thu, 3 May 2018 00:42:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D49FC29153; Thu, 3 May 2018 00:42:36 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4640029137 for <patchwork-linux-usb@patchwork.kernel.org>; Thu, 3 May 2018 00:42:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751885AbeECAme (ORCPT <rfc822;patchwork-linux-usb@patchwork.kernel.org>); Wed, 2 May 2018 20:42:34 -0400 Received: from mail-eopbgr10042.outbound.protection.outlook.com ([40.107.1.42]:55200 "EHLO EUR02-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751708AbeECAmd (ORCPT <rfc822;linux-usb@vger.kernel.org>); Wed, 2 May 2018 20:42:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=O2Sxt+Xlbv7BYPXcYC+owqkkO4G6B95Y8+tmBPhhzNQ=; b=qboqfuha9wEeltIn/yO0UoQXY8XDw4h/rd4+o/E9+UGAUWhzp/YSJlK8IK/1tlGdyWuXxlwSN3BV1xCnOGqoFGC9KIZ1Guu51QQeR6JuxahJDGYi93DaLgqUJeoH1YMb5B2k2S9GmaRAgkxHnuq51SXSbHuG+UP0Zb8wuCp8WRM= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=jun.li@nxp.com; Received: from b47624-OptiPlex-7040.ap.freescale.net (92.121.68.129) by DB3PR0402MB3914.eurprd04.prod.outlook.com (2603:10a6:8:f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.715.24; Thu, 3 May 2018 00:42:24 +0000 From: Li Jun <jun.li@nxp.com> To: robh+dt@kernel.org, gregkh@linuxfoundation.org, heikki.krogerus@linux.intel.com, linux@roeck-us.net Cc: jun.li@nxp.com, a.hajda@samsung.com, cw00.choi@samsung.com, shufan_lee@richtek.com, peter.chen@nxp.com, gsomlo@gmail.com, devicetree@vger.kernel.org, linux-usb@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v5 13/14] staging: typec: tcpci: Only touch target bit when enable vconn Date: Thu, 3 May 2018 08:24:53 +0800 Message-Id: <1525307094-27402-14-git-send-email-jun.li@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1525307094-27402-1-git-send-email-jun.li@nxp.com> References: <1525307094-27402-1-git-send-email-jun.li@nxp.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [92.121.68.129] X-ClientProxiedBy: OSAPR01CA0012.jpnprd01.prod.outlook.com (2603:1096:603:2a::24) To DB3PR0402MB3914.eurprd04.prod.outlook.com (2603:10a6:8:f::29) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(48565401081)(5600026)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:DB3PR0402MB3914; X-Microsoft-Exchange-Diagnostics: 1; DB3PR0402MB3914; 3:zlH58DrH2qZOdi1UTTKioPbcOzAwcUm0QxnIFYjALiEBdwaAqgVpGntIv/uMIktWcAVgTTNLyrZkwZdYfJtyqS1yt26BIl7J/NT3M3pLYV13xjFEozoKBytApvscvcliY7B33ABDKGkwOBsgJhWlQfpTST1YI89uAV4Ck9KjMp/Z388KG8MeT/ApJOf/ev8MTmNbj/1EOT0kLDFBjZ8a7dBnW9PP22quY2C3Dh8yoGKvBnoT+Da6SNxbTPZc1Jqi; 25:F920eyDGwLk1ghpC9BhpPt1CW7xUql08SoOGDHOZQaaYOH9sXeukZfMqkgoXAk6DJoRrlR4K2kob6lf3zkKQs3EUnbe5sWJFBDGTgyyShwVFPPa/TqS9YUGYwiVcuewXe7fuZrKObiebH3+q2pyUMYaRxOPo02ZB8UZIxorEmq34l9jJAhSjF25Vngx/L7IQjHGVV6WHh7UOdbhY7OdubCjbY4dlmW1ZMda3QbS4w2CO1NFiKNDgcT691pREDlkQNyNnw1QaJCvPUhxYqC6v3z7dnNaxGHutc+g4Amf7GavQP4DYF95BQ6PYDMQiCIHcnxFD8rEETC8Q+vAa0pvqwg==; 31:VCMblnAeIGJwFYa34Upyl8Ieq2Eup2NBXE8o0IZYihfCYK/N+59vLgqHFEaVbMT0rrTtakaOKhcrDuVMhK6bqGkFUGhu+HmT8rE/WmKeciJBtwhexCzaSPu/KsBLMlAWiwRIWA0QZV4sY6g0kfjv4stG99+VKBMn9G6RPE3ce1oKFdtXTadTmoPLE6VJyAjkNQv+9hkjWARCgPka7ihGpztSp7C0LN1f6Nek+vNaSx4= X-MS-TrafficTypeDiagnostic: DB3PR0402MB3914: X-Microsoft-Exchange-Diagnostics: 1; DB3PR0402MB3914; 20:uaJFQzg2rjw9spm2g0r704DbLa8Abj3fIFRWN25XwKGMGMuUZSgRFSploTGCEcK0i+pQNFlzsAwKpoG+ZIMF3Aw/rTCsM1sxRPsvho+UgojusMxVKpsNIfAKBCeTt1e3WFm5cThE4ZkkEpbopN+FwfwdcitIBnPaLVeR9583BSHHcdGFj7qTOejsl8/HvWnTDngM0U2qh6a6X8aOPw0fvadPCy/ETcQmpHapQ0lR17Vl2swquv4ozvIXTFknOSGbhFDiVBzOaJDl8F21kGo9TVp1QZr0t2QJ9hW8hnYEHYXJ5kqakav6bATW3fbflIOXzVxOHsBFAL2XdlmHScggbLggzPT9biAjVlqn2sKXwsX7Sr7t5BEuVzi84WjANZMgTuJJkK895VoXMsT4QG4qeBdUx4t51K/BS5C28kbxm2B2hzBLhpstRvOK2DyDDRnitMQN5AozfU/w4AbICU6XZ9yO08UEAZm/cWP5FDYCAP0CFauoja/Sf+uwZ+wAX2FA; 4:zXg5RtVzAN0mjZHpqeAIf5O2jMsoU7Lp1Xyep+CF5L3Wl1jXdZhxkq6JEVnN5gHttkQFYbf2c7TsnLRTJJV+OCB5/xN6KBM7jdi5pMZ9pIs7HacP7TOWru4hOHZDbMYlF4yCm00SihzhMuvqkIAjLircnX+1HNdr4lL4OeUhc3Z3IIQuWOliW/zMbWAj7YNgxtPL80IKF99X7n882hBSfGJvC49qYl8hQsdOvaK9nsX+yHmmEsDknqHmBac+CvBHduqEerAMlGGJ9tyoeFNgII2gtyXX89dcacmJdSBojGsvHY/fw75U5A+70xXF/1C7 X-Microsoft-Antispam-PRVS: <DB3PR0402MB3914418867ADFE3FD667B53789870@DB3PR0402MB3914.eurprd04.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3002001)(93006095)(93001095)(10201501046)(3231254)(944501410)(52105095)(6055026)(6041310)(20161123562045)(20161123560045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123564045)(6072148)(201708071742011); SRVR:DB3PR0402MB3914; BCL:0; PCL:0; RULEID:; SRVR:DB3PR0402MB3914; X-Forefront-PRVS: 066153096A X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(396003)(39380400002)(376002)(39860400002)(346002)(366004)(189003)(199004)(7416002)(47776003)(7736002)(8936002)(66066001)(305945005)(106356001)(2906002)(5660300001)(6486002)(105586002)(6116002)(3846002)(6666003)(81166006)(8676002)(50226002)(68736007)(81156014)(36756003)(956004)(2616005)(386003)(16586007)(476003)(50466002)(6506007)(59450400001)(6512007)(97736004)(316002)(446003)(39060400002)(575784001)(52116002)(26005)(76176011)(48376002)(4326008)(5890100001)(11346002)(486006)(16526019)(86362001)(51416003)(53936002)(186003)(478600001)(25786009); DIR:OUT; SFP:1101; SCL:1; SRVR:DB3PR0402MB3914; H:b47624-OptiPlex-7040.ap.freescale.net; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DB3PR0402MB3914; 23:nzoE4pVFW3KNRfLvpGB9op05CqusKWtCsqeJyAy?= =?us-ascii?Q?OjxY5t+31hKjesiWLoZIxHdEC0FH9K21S/xmiRWdqaE75xizBITd4XvyPjuD?= =?us-ascii?Q?Wvcoxir9W7fOdCGiG2AAdBYBcARIlHCvAmZCkskOYwGYLesuBHtrP+j6kHqZ?= =?us-ascii?Q?n2B5bU4HxiQKd29ohJJx5ET8MvA2+r+w/pq0G5emnrrkncg1AV4/GTRd1v4X?= =?us-ascii?Q?RyNewH88aOycE4vFMWZTUZBQko+LcHaV1OtUTSB4wTFUPEVKYD58At2r9mWl?= =?us-ascii?Q?zbwP7qPIthgIpU1S5TmXnQKs/i9v6HRV1S9pkyOua6f5MbfKNeHtrAAS2HcB?= =?us-ascii?Q?OvrFUxhMtd4iZiIjpqj/QxiIYwYnhjtCgu6WdAx6PMn7do2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1MAXdRs= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; DB3PR0402MB3914; 7:kLzABBQvrTTVW9CwaD60AQGK8VRUf652W4JGDeY59i9a180vzeHEyU9Kc16QFVtLTi/hMXKfyjZHfQ7rGdvaL8opithJsia4zmtz6PFEvu9nhuoOG1EnXm8b5aM7yzjQiH6zw0kW5FtSc6MQB0NGrcj6RUwd0AZ1OqGyl4TGIa2K1HU4WfKrBJop/HpLUogthjN4qMIXfBhrnqp2aLX++cNLJi3wJxMxHCWknb26iSFKB2bUAsH+ZD7sLLww+Pqv X-MS-Office365-Filtering-Correlation-Id: 0f0c7289-8620-4ccd-e736-08d5b08ec031 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 May 2018 00:42:24.3351 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 0f0c7289-8620-4ccd-e736-08d5b08ec031 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB3PR0402MB3914 Sender: linux-usb-owner@vger.kernel.org Precedence: bulk List-ID: <linux-usb.vger.kernel.org> X-Mailing-List: linux-usb@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/drivers/staging/typec/tcpci.c b/drivers/staging/typec/tcpci.c index 5c0c5e3..2818a4d 100644 --- a/drivers/staging/typec/tcpci.c +++ b/drivers/staging/typec/tcpci.c @@ -218,12 +218,9 @@ static int tcpci_set_vconn(struct tcpc_dev *tcpc, bool enable) return ret; } - ret = regmap_write(tcpci->regmap, TCPC_POWER_CTRL, - enable ? TCPC_POWER_CTRL_VCONN_ENABLE : 0); - if (ret < 0) - return ret; - - return 0; + return regmap_update_bits(tcpci->regmap, TCPC_POWER_CTRL, + TCPC_POWER_CTRL_VCONN_ENABLE, + enable ? TCPC_POWER_CTRL_VCONN_ENABLE : 0); } static int tcpci_set_roles(struct tcpc_dev *tcpc, bool attached,