Received: by 2002:a05:7412:8d09:b0:fa:4c10:6cad with SMTP id bj9csp297230rdb; Mon, 15 Jan 2024 23:46:26 -0800 (PST) X-Google-Smtp-Source: AGHT+IGFzlFAnaxwRKFClb5rHuvMOodNHCX4+OkffYtUAaq1h+qWCMM0cZFDYDDBOZkfzbl4c0lm X-Received: by 2002:a05:6808:1188:b0:3bd:47ee:5f66 with SMTP id j8-20020a056808118800b003bd47ee5f66mr8645529oil.20.1705391185865; Mon, 15 Jan 2024 23:46:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1705391185; cv=none; d=google.com; s=arc-20160816; b=AysFfU3joDCVJLea+1pJd0cfaXibhbUQ35AknyQ5n3K9dsUyX3oBN97KLYsaq9lLtN pp5WwmJtey+zah6d2m7lnzCR3NGWw5XvlGaSZUD9T5TLh7V0wEJ86nqiDBsMkPvskzFA u8OtCjwmZ5wbh5eVq50n0NfUhdZFAUwXT3wfzQ+s5iloJaVn1BXAebQOh2oksUKlFlvW FUaeE2/CpylvQ6qojA1ceu6C5W0oHhNUPvUMw4qysuNEwl8bX3YxJLM6CSN3HZPwhjYk YGpf9sAhAr9i0DDDjmIktKAqv+gqhMkpK3wasJ56eTQ01qMhVP6HPZOKjhJy5AxuHOYO uQHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=D14SLbjX1GLnHuhrFGkm5qKGMOubngFldvMxw9TZU/8=; fh=xmaDXklkLvAQCXKl2G3wrcHyvXoykbyEhnkOJHZhuug=; b=OGfOUm3dKgj1CbnWaAYpK82lAe1cwCdTLlYr7nGHws0YMtGTVtuF6+yUTP8cuGp/Y9 KTabjIfL+fqcOWz+u/FCETr19btbhgzDd1a8BDSFU2yW+lhUERp9v47lHpKV1O3CAgCI vycIYQuWqcg8M4xYq0hSd6dvdoZKxX7dmHNzXlmCpVnyxZSHwqExaJI+ElzqNfOmfBrD 5XdpPixPZsHOqtD6Wvo8OXQXCJs6vQVXBp+5mDvipNoy5stGTUg0nDibHuCzNCx7FaHb /bm1QY7AqDlVU9tqZJUAgGdercAeeo2QpMRG+alDaozzh7oHiMpisCPAea2zhT9GFZwy TgJg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZymAZFJH; spf=pass (google.com: domain of linux-kernel+bounces-27096-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-27096-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id h12-20020a056a00230c00b006db6fb3c0c4si5873329pfh.214.2024.01.15.23.46.25 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Jan 2024 23:46:25 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-27096-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZymAZFJH; spf=pass (google.com: domain of linux-kernel+bounces-27096-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-27096-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 7B957284F80 for ; Tue, 16 Jan 2024 07:46:25 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 04B62111A1; Tue, 16 Jan 2024 07:46:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="ZymAZFJH" Received: from mail-ed1-f44.google.com (mail-ed1-f44.google.com [209.85.208.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A69F01118B for ; Tue, 16 Jan 2024 07:46:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-ed1-f44.google.com with SMTP id 4fb4d7f45d1cf-557c188f313so14884043a12.1 for ; Mon, 15 Jan 2024 23:46:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1705391175; x=1705995975; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=D14SLbjX1GLnHuhrFGkm5qKGMOubngFldvMxw9TZU/8=; b=ZymAZFJHfvtZr9QEvHplDakWNb0tQIQpPc4m1/Ebw5AzJTdPopEFVKLlH+dVxSiD3v BXzPpG7fLcBYi1y8/ecIFMTknyAdNTF/DwzDAb3lbDvawJQgE2WEKEytgV3WEmGYK6WD qBHmpeFtDWVPk6FjVbPiTQvUedvFjbQ373xmZCntaajwzZVfDYMy52VxlcMphptRd0Pl RxhWB1ba8yve1fSAHV1z5k3KhmIFdO5Uy/ZvSiFUximYdd5IVbOP8/w9aHeIrxCT77ZE fgvfG6oVHEx6BPVl67vnOA5yirHkLW574IbsAiuUtcCB0zqMNB63T/LSgAfEO4vSbJLi wVSA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705391175; x=1705995975; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=D14SLbjX1GLnHuhrFGkm5qKGMOubngFldvMxw9TZU/8=; b=sw2l22lvSr6fq/N7AjbnP9wEKeDLSJlgIGwb44gZYg1yfVwwPWcQksD4m+1C39FhM0 dvS02bF48+edwKsq/MesGzaGamZLhOreTJbWZR/8SUhqZZpeEispuaMwDXPGZg/RVZpX FDMLeBfybB9aCNzTTbP3knsdz0LzwjgqIXyjdo+eUrj3QwVG7ujN4lQaoEI6XHGJcfxm HoVixjNaaWQeqFgYnk1OWB4aH8LsXxejiqRApKIqa5BgDfrCZiTIKxyhnLHbHTPDIp+b mg/BMw20uejAHu4JIxYy1iVKjAenj+Z6JOtNb9/CTp2O63lOBU6FVan0Ch/nEg+ZvsqW HDEw== X-Gm-Message-State: AOJu0Yxpb4t0PXGhIgSApDm7vmH3W1Xnv6BT+MJnG2mkuRx9K6OkxRg9 wqxvBFvZXyk8rW7gcJCTJqMX1mH+Ogv4GQ== X-Received: by 2002:aa7:d5c7:0:b0:557:2be5:6620 with SMTP id d7-20020aa7d5c7000000b005572be56620mr7141794eds.23.1705391174991; Mon, 15 Jan 2024 23:46:14 -0800 (PST) Received: from [192.168.1.20] ([178.197.215.66]) by smtp.gmail.com with ESMTPSA id n13-20020a05640204cd00b0055971af7a23sm1159774edw.95.2024.01.15.23.46.13 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 15 Jan 2024 23:46:14 -0800 (PST) Message-ID: <9a1c77f8-bcf9-4cbf-ab51-694353dd0ef3@linaro.org> Date: Tue, 16 Jan 2024 08:46:12 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v6 2/3] rtc: sophgo: add rtc support for Sophgo CV1800 SoC Content-Language: en-US To: Jingbao Qiu , alexandre.belloni@bootlin.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, chao.wei@sophgo.com, unicorn_wang@outlook.com, paul.walmsley@sifive.com, palmer@dabbelt.com, aou@eecs.berkeley.edu Cc: linux-rtc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, dlan@gentoo.org, inochiama@outlook.com References: <20240115160600.5444-1-qiujingbao.dlmu@gmail.com> <20240115160600.5444-3-qiujingbao.dlmu@gmail.com> From: Krzysztof Kozlowski Autocrypt: addr=krzysztof.kozlowski@linaro.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xeYJtjUH0ZX6ndJ33FJYf5V3yXqqjcZ30FgHzJCFUu JMp7PSyMPzpUXfU12yfcRYVEMQrmplNZssmYhiTeVicuOOypWugZKVLGNm0IweVCaZ/DJDIH gNbpvVwjcKYrx85m9cBVEBUGaQP6AT7qlVCkrf50v8bofSIyVa2xmubbAwwFA1oxoOusjPIE J3iadrwpFvsZjF5uHAKS+7wHLoW9hVzOnLbX6ajk5Hf8Pb1m+VH/E8bPBNNYKkfTtypTDUCj NYcd27tjnXfG+SDs/EXNUAIRefCyvaRG7oRYF3Ec+2RgQDRnmmjCjoQNbFrJvJkFHlPeHaeS BosGY+XWKydnmsfY7SSnjAzLUGAFhLd/XDVpb1Een2XucPpKvt9ORF+48gy12FA5GduRLhQU vK4tU7ojoem/G23PcowM1CwPurC8sAVsQb9KmwTGh7rVz3ks3w/zfGBy3+WmLg++C2Wct6nM Pd8/6CBVjEWqD06/RjI2AnjIq5fSEH/BIfXXfC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X47nr6jIsEB5ZftdybIzpMZ5V9v45lUwmdnMrSzZVgC4jRGXzsU EViBQt2CopXtHtYfPAO5nAkIvKSNp3jmGxZw4aTc5xoAZBLo0OV+Ezo71pg3AYvq0a3/oGRG KQ06ztUMRrj8eVtpImjsWCd0bDWRaaR4vqhCHvAG9iWXZu4qh3ipie2Y0oSJygcZT7H3UZxq fyYKiqEmRuqsvv6dcbblD8ZLkz1EVZL6djImH5zc5x8qpVxlA0A0i23v5QvN00m6G9NFF0Le D2GYIS41Kv4Isx2dEFh+/Q== In-Reply-To: <20240115160600.5444-3-qiujingbao.dlmu@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 15/01/2024 17:05, Jingbao Qiu wrote: > Implement the RTC driver for CV1800, which able to provide time alarm > and calibrate functionality. > > Signed-off-by: Jingbao Qiu > --- > + > +static int cv1800_rtc_probe(struct platform_device *pdev) > +{ > + struct cv1800_rtc_priv *rtc; > + uint32_t ctrl_val; > + int ret; > + > + rtc = devm_kzalloc(&pdev->dev, sizeof(struct cv1800_rtc_priv), > + GFP_KERNEL); > + if (!rtc) > + return -ENOMEM; > + > + rtc->dev = &pdev->dev; > + > + rtc->rtc_map = syscon_node_to_regmap(rtc->dev->of_node->parent); > + if (IS_ERR(rtc->rtc_map)) > + return PTR_ERR(rtc->rtc_map); Why do you take the parent? Your bindings say this device is the syscon, not parent. Your DTS shows there is no parent syscon! This wasn't tested. Best regards, Krzysztof