From patchwork Wed May 3 13:10:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 13230163 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E8ACAC7EE22 for ; Wed, 3 May 2023 13:11:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=7fRMQY/SyCGZQZP1BO+BaPLOpODz1dqauBwTL5uwVes=; b=jF+Gs3sFGGwNiw moAFzldCyj5+vwKPOCxUzCtGv07dsuN7C63dQonCSKpQkF1JmWMpxEDNSUAN9aOnVLsrr4uj3WmpJ 2CgDo94myHPTIRBznWPdcG4E4erB7KdC0DQSv+b5TlmFtrB5aT3yKrs7+I2MVwU0fJw/JegLL+hgP 56AY6TJYzbIWlenMFenp3A78rzsYZUev46hkUfS+WvUUvmR03A9vB/LgZWv6RqZYAuYsObwBg4q8L /Cia9OX0xpLXBy0CK+Anmn21vUqy+n9fIHwj2PPbaB/dbdE/eMtoKzRcJKmZ495/KE2Zwx6RR4HAJ NBLx/HOpO7Xa7BhAt+Gw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1puCFy-004eeG-1o; Wed, 03 May 2023 13:10:54 +0000 Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1puCFt-004eW1-0v for linux-arm-kernel@lists.infradead.org; Wed, 03 May 2023 13:10:50 +0000 Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-3f1cfed93e2so51530875e9.3 for ; Wed, 03 May 2023 06:10:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683119444; x=1685711444; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=dqfFtZjpBwpHnbanMeS8saew2f7WSD17vQFnp7exxSY=; b=X5e6nqdeOr1LhOT2w/el4JzYGIvop1TUIUA4iuy12YgJensJNeBpHZUaRoKhT6XH8a u3bnyRS1QOhwA4nS0cG/hdhqxUuMTEpSO/BqO2iTGX5bx0ZQWhAho2CVy2vEBmOl5fXG lAffKN3jTYXLMBX1ln7NJi/54k2kdpgCTG5wH2ODSON0X+zAZa0gzWrR5MywWELPA+aB CWkunyqovCogsBaWQTkFN4opqP3s8GZ0FTVghh45le+FlSOSl3jTTiUOO5yNoUrzc9Wx fWt1dJFqXC6JaQ8Kw/+bgQfzzfI+MZh0dk1/t04bbutsAe666GuocpNGEjhzkyJW/Ufb vmWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683119444; x=1685711444; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dqfFtZjpBwpHnbanMeS8saew2f7WSD17vQFnp7exxSY=; b=Yot3nXK1J5wVbck+LodJAmcYKZmR8PPWSaiWtp+cbvid2ScrxyEGNgAXQTxjdyMTFQ VDaCE4WLCJ0f9zZMbC4aOl6316SOz0r8ReTDd8EPe5NBh9mahltO93Jg8zBsc8siYF9K 4kAd1Kq328R9nnttsEe8SPX4wNiAUZIj0OZTFQ2DE0ZSlWCunz5cLJN1UvFMf+lBJpap ZUidi+ud60ttzi8H50+MOXnIQuHhAKI2n+ugM4RJZWDpG/OuZdDFIROeieNXQ2qgYO2A ng62V8ZFi4LZ60hZQwmwBYe7saOiVC0f5KOvEPvhlFyaQd5RkiNyUSYyZGKu6nnWfcfO nyQw== X-Gm-Message-State: AC+VfDyMYFd9uAtJLMqQJUuQTpbwW3zbk4nzPgKAsCL/1n7PWl/fwlrM 0Uu9upA5P9+17TKvU0WyOnjBag== X-Google-Smtp-Source: ACHHUZ7MqVtgOQb7P5ctA+ifWc9qBzWFe18a8FP1dLDAbK8Jws0XBRT1oGq5jHOfhrx+tCkcCQQSEQ== X-Received: by 2002:a7b:cb85:0:b0:3f1:7136:dd45 with SMTP id m5-20020a7bcb85000000b003f17136dd45mr14793376wmi.30.1683119444023; Wed, 03 May 2023 06:10:44 -0700 (PDT) Received: from arrakeen.starnux.net ([2a01:e0a:982:cbb0:8261:5fff:fe11:bdda]) by smtp.gmail.com with ESMTPSA id c10-20020adffb0a000000b00306344eaebfsm5413479wrr.28.2023.05.03.06.10.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 May 2023 06:10:43 -0700 (PDT) From: Neil Armstrong Date: Wed, 03 May 2023 15:10:38 +0200 Subject: [PATCH 6/6] qcom: pmic_glink: enable altmode for SM8450 MIME-Version: 1.0 Message-Id: <20230503-topic-sm8450-graphics-dp-next-v1-6-d1ee9397f2a6@linaro.org> References: <20230503-topic-sm8450-graphics-dp-next-v1-0-d1ee9397f2a6@linaro.org> In-Reply-To: <20230503-topic-sm8450-graphics-dp-next-v1-0-d1ee9397f2a6@linaro.org> To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Catalin Marinas , Will Deacon Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Neil Armstrong X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1399; i=neil.armstrong@linaro.org; h=from:subject:message-id; bh=qkASJFOC8Sum3nf8ciK4XNKG+cxf4hgwBJ+cUAn3rO4=; b=owEBbQKS/ZANAwAKAXfc29rIyEnRAcsmYgBkUl1NKRunTI8gTuu1bmZf0rFwrWODpoC9Ruv+xEWx dqZglNOJAjMEAAEKAB0WIQQ9U8YmyFYF/h30LIt33NvayMhJ0QUCZFJdTQAKCRB33NvayMhJ0f1yEA DAHeZRXxPUb4hZtFMNqS8d/kOp/k4sNXsY/IAWHPTsRBj14r04Gq7SWME1lm2Q82PRKdnyGOZSHkYw CPhKE82yL7J6D5xPEy1mxlFFMCd8e2J2XOBXIYO7hl7IXx3qLlkQSLaDfY1YlYSUoVFzVSWX8PY1O4 hLu7+a4PkFE/b6jGzu5RMuze6qGz5RguPb1XCQvb3Q8MiixJeAy+Es5vp7+RFsIbVj1ukmjx7BszKr mlsC6LKI5+Uz0KXr2QLmdp78YyJF6UsXqSVbIz6w4mqRNaEsokKPtufIx2zcvl6JBd/xZLQvnIT4fk G7dTJ7OyBQ/80sABtv3HxWjzxFFidNwBbbPPSUoydVNOSlAR+1fygt0HVSOIgqAdWlQbWPhuY5u1NU Fs7cbB1vlhrFg5uRckf8PsN0qZWnSnvW+UKfQtGpY0R6H+dOXbfAGkDKWvdt1A12+Tti2v/vQyZM7h lGc0TYKlVgHoYj2cq3n2Ya+8n12OINqsdAN5/kmtUTcGDSGUawiOkY8EwZn6Sl+nu7Wn3r7zeyoob9 aUy7jcI/oqRzJTcvmvD0d7t969uAf800JjPx79ZHbQ0POfZYUlftJ4c8fH+YyOtFQ3t4dUlKk3FsiR SRTWTpmFONG0+TEaC+nJm1QNvBdXhHLV0O2f8/DgVJKfoJivz7hoDRwN/gAQ== X-Developer-Key: i=neil.armstrong@linaro.org; a=openpgp; fpr=89EC3D058446217450F22848169AB7B1A4CFF8AE X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230503_061049_324229_5EBC0713 X-CRM114-Status: GOOD ( 12.98 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Create a separate bitmask for sm8550 and enable altmode aux driver for sm8450 platform to enable pmic-glink altmode events. Signed-off-by: Neil Armstrong --- drivers/soc/qcom/pmic_glink.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/soc/qcom/pmic_glink.c b/drivers/soc/qcom/pmic_glink.c index 8bf95df0a56a..c87056769ebd 100644 --- a/drivers/soc/qcom/pmic_glink.c +++ b/drivers/soc/qcom/pmic_glink.c @@ -338,13 +338,17 @@ static int pmic_glink_remove(struct platform_device *pdev) return 0; } -/* Do not handle altmode for now on those platforms */ static const unsigned long pmic_glink_sm8450_client_mask = BIT(PMIC_GLINK_CLIENT_BATT) | + BIT(PMIC_GLINK_CLIENT_ALTMODE) | + BIT(PMIC_GLINK_CLIENT_UCSI); + +/* Do not handle altmode for now on those platforms */ +static const unsigned long pmic_glink_sm8550_client_mask = BIT(PMIC_GLINK_CLIENT_BATT) | BIT(PMIC_GLINK_CLIENT_UCSI); static const struct of_device_id pmic_glink_of_match[] = { { .compatible = "qcom,sm8450-pmic-glink", .data = &pmic_glink_sm8450_client_mask }, - { .compatible = "qcom,sm8550-pmic-glink", .data = &pmic_glink_sm8450_client_mask }, + { .compatible = "qcom,sm8550-pmic-glink", .data = &pmic_glink_sm8550_client_mask }, { .compatible = "qcom,pmic-glink" }, {} };