Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp17769imm; Fri, 10 Aug 2018 06:59:44 -0700 (PDT) X-Google-Smtp-Source: AA+uWPy5bpVgBnIM1w2nt7EZ4d1vfRYPjmn8pUGfquEsoKrPUMm59xysUWa5aqNgXHo5Q2uD68Bq X-Received: by 2002:a63:da56:: with SMTP id l22-v6mr6583053pgj.179.1533909584665; Fri, 10 Aug 2018 06:59:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533909584; cv=none; d=google.com; s=arc-20160816; b=kdVf7FWeuR/Oesh3EtjVIyqD2QtYXW8SnLlO64NJ3aSlR+KlxrPxX073fNX5hbwovb uyFeR2JT8HKsh5qDyyjl8feGrUEe4MVdTMNfKueqZHQqpJhoZXejOvswx5euF/nvrNfE vJClWweivZbyPdvlMsiQAWB49sas7awLocPu48rW5IOSz5wbHhNoHX4fyHzyYEhPpG2L EfEzz6pCrJvh52SsbVthAN46mLMYprCmvHlth9h1FjAPD2saKc+t41Uvn4SfA+jHV6nJ 6jwPWQFKp3MHmx43kDWZn6A+kE3Ot5Dby4VuXtn53IkZc/oBuiGt4W5Xp1bpL7ZfKv/l 8tmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=EKERvPyccN5L6jSux9V7ILEhqtIjCsSZuoPK0qXWjtQ=; b=lnU5GIimTsGnnu2OWiZ7jEysE2DRtNU/imQZ7e7bKGI3Wd/JkYKuzgX7GIp/Kka/1l dLiVNkwiYf8yjgKi04ILuMDnj5RR33ZlukMDz/ZNbg+43AmlDQa8lCmDwFzTOxmGW1yP LM4NMPzx/Mg30kD9iSaenC3pHiC0Mt1nUFeSQT3TXt5cyWSD7lYFLUryQQktuhhPSHO6 ozkFIM4Uv7EkGYQPzBTCNfWs56FdzIf9vWx6WtPmpS3qNRGUUEluxKmtokOEWD4LVA4H oizrOf1gkbOmHX7hakU9fZnnz7vzg7D6Cg1gff77CFZNuabl2XkYLRinJHblRdlnsmvb YYMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=FlWt0QWQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r28-v6si10288525pfb.65.2018.08.10.06.59.28; Fri, 10 Aug 2018 06:59:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=FlWt0QWQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728326AbeHJPrM (ORCPT + 99 others); Fri, 10 Aug 2018 11:47:12 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:52508 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727704AbeHJPrL (ORCPT ); Fri, 10 Aug 2018 11:47:11 -0400 Received: by mail-wm0-f65.google.com with SMTP id o11-v6so1853272wmh.2 for ; Fri, 10 Aug 2018 06:17:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=EKERvPyccN5L6jSux9V7ILEhqtIjCsSZuoPK0qXWjtQ=; b=FlWt0QWQkvC2jCEGddZZXlWvOtTIqPrS7CDfGSQlO2pWIwqxoGMx2LcsyV+45S40ng 61Ev0E6Vwl+a3BykxHy65WOTDZMPveZ35Xts0aRCTZyRt15pY5uIbg8B2RsqYXXJ1I2W wz3YkhyIwVjODK5aBCF/y4PPVx5trIAyerNtr1CFducwBVJjpRzCoIx8pxjz7AKqEo+H 30AaZMivqxGiwGhUlfm7dVm3Koop4+Hgahh8s5DmU1CqbMtnazRM1yQXg6hs+geEagi6 sA/ImXOtBXoOiWVvJ/l3AQGAJH46Skjm6OaFSd2zUDZZ6lMeWGwXvSnCZ8LZzfaYERI8 gSCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=EKERvPyccN5L6jSux9V7ILEhqtIjCsSZuoPK0qXWjtQ=; b=ud/pODTR09BR78LolDe+jDoQxnoWhMy3LKhb7jlZhhb9G968mktnSzIjpmaks43Ptq c0okMAwMjJ1F1DexXzxb7mz14liynWNuGdM2jWR0oUUb0jQIuxx20VTwy91LsfJg18qn bJM0obMCTBdxJA7c3J9G7lSZWy9K1XgPMID69ixmmdZjmedyU+/rGcEgNV/zntvfexZR n3zIeH/46cHNVgEIQlLivbFDHRUP5qvgTuqsZHa3gvizFWXN+7IpWLnkefnSyailOz2A yxgXsGtf73tNNnoF5xs4ZWFFg4owXvC4i9iujnyVBQ0VwkctQ0lQqZR29ZaLoo5BOiLn 64Gg== X-Gm-Message-State: AOUpUlHJiY5Ajtv2pGaJKXy0qSMyE7xCpxwnaqAGEpffzkBCfk1lscxV X/wR78c3DL+CJDFQy4/MK2JnAAadDdh7Xg== X-Received: by 2002:a1c:b213:: with SMTP id b19-v6mr1443257wmf.141.1533907037844; Fri, 10 Aug 2018 06:17:17 -0700 (PDT) Received: from radium.baylibre.local (AStLambert-681-1-8-155.w90-86.abo.wanadoo.fr. [90.86.13.155]) by smtp.gmail.com with ESMTPSA id i205-v6sm2069523wmf.30.2018.08.10.06.17.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 10 Aug 2018 06:17:17 -0700 (PDT) From: Fabien Parent To: Sebastian Reichel , Lee Jones Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, gpain@baylibre.com, Fabien Parent Subject: [PATCH v2 1/3] mfd: cros: add charger port count command definition Date: Fri, 10 Aug 2018 15:13:47 +0200 Message-Id: <20180810131349.3883-2-fparent@baylibre.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180810131349.3883-1-fparent@baylibre.com> References: <20180810131349.3883-1-fparent@baylibre.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org A new more command has been added to the ChromeOS embedded controller that allows to get the number of charger port count. Unlike EC_CMD_USB_PD_PORTS, this new command also includes the dedicated port if present. This command will be used to expose the dedicated charger port in the ChromeOS charger driver. Signed-off-by: Fabien Parent Acked-for-MFD-by: Lee Jones --- V1 -> V2: * No change --- include/linux/mfd/cros_ec_commands.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/linux/mfd/cros_ec_commands.h b/include/linux/mfd/cros_ec_commands.h index 0d926492ac3a..e3187f8bdb7e 100644 --- a/include/linux/mfd/cros_ec_commands.h +++ b/include/linux/mfd/cros_ec_commands.h @@ -3005,6 +3005,16 @@ struct ec_params_usb_pd_info_request { uint8_t port; } __packed; +/* + * This command will return the number of USB PD charge port + the number + * of dedicated port present. + * EC_CMD_USB_PD_PORTS does NOT include the dedicated ports + */ +#define EC_CMD_CHARGE_PORT_COUNT 0x0105 +struct ec_response_charge_port_count { + uint8_t port_count; +} __packed; + /* Read USB-PD Device discovery info */ #define EC_CMD_USB_PD_DISCOVERY 0x0113 struct ec_params_usb_pd_discovery_entry { -- 2.18.0