From patchwork Thu Sep 19 06:29:42 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hunter Yu X-Patchwork-Id: 13807528 Received: from mail-m127216.xmail.ntesmail.com (mail-m127216.xmail.ntesmail.com [115.236.127.216]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 87FF11957E7; Thu, 19 Sep 2024 08:56:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=115.236.127.216 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1726736183; cv=none; b=iAzCnFropVjiPJdP8e1MrweJC+fHmpIAZ0FJXqDLeumj8xEqFPDZXt8f26pn7E0mzMkJpZ5zvcL2978ufRp/iUc96GBlvClu2DOI6iYfXpn1VcO/IfgKk8ha9Gcds+v+GjvzSqAWkZ6ptS6BLQJOsrKsOUyzNy75fxZfdDFI/1I= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1726736183; c=relaxed/simple; bh=/ixGIeAgu4kH+iosDw5OZDaR7cm/8EdtfaIqfr9QDRE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=La5E3R/qWCPpIHi2F0+C6AJDaSg/I0B4ztJ7tGRRMA3Aj967M8TtcZmJ6iqrG5346yqtgwvwxtl+HXGfqnpGcTGRu9itVKJfHXSCs6n+jTyQLqONxG5ObSdGRYRZPQkpSyjPpgavbRnENeNNv8Hvr6H0RNLJH+L53MKffBovAR4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=hj-micro.com; spf=pass smtp.mailfrom=hj-micro.com; arc=none smtp.client-ip=115.236.127.216 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=hj-micro.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=hj-micro.com Received: from localhost.localdomain (unknown [122.224.147.158]) by smtp.qiye.163.com (Hmail) with ESMTPA id 0E1F13808E3; Thu, 19 Sep 2024 14:30:17 +0800 (CST) From: hunter.yu@hj-micro.com To: rafael@kernel.org, lenb@kernel.org, jarkko.nikula@linux.intel.com, andriy.shevchenko@linux.intel.com, mika.westerberg@linux.intel.com, jsd@semihalf.com, andi.shyti@kernel.org Cc: linux-acpi@vger.kernel.org, linux-i2c@vger.kernel.org, hunter.yu@hj-micro.com Subject: [PATCH 1/2] ACPI: APD: Add clock frequency for HJMC01 I2C controller Date: Thu, 19 Sep 2024 14:29:42 +0800 Message-Id: <20240919062943.1551197-2-hunter.yu@hj-micro.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20240919062943.1551197-1-hunter.yu@hj-micro.com> References: <20240919062943.1551197-1-hunter.yu@hj-micro.com> Precedence: bulk X-Mailing-List: linux-acpi@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-HM-Spam-Status: e1kfGhgUHx5ZQUpXWQgPGg8OCBgUHx5ZQUlOS1dZFg8aDwILHllBWSg2Ly tZV1koWUFITzdXWS1ZQUlXWQ8JGhUIEh9ZQVkaSxhMVhlPTk9CSRhMTR1ITlYVFAkWGhdVEwETFh oSFyQUDg9ZV1kYEgtZQVlKSUlVSUlPVUpPTFVKTkNZV1kWGg8SFR0UWUFZT0tIVUpLSU9PT0hVSk tLVUpCS0tZBg++ X-HM-Tid: 0a9208f96e6509cdkunm0e1f13808e3 X-HM-MType: 1 X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6PjY6OAw5HzI5Pw0zCE0jAx8f LUswFCpVSlVKTElNTElMT0pDSkJLVTMWGhIXVRMOFQ8eCVUCDjsTEVYWEhgJFFUYFBZFWVdZEgtZ QVlKSUlVSUlPVUpPTFVKTkNZV1kIAVlBSUlMSTcG From: "hunter.yu" I2C clock frequency for HJMC01 is 200M, define a new ACPI HID for it. Signed-off-by: hunter.yu --- drivers/acpi/acpi_apd.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/acpi/acpi_apd.c b/drivers/acpi/acpi_apd.c index 800f97868448..bc271d1cb31b 100644 --- a/drivers/acpi/acpi_apd.c +++ b/drivers/acpi/acpi_apd.c @@ -181,6 +181,11 @@ static const struct apd_device_desc hip08_spi_desc = { .setup = acpi_apd_setup, .fixed_clk_rate = 250000000, }; + +static const struct apd_device_desc hjmc_i2c_desc = { + .setup = acpi_apd_setup, + .fixed_clk_rate = 200000000, +}; #endif /* CONFIG_ARM64 */ #endif @@ -252,6 +257,7 @@ static const struct acpi_device_id acpi_apd_device_ids[] = { { "HISI02A3", APD_ADDR(hip08_lite_i2c_desc) }, { "HISI0173", APD_ADDR(hip08_spi_desc) }, { "NXP0001", APD_ADDR(nxp_i2c_desc) }, + { "HJMC3001", APD_ADDR(hjmc_i2c_desc) }, #endif { } }; From patchwork Thu Sep 19 06:29:43 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hunter Yu X-Patchwork-Id: 13807623 Received: from mail-m103.netease.com (mail-m103.netease.com [154.81.10.3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 28A75194AF3; Thu, 19 Sep 2024 10:06:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=154.81.10.3 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1726740381; cv=none; b=X+CJwc6MyDRCiwpVAHrVEIeEHaLoakaSZBE5IR43k8wb7HAem0CN7JnSgBDO3eGwFVPBcUxGu9Pee5mM0EDbOOWDIDkz/Uky8+/iWTsl3y9fwwCED2pI+B02KjqQDsuuwNPJL8uOn7yCe7TgE+s2KS6cX9kUJD54sMj3BFSBQL8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1726740381; c=relaxed/simple; bh=ej88sRnXdnb3kp37itE2k6jAkSH6fe9ggZ7aix7doy8=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Z5fJcHt637kcD0qtRazMJfInEa7wexewUdxzPWrSEc5BEkcZ1+MBovsSZT79lDMQ0BcXgC3r1mp+myM8ctCxw5YFnpJ8TYBp4Fr8hOwmhsbB76pea09i8hpTWUodf/Mmdgup+34J+z1oaS7v9nONg7y9ckLlrJdMnjk/b4duWMs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=hj-micro.com; spf=pass smtp.mailfrom=hj-micro.com; arc=none smtp.client-ip=154.81.10.3 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=hj-micro.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=hj-micro.com Received: from localhost.localdomain (unknown [122.224.147.158]) by smtp.qiye.163.com (Hmail) with ESMTPA id 415EE3808D2; Thu, 19 Sep 2024 14:30:18 +0800 (CST) From: hunter.yu@hj-micro.com To: rafael@kernel.org, lenb@kernel.org, jarkko.nikula@linux.intel.com, andriy.shevchenko@linux.intel.com, mika.westerberg@linux.intel.com, jsd@semihalf.com, andi.shyti@kernel.org Cc: linux-acpi@vger.kernel.org, linux-i2c@vger.kernel.org, hunter.yu@hj-micro.com Subject: [PATCH 2/2] i2c: designware: Add a new ACPI HID for HJMC01 I2C controller Date: Thu, 19 Sep 2024 14:29:43 +0800 Message-Id: <20240919062943.1551197-3-hunter.yu@hj-micro.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20240919062943.1551197-1-hunter.yu@hj-micro.com> References: <20240919062943.1551197-1-hunter.yu@hj-micro.com> Precedence: bulk X-Mailing-List: linux-acpi@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-HM-Spam-Status: e1kfGhgUHx5ZQUpXWQgPGg8OCBgUHx5ZQUlOS1dZFg8aDwILHllBWSg2Ly tZV1koWUFITzdXWS1ZQUlXWQ8JGhUIEh9ZQVlDTxkfVhhOHxpPSR5NSENLH1YVFAkWGhdVEwETFh oSFyQUDg9ZV1kYEgtZQVlKSUlVSUlPVUpPTFVKTkNZV1kWGg8SFR0UWUFZT0tIVUpLSU9PT0hVSk tLVUpCS0tZBg++ X-HM-Tid: 0a9208f9732309cdkunm415ee3808d2 X-HM-MType: 1 X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6Kxg6Aww*EDI0AQ0SCEIfAx09 DBFPCgJVSlVKTElNTElMT0pCSEhKVTMWGhIXVRMOFQ8eCVUCDjsTEVYWEhgJFFUYFBZFWVdZEgtZ QVlKSUlVSUlPVUpPTFVKTkNZV1kIAVlBSkJDQjcG From: "hunter.yu" Define a new ACPI HID for HJMC01 Signed-off-by: hunter.yu Acked-by: Jarkko Nikula --- drivers/i2c/busses/i2c-designware-platdrv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/i2c/busses/i2c-designware-platdrv.c b/drivers/i2c/busses/i2c-designware-platdrv.c index df3dc1e8093e..06dcefa3b103 100644 --- a/drivers/i2c/busses/i2c-designware-platdrv.c +++ b/drivers/i2c/busses/i2c-designware-platdrv.c @@ -58,6 +58,7 @@ static const struct acpi_device_id dw_i2c_acpi_match[] = { { "HISI02A2", 0 }, { "HISI02A3", 0 }, { "HYGO0010", ACCESS_INTR_MASK }, + { "HJMC3001", 0 }, { } }; MODULE_DEVICE_TABLE(acpi, dw_i2c_acpi_match);