From patchwork Fri Apr 12 16:08:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 788288 Delivered-To: patch@linaro.org Received: by 2002:adf:e6ca:0:b0:346:15ad:a2a with SMTP id y10csp793623wrm; Fri, 12 Apr 2024 09:09:41 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWgzZrKM4Z73tr55DGzBVNILxQc33Q0KYKBrlTTvVvvNwYb00QDHO2rGY7zRcJXumXez+hCXkDYb4ccxDXSHkuA X-Google-Smtp-Source: AGHT+IER/tPxofnVE4ZzficE0nhIhg7nMQqoUippzR3JWw2iUEumtzaRMSZYDkjwgY9d0HaX/Zw8 X-Received: by 2002:a05:6122:c81:b0:4d1:34a1:c892 with SMTP id ba1-20020a0561220c8100b004d134a1c892mr3499886vkb.13.1712938180822; Fri, 12 Apr 2024 09:09:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1712938180; cv=none; d=google.com; s=arc-20160816; b=0EUIe/wZ/J3e2sXkeQ4AhWJ5FhLQBB13M8crpgPrEPK/hOstEQBz72P1K71K3wW6B8 QVEkD6zC+wJt/hulmK1NPraipPE3eHOMPdvJSimeh0FBtgXog2tZsigJzsCMMLiAJmiG CSLIhbmf7SjUwNh/IeBGmtG1yUP2+nshh+hjZesOl+nq3PhFWydz/K16mNbcwGSpbKpJ E6nvDcEeFYJxfkv2g4kB8wx6HYxmKPhkR/JeDBvusObg/j0dvWSsAjLXyCPvVghubEJy xCb+4S2s55n4YBf8mWs98LKkFtHD2DC3/FaZLHHrL9fia5lzXk1KwWnD/A7GnJ/wgMhV zKBQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=vCinoxi3fpxu2uzsSkCV5+1SLMrawhwh7G4zKOQNXrM=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=ad0DeuQa3SvygPUGhVFuh03WNwBDnE3SRP9x1oe/jqYLl8aAkYO53dbwC0Avpv3XwR 1l5oMVZkeGa0lwOjerL5qtpuslD3sRvWWD9ySBppZyeiyNZOxvKR3Ym4eXnKyjqxa94c OSMQunAk3t69mRvx6jq1xa6rBmsp8PgVAGOfXdsU/ToCyRKDndBqBa2wTA0DrtAv49YM 0qQ0ePUEskpIV5KAmrBmdoMV6p5rbUKnYwyJYD+Ml3eBpNpzDI6KB/k77Y2CgtUZfamw vFYXZcBVFGvos6bhxdXQlN9M0JPzUJp9ZowDexfO60rwqjJD1dgH4bqgyPu/SQZvAmrH opXA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hEIaJi6d; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id if8-20020a0561022c8800b0047b640de6c1si97720vsb.784.2024.04.12.09.09.40 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 12 Apr 2024 09:09:40 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hEIaJi6d; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rvJRr-0001tS-G3; Fri, 12 Apr 2024 12:08:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rvJRq-0001sh-15 for qemu-devel@nongnu.org; Fri, 12 Apr 2024 12:08:18 -0400 Received: from mail-wm1-x335.google.com ([2a00:1450:4864:20::335]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rvJRn-0004Zh-FH for qemu-devel@nongnu.org; Fri, 12 Apr 2024 12:08:17 -0400 Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-417d0194705so7468445e9.2 for ; Fri, 12 Apr 2024 09:08:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1712938094; x=1713542894; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=vCinoxi3fpxu2uzsSkCV5+1SLMrawhwh7G4zKOQNXrM=; b=hEIaJi6dGCmXsIB0iiIe72DqFeR1QvNqquo2AKcSfV+O32Ty9OlUgxVygLwC1Dh7xl u2xIKCVTLA2YtjD8VkXWL8hY2njYeK8kn6TQnm7+7nVw8z4TOa2RTA2cSRMFgPNu8Deq tpOFIr+9sClXajfQBlotLyczdfJ1+R9vg2aemHxa1j+R5ps83ErPRE7Alo/WLl+QAgwj I9/QYHkqsYWETxJSBthXP9FkspdoOtXE1CLOk+83mV70qYaNnv7XyKO7wcCvsOPbm2SV 6qpDrvgtOZjFY5rER10/wlj5+5YeouukDC2gr4EbaDSJvbTchUAxnq/+k9nquMt3Y8AA jY6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712938094; x=1713542894; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vCinoxi3fpxu2uzsSkCV5+1SLMrawhwh7G4zKOQNXrM=; b=DhCHSDi3BN7GJoGxZ3BZ7HzC3nw7UAUNSLKnNmDBaPZUODCLdte2oQ+zmrVP8W7zMC sjX23HJ5z8HmaKMm+HqZW+rPbEE1Zxf8LcjtleVME6EDyWzNpL6qXlZEOLiy6REVjGF9 4+ok6P6FlYm4xCiUYB5oZcfzxE3At6eirVLtJlLOKNaZn39IEnhgLogBix/+VjE0pcRT EnWCjlVCSWMQ5eFhHfR4kgQEZoj+1/TfgORgzbMQa47AmFrSYL/p4+ZB069Iatp8VjHI 1HhzhKfuj8J1Sd8sN2kbxO2r9W191bjjgHnwREWIVQp8aChGzrkDdKmaQmdmbdZ3+XkV DLag== X-Gm-Message-State: AOJu0YymJcE2TicR8wgx7bzKCo4retU2LeA8ir+LM93ZKu0y+38BTj5c NqGI5NNyGtyuzaW1Fut1NFc97v4Q+EgFcm2ZAeq4dnGmQaOCDyhDGpnuMPMWqC7Mk/agRlbpS/C 3 X-Received: by 2002:a05:600c:4586:b0:417:c5cc:77a7 with SMTP id r6-20020a05600c458600b00417c5cc77a7mr2122453wmo.13.1712938094062; Fri, 12 Apr 2024 09:08:14 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [2001:8b0:1d0::2]) by smtp.gmail.com with ESMTPSA id cr12-20020a05600004ec00b00341ce80ea66sm4582371wrb.82.2024.04.12.09.08.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Apr 2024 09:08:13 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Subject: [PATCH 5/6] docs/devel/reset: Update to new API for hold and exit phase methods Date: Fri, 12 Apr 2024 17:08:08 +0100 Message-Id: <20240412160809.1260625-6-peter.maydell@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240412160809.1260625-1-peter.maydell@linaro.org> References: <20240412160809.1260625-1-peter.maydell@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::335; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x335.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Update the reset documentation's example code to match the new API for the hold and exit phase method APIs where they take a ResetType argument. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Luc Michel --- docs/devel/reset.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/devel/reset.rst b/docs/devel/reset.rst index 2ea85e7779b..49baa1ea271 100644 --- a/docs/devel/reset.rst +++ b/docs/devel/reset.rst @@ -150,25 +150,25 @@ in reset. mydev->var = 0; } - static void mydev_reset_hold(Object *obj) + static void mydev_reset_hold(Object *obj, ResetType type) { MyDevClass *myclass = MYDEV_GET_CLASS(obj); MyDevState *mydev = MYDEV(obj); /* call parent class hold phase */ if (myclass->parent_phases.hold) { - myclass->parent_phases.hold(obj); + myclass->parent_phases.hold(obj, type); } /* set an IO */ qemu_set_irq(mydev->irq, 1); } - static void mydev_reset_exit(Object *obj) + static void mydev_reset_exit(Object *obj, ResetType type) { MyDevClass *myclass = MYDEV_GET_CLASS(obj); MyDevState *mydev = MYDEV(obj); /* call parent class exit phase */ if (myclass->parent_phases.exit) { - myclass->parent_phases.exit(obj); + myclass->parent_phases.exit(obj, type); } /* clear an IO */ qemu_set_irq(mydev->irq, 0);