From patchwork Wed Sep 22 23:09:45 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 514517 Delivered-To: patch@linaro.org Received: by 2002:a02:c816:0:0:0:0:0 with SMTP id p22csp866315jao; Wed, 22 Sep 2021 16:11:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzMGrN2t5Ynyb2YLJ8LWyIIriiDux1czyB/g2uIkahixP3ahep4/dXYZIbrR9MOUhoN3mq4 X-Received: by 2002:a92:cdad:: with SMTP id g13mr1174292ild.149.1632352313591; Wed, 22 Sep 2021 16:11:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632352313; cv=none; d=google.com; s=arc-20160816; b=FVJTuJQih2R2cTtNR24uQRwOjtKOw2HZefosoqnojfZbOLfx2OTSzCaPpMhvnD9a91 8ZPBWo18MRb6V7Nx5+AIyniIVgKyI63bwucveFpwxrZrtDOcQxo3Se+ERENm60TdCXTy 4EPCpUQPzMOtnd4lglesvWT5Mxxx4L9CQw1r8N0SHxG3rW0eZEKPEZQXMdFFmXtto5Cu RvsCktwESr8fcv3q9FxAl1CR5dWOwyiHVDm4dg7Es1o8WVIQjp52ERBaE/SxvF72bDWh KFsI8/zHBOylPlJaSlJ4Q76bYqVpk23kzmmZ/ZADyCpcbYwhYQgWjoOwkjJhMK6MMU6w nSfg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=LXrbDHPFbLNfw7aqFMhZysQCuGl8i7wEipi1H6MoIeg=; b=OxjSUL62JlzuyVyBL2CLvHXK7qF/LWJzNjitvLf3WjTl6noYW+kH3NFudTSFIRbxd+ uhKuxnikZ97HQtN3e9QmOA9BnzZe0/jejc9x+KdIlsZP9Y8SkFGr+myP8qs7rwKGpOwu 2xk2EMCpHXJqeba3R08M0LFY+1iRMHwwJhvhvWuKcSyr7fzuXrWqGSPYL7jPHm+GHxHp 1G7Hqts5J7uTaLOU6/1hJH41isOyRRzrXHQp47zm1uUwqRP4vDfVs8FU8XwW8GbWjdMr y6rO92NTjy6dX1YsxeBSxAbQCD9igASxQV79pE76jrpLfKpWnTS0F3ynpEu9et3vRlf+ 8YJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=e2ZGk9t3; spf=pass (google.com: domain of linux-watchdog-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-watchdog-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m14si3810623jac.89.2021.09.22.16.11.53 for ; Wed, 22 Sep 2021 16:11:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-watchdog-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=e2ZGk9t3; spf=pass (google.com: domain of linux-watchdog-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-watchdog-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238404AbhIVXNW (ORCPT ); Wed, 22 Sep 2021 19:13:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37266 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238389AbhIVXNW (ORCPT ); Wed, 22 Sep 2021 19:13:22 -0400 Received: from mail-lf1-x130.google.com (mail-lf1-x130.google.com [IPv6:2a00:1450:4864:20::130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3BCABC061574 for ; Wed, 22 Sep 2021 16:11:51 -0700 (PDT) Received: by mail-lf1-x130.google.com with SMTP id u18so17937707lfd.12 for ; Wed, 22 Sep 2021 16:11:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LXrbDHPFbLNfw7aqFMhZysQCuGl8i7wEipi1H6MoIeg=; b=e2ZGk9t3fIF55m6TCjuRyJ+kVyKL8xNgPSZuLe6emtzWGgIO3a4f4ZpxbwGdeAEyZ8 LAaH1F/jv5NQ8t7/7W8kwuce19EJ9s0fTYyIr55k4Otiqo1r7h0q76AcYF8MpLc5NrTE BmWmZp864JT1CZ5ss+76qxHD0gupUE/rDprQiNBzSrtofDsgZYquWM6aX//ZGKglptt6 I8LBF5l9+nVvbKz2duAtsPBJSo/dtDF227DgFhNo+beA4PKBPmcbHDz3A57N3TlJZneJ gR0jBIYZb62gbvHme/VzCDnaoJICpSBLwJAG1hHwdk2Y5iZgCLB4iPA7iYrUJQhCceDb sfsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LXrbDHPFbLNfw7aqFMhZysQCuGl8i7wEipi1H6MoIeg=; b=Y+/pzVrgeaHscTvGK+jNfPOR7CDRjxsrxX3En5KcWb28F3P+xXqVfHtmqAo4jD/QDG 970CGfZ3XoHKsFO2xc++wpLd/QzCyt3eazokUlGRz7OHgYVB+4JlAvXCdXns2hfwgY2L mbCGMh4geiasWhCZtXfDI0vX0brA9OBTqG/pxstOOPLmUZZQmB7JbxJJY9VyJmVExpML sXJs7M+xrUqj9DgMOQr5gLi4eanrq3UVgQxjMKVYaZECm6i2tnGp7oTRh1jSXfrmLKVF s6Kl6kQ67NaC/WHvBBT3xT78r3vvkkh8klYEAUiRf/WTJ+fqQwloZDjAYy+kUGatYUq7 SNsg== X-Gm-Message-State: AOAM530OfptfzZeP/HXBFUXmjcX7YW1G1aRk4x68jg2LZUDewwtGiG+v iDoNclVCDRzsiM+WlnEjbf95Kg== X-Received: by 2002:a2e:58c:: with SMTP id 134mr1909870ljf.269.1632352309508; Wed, 22 Sep 2021 16:11:49 -0700 (PDT) Received: from localhost.localdomain (c-fdcc225c.014-348-6c756e10.bbcust.telenor.se. [92.34.204.253]) by smtp.gmail.com with ESMTPSA id u28sm288044lfo.47.2021.09.22.16.11.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Sep 2021 16:11:49 -0700 (PDT) From: Linus Walleij To: Wim Van Sebroeck , Guenter Roeck Cc: linux-watchdog@vger.kernel.org, Linus Walleij , Lee Jones Subject: [PATCH 1/3] watchdog: ux500_wdt: Drop platform data Date: Thu, 23 Sep 2021 01:09:45 +0200 Message-Id: <20210922230947.1864357-1-linus.walleij@linaro.org> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-watchdog@vger.kernel.org Drop the platform data passing from the PRCMU driver. This platform data was part of the ambition to support more SoCs, which in turn were never mass produced. Only a name remains of the MFD cell so switch to MFD_CELL_NAME(). Cc: Lee Jones Signed-off-by: Linus Walleij --- Lee: it'd be prefect if you could ACK this so the watchdog people can merge it, it shouldn't collide with any other changes to the PRCMU driver. --- drivers/mfd/db8500-prcmu.c | 13 +------------ drivers/watchdog/ux500_wdt.c | 13 ++----------- include/linux/platform_data/ux500_wdt.h | 18 ------------------ 3 files changed, 3 insertions(+), 41 deletions(-) delete mode 100644 include/linux/platform_data/ux500_wdt.h -- 2.31.1 Reviewed-by: Guenter Roeck diff --git a/drivers/mfd/db8500-prcmu.c b/drivers/mfd/db8500-prcmu.c index c1d3e7c116cf..ccf6be922b39 100644 --- a/drivers/mfd/db8500-prcmu.c +++ b/drivers/mfd/db8500-prcmu.c @@ -36,7 +36,6 @@ #include #include #include -#include #include "db8500-prcmu-regs.h" /* Index of different voltages to be used when accessing AVSData */ @@ -2939,18 +2938,8 @@ static struct regulator_init_data db8500_regulators[DB8500_NUM_REGULATORS] = { }, }; -static struct ux500_wdt_data db8500_wdt_pdata = { - .timeout = 600, /* 10 minutes */ - .has_28_bits_resolution = true, -}; - static const struct mfd_cell common_prcmu_devs[] = { - { - .name = "ux500_wdt", - .platform_data = &db8500_wdt_pdata, - .pdata_size = sizeof(db8500_wdt_pdata), - .id = -1, - }, + MFD_CELL_NAME("ux500_wdt"), MFD_CELL_NAME("db8500-cpuidle"), }; diff --git a/drivers/watchdog/ux500_wdt.c b/drivers/watchdog/ux500_wdt.c index 072758106865..40f8cf1cb234 100644 --- a/drivers/watchdog/ux500_wdt.c +++ b/drivers/watchdog/ux500_wdt.c @@ -15,7 +15,6 @@ #include #include #include -#include #include @@ -23,7 +22,6 @@ #define WATCHDOG_MIN 0 #define WATCHDOG_MAX28 268435 /* 28 bit resolution in ms == 268435.455 s */ -#define WATCHDOG_MAX32 4294967 /* 32 bit resolution in ms == 4294967.295 s */ static unsigned int timeout = WATCHDOG_TIMEOUT; module_param(timeout, uint, 0); @@ -80,22 +78,15 @@ static struct watchdog_device ux500_wdt = { .info = &ux500_wdt_info, .ops = &ux500_wdt_ops, .min_timeout = WATCHDOG_MIN, - .max_timeout = WATCHDOG_MAX32, + .max_timeout = WATCHDOG_MAX28, }; static int ux500_wdt_probe(struct platform_device *pdev) { struct device *dev = &pdev->dev; int ret; - struct ux500_wdt_data *pdata = dev_get_platdata(dev); - - if (pdata) { - if (pdata->timeout > 0) - timeout = pdata->timeout; - if (pdata->has_28_bits_resolution) - ux500_wdt.max_timeout = WATCHDOG_MAX28; - } + timeout = 600; /* Default to 10 minutes */ ux500_wdt.parent = dev; watchdog_set_nowayout(&ux500_wdt, nowayout); diff --git a/include/linux/platform_data/ux500_wdt.h b/include/linux/platform_data/ux500_wdt.h deleted file mode 100644 index de6a4ad41e76..000000000000 --- a/include/linux/platform_data/ux500_wdt.h +++ /dev/null @@ -1,18 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ -/* - * Copyright (C) ST Ericsson SA 2011 - * - * STE Ux500 Watchdog platform data - */ -#ifndef __UX500_WDT_H -#define __UX500_WDT_H - -/** - * struct ux500_wdt_data - */ -struct ux500_wdt_data { - unsigned int timeout; - bool has_28_bits_resolution; -}; - -#endif /* __UX500_WDT_H */