From patchwork Wed Mar 11 06:44:05 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 184384 Delivered-To: patch@linaro.org Received: by 2002:a92:1f12:0:0:0:0:0 with SMTP id i18csp277263ile; Tue, 10 Mar 2020 23:44:53 -0700 (PDT) X-Google-Smtp-Source: ADFU+vu15NCU4ReopuxaVgzFwS3kCj+cV5zE1IbQEF6dld5enzmh77m7cMc8CGCI88lLL4U2Juy2 X-Received: by 2002:ac8:4cd1:: with SMTP id l17mr1357877qtv.165.1583909093479; Tue, 10 Mar 2020 23:44:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1583909093; cv=none; d=google.com; s=arc-20160816; b=PDaSACRDgx8ZpRzNa08IoNWwAxuWuOgQeRnkyn3w414vFKEHZEmU/jUR+7h7scrvF2 l6/63w5W/9b8Jf8hU229ekTZ2M43cJeQ9eDucZ8mbcs0kHOVL5GLITKm1DcLsEFGi4UM NsXEpEx/Of0T+1SJvgqr00CBQ1EEM16Xvbny4SRrXxXFqEDgT3twpXpvSLs3C+DB44wn Xq0+PzXqEDHUtGNf9ZVHXjG5nP/LdaypNK1R+9bvjQ9ZI6eEz0zAnAhgOjZZJ/cVl+m0 mekEG7sDa1TdUfhIkmIfvs2sPyO6v1XlR0Ga7N7TcoQ8Paj3oUUGEfhxreJttA9n/Tde oTqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc: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=ME4wdyObWWzU36JOWOP068GfXM/kHUGKiy3+FE+Caek=; b=vxONop2FculRaC/mTgRVEcR/jdHGX4Vb19eOV5UBvcB80zxg/8ybAfarEc8419+Gpf 4Pz5ipKh0NrLSN5p5ZTPaJcr8LFVnfTS9QUlpGPB9co5X68ipl16AkE1XRvIXxW3PhOh 72/Fup2yqyXeFzW32Q5lKs2G4lpLomQQdZ+JOrBVlT8XQ/3eYVBK0NmpszTaK19n2S3N TUV//jIvSF7FrsuQwsmQsVL9+zvOlu0i8+XjM30XXpfJOYv3R99py70UpkzCQXyLCElL t0KwIOtUWqfo+z7z/XUoO5YYZ1v/6zpx+dzOpYCMc5mODvLhFGBLHxxrvSoAmAAzXwFq ZLWw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=nAqcHY80; 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 w14si482183qki.211.2020.03.10.23.44.53 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 10 Mar 2020 23:44:53 -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=nAqcHY80; 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]:46170 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jBv6q-00068B-UQ for patch@linaro.org; Wed, 11 Mar 2020 02:44:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59301) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jBv6Q-000665-Es for qemu-devel@nongnu.org; Wed, 11 Mar 2020 02:44:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jBv6O-0001f1-Hm for qemu-devel@nongnu.org; Wed, 11 Mar 2020 02:44:26 -0400 Received: from mail-pg1-x541.google.com ([2607:f8b0:4864:20::541]:38245) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jBv6O-0001cs-Cw for qemu-devel@nongnu.org; Wed, 11 Mar 2020 02:44:24 -0400 Received: by mail-pg1-x541.google.com with SMTP id x7so639014pgh.5 for ; Tue, 10 Mar 2020 23:44:24 -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:in-reply-to:references :mime-version:content-transfer-encoding; bh=ME4wdyObWWzU36JOWOP068GfXM/kHUGKiy3+FE+Caek=; b=nAqcHY80e4ejxIJMyR8NQ/oenp6q+JKoqoSjzsnDo3V0irsukHBJXuIFSZMeH2FA91 nqThih0v1cRFxjbr0+jn2U6EUvJt+351gAGkWdsQAusWjD+k7ZaTRrMfVcBzFUqudBDs 22boIFp7rItiG50EB5sHmTOm72nPPhIJS06g+UEHGhfUS73ZT/FP6OTlWitNLXQlBEzr 7TVgPHIA4hzZx87mHNTDbqn3DTtgSD9DTLzNLd578xOMPPNqmAivDyftR8KhKM84zPxh OVkWZsWp3ZHMK9Ce/V6QQEVWr58hC6Lnr3t+DW6KHbHRF0DdT54SXtBgkpMQSNF8FK7z LIfw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ME4wdyObWWzU36JOWOP068GfXM/kHUGKiy3+FE+Caek=; b=nU5XCeWwXbqhto6JeU5oamSSXxTywmXgW6mm5lolLlmn26B1EiR7DOqggSL5AMxzVd VeFi/l2VU+9eCpMlD50VHsizCC/ZGbB2tIJ6kRp7lrWHJSDsnITp0m86q2W8CRiPiSdI /4ZOw7Z630bQ0sbqSj3+XmZW7RHwkpkqJ3UV0sHzCCDlzKGZiJ8fJwFdtbZ8JZBH8QzN jt5ucceGpM5Ngu8oOA221MKBTZlra12d2ivv/EfJ//t2yZMV6/GCTQQpH1kuBcnxj2RX Immfv2yJ6TyCD+nIqXX+f5WOIelmrwkYnL2okQWLnMBluTZpN2Vjc+Q30/BOgnOuK31E maJw== X-Gm-Message-State: ANhLgQ26GrGurwQBKKAYmJF1gs+xc7ZpaBFw65gdeS+BsAXTabOLp9cx 3tubebmVIU3TfBmQye0euEnr+4TlD7w= X-Received: by 2002:a62:7cc9:: with SMTP id x192mr767250pfc.176.1583909062988; Tue, 10 Mar 2020 23:44:22 -0700 (PDT) Received: from localhost.localdomain (97-126-123-70.tukw.qwest.net. [97.126.123.70]) by smtp.gmail.com with ESMTPSA id z3sm50137807pfz.155.2020.03.10.23.44.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Mar 2020 23:44:22 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH 01/16] accel/tcg: Add block comment for probe_access Date: Tue, 10 Mar 2020 23:44:05 -0700 Message-Id: <20200311064420.30606-2-richard.henderson@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200311064420.30606-1-richard.henderson@linaro.org> References: <20200311064420.30606-1-richard.henderson@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::541 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: peter.maydell@linaro.org, qemu-arm@nongnu.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Richard Henderson --- include/exec/exec-all.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) -- 2.20.1 Reviewed-by: Peter Maydell diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h index 350c4b451b..d656a1f05c 100644 --- a/include/exec/exec-all.h +++ b/include/exec/exec-all.h @@ -330,6 +330,23 @@ static inline void tlb_flush_by_mmuidx_all_cpus_synced(CPUState *cpu, { } #endif +/** + * probe_access: + * @env: CPUArchState + * @addr: guest virtual address to look up + * @size: size of the access + * @access_type: read, write or execute permission + * @mmu_idx: MMU index to use for lookup + * @retaddr: return address for unwinding + * + * Look up the guest virtual address @addr. Raise an exception if the + * page does not satisfy @access_type. Raise an exception if the + * access (@addr, @size) hits a watchpoint. For writes, mark a clean + * page as dirty. + * + * Finally, return the host address for a page that is backed by RAM, + * or NULL if the page requires I/O. + */ void *probe_access(CPUArchState *env, target_ulong addr, int size, MMUAccessType access_type, int mmu_idx, uintptr_t retaddr);